summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorAlexey Khoroshilov <khoroshilov@ispras.ru>2018-10-13 23:51:03 +0300
committerWim Van Sebroeck <wim@linux-watchdog.org>2018-10-22 11:16:28 +0300
commitcd6ba41c192deca20d9add5554bc8c51d0f07de2 (patch)
tree8865c1361cd429c1655583a2060dcc2b3675aaa9 /drivers
parentc8ca6e70fb74cd3bb6fc0738aed40991b9de0b87 (diff)
downloadlinux-cd6ba41c192deca20d9add5554bc8c51d0f07de2.tar.xz
watchdog: ts4800: release syscon device node in ts4800_wdt_probe()
Put syscon device node when it is not needed anymore. Found by Linux Driver Verification project (linuxtesting.org). Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru> Reviewed-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@linux-watchdog.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/watchdog/ts4800_wdt.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/watchdog/ts4800_wdt.c b/drivers/watchdog/ts4800_wdt.c
index 2b8de8602b67..89843b16b04a 100644
--- a/drivers/watchdog/ts4800_wdt.c
+++ b/drivers/watchdog/ts4800_wdt.c
@@ -135,6 +135,7 @@ static int ts4800_wdt_probe(struct platform_device *pdev)
/* set regmap and offset to know where to write */
wdt->feed_offset = reg;
wdt->regmap = syscon_node_to_regmap(syscon_np);
+ of_node_put(syscon_np);
if (IS_ERR(wdt->regmap)) {
dev_err(&pdev->dev, "cannot get parent's regmap\n");
return PTR_ERR(wdt->regmap);