Commit e73a7802 authored by Wim Van Sebroeck's avatar Wim Van Sebroeck

[WATCHDOG] Correct WDIOF_MAGICCLOSE flag

Make sure that when the WDIOF_MAGICCLOSE flag is set we also
support the magic-close feature...
Signed-off-by: default avatarWim Van Sebroeck <wim@iguana.be>
parent b6bf291f
...@@ -246,7 +246,8 @@ static long ar7_wdt_ioctl(struct file *file, ...@@ -246,7 +246,8 @@ static long ar7_wdt_ioctl(struct file *file,
static struct watchdog_info ident = { static struct watchdog_info ident = {
.identity = LONGNAME, .identity = LONGNAME,
.firmware_version = 1, .firmware_version = 1,
.options = (WDIOF_SETTIMEOUT | WDIOF_KEEPALIVEPING), .options = (WDIOF_SETTIMEOUT | WDIOF_KEEPALIVEPING |
WDIOF_MAGICCLOSE),
}; };
int new_margin; int new_margin;
......
...@@ -156,7 +156,8 @@ static int at91_wdt_settimeout(unsigned int timeout) ...@@ -156,7 +156,8 @@ static int at91_wdt_settimeout(unsigned int timeout)
static const struct watchdog_info at91_wdt_info = { static const struct watchdog_info at91_wdt_info = {
.identity = DRV_NAME, .identity = DRV_NAME,
.options = WDIOF_SETTIMEOUT | WDIOF_KEEPALIVEPING, .options = WDIOF_SETTIMEOUT | WDIOF_KEEPALIVEPING |
WDIOF_MAGICCLOSE,
}; };
/* /*
......
...@@ -83,7 +83,6 @@ static int indydog_open(struct inode *inode, struct file *file) ...@@ -83,7 +83,6 @@ static int indydog_open(struct inode *inode, struct file *file)
indydog_start(); indydog_start();
indydog_ping(); indydog_ping();
indydog_alive = 1;
printk(KERN_INFO "Started watchdog timer.\n"); printk(KERN_INFO "Started watchdog timer.\n");
return nonseekable_open(inode, file); return nonseekable_open(inode, file);
...@@ -113,8 +112,7 @@ static long indydog_ioctl(struct file *file, unsigned int cmd, ...@@ -113,8 +112,7 @@ static long indydog_ioctl(struct file *file, unsigned int cmd,
{ {
int options, retval = -EINVAL; int options, retval = -EINVAL;
static struct watchdog_info ident = { static struct watchdog_info ident = {
.options = WDIOF_KEEPALIVEPING | .options = WDIOF_KEEPALIVEPING,
WDIOF_MAGICCLOSE,
.firmware_version = 0, .firmware_version = 0,
.identity = "Hardware Watchdog for SGI IP22", .identity = "Hardware Watchdog for SGI IP22",
}; };
......
...@@ -239,7 +239,8 @@ static long it8712f_wdt_ioctl(struct file *file, unsigned int cmd, ...@@ -239,7 +239,8 @@ static long it8712f_wdt_ioctl(struct file *file, unsigned int cmd,
static struct watchdog_info ident = { static struct watchdog_info ident = {
.identity = "IT8712F Watchdog", .identity = "IT8712F Watchdog",
.firmware_version = 1, .firmware_version = 1,
.options = WDIOF_SETTIMEOUT | WDIOF_KEEPALIVEPING, .options = WDIOF_SETTIMEOUT | WDIOF_KEEPALIVEPING |
WDIOF_MAGICCLOSE,
}; };
int value; int value;
......
...@@ -93,7 +93,7 @@ static int expect_close; ...@@ -93,7 +93,7 @@ static int expect_close;
static const struct watchdog_info ident = { static const struct watchdog_info ident = {
.options = WDIOF_CARDRESET | WDIOF_SETTIMEOUT | .options = WDIOF_CARDRESET | WDIOF_SETTIMEOUT |
WDIOF_KEEPALIVEPING, WDIOF_KEEPALIVEPING | WDIOF_MAGICCLOSE,
.identity = "SiByte Watchdog", .identity = "SiByte Watchdog",
}; };
......
...@@ -107,8 +107,7 @@ static long epx_c3_ioctl(struct file *file, unsigned int cmd, ...@@ -107,8 +107,7 @@ static long epx_c3_ioctl(struct file *file, unsigned int cmd,
int options, retval = -EINVAL; int options, retval = -EINVAL;
int __user *argp = (void __user *)arg; int __user *argp = (void __user *)arg;
static const struct watchdog_info ident = { static const struct watchdog_info ident = {
.options = WDIOF_KEEPALIVEPING | .options = WDIOF_KEEPALIVEPING,
WDIOF_MAGICCLOSE,
.firmware_version = 0, .firmware_version = 0,
.identity = "Winsystems EPX-C3 H/W Watchdog", .identity = "Winsystems EPX-C3 H/W Watchdog",
}; };
......
...@@ -165,7 +165,8 @@ static long scx200_wdt_ioctl(struct file *file, unsigned int cmd, ...@@ -165,7 +165,8 @@ static long scx200_wdt_ioctl(struct file *file, unsigned int cmd,
static const struct watchdog_info ident = { static const struct watchdog_info ident = {
.identity = "NatSemi SCx200 Watchdog", .identity = "NatSemi SCx200 Watchdog",
.firmware_version = 1, .firmware_version = 1,
.options = WDIOF_SETTIMEOUT | WDIOF_KEEPALIVEPING, .options = WDIOF_SETTIMEOUT | WDIOF_KEEPALIVEPING |
WDIOF_MAGICCLOSE,
}; };
int new_margin; int new_margin;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment