-
Notifications
You must be signed in to change notification settings - Fork 65
Description
Hi!
Does anyone managed to make Linux sleep/suspend power mode works on a LicheeRV Nano?
There is Linux doc about it.
But by default, there is no /sys/power/state
file (also /sys/power
dir is missed).
Research leads me to the Milk-V forum thread. It seems sleep/suspend works on a Milk-V Duo 256m board with the same SG2002 as in LicheeRV Nano.
Here are Linux configs I managed to found:
# build/boards/sg200x/sg2002_licheervnano_sd/linux/sg2002_licheervnano_sd_defconfig
CONFIG_PM=y
CONFIG_PM_RUNTIME=y
CONFIG_PM_SLEEP=y
CONFIG_SUSPEND=y
CONFIG_SUSPEND_FREEZER=y
# build/boards/sg200x/sg2002_licheervnano_sd/sg2002_licheervnano_sd_defconfig
# both variants have no effect
CONFIG_KERNEL_SUSPEND=y
CONFIG_SUSPEND=y
After rebuild, /sys/power/state
file appears, but it's empty. Also there are no anymore files in /sys/power
dir.
Need help.
PS: I tried to force Linux CPU suspending with SG2002 registers, but after setting RTC_EN_SUSPEND_REQ to 1 (devmem 0x050260E4 32 0x1
) the board instantly dies. So it's impossible to try to make next steps to implement suspending (write to req_suspend register and so on). But it's another story not connected to a Linux, I think.