diff options
author | Russell King <rmk@dyn-67.arm.linux.org.uk> | 2008-08-08 12:33:47 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2008-08-08 14:18:18 -0400 |
commit | 097d9eb537ff4d88b74c3fe67392e27c478ca3c5 (patch) | |
tree | 9034d676d9096857a380aab9d99e3e88fccb6bfe /drivers/watchdog/ep93xx_wdt.c | |
parent | c41107c2d4fd31924533f4dbc4c3428acc2b5894 (diff) | |
parent | aeee90dfa01844168cd7f8051d0a0f969c573067 (diff) |
Merge Linus' latest into master
Conflicts:
drivers/watchdog/at91rm9200_wdt.c
drivers/watchdog/davinci_wdt.c
drivers/watchdog/ep93xx_wdt.c
drivers/watchdog/ixp2000_wdt.c
drivers/watchdog/ixp4xx_wdt.c
drivers/watchdog/ks8695_wdt.c
drivers/watchdog/omap_wdt.c
drivers/watchdog/pnx4008_wdt.c
drivers/watchdog/sa1100_wdt.c
drivers/watchdog/wdt285.c
Diffstat (limited to 'drivers/watchdog/ep93xx_wdt.c')
-rw-r--r-- | drivers/watchdog/ep93xx_wdt.c | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/drivers/watchdog/ep93xx_wdt.c b/drivers/watchdog/ep93xx_wdt.c index af8ef14c0e4c..e9f950ff86ea 100644 --- a/drivers/watchdog/ep93xx_wdt.c +++ b/drivers/watchdog/ep93xx_wdt.c | |||
@@ -28,9 +28,8 @@ | |||
28 | #include <linux/miscdevice.h> | 28 | #include <linux/miscdevice.h> |
29 | #include <linux/watchdog.h> | 29 | #include <linux/watchdog.h> |
30 | #include <linux/timer.h> | 30 | #include <linux/timer.h> |
31 | 31 | #include <linux/uaccess.h> | |
32 | #include <mach/hardware.h> | 32 | #include <mach/hardware.h> |
33 | #include <asm/uaccess.h> | ||
34 | 33 | ||
35 | #define WDT_VERSION "0.3" | 34 | #define WDT_VERSION "0.3" |
36 | #define PFX "ep93xx_wdt: " | 35 | #define PFX "ep93xx_wdt: " |
@@ -136,9 +135,8 @@ static struct watchdog_info ident = { | |||
136 | .identity = "EP93xx Watchdog", | 135 | .identity = "EP93xx Watchdog", |
137 | }; | 136 | }; |
138 | 137 | ||
139 | static int | 138 | static long ep93xx_wdt_ioctl(struct file *file, |
140 | ep93xx_wdt_ioctl(struct inode *inode, struct file *file, unsigned int cmd, | 139 | unsigned int cmd, unsigned long arg) |
141 | unsigned long arg) | ||
142 | { | 140 | { |
143 | int ret = -ENOTTY; | 141 | int ret = -ENOTTY; |
144 | 142 | ||
@@ -156,15 +154,15 @@ ep93xx_wdt_ioctl(struct inode *inode, struct file *file, unsigned int cmd, | |||
156 | ret = put_user(boot_status, (int __user *)arg); | 154 | ret = put_user(boot_status, (int __user *)arg); |
157 | break; | 155 | break; |
158 | 156 | ||
159 | case WDIOC_GETTIMEOUT: | ||
160 | /* actually, it is 0.250 seconds.... */ | ||
161 | ret = put_user(1, (int __user *)arg); | ||
162 | break; | ||
163 | |||
164 | case WDIOC_KEEPALIVE: | 157 | case WDIOC_KEEPALIVE: |
165 | wdt_keepalive(); | 158 | wdt_keepalive(); |
166 | ret = 0; | 159 | ret = 0; |
167 | break; | 160 | break; |
161 | |||
162 | case WDIOC_GETTIMEOUT: | ||
163 | /* actually, it is 0.250 seconds.... */ | ||
164 | ret = put_user(1, (int __user *)arg); | ||
165 | break; | ||
168 | } | 166 | } |
169 | return ret; | 167 | return ret; |
170 | } | 168 | } |
@@ -174,8 +172,8 @@ static int ep93xx_wdt_release(struct inode *inode, struct file *file) | |||
174 | if (test_bit(WDT_OK_TO_CLOSE, &wdt_status)) | 172 | if (test_bit(WDT_OK_TO_CLOSE, &wdt_status)) |
175 | wdt_shutdown(); | 173 | wdt_shutdown(); |
176 | else | 174 | else |
177 | printk(KERN_CRIT PFX "Device closed unexpectedly - " | 175 | printk(KERN_CRIT PFX |
178 | "timer will not stop\n"); | 176 | "Device closed unexpectedly - timer will not stop\n"); |
179 | 177 | ||
180 | clear_bit(WDT_IN_USE, &wdt_status); | 178 | clear_bit(WDT_IN_USE, &wdt_status); |
181 | clear_bit(WDT_OK_TO_CLOSE, &wdt_status); | 179 | clear_bit(WDT_OK_TO_CLOSE, &wdt_status); |
@@ -186,7 +184,7 @@ static int ep93xx_wdt_release(struct inode *inode, struct file *file) | |||
186 | static const struct file_operations ep93xx_wdt_fops = { | 184 | static const struct file_operations ep93xx_wdt_fops = { |
187 | .owner = THIS_MODULE, | 185 | .owner = THIS_MODULE, |
188 | .write = ep93xx_wdt_write, | 186 | .write = ep93xx_wdt_write, |
189 | .ioctl = ep93xx_wdt_ioctl, | 187 | .unlocked_ioctl = ep93xx_wdt_ioctl, |
190 | .open = ep93xx_wdt_open, | 188 | .open = ep93xx_wdt_open, |
191 | .release = ep93xx_wdt_release, | 189 | .release = ep93xx_wdt_release, |
192 | }; | 190 | }; |
@@ -243,7 +241,9 @@ module_param(nowayout, int, 0); | |||
243 | MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started"); | 241 | MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started"); |
244 | 242 | ||
245 | module_param(timeout, int, 0); | 243 | module_param(timeout, int, 0); |
246 | MODULE_PARM_DESC(timeout, "Watchdog timeout in seconds. (1<=timeout<=3600, default=" __MODULE_STRING(WATCHDOG_TIMEOUT) ")"); | 244 | MODULE_PARM_DESC(timeout, |
245 | "Watchdog timeout in seconds. (1<=timeout<=3600, default=" | ||
246 | __MODULE_STRING(WATCHDOG_TIMEOUT) ")"); | ||
247 | 247 | ||
248 | MODULE_AUTHOR("Ray Lehtiniemi <rayl@mail.com>," | 248 | MODULE_AUTHOR("Ray Lehtiniemi <rayl@mail.com>," |
249 | "Alessandro Zummo <a.zummo@towertech.it>"); | 249 | "Alessandro Zummo <a.zummo@towertech.it>"); |