Commit 8bc22a2f authored by Ji Sheng Teoh's avatar Ji Sheng Teoh Committed by Wim Van Sebroeck
Browse files

watchdog: starfive: Check pm_runtime_enabled() before decrementing usage counter



In the probe function, pm_runtime_put_sync() will fail on platform with
runtime PM disabled.
Check if runtime PM is enabled before calling pm_runtime_put_sync() to
fix it.

Fixes: db728ea9 ("drivers: watchdog: Add StarFive Watchdog driver")
Signed-off-by: default avatarXingyu Wu <xingyu.wu@starfivetech.com>
Signed-off-by: default avatarLey Foon Tan <leyfoon.tan@starfivetech.com>
Signed-off-by: default avatarJi Sheng Teoh <jisheng.teoh@starfivetech.com>
Reviewed-by: default avatarGuenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20240119082722.1133024-1-jisheng.teoh@starfivetech.com


Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
Signed-off-by: default avatarWim Van Sebroeck <wim@linux-watchdog.org>
parent 975e4b27
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment