[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: laptop resume and apmd



Bruce Perens writes:

> My hypothesis is that "apmd" is swapped out when the user-suspend signal
> comes in (because there is so little RAM). It takes too long to run, and
> thus the laptop doesn't suspend properly. I also notice that it is logging
> resume, but not suspend.

> Is anyone else experiencing this?

No.  Another guess at what may be happening is that the computer shuts
down during a write to the disk.  AFAIK, the APM BIOS will signal to
apmd that it has received a suspend request, and then wait for a
confirmation that it can perform the actual suspend operation.  If no
confirmation arrives within 20 seconds, it will suspend regardless.

apmd, upon receipt of a suspend request, calls sync, sleeps for 2
seconds, and then signals to the APM BIOS that the machine is ready
for the suspend.  Perhaps these 2 seconds aren't long enough and the
suspend happens during the write to disk.  (Not using apmd means that
the disk isn't sync'ed at all.)

A possible solution might then be to get the sources of apmd and make
it sleep longer before suspending.  The relevant sleep call is found
in the apm_suspend function in apmlib.c.

-- 
Olaf Weber


--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
debian-user-request@lists.debian.org . 
Trouble?  e-mail to templin@bucknell.edu .


Reply to: