Bug 11919 - apmd does not work
Summary: apmd does not work
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: kernel
Version: 6.2
Hardware: i386
OS: Linux
high
high
Target Milestone: ---
Assignee: Michael K. Johnson
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2000-06-06 05:24 UTC by scot
Modified: 2008-05-01 15:37 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2000-06-12 21:31:03 UTC
Embargoed:


Attachments (Terms of Use)

Description scot 2000-06-06 05:24:55 UTC
apmd does not work on IBM Thinkpad 385D with 2.2.15 kernel; it reports
incorrect AC/Battery status.  This is what it says with the AC cord plugged
into an outlet.  It says the same thing if I unplug the cord from the wall
socket.  I've tried building the latest Rawhide apmd from src rpm but it's
still broken.

$ rpm -qa|grep apmd
apmd-3.0final-3

$ apm -v
APM BIOS 1.2 (kernel driver 1.12)
AC off-line, battery status high: 80%

This model of Thinkpad is limited in that it shows only 10%, 80% or 100%
battery capacity.  Under RedHat 5.2, apm worked ok correctly showing AC or
Battery status.  

'shutdown -h 0' does power the machine off though.

Comment 1 Bernhard Rosenkraenzer 2000-06-12 20:52:21 UTC
This seems to be a kernel issue rather than an apmd issue (apmd does little more
than querying the values reported by the kernel).

Does /proc/apm have the correct value?
Does it work with a different OS or version right now (might be a bug in an
updated BIOS etc)?

Comment 2 scot 2000-06-12 21:31:02 UTC
This is what apm currently reports:  

$ cat /proc/apm 
1.12 1.2 0x03 0x01 0x00 0x01 100% -1 ?

$ apm -v
APM BIOS 1.2 (kernel driver 1.12)
AC on-line, battery status high: 100%

The problem I have is that it still reports "AC on-line" even if I pull the plug
from the wall.  I left the machine unplugged until the battery was almost empty,
and apm still reported "AC on-line".  I think the BIOS is ok because it worked
fine under RedHat 5.2 with 2.0.38 kernel.  Also the BIOS does blink the battery
LED and beeps when the machine is about out of juice; this still happens under
RedHat 6.2 and 2.2.15 kernel but apm doesn't seem to know about it.  

If I start out on AC, boot up, 'apm -v' shows I'm on AC.  I then pull the plug,
'apm -v' still shows on AC.  If I then reboot, as the machine is booting, and
apm starts it shows on-battery.  It would appear that apm is only reading the
power status after a reboot.  I've tried stopping and restarting apmd via init
scripts but that doesn't seem to work.  Only after a reboot does it appear to
know what the current state is.


Comment 3 scot 2000-06-13 05:48:34 UTC
apmd seems to be working now.  Here's what I did: downloaded the latest src.rpm
from rawhide and compiled _on_the_laptop.  I normally do my compiles on another
machine (desktop) and then just install the binary rpms.  In this case, the
other machine does not have apm support in the kernel so, eventhough the binary
rpm builds ok, it doesn't work on my laptop.  Not sure why the original rpm that
came with 6.2 distribution didn't work.

Comment 4 scot 2000-06-13 05:51:23 UTC
p.s. I still use xapm and would like it left in the rpm; I know you're trying to
get rid of fvwm 1, but it's probably the smallest memory footprint of the window
managers out there.  I've been using it since RedHat 3.03 and swear by it.


Note You need to log in before you can comment on or make changes to this bug.