[ltp] ACPI & APM Confused

Franz Rühmland linux-thinkpad@linux-thinkpad.org
Mon, 01 Mar 2004 18:30:30 +0100


> I have a T41p. I'm using all ACPI, suspened (FN+F?) doesn't work at all. Is
> APM generally more reliable? What features work in APM that don't work in
> ACPI and vice versa? 

Well, One killer feature I believe in ACPI is C3 power mode for the CPU. 
I don't think this works in apm. That will probably make the battery 
last a lot longer. (Don't know how much or if there are any problems 
with it on the T41:s) Basically, I don't really know... :). Someone, 
please correct me of I'm wrong.

To get the buttons to work, fn+f4, the lid and the power button are the 
only ones I got events for in ACPI, you have to define what the computer 
should do after getting the events. ('cat /proc/acpi/event' to look at 
what's happening.) This can be done with acpid.
(I take it you mean nothing happens when you push the buttons.)

To suspend to RAM do 'echo -n mem > /sys/power/state' or 'echo -n 3 > 
/proc/acpi/sleep' depending on kernel version and what you have compiled in.

To suspend to disk do 'echo -n disk > /sys/power/state' or 'echo -n 4 > 
/proc/acpi/sleep' instead. You also have to pass 
resume=/dev/hd$SWAP_PARTITION_GOES_HERE to the kernel at boot to get it 
to resume from disk.

I doubt you will have much luck with getting it to resume ok, though.
For me the USB borks completely and I get neverending messages about it 
not working to every virtual terminal. I have heard several other people 
  with this experience too. I don't think the wlan came back up either, 
but I'm not sure. Also I didn't get any button events after a suspend. 
Never checked if battery events worked though.

APM on the other hand has been 100% reliable for me. T41 1400MHz 
(2373-2FG) Using kernel 2.6.3-gentoo-r1 patched with laptop-mode and 
using powernowd to handle cpufreq. I get ~3h battery time with a 6 cell 
battery, backlight turned down, using wlan, laptop-mode and CPU at 
600MHz. If anyone know how to increase battery time, please do tell.

I'm using the Phoenix-bios to hibernate. Just make sure you compile USB 
drivers (uhci_hcd & ehci_hcd) as modules and unload them at suspend and, 
of course reload them at resume.  I also unload the ndiswrapper module 
for the intel 2100 wlan card.
Closing the lid, Fn+* all works as expected.

I don't know about the pcmcia or bluetooth, simply because I don't have 
any devices to test it with.

I use apmd to detect apm events and have written some scripts to take 
care of the unloading and loading of modules. I have also scripts to 
handle toggling of laptop_mode and powernowd settings when I switch 
between battery and AC.