diff options
| author | Wentao Liang <vulab@iscas.ac.cn> | 2026-09-16 17:07:04 +0000 |
|---|---|---|
| committer | Guenter Roeck <linux@roeck-us.net> | 2026-09-16 17:45:13 -0700 |
| commit | 8f0ca55016a7647109ae2bc91bcb346fc8b13785 (patch) | |
| tree | 44a7f2e0b9b8dc41384ef110e3d5d1c5e417fa61 /tools/perf/scripts/python | |
| parent | 5071122bf5a628494db16d98d253f622a5aab074 (diff) | |
| download | linux-next-8f0ca55016a7647109ae2bc91bcb346fc8b13785.tar.gz linux-next-8f0ca55016a7647109ae2bc91bcb346fc8b13785.zip | |
watchdog: starfive-wdt: Fix runtime PM leak in starfive_wdt_pm_start()
starfive_wdt_pm_start() takes a runtime PM reference with
pm_runtime_get_sync(), which increments the usage counter even when it
fails, and returns the error without dropping it again. The watchdog
core does not invoke the stop callback when start fails, so the
reference taken on the error path is leaked.
Use pm_runtime_resume_and_get() instead, which keeps the usage counter
balanced when the resume fails.
Fixes: db728ea9c7be ("drivers: watchdog: Add StarFive Watchdog driver")
Cc: stable@vger.kernel.org
Signed-off-by: Wentao Liang <vulab@iscas.ac.cn>
Link: https://patch.msgid.link/20260916170704.2086331-1-vulab@iscas.ac.cn
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
