Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

watchdog: wdt285: Fix variable type

Variable "new_margin" is checked in the function watchdog_ioctl()
to be non-negative, so change its type to "int".

Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>

authored by

Alexander Shiyan and committed by
Wim Van Sebroeck
70605d9b 1cf8a348

+1 -2
+1 -2
drivers/watchdog/wdt285.c
··· 139 139 static long watchdog_ioctl(struct file *file, unsigned int cmd, 140 140 unsigned long arg) 141 141 { 142 - unsigned int new_margin; 143 142 int __user *int_arg = (int __user *)arg; 144 - int ret = -ENOTTY; 143 + int new_margin, ret = -ENOTTY; 145 144 146 145 switch (cmd) { 147 146 case WDIOC_GETSUPPORT: