git: fcaea1200aad - main - acpi: Implement debug.acpi.suspend_bounce for suspend-to-idle
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 04 Nov 2026 17:43:12 UTC
The branch main has been updated by obiwac:
URL: https://cgit.FreeBSD.org/src/commit/?id=fcaea1200aad79d7c0f7c70e56aae76a34d0abab
commit fcaea1200aad79d7c0f7c70e56aae76a34d0abab
Author: Aymeric Wibo <obiwac@FreeBSD.org>
AuthorDate: 2026-11-02 14:47:20 +0000
Commit: Aymeric Wibo <obiwac@FreeBSD.org>
CommitDate: 2026-11-04 17:42:36 +0000
acpi: Implement debug.acpi.suspend_bounce for suspend-to-idle
Reviewed by: olce
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D61134
---
sys/dev/acpica/acpi.c | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/sys/dev/acpica/acpi.c b/sys/dev/acpica/acpi.c
index ed07ca62382c..b283856ffe52 100644
--- a/sys/dev/acpica/acpi.c
+++ b/sys/dev/acpica/acpi.c
@@ -3641,6 +3641,12 @@ do_idle(struct acpi_softc *sc, enum acpi_sleep_state *slp_state,
register_t rflags)
{
+ if (acpi_susp_bounce) {
+ device_printf(sc->acpi_dev,
+ "debug.acpi.suspend_bounce set; not suspending-to-idle\n");
+ goto bounce;
+ }
+
intr_suspend();
/*
@@ -3660,6 +3666,8 @@ do_idle(struct acpi_softc *sc, enum acpi_sleep_state *slp_state,
cpu_idle(0);
intr_resume(false);
+
+bounce:
intr_restore(rflags);
*slp_state |= ACPI_SS_SLEPT;
}
@@ -3874,7 +3882,7 @@ backout:
EVENTHANDLER_INVOKE(power_resume, stype);
- if (ACPI_SUCCESS(status)) {
+ if (ACPI_SUCCESS(status) && !acpi_susp_bounce) {
if (stype == POWER_STYPE_SUSPEND_TO_IDLE)
check_post_suspend_to_idle(sc->acpi_dev);
EVENTHANDLER_INVOKE(power_resume_check, stype);