我使用DM355,系统是linux-2.6.10. 在实现deep sleep时发现只要关闭ddr,系统就会死掉。deep sleep的功能是从3.1.2版本上抄过来的,睡眠的函数会拷贝到DTCM里去。在启动的时候,我使用如下语句使能了DTCM.
tmp = 0x10019;
asm volatile ("mcr p15, 0, %0, c9, c1, 0" : : "r" (tmp));
现在只要disable PSC 的 module 13, 系统就挂住了。
请问该如何处理?
VampireDaVinci:
1. DDR的时钟是否也同时关掉了?
Tuff Li:
回复 VampireDaVinci:
Deep sleep不是这样简单的,首先要把所有的ddr操作都停掉,保存现场,然后程序跳转到TCM的,然后让DDR自刷新
Feng Dong:
回复 Tuff Li:
usually you need some code in internal ram for deep sleep save context operation and resume context operation.
By the way usually you need run WFI as the lastest code before sleep.
You can not run code in DDR if you set DDR in self refresh.