diff options
| author | Aymeric Wibo <obiwac@FreeBSD.org> | 2026-10-13 21:20:23 +0000 |
|---|---|---|
| committer | Aymeric Wibo <obiwac@FreeBSD.org> | 2026-10-13 21:21:26 +0000 |
| commit | cd96657b6708e42caa55531f8118bff6dcb38769 (patch) | |
| tree | a0f158d61efb6c9a532b2eab55fdebaa3763c5cc | |
| parent | 84f790e5b6ccca9d7253834b7dcac5f4432b2917 (diff) | |
amdsmu: Print how long system spent in S0i3
It's practical to have this printed out proactively, at least while this
is still very experimental.
Sponsored by: The FreeBSD Foundation
| -rw-r--r-- | sys/dev/amdsmu/amdsmu.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sys/dev/amdsmu/amdsmu.c b/sys/dev/amdsmu/amdsmu.c index 45e5cf7e944d..0e4f0bc17e22 100644 --- a/sys/dev/amdsmu/amdsmu.c +++ b/sys/dev/amdsmu/amdsmu.c @@ -323,8 +323,12 @@ amdsmu_resume_check(device_t dev, enum power_stype stype) if (stype != POWER_STYPE_SUSPEND_TO_IDLE) return; - if (m->s0i3_last_entry_status != 0) + if (m->s0i3_last_entry_status != 0) { + device_printf(dev, + "spent %lu seconds in S0i3 during last suspend\n", + m->time_last_in_s0i3 / 1000000); return; + } device_printf(dev, "failed to enter S0i3 during last suspend; " |
