paul%whooppee.com@localhost said:
Please update to rev 1.78 of src/sys/dev/sysmon/sysmon_envsys_events.c
and try again.
Thanks -- I just managed to run low on battery with a new kernel.
I can confirm that the problem is fixed, the box runs well until
graceful shutdown by the "sensor_battery" script.
But -- since my battery was low anyway I did another test, whether
it behaves well if the userland "powerd" is not running. It does not.
I'd expect it to hit the cpu_reboot() call in sysmon_penvsys_event()
eventually, but it did not. It didn't even update the "charge"
value visible in envstat(8) -- this stayed at "6.00%" (this is where
I killed "powerd") even when the red battery LED on my (Dell)
laptop started to light permanently, which happens below 3% (the
"low cap" limit).
This used to work, so there is another regression.