diff options
author | Tero Kristo <t-kristo@ti.com> | 2020-07-17 16:29:58 +0300 |
---|---|---|
committer | Wim Van Sebroeck <wim@linux-watchdog.org> | 2020-08-05 18:43:03 +0200 |
commit | d5b29c2c5ba2bd5bbdb5b744659984185d17d079 (patch) | |
tree | 59d2db16b0a3330afc70bcd3a6e16adb39ae75ea /drivers/watchdog/rti_wdt.c | |
parent | 5527483f8f7c8edadb5ad4fe8fcb569f565369ea (diff) | |
download | lwn-d5b29c2c5ba2bd5bbdb5b744659984185d17d079.tar.gz lwn-d5b29c2c5ba2bd5bbdb5b744659984185d17d079.zip |
watchdog: rti-wdt: balance pm runtime enable calls
PM runtime should be disabled in the fail path of probe and when
the driver is removed.
Fixes: 2d63908bdbfb ("watchdog: Add K3 RTI watchdog support")
Signed-off-by: Tero Kristo <t-kristo@ti.com>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20200717132958.14304-5-t-kristo@ti.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Wim Van Sebroeck <wim@linux-watchdog.org>
Diffstat (limited to 'drivers/watchdog/rti_wdt.c')
-rw-r--r-- | drivers/watchdog/rti_wdt.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/watchdog/rti_wdt.c b/drivers/watchdog/rti_wdt.c index 7cbdc178ffe8..705e8f7523e8 100644 --- a/drivers/watchdog/rti_wdt.c +++ b/drivers/watchdog/rti_wdt.c @@ -303,6 +303,7 @@ static int rti_wdt_probe(struct platform_device *pdev) err_iomap: pm_runtime_put_sync(&pdev->dev); + pm_runtime_disable(&pdev->dev); return ret; } @@ -313,6 +314,7 @@ static int rti_wdt_remove(struct platform_device *pdev) watchdog_unregister_device(&wdt->wdd); pm_runtime_put(&pdev->dev); + pm_runtime_disable(&pdev->dev); return 0; } |