watchdog: ts72xx_wdt: Propagate return value from timeout_to_regval
Guenter Roeck
maintainerPATCH 1/1 watchdog: ts72xx_wdt: Propagate return value from timeout_to_regval
timeout_to_regval() returns a valid error code. Might as well use it.
Signed-off-by Guenter Roeck <[email protected]>
--- drivers/watchdog/ts72xx_wdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/watchdog/ts72xx_wdt.c +1 -1
@@ -192,7 +192,7 @@ static int ts72xx_wdt_open(struct inode *inode, struct file *file)dev_err (&wdt->pdev->dev,"failed to convert timeout (%d) to register value\n" , timeout); -return -EINVAL ; +return regval; }if (mutex_lock_interruptible (&wdt->lock))
Signature · 1 line
1.7.9.7
Hi Guenter,
Quoted 12 lines
timeout_to_regval()returns a valid error code. Might as well use it.Signed-off-by Guenter Roeck <[email protected]>--- drivers/watchdog/ts72xx_wdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/watchdog/ts72xx_wdt.c +0
-0
drivers/watchdog/ts72xx_wdt.c static int ts72xx_wdt_open(struct inode *inode, struct file *file) · line 198
Quoted 8 lines
drivers/watchdog/ts72xx_wdt.c +1
-1@@ -192,7 +192,7 @@ static int ts72xx_wdt_open(struct inode *inode, struct file *file)dev_err (&wdt->pdev->dev,"failed to convert timeout (%d) to register value\n" , timeout); -return -EINVAL ; +return regval; }if (mutex_lock_interruptible (&wdt->lock))
This patch has been added to linux-watchdog-next.
Kind regards,
Wim.