X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=drivers%2Fchar%2Fwatchdog%2Findydog.c;h=0bc239308989d53dbf7adf8ad537ada06e086b12;hb=refs%2Fheads%2Fvserver;hp=4e9093b4af8d82bb2e20f9c37f5609a53d4fae8f;hpb=9bf4aaab3e101692164d49b7ca357651eb691cb6;p=linux-2.6.git diff --git a/drivers/char/watchdog/indydog.c b/drivers/char/watchdog/indydog.c index 4e9093b4a..0bc239308 100644 --- a/drivers/char/watchdog/indydog.c +++ b/drivers/char/watchdog/indydog.c @@ -13,7 +13,6 @@ #include #include -#include #include #include #include @@ -29,14 +28,9 @@ #define PFX "indydog: " static int indydog_alive; -#ifdef CONFIG_WATCHDOG_NOWAYOUT -static int nowayout = 1; -#else -static int nowayout = 0; -#endif - #define WATCHDOG_TIMEOUT 30 /* 30 sec default timeout */ +static int nowayout = WATCHDOG_NOWAYOUT; module_param(nowayout, int, 0); MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started (default=CONFIG_WATCHDOG_NOWAYOUT)"); @@ -118,7 +112,7 @@ static int indydog_ioctl(struct inode *inode, struct file *file, switch (cmd) { default: - return -ENOIOCTLCMD; + return -ENOTTY; case WDIOC_GETSUPPORT: if (copy_to_user((struct watchdog_info *)arg, &ident, sizeof(ident))) @@ -160,8 +154,9 @@ static int indydog_notify_sys(struct notifier_block *this, unsigned long code, v return NOTIFY_DONE; } -static struct file_operations indydog_fops = { +static const struct file_operations indydog_fops = { .owner = THIS_MODULE, + .llseek = no_llseek, .write = indydog_write, .ioctl = indydog_ioctl, .open = indydog_open,