Unable to wake from hibernation on ls1028 platform

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Unable to wake from hibernation on ls1028 platform

Jump to solution
2,860 Views
Eddy1
Contributor V

Hi:

Recently, we found that we can't wake up from sleep on the ls1028 platform(BSP  OPENIL1.10),

Here are my steps:

echo enabled > /sys/devices/platform/soc/21c0500.serial/tty/ttyS0/power/wakeup

echo mem > /sys/power/state

[ 43.989864] 001: PM: suspend entry (deep)
[ 43.998612] 001: Filesystems sync: 0.008 seconds

[ 64.621811] 001: cfg80211: failed to load regulatory.db
[ 64.623277] 000: Freezing user space processes ...
[ 64.624555] 001: (elapsed 0.001 seconds) done.
[ 64.624559] 001: OOM killer disabled.
[ 64.624562] 001: Freezing remaining freezable tasks ... (elapsed 0.055 seconds) done.
[ 64.680088] 001: printk: Suspending console(s) (use no_console_suspend to debug)

Then I type any character on the keyboard, but i find no response.Could you give me some suggestions to find out this problem?Thanks!

0 Kudos
Reply
1 Solution
2,834 Views
yipingwang
NXP TechSupport
NXP TechSupport

Please use the following command

echo 0 > /sys/class/rtc/rtc1/wakealarm && echo +5 >/sys/class/rtc/rtc1/wakealarm && echo mem > /sys/power/state

View solution in original post

0 Kudos
Reply
11 Replies
2,853 Views
yipingwang
NXP TechSupport
NXP TechSupport

Required fsl,rcpm-wakeup property should be added to a device node if the device
can be used as a wakeup source.

- fsl,rcpm-wakeup: Consists of a phandle to the rcpm node and the IPPDEXPCR
register cells. The number of IPPDEXPCR register cells is defined in
"#fsl,rcpm-wakeup-cells" in the rcpm node. The first register cell is
the bit mask that should be set in IPPDEXPCR0, and the second register
cell is for IPPDEXPCR1, and so on.

Note: IPPDEXPCR(IP Powerdown Exception Control Register) provides a
mechanism for keeping certain blocks awake during STANDBY and MEM, in
order to use them as wake-up sources.

Example:
lpuart0: serial@2950000 {
compatible = "fsl,ls1021a-lpuart";
reg = <0x0 0x2950000 0x0 0x1000>;
interrupts = <GIC_SPI 80 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&sysclk>;
clock-names = "ipg";
fsl,rcpm-wakeup = <&rcpm 0x0 0x40000000>;
};

0 Kudos
Reply
2,843 Views
Eddy1
Contributor V

Hi:

In addition, on the layerscape ls1028a reference design board, the results are the same.

Build image by:

$ cd openil
$ make nxp_ls1028ardb-64b_defconfig

$ make 

The wake-up log:

[root@LS1028ARDB ~] # echo +5 > /sys/class/rtc/rtc1/wakealarm
[root@LS1028ARDB ~] # echo mem > /sys/power/state
[ 77.734072] 001: PM: suspend entry (deep)
[ 77.736608] 001: Filesystems sync: 0.002 seconds
[ 77.737647] 000: Freezing user space processes ... (elapsed 0.001 seconds) done.
[ 77.738885] 000: OOM killer disabled.
[ 77.738888] 000: Freezing remaining freezable tasks ... (elapsed 0.079 seconds) done.
[ 77.818525] 000: printk: Suspending console(s) (use no_console_suspend to debug)
[ 78.461229] 001: rtc-pcf2127-i2c 4-0051: oscillator stop detected, date/time is not reliable

0 Kudos
Reply
2,835 Views
yipingwang
NXP TechSupport
NXP TechSupport

Please use the following command

echo 0 > /sys/class/rtc/rtc1/wakealarm && echo +5 >/sys/class/rtc/rtc1/wakealarm && echo mem > /sys/power/state

0 Kudos
Reply
1,860 Views
PaulGreenwood
Contributor II

Hello,

I've tried the suggested command:

echo 0 > /sys/class/rtc/rtc1/wakealarm && echo +5 >/sys/class/rtc/rtc1/wakealarm && echo mem > /sys/power/state

but it hangs until the watchdog timer reboots the system.
 
I'm on an LS1028ARDB board and running:  NXP LSDK 2108 main (custom based on ubuntu 20.04)
 
Ideas?
0 Kudos
Reply
1,491 Views
PaulGreenwood
Contributor II

After changing OS images, this works but I'm limited to 262 seconds of sleep time.  Any ideas on how to make this longer?

0 Kudos
Reply
2,829 Views
Eddy1
Contributor V

Hi:

Thank you very much for your help.Entering in mem mode by putting your command. And after that MPU  wakes.

0 Kudos
Reply
2,851 Views
Eddy1
Contributor V

Hi:

Thank you for your reply, but it still doesn't work!

0 Kudos
Reply
2,835 Views
yipingwang
NXP TechSupport
NXP TechSupport

I just confirmed with LSDK development team, waking up from UART is not supported.

0 Kudos
Reply
2,751 Views
Eddy1
Contributor V

Hi:

Thank you for your reply. Does it support wake-up from GPIO?I added the wake-up attribute, but it didn't work.

gpio_keys: wakeup_keys@0 {
compatible = "gpio-keys";
user {
label = "User";
gpios = <&gpio3 3 GPIO_ACTIVE_HIGH>;
gpio-key,wakeup;
linux,code = <KEY_1>;
fsl,rcpm-wakeup = <&rcpm 0x0 0x0 0x0 0x0 0x200 0x0 0x0>;
};

};

0 Kudos
Reply
2,731 Views
yipingwang
NXP TechSupport
NXP TechSupport

Please refer to the procedure in page 1308 in LSDK 20.12 user manual.

0 Kudos
Reply
2,724 Views
Eddy1
Contributor V

Hi:

Thank you very much for your help.Now it works.

0 Kudos
Reply