learning uboot how to enable watchdog in qca4531 cpu
find cpu datasheet , watchdog relate registers:
0x18060008 watchdong timer control
0x1806000c watchdog timer
we can read and write watchdog register under uboot console:
#mw 0x1806000c 0xffffffff 1
#mw 0x1806000c 0x10000000 1
#mw 0x18060008 0x3 1
#md 0x18060008 1
#md 0x1806000c 1
// init watchdog function
//init watchdog timer
//int watchdon timer
control
// watchdog action bit[1:0]
#define No_action 0
#define General_purpose_interrupt 1
#define Non_maskable_interrupt 2
#define Full_chip_reset 3
#define WATCHDOG_TIMER_CONTROL 0x18060008
#define WATCHDOG_TIMER 0x1806000c
void enable_watchdog(){
ath_reg_wr(WATCHDOG_TIMER,0xffffffff);
ath_reg_wr(WATCHDOG_TIMER_CONTROL, Full_chip_reset);
}
void disable_watchdog(){
ath_reg_wr(WATCHDOG_TIMER_CONTROL, No_action);
}
void feed_watchdog(){
ath_reg_wr(WATCHDOG_TIMER,0xffffffff);
}
after we encapsulated watchdog interface; we can enable watchdog in the uboot bootup stage
learning uboot how to enable watchdog in qca4531 cpu的更多相关文章
- learning uboot support web http function in qca4531 cpu
reference :https://forum.openwrt.org/viewtopic.php?id=43237 reference :http://blog.chinaunix.net/uid ...
- learning uboot auto switch to stanbdy system in qca4531 cpu
design: when uboot load kerne failed,we can switch to stanbdy system; how to realize: when boot fail ...
- learning uboot enable protect console
reference :https://github.com/lentinj/u-boot/blob/master/doc/README.autoboot how to enable protect s ...
- learning uboot how to set ddr parameter in qca4531 cpu
DDR工作频率 在600MHZ. include/configs/board953x.h #define CFG_PLL_FREQ CFG_PLL_650_600_200 #d ...
- learning uboot test command
uboot commad test test - minimal test like /bin/sh so we can use test command to some judge for exam ...
- learning uboot distro design in am335x-evm board
reference: uboot_dir/doc/README.distro Linux distributions are faced with supporting a variety of bo ...
- learning uboot switch to standby system using button
pseudocode: If(reset_button was pressed ) { Change uboot env bootslot^1 }
- learning uboot source command
reference: http://www.denx.de/wiki/DULG/UBootCmdGroupExec => help source source - run script from ...
- learning uboot fstype command
=> fstypefstype - Look up a filesystem type Usage:fstype <interface> <dev>:<part&g ...
随机推荐
- compile vi from source code
1.install ncurses library (vi depend on ncurses library) ./configure --prefix=/usr --with-termlib m ...
- windows10下cygwin安装神器apt-cyg
一.背景 需要在cygwin下安装一些库 二.安装 2.1获取apt-cyg源码 git clone https://github.com/transcode-open/apt-cyg.git 2.2 ...
- hdu4528 小明系列故事——捉迷藏(记录状态的BFS)题解
思路: 一道BFS题,和以前的BFS有点不同,这里的vis数组需要记录每次走时的状态,所以开了3维,只对该状态下的vis修改. 注意坑点:S的位置是可以走的 代码: #include<queue ...
- printf("%f\n",5);
http://zhidao.baidu.com/link?url=87OGcxtDa6fQoeKmk1KylLu4eIBLJSh7CA3n5NWY-Ipm9TxZViFnIui307duCXWhaM0 ...
- BZOJ4401: 块的计数 思维题
Description 小Y最近从同学那里听说了一个十分牛B的高级数据结构——块状树.听说这种数据结构能在sqrt(N)的时间内维护树上的各种信息,十分的高效.当然,无聊的小Y对这种事情毫无兴趣,只是 ...
- 3、CommonChunkPlugin提取公共js-以提取一个jquery为例
cnpm install css-loader --save-dev //css-loader 是将css打包进js cnpm install style-loader --save-dev ...
- [SpringBoot] - 上线一份项目记录
首先在服务器上运行war包. (新建项目) 其后,选择数据库,因为之前感觉mysql比较难安装,这次就再试一次,之前的PostgreSQL没有问题. 将原有文件进行复制,排除导包错误. 首先测试邮件发 ...
- YOLO(Darknet官方)训练分类器
目录 1. 分类数据准备 2. Darknet配置 3. Darknet命令使用 4. cifar-10 使用示例 1. 分类数据准备 需要的文件列表: 1. train.list : 训练的图片的绝 ...
- 【Android实验】 UI设计-ListView
目录 实验目的 实验要求 实验内容 实现效果 实验代码 实验总结 实验目的 学习使用ListView 学习使用menu 实验要求 实现一个列表,其中显示班级学号姓名,提供添加功能,如需要删去某一项,长 ...
- 51nod 1444 破坏道路(最短路)
http://www.51nod.com/onlineJudge/questionCode.html#!problemId=1444 题意: 思路: 哇,思路爆炸. 因为每条边的权值都为1,所以可以直 ...