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的更多相关文章

  1. learning uboot support web http function in qca4531 cpu

    reference :https://forum.openwrt.org/viewtopic.php?id=43237 reference :http://blog.chinaunix.net/uid ...

  2. 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 ...

  3. learning uboot enable protect console

    reference :https://github.com/lentinj/u-boot/blob/master/doc/README.autoboot how to enable protect s ...

  4. 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 ...

  5. learning uboot test command

    uboot commad test test - minimal test like /bin/sh so we can use test command to some judge for exam ...

  6. learning uboot distro design in am335x-evm board

    reference: uboot_dir/doc/README.distro Linux distributions are faced with supporting a variety of bo ...

  7. learning uboot switch to standby system using button

    pseudocode: If(reset_button was pressed ) { Change  uboot env bootslot^1 }

  8. learning uboot source command

    reference: http://www.denx.de/wiki/DULG/UBootCmdGroupExec => help source source - run script from ...

  9. learning uboot fstype command

    => fstypefstype - Look up a filesystem type Usage:fstype <interface> <dev>:<part&g ...

随机推荐

  1. Win32 API编程:使用CreateProcess创建新进程

    #include <windows.h> #include <tchar.h> #include <stdio.h> int main(int argc, char ...

  2. 如何Python写一个安卓APP

    前言:用Python写安卓APP肯定不是最好的选择,但是肯定是一个很偷懒的选择,而且实在不想学习Java,再者,就编程而言已经会的就Python与Golang(注:Python,Golang水平都一般 ...

  3. 【第二十章】 springboot + consul(1)

    consul的具体安装与操作查看博客的consul系列. 一.启动consul (1个server+1个client,方便起见,client使用本机):查看:http://www.cnblogs.co ...

  4. 事务(Transaction)

    1.演示转账的功能:(1)创建一张表示学生表表 CREATE TABLE student( id INT PRIMARY KEY AUTO_INCREMENT,name VARCHAR(50), ac ...

  5. Android Studio下载新的AVD映像把C盘给占满了

    不管你的Android SDK/Studio安装哪儿, 默认总是下载到 C:\Users\Administrator\.android ... 可以设置ANDROID_SDK_HOME 指定到新的目录 ...

  6. LA 4254 处理器(二分+贪心)

    https://icpcarchive.ecs.baylor.edu/index.php?option=com_onlinejudge&Itemid=8&page=show_probl ...

  7. MUI --- 多个页面之间的传值 A页面B 页面 C页面

    问题: 夸页面传值的,A.B.C三个页面,点A弹出B,C是B子页面;A有两个值要传到C页面中,要怎么样传递呢? A页面传值就不累述了 B页面才是关键 mui.plusReady(function() ...

  8. MVC ---- 如何使用Action委托

    先建立一个Serven 类 public class Seven { public static void TestSeven1() { List<User> userList = Fiv ...

  9. 利用JSP中的过滤器解决中文乱码问题

    首先我们创建过过滤器: package com.gbx; import java.io.IOException; import javax.servlet.Filter; import javax.s ...

  10. Windows 2003 server下载

    http://www.downza.cn/soft/182837.html或http://www.imsdn.cn/operating-systems/windows-server-2003/