tizen 2.4 release
[kernel/u-boot-tm1.git] / arch / arm / cpu / arm926ejs / sc8800x / watchdog.c
1 #include <config.h>
2 #include <asm/io.h>
3 #include <asm/arch/regs_global.h>
4 #include <asm/arch/bits.h>
5 #include <linux/types.h>
6 #include <asm/arch/regs_wdg.h>
7
8 void start_watchdog(uint32_t init_time_ms)
9 {
10 }
11
12 void stop_watchdog(void)
13 {
14         
15         //Enable watchdog programming
16         REG32(GR_GEN0) |=GEN0_WDG_EN;
17         REG32(GR_CLK_EN) &= ~0x04;
18         //Unlock watchdog load rigiter
19         REG32(WDG_LOCK) = 0x1ACCE551;
20         //clear watchdog interrupt
21         REG32(WDG_INT_CLR) = 1;
22
23         //Disable watchdog timer clock and interrupt mode
24         REG32(WDG_CTL) &= ~(BIT_1  | BIT_0);
25         //lOCK WATCH DOG 
26         REG32(WDG_LOCK) = 0x12345678;
27         //Disable watchdog programming
28         REG32(GR_GEN0) &= ~GEN0_WDG_EN;
29 }
30
31 void init_watchdog(void)
32 {
33
34 }
35
36 void feed_watchdog(void)
37 {
38 }
39
40 void load_watchdog(uint32_t time_ms)
41 {
42 }
43 void hw_watchdog_reset(void)
44 {
45 }