Low power mode support in 3.10.9 kernel

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Low power mode support in 3.10.9 kernel

1,911 次查看
krishnanp
Contributor III

Hello,

I need to enable power saving mode on my i.MX6 Solo based board. The board used same  configuration  of sabrelite  with additional PMIC (PF0100  as pmic).

All I need is to  switch the device  to STANDBY mode based on a GPIO interrupt (looks like mem mode is not supported by the kernel)

These are the power state modes supported in my board.

root@imx6qsabrelite:/# cat /sys/power/state

freeze standby mem

I am also able to make  switch  board to STOP mode by  below command.

root@imx6qsabrelite:~# echo standby > /sys/power/state

PM: Syncing filesystems ... done.

Freezing user space processes ... (elapsed 0.01 seconds) done.

...

...

...

PM: Calling sched_clock_suspend+0x0/0x2c

PM: Calling fw_suspend+0x0/0x24

PM: Calling cpufreq_bp_suspend+0x0/0xc4

PM: Calling cpu_pm_suspend+0x0/0x20

How do I configure a GPIO  as the wake up source?

Appreciate your pointers...

Regards,

Krishnan.

标签 (2)
标记 (4)
0 项奖励
回复
2 回复数

925 次查看
AnsonHuang
NXP Employee
NXP Employee

From hardware design perspective, to enable an interrupt as an wakeup source of STOP mode, you just need to ensure this interrupt is triggered and its mask bit in GPC is not set, you can refer to the routine imx_gpc_irq_mask in arch/arm/mach-imx/gpc.c. In kernel, you should call enable_irq_wake before suspend, just as Fabio said, you can refer to the code of gpio-key, drivers/input/keyboard/gpio_keys.c, gpio_keys_suspend.

0 项奖励
回复

925 次查看
fabio_estevam
NXP Employee
NXP Employee

You can use gpio-key,wakeup.

An example is available here:

https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/arch/arm/boot/dts/imx6qdl-sabre...

Regards,

Fabio Estevam

0 项奖励
回复