RISC-V With Linux 6.4 Adds Hibernation / Suspend-To-Disk Support

Written by Michael Larabel in RISC-V on 6 May 2023 at 08:16 AM EDT. Add A Comment
RISC-V
One of the missing RISC-V features now in place for the in-development Linux 6.4 kernel is system hibernation / suspend-to-disk support.

In development the past number of months and going through a number of rounds of review is RISC-V hibernation/suspend-to-disk support. From the earlier patch series:
"To enable hibernation/suspend to disk into RISCV, the below config need to be enabled:

- CONFIG_HIBERNATION
- CONFIG_ARCH_HIBERNATION_HEADER
- CONFIG_ARCH_HIBERNATION_POSSIBLE

At high-level, this series includes the following changes:
1) Change suspend_save_csrs() and suspend_restore_csrs() to public function as these functions are common to suspend/hibernation.
2) Refactor the common code in the __cpu_resume_enter() function and __hibernate_cpu_resume() function. The common code are used by hibernation and suspend.
3) Enhance kernel_page_present() function to support huge page.
4) Add arch/riscv low level functions to support hibernation/suspend to disk.

The above patches are based on kernel v6.3-rc4 and have been tested on StarFive VF2 SBC board and Qemu (using raw disk format). ACPI platform mode is not supported in this series."

VisionFive 2


The RISC-V hibernation support in turn was submitted on Friday as part of additional RISC-V patches for Linux 6.4.
Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com.

Popular News This Week