[ltp] belt & suspenders suspend-to-ram script for acpid

Florian Reitmeir linux-thinkpad@linux-thinkpad.org
Fri, 23 Jun 2006 11:48:23 +0200


On Fre, 23 Jun 2006, Richard Neill wrote:

> >>Ah. Could it be that you have the BIOS configured to suspend on 
> >>lid-close? The BIOS's internal suspend-logic is independent of ACPI!
> >There is no "BIOS's internal suspend-logic" if ACPI is in use. Thats all
> >about ACPI, not using the BIOS to make things happen.
> >
> >APM = everything does the BIOS
> >ACPI = everthing does the OS
> Thanks for the correction. Still, at least on my A22p, I normally have 
> suspend working thus:
> 
>   lid-close -> ACPI event -> acpi sleep script -> suspend to RAM.
>     -> open lid -> wake.
> 
> BUT, if I also have "suspend on lid close" enabled in the BIOS, the 
> machine either sleeps again immediately after waking (and needs to be 
> woken twice), or crashes.
> 
> So the BIOS certainly does something as well as the OS. Maybe the BIOS 
> does an APM suspend while the OS does an ACPI suspend?
> 
> The A22 is an odd machine in that it seems to do both apm and acpi; you 
> can choose, although neither is done well.

I've seen notebooks which send the LID-close-event twice. So maybe you get
other after resume. In my ACPI scripts i test before suspend
the LID state (somewhere in /proc/acpi/.../LID).

-- 
Florian Reitmeir