Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

watchdog: starfive: Add missing clk_disable_unprepare()

Add the missing clk_disable_unprepare() before return in
starfive_wdt_enable_clock().

Signed-off-by: Chen Ni <nichen@iscas.ac.cn>
Reviewed-by: Xingyu Wu <xingyu.wu@starfivetech.com>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20240628033508.281058-1-nichen@iscas.ac.cn
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Wim Van Sebroeck <wim@linux-watchdog.org>

authored by

Chen Ni and committed by
Wim Van Sebroeck
9dca7a0a d794a741

+3 -1
+3 -1
drivers/watchdog/starfive-wdt.c
··· 152 152 return dev_err_probe(wdt->wdd.parent, ret, "failed to enable apb clock\n"); 153 153 154 154 ret = clk_prepare_enable(wdt->core_clk); 155 - if (ret) 155 + if (ret) { 156 + clk_disable_unprepare(wdt->apb_clk); 156 157 return dev_err_probe(wdt->wdd.parent, ret, "failed to enable core clock\n"); 158 + } 157 159 158 160 return 0; 159 161 }