diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-08-11 13:42:43 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-08-11 13:42:43 -0400 |
commit | 3f1ae223902834d81b54b5d333f9efca07ad656b (patch) | |
tree | dd03e325404fc03692ffd1cd9f4d83ad89584d69 /drivers | |
parent | e2205a156f4dd727097f7f492bf03aa8920b0071 (diff) | |
parent | 36cbaa8777dd5a79cb56c2a3d7d56f0c80b2bab6 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog
* git://git.kernel.org/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog:
[WATCHDOG] pcwd.c - fix open_allowed type.
[WATCHDOG] fix watchdog/ixp4xx_wdt.c compilation
[WATCHDOG] fix watchdog/wdt285.c compilation
[WATCHDOG] fix watchdog/at91rm9200_wdt.c compilation
[WATCHDOG] fix watchdog/shwdt.c compilation
[WATCHDOG] fix watchdog/txx9wdt.c compilation
[WATCHDOG] MAINTAINERS: remove ZF MACHZ WATCHDOG entry
[WATCHDOG] Fix build with CONFIG_ITCO_VENDOR_SUPPORT=n
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/watchdog/Makefile | 5 | ||||
-rw-r--r-- | drivers/watchdog/at91rm9200_wdt.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/ixp4xx_wdt.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/pcwd.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/shwdt.c | 24 | ||||
-rw-r--r-- | drivers/watchdog/txx9wdt.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/wdt285.c | 2 |
7 files changed, 21 insertions, 18 deletions
diff --git a/drivers/watchdog/Makefile b/drivers/watchdog/Makefile index 049c91895699..ca3dc043d786 100644 --- a/drivers/watchdog/Makefile +++ b/drivers/watchdog/Makefile | |||
@@ -66,7 +66,10 @@ obj-$(CONFIG_IB700_WDT) += ib700wdt.o | |||
66 | obj-$(CONFIG_IBMASR) += ibmasr.o | 66 | obj-$(CONFIG_IBMASR) += ibmasr.o |
67 | obj-$(CONFIG_WAFER_WDT) += wafer5823wdt.o | 67 | obj-$(CONFIG_WAFER_WDT) += wafer5823wdt.o |
68 | obj-$(CONFIG_I6300ESB_WDT) += i6300esb.o | 68 | obj-$(CONFIG_I6300ESB_WDT) += i6300esb.o |
69 | obj-$(CONFIG_ITCO_WDT) += iTCO_wdt.o iTCO_vendor_support.o | 69 | obj-$(CONFIG_ITCO_WDT) += iTCO_wdt.o |
70 | ifeq ($(CONFIG_ITCO_VENDOR_SUPPORT),y) | ||
71 | obj-$(CONFIG_ITCO_WDT) += iTCO_vendor_support.o | ||
72 | endif | ||
70 | obj-$(CONFIG_IT8712F_WDT) += it8712f_wdt.o | 73 | obj-$(CONFIG_IT8712F_WDT) += it8712f_wdt.o |
71 | obj-$(CONFIG_HP_WATCHDOG) += hpwdt.o | 74 | obj-$(CONFIG_HP_WATCHDOG) += hpwdt.o |
72 | obj-$(CONFIG_SC1200_WDT) += sc1200wdt.o | 75 | obj-$(CONFIG_SC1200_WDT) += sc1200wdt.o |
diff --git a/drivers/watchdog/at91rm9200_wdt.c b/drivers/watchdog/at91rm9200_wdt.c index bacd867dd22e..d061f0ad2d20 100644 --- a/drivers/watchdog/at91rm9200_wdt.c +++ b/drivers/watchdog/at91rm9200_wdt.c | |||
@@ -128,7 +128,7 @@ static struct watchdog_info at91_wdt_info = { | |||
128 | /* | 128 | /* |
129 | * Handle commands from user-space. | 129 | * Handle commands from user-space. |
130 | */ | 130 | */ |
131 | static long at91_wdt_ioct(struct file *file, | 131 | static long at91_wdt_ioctl(struct file *file, |
132 | unsigned int cmd, unsigned long arg) | 132 | unsigned int cmd, unsigned long arg) |
133 | { | 133 | { |
134 | void __user *argp = (void __user *)arg; | 134 | void __user *argp = (void __user *)arg; |
diff --git a/drivers/watchdog/ixp4xx_wdt.c b/drivers/watchdog/ixp4xx_wdt.c index 41264a5f1731..8302ef005be7 100644 --- a/drivers/watchdog/ixp4xx_wdt.c +++ b/drivers/watchdog/ixp4xx_wdt.c | |||
@@ -29,7 +29,7 @@ static int nowayout = WATCHDOG_NOWAYOUT; | |||
29 | static int heartbeat = 60; /* (secs) Default is 1 minute */ | 29 | static int heartbeat = 60; /* (secs) Default is 1 minute */ |
30 | static unsigned long wdt_status; | 30 | static unsigned long wdt_status; |
31 | static unsigned long boot_status; | 31 | static unsigned long boot_status; |
32 | static spin_lock_t wdt_lock; | 32 | static DEFINE_SPINLOCK(wdt_lock); |
33 | 33 | ||
34 | #define WDT_TICK_RATE (IXP4XX_PERIPHERAL_BUS_CLOCK * 1000000UL) | 34 | #define WDT_TICK_RATE (IXP4XX_PERIPHERAL_BUS_CLOCK * 1000000UL) |
35 | 35 | ||
diff --git a/drivers/watchdog/pcwd.c b/drivers/watchdog/pcwd.c index 3b0ddc7fcf3f..9e1331a3b215 100644 --- a/drivers/watchdog/pcwd.c +++ b/drivers/watchdog/pcwd.c | |||
@@ -168,7 +168,7 @@ static const int heartbeat_tbl[] = { | |||
168 | static int cards_found; | 168 | static int cards_found; |
169 | 169 | ||
170 | /* internal variables */ | 170 | /* internal variables */ |
171 | static atomic_t open_allowed = ATOMIC_INIT(1); | 171 | static unsigned long open_allowed; |
172 | static char expect_close; | 172 | static char expect_close; |
173 | static int temp_panic; | 173 | static int temp_panic; |
174 | 174 | ||
diff --git a/drivers/watchdog/shwdt.c b/drivers/watchdog/shwdt.c index 824125adf90a..cdc7138be301 100644 --- a/drivers/watchdog/shwdt.c +++ b/drivers/watchdog/shwdt.c | |||
@@ -30,7 +30,7 @@ | |||
30 | #include <linux/mm.h> | 30 | #include <linux/mm.h> |
31 | #include <linux/io.h> | 31 | #include <linux/io.h> |
32 | #include <linux/uaccess.h> | 32 | #include <linux/uaccess.h> |
33 | #include <linux/watchdog.h> | 33 | #include <asm/watchdog.h> |
34 | 34 | ||
35 | #define PFX "shwdt: " | 35 | #define PFX "shwdt: " |
36 | 36 | ||
@@ -68,7 +68,7 @@ static int clock_division_ratio = WTCSR_CKS_4096; | |||
68 | static void sh_wdt_ping(unsigned long data); | 68 | static void sh_wdt_ping(unsigned long data); |
69 | 69 | ||
70 | static unsigned long shwdt_is_open; | 70 | static unsigned long shwdt_is_open; |
71 | static struct watchdog_info sh_wdt_info; | 71 | static const struct watchdog_info sh_wdt_info; |
72 | static char shwdt_expect_close; | 72 | static char shwdt_expect_close; |
73 | static DEFINE_TIMER(timer, sh_wdt_ping, 0, 0); | 73 | static DEFINE_TIMER(timer, sh_wdt_ping, 0, 0); |
74 | static unsigned long next_heartbeat; | 74 | static unsigned long next_heartbeat; |
@@ -89,7 +89,7 @@ static void sh_wdt_start(void) | |||
89 | __u8 csr; | 89 | __u8 csr; |
90 | unsigned long flags; | 90 | unsigned long flags; |
91 | 91 | ||
92 | spin_lock_irqsave(&wdt_lock, flags); | 92 | spin_lock_irqsave(&shwdt_lock, flags); |
93 | 93 | ||
94 | next_heartbeat = jiffies + (heartbeat * HZ); | 94 | next_heartbeat = jiffies + (heartbeat * HZ); |
95 | mod_timer(&timer, next_ping_period(clock_division_ratio)); | 95 | mod_timer(&timer, next_ping_period(clock_division_ratio)); |
@@ -127,7 +127,7 @@ static void sh_wdt_start(void) | |||
127 | csr &= ~RSTCSR_RSTS; | 127 | csr &= ~RSTCSR_RSTS; |
128 | sh_wdt_write_rstcsr(csr); | 128 | sh_wdt_write_rstcsr(csr); |
129 | #endif | 129 | #endif |
130 | spin_unlock_irqrestore(&wdt_lock, flags); | 130 | spin_unlock_irqrestore(&shwdt_lock, flags); |
131 | } | 131 | } |
132 | 132 | ||
133 | /** | 133 | /** |
@@ -139,14 +139,14 @@ static void sh_wdt_stop(void) | |||
139 | __u8 csr; | 139 | __u8 csr; |
140 | unsigned long flags; | 140 | unsigned long flags; |
141 | 141 | ||
142 | spin_lock_irqsave(&wdt_lock, flags); | 142 | spin_lock_irqsave(&shwdt_lock, flags); |
143 | 143 | ||
144 | del_timer(&timer); | 144 | del_timer(&timer); |
145 | 145 | ||
146 | csr = sh_wdt_read_csr(); | 146 | csr = sh_wdt_read_csr(); |
147 | csr &= ~WTCSR_TME; | 147 | csr &= ~WTCSR_TME; |
148 | sh_wdt_write_csr(csr); | 148 | sh_wdt_write_csr(csr); |
149 | spin_unlock_irqrestore(&wdt_lock, flags); | 149 | spin_unlock_irqrestore(&shwdt_lock, flags); |
150 | } | 150 | } |
151 | 151 | ||
152 | /** | 152 | /** |
@@ -157,9 +157,9 @@ static inline void sh_wdt_keepalive(void) | |||
157 | { | 157 | { |
158 | unsigned long flags; | 158 | unsigned long flags; |
159 | 159 | ||
160 | spin_lock_irqsave(&wdt_lock, flags); | 160 | spin_lock_irqsave(&shwdt_lock, flags); |
161 | next_heartbeat = jiffies + (heartbeat * HZ); | 161 | next_heartbeat = jiffies + (heartbeat * HZ); |
162 | spin_unlock_irqrestore(&wdt_lock, flags); | 162 | spin_unlock_irqrestore(&shwdt_lock, flags); |
163 | } | 163 | } |
164 | 164 | ||
165 | /** | 165 | /** |
@@ -173,9 +173,9 @@ static int sh_wdt_set_heartbeat(int t) | |||
173 | if (unlikely(t < 1 || t > 3600)) /* arbitrary upper limit */ | 173 | if (unlikely(t < 1 || t > 3600)) /* arbitrary upper limit */ |
174 | return -EINVAL; | 174 | return -EINVAL; |
175 | 175 | ||
176 | spin_lock_irqsave(&wdt_lock, flags); | 176 | spin_lock_irqsave(&shwdt_lock, flags); |
177 | heartbeat = t; | 177 | heartbeat = t; |
178 | spin_unlock_irqrestore(&wdt_lock, flags); | 178 | spin_unlock_irqrestore(&shwdt_lock, flags); |
179 | return 0; | 179 | return 0; |
180 | } | 180 | } |
181 | 181 | ||
@@ -189,7 +189,7 @@ static void sh_wdt_ping(unsigned long data) | |||
189 | { | 189 | { |
190 | unsigned long flags; | 190 | unsigned long flags; |
191 | 191 | ||
192 | spin_lock_irqsave(&wdt_lock, flags); | 192 | spin_lock_irqsave(&shwdt_lock, flags); |
193 | if (time_before(jiffies, next_heartbeat)) { | 193 | if (time_before(jiffies, next_heartbeat)) { |
194 | __u8 csr; | 194 | __u8 csr; |
195 | 195 | ||
@@ -203,7 +203,7 @@ static void sh_wdt_ping(unsigned long data) | |||
203 | } else | 203 | } else |
204 | printk(KERN_WARNING PFX "Heartbeat lost! Will not ping " | 204 | printk(KERN_WARNING PFX "Heartbeat lost! Will not ping " |
205 | "the watchdog\n"); | 205 | "the watchdog\n"); |
206 | spin_unlock_irqrestore(&wdt_lock, flags); | 206 | spin_unlock_irqrestore(&shwdt_lock, flags); |
207 | } | 207 | } |
208 | 208 | ||
209 | /** | 209 | /** |
diff --git a/drivers/watchdog/txx9wdt.c b/drivers/watchdog/txx9wdt.c index dbbc018a5f46..6adab77fbbb0 100644 --- a/drivers/watchdog/txx9wdt.c +++ b/drivers/watchdog/txx9wdt.c | |||
@@ -45,7 +45,7 @@ static unsigned long txx9wdt_alive; | |||
45 | static int expect_close; | 45 | static int expect_close; |
46 | static struct txx9_tmr_reg __iomem *txx9wdt_reg; | 46 | static struct txx9_tmr_reg __iomem *txx9wdt_reg; |
47 | static struct clk *txx9_imclk; | 47 | static struct clk *txx9_imclk; |
48 | static DECLARE_LOCK(txx9_lock); | 48 | static DEFINE_SPINLOCK(txx9_lock); |
49 | 49 | ||
50 | static void txx9wdt_ping(void) | 50 | static void txx9wdt_ping(void) |
51 | { | 51 | { |
diff --git a/drivers/watchdog/wdt285.c b/drivers/watchdog/wdt285.c index c8d7f1b2df02..db362c34958b 100644 --- a/drivers/watchdog/wdt285.c +++ b/drivers/watchdog/wdt285.c | |||
@@ -208,7 +208,7 @@ static int __init footbridge_watchdog_init(void) | |||
208 | soft_margin); | 208 | soft_margin); |
209 | 209 | ||
210 | if (machine_is_cats()) | 210 | if (machine_is_cats()) |
211 | printk(KERN_WARN | 211 | printk(KERN_WARNING |
212 | "Warning: Watchdog reset may not work on this machine.\n"); | 212 | "Warning: Watchdog reset may not work on this machine.\n"); |
213 | return 0; | 213 | return 0; |
214 | } | 214 | } |