Update hw.power whenever we refresh the AC state. This makes sure the state
authorkettenis <kettenis@openbsd.org>
Mon, 21 Mar 2022 13:38:34 +0000 (13:38 +0000)
committerkettenis <kettenis@openbsd.org>
Mon, 21 Mar 2022 13:38:34 +0000 (13:38 +0000)
commitba27658807ea823622cfd6c4ddce7f48c4ce97fb
treee90930a5dd57e10642910705f2632816417ba2d9
parent2970de9e9ca1c861104fe3d9b730a62c0ee2cea6
Update hw.power whenever we refresh the AC state.  This makes sure the state
doesn't get out of sync with what apm(8) reports if power is plugged or
unplugged when a machine is suspended.  Which in turn makes sure the machine
properly goes into a low CPU P-state when requested.

ok deraadt@, florian@
sys/dev/acpi/acpiac.c