Commit d5b29c2c authored by Tero Kristo's avatar Tero Kristo Committed by Wim Van Sebroeck

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: 2d63908b ("watchdog: Add K3 RTI watchdog support")
Signed-off-by: default avatarTero Kristo <t-kristo@ti.com>
Reviewed-by: default avatarGuenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20200717132958.14304-5-t-kristo@ti.comSigned-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
Signed-off-by: default avatarWim Van Sebroeck <wim@linux-watchdog.org>
parent 5527483f
...@@ -303,6 +303,7 @@ static int rti_wdt_probe(struct platform_device *pdev) ...@@ -303,6 +303,7 @@ static int rti_wdt_probe(struct platform_device *pdev)
err_iomap: err_iomap:
pm_runtime_put_sync(&pdev->dev); pm_runtime_put_sync(&pdev->dev);
pm_runtime_disable(&pdev->dev);
return ret; return ret;
} }
...@@ -313,6 +314,7 @@ static int rti_wdt_remove(struct platform_device *pdev) ...@@ -313,6 +314,7 @@ static int rti_wdt_remove(struct platform_device *pdev)
watchdog_unregister_device(&wdt->wdd); watchdog_unregister_device(&wdt->wdd);
pm_runtime_put(&pdev->dev); pm_runtime_put(&pdev->dev);
pm_runtime_disable(&pdev->dev);
return 0; return 0;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment