]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
watchdog: twl4030: Remove redundant platform_set_drvdata()
authorSachin Kamat <sachin.kamat@linaro.org>
Fri, 3 May 2013 20:11:18 +0000 (01:41 +0530)
committerWim Van Sebroeck <wim@iguana.be>
Thu, 11 Jul 2013 19:10:13 +0000 (21:10 +0200)
Commit 0998d06310 (device-core: Ensure drvdata = NULL when no
driver is bound) removes the need to set driver data field to
NULL.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Timo Kokkonen <timo.t.kokkonen@nokia.com>
Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
drivers/watchdog/twl4030_wdt.c

index 0f03106f7516ab8a6d1198b1f4b4dd31b06e09cc..2d4535dc2676062a8edf85e4132cea26874f6890 100644 (file)
@@ -90,10 +90,8 @@ static int twl4030_wdt_probe(struct platform_device *pdev)
        twl4030_wdt_stop(wdt);
 
        ret = watchdog_register_device(wdt);
-       if (ret) {
-               platform_set_drvdata(pdev, NULL);
+       if (ret)
                return ret;
-       }
 
        return 0;
 }
@@ -103,7 +101,6 @@ static int twl4030_wdt_remove(struct platform_device *pdev)
        struct watchdog_device *wdt = platform_get_drvdata(pdev);
 
        watchdog_unregister_device(wdt);
-       platform_set_drvdata(pdev, NULL);
 
        return 0;
 }