mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-04 16:15:11 +00:00
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: 2d63908bdb
("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>
This commit is contained in:
parent
5527483f8f
commit
d5b29c2c5b
1 changed files with 2 additions and 0 deletions
|
@ -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;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue