RK3588/RK3576 Suspend-Resume Issues
It currently appears as if suspend/resume on RK3576 is broken. It's possible that it's broken on RK3588 as well (to be determined). This was discovered by !39
Some observations:
- on the sige5, with an rtc battery hooked up and a time set, we do actually receive an interrupt (check
/proc/interrupts
) withrtcwake rtc0 -m on -s 60
. - while suspending does not produce any suspicious output even with
no_console_suspend
in the kernel params, the device never resumes - the HYM8563 only has a one minute resolution, so "proper" testing of suspend-resume is going to take you at least one minute. rtcwake will totally let you pass a number of seconds less than 60, and the rtc driver will totally not actually enable the interrupt but let the system go to sleep anyway, so I don't recommend doing this.
- the very similar PCF8563 had some thing relating to wakeup changed in 2024 that hym8563 lacks, but experimentally doing the same thing didn't make it magically work for me, so I'm assuming we are not "some platforms".
- the x86 way of debugging suspend/resume by stowing some values away in the RTC memory isn't available on arm64, or at least not hooked up, so
Documentation/power/s2ram.rst
is probably not very useful. (But it is 2006 era Linus material that immediately opens up by throwing some person named "Chuck" under the bus.) -
Documentation/power/basic-pm-debugging.rst
links to http://suspend.sf.net but this seems to be from 2011 and maybe it's x86 specific, who knows. I think the thing it does is now done by systemd and is unrelated to debugging this, so I'm not sure why it's being linked to. - In the end we might end up having to squirrel some ftrace buffer into a persistent-across-hot-reboots memory region to debug this fully, unless there's a way to dump ftrace output to console and keep the console awake for as long as possible
Also, I have a trillion CR2032 cases and the right connectors for the Sige5 to plug those in, so if we need some for the CI lab I can make them but it might be cheaper to just get the 2-pin JST SUR connector and a CR2032 case locally. Armsom doesn't appear to sell any officially at least as far as I can tell. The schematic has a diode in line, so I don't think it charges the battery.
Edited by Nicolas Frattaroli