My hardware:
- CPU i7-10700
- 16GB RAM
- AMD RX6400 GPU
- ASUS B460-I / UEFI
Prior to Fedora 42 my machine was able to immediately suspend to RAM when instructed.
On Fedora 42 when the suspend was initiated, my screen would tear/have artifacts (similar to a memory error), and would still be operational but with tremendous lag. After 1 or 2 minutes it would finally suspend.
I cannot say with certainty what the default suspend state is, but looking through https://www.kernel.org/doc/Documentation/power/states.txt, the sleep state I was looking for/expected is “deep”:
State: Suspend-to-RAM
ACPI State: S3
Label: "deep"
This state, if supported, offers significant power savings as everything in the
system is put into a low-power state, except for memory, which should be placed
into the self-refresh mode to retain its contents. All of the steps carried out
when entering Power-On Suspend are also carried out during transitions to STR.
Additional operations may take place depending on the platform capabilities. In
particular, on ACPI systems the kernel passes control to the BIOS (platform
firmware) as the last step during STR transitions and that usually results in
powering down some more low-level components that aren't directly controlled by
the kernel.
System and device state is saved and kept in memory. All devices are suspended
and put into low-power states. In many cases, all peripheral buses lose power
when entering STR, so devices must be able to handle the transition back to the
"on" state.
For at least ACPI, STR requires some minimal boot-strapping code to resume the
system from it. This may be the case on other platforms too.
Solution
After checking that my system supported the “deep” sleep state, I created /etc/systemd/sleep.conf
A new configuration file /etc/systemd/sleep.conf has been
added that may be used to configure which kernel operation
systemd is supposed to execute when “suspend”, “hibernate”
or “hybrid-sleep” is requested. This makes the new kernel
“freeze” state accessible to the user.
with the contents:
[Sleep]
SuspendState=mem
AllowSuspend=yes
MemorySleepMode=deep
SuspendState
value was chosen from the contents of /sys/power/state
MemorySleepMode
value was chosen from the contents of /sys/power/mem_sleep
The meaning of the “mem” string is controlled by the /sys/power/mem_sleep file.
It contains strings representing the available modes of system suspend that may
be triggered by writing “mem” to /sys/power/state.
More information can be found on the same “System Power Management Sleep States” [1] page
After reboot (possibly not needed?) my machine suspends instantly again without issue.
Hopefully this is helpful to others!