Refresh ACPI APM and PMU devices on resume

Richard Hughes hughsient at
Thu Mar 30 00:45:41 PST 2006

The attached patch makes selected HAL devices Rescan() on resume.

We need this patch so that ACPI does not get confused when we resume, as
often it forgets the state of it's own batteries.

It especially forgets the value of the lid (frequently), which really
confuses gnome-power-manager and causes really odd effects on resume.

You can test this snippet of code if you stop the acpid service, wait a
while on battery, and then run the code -- there should be a flurry of
BATx updates.

Also a common problem this patch should fix, is when you suspend and
resume, HAL takes a few seconds to realise that there is a battery

Does this look okay to commit?

-------------- next part --------------
A non-text attachment was scrubbed...
Name: hal-refresh-on-resume-local.patch
Type: text/x-patch
Size: 1377 bytes
Desc: not available
Url :

More information about the hal mailing list