]> Git Repo - J-linux.git/commitdiff
watchdog: rti-wdt: balance pm runtime enable calls
authorTero Kristo <[email protected]>
Fri, 17 Jul 2020 13:29:58 +0000 (16:29 +0300)
committerWim Van Sebroeck <[email protected]>
Wed, 5 Aug 2020 16:43:03 +0000 (18:43 +0200)
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 <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Guenter Roeck <[email protected]>
Signed-off-by: Wim Van Sebroeck <[email protected]>
drivers/watchdog/rti_wdt.c

index 7cbdc178ffe8748e13d802dbe2386547298e18d0..705e8f7523e814f879592bc9df7077ef8f5bab62 100644 (file)
@@ -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;
 }
This page took 0.054307 seconds and 4 git commands to generate.