Add the missing clk_disable_unprepare() before return in bt1_apb_request_clk(). Signed-off-by: Gaosheng Cui <cuigaosheng1@xxxxxxxxxx> --- drivers/bus/bt1-apb.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/bus/bt1-apb.c b/drivers/bus/bt1-apb.c index 595fb22b73e0..244f03988545 100644 --- a/drivers/bus/bt1-apb.c +++ b/drivers/bus/bt1-apb.c @@ -210,12 +210,14 @@ static int bt1_apb_request_clk(struct bt1_apb *apb) ret = devm_add_action_or_reset(apb->dev, bt1_apb_disable_clk, apb); if (ret) { dev_err(apb->dev, "Can't add APB EHB clocks disable action\n"); + clk_disable_unprepare(apb->pclk); return ret; } apb->rate = clk_get_rate(apb->pclk); if (!apb->rate) { dev_err(apb->dev, "Invalid clock rate\n"); + clk_disable_unprepare(apb->pclk); return -EINVAL; } -- 2.25.1