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

watchdog: twl4030: Remove redundant platform_set_drvdata()

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>

authored by

Sachin Kamat and committed by
Wim Van Sebroeck
6638f4e5 6697dbd2

+1 -4
+1 -4
drivers/watchdog/twl4030_wdt.c
··· 90 90 twl4030_wdt_stop(wdt); 91 91 92 92 ret = watchdog_register_device(wdt); 93 - if (ret) { 94 - platform_set_drvdata(pdev, NULL); 93 + if (ret) 95 94 return ret; 96 - } 97 95 98 96 return 0; 99 97 } ··· 101 103 struct watchdog_device *wdt = platform_get_drvdata(pdev); 102 104 103 105 watchdog_unregister_device(wdt); 104 - platform_set_drvdata(pdev, NULL); 105 106 106 107 return 0; 107 108 }