HomeFreeBSD

acpi: Add back `hw.acpi.suspend_state` sysctl

Description

acpi: Add back hw.acpi.suspend_state sysctl

When writing an ACPI S-state to it it will set kern.power.suspend to the
appropriate sleep type, and when reading from it it will return the
corresponding ACPI S-state to the sleep type in kern.power.suspend.

This is deprecated and kern.power.suspend should be used directly
instead, but add this back because zzz(1) makes use of this and we can't
easily rewrite it just now.

PR: 289634
Reviewed by: cy, markj
Approved by: cy, markj
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D52600
Event: EuroBSDcon 2025 Devsummit

Details

Provenance
obiwacAuthored on Sep 26 2025, 3:49 PM
Reviewer
cy
Differential Revision
D52600: acpi: Add back `hw.acpi.suspend_state` sysctl
Parents
rG97d152698f48: acpi: Use sleep types defined in sys/power.h
Branches
Unknown
Tags
Unknown