RK3568-rk809rtc休眠唤醒
参考链接
https://www.360doc.cn/article/71858349_1119199262.html
修改驱动drivers/mfd/rk808.c
static void rk817_shutdown_prepare(void)
{
int ret;
struct rk808 *rk808 = i2c_get_clientdata(rk808_i2c_client);
/* close int when power off */
regmap_update_bits(rk808->regmap,
RK817_INT_STS_MSK_REG0,
- 0xff, 0xff);
+ 0xff, 0x9f);
regmap_update_bits(rk808->regmap,
RK817_INT_STS_MSK_REG1,
0xff, 0xff);
regmap_update_bits(rk808->regmap,
RK817_INT_STS_MSK_REG2,
0xff, 0xff);
regmap_update_bits(rk808->regmap,
RK817_RTC_INT_REG,
- (0x3 << 2), (0x0 << 2));
+ (0x3 << 2), (0x3 << 2));
测试验证
echo +60 > /sys/class/rtc/rtc0/wakealarm 去设置60秒后开机
然后echo freeze > /sys/power/state等待开机
RTC唤醒时间是从执行echo +60 > /sys/class/rtc/rtc0/wakealarm 起算
原文地址:https://blog.csdn.net/qq_42952079/article/details/145067870
免责声明:本站文章内容转载自网络资源,如本站内容侵犯了原著者的合法权益,可联系本站删除。更多内容请关注自学内容网(zxcms.com)!