]> www.infradead.org Git - users/jedix/linux-maple.git/commit
watchdog: rti_wdt: Fix an OF node leak in rti_wdt_probe()
authorJoe Hattori <joe@pf.is.s.u-tokyo.ac.jp>
Sun, 5 Jan 2025 11:17:18 +0000 (20:17 +0900)
committerWim Van Sebroeck <wim@linux-watchdog.org>
Mon, 6 Jan 2025 18:38:07 +0000 (19:38 +0100)
commit143981aa63f33d469a55a55fd9fb81cd90109672
treeb19f7a11132b74616be448091d77f0095c760adb
parent7da5fc3408f3165e8a7dfb0d15b934aa3531082a
watchdog: rti_wdt: Fix an OF node leak in rti_wdt_probe()

rti_wdt_probe() does not release the OF node reference obtained by
of_parse_phandle(). Add a of_node_put() call.

This was found by an experimental verification tool that I am
developing. Due to the lack of the actual device, no runtime test was
able to be performed.

Fixes: f20ca595ae23 ("watchdog:rit_wdt: Add support for WDIOF_CARDRESET")
Signed-off-by: Joe Hattori <joe@pf.is.s.u-tokyo.ac.jp>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20250105111718.4184192-1-joe@pf.is.s.u-tokyo.ac.jp
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Wim Van Sebroeck <wim@linux-watchdog.org>
drivers/watchdog/rti_wdt.c