watchdog: ts72xx_wdt: Kill superfluous variable in remove
authorMika Westerberg <mika.westerberg@linux.intel.com>
Tue, 19 Aug 2014 11:57:12 +0000 (14:57 +0300)
committerWim Van Sebroeck <wim@iguana.be>
Mon, 20 Oct 2014 18:44:55 +0000 (20:44 +0200)
There is no need to store the return value of misc_deregister() in a
variable. Instead we can just return the value directly.

Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
drivers/watchdog/ts72xx_wdt.c

index afa9d6ef353ab3ab8e13f44acfa5a448953961a8..dee9c6cbe6df57f28104e9917be60a3d935f9277 100644 (file)
@@ -428,11 +428,7 @@ static int ts72xx_wdt_probe(struct platform_device *pdev)
 
 static int ts72xx_wdt_remove(struct platform_device *pdev)
 {
-       int error;
-
-       error = misc_deregister(&ts72xx_wdt_miscdev);
-
-       return error;
+       return misc_deregister(&ts72xx_wdt_miscdev);
 }
 
 static struct platform_driver ts72xx_wdt_driver = {