[PATCH 05/30] clk: renesas: Fix incorrect return RPC clk_get_rate

Marek Vasut marek.vasut at gmail.com
Wed Apr 28 21:29:27 CEST 2021


From: Hai Pham <hai.pham.ud at renesas.com>

RPC clk_get_rate will return error code instead of expected clock rate.
Fix this.

Signed-off-by: Hai Pham <hai.pham.ud at renesas.com>
Signed-off-by: Marek Vasut <marek.vasut+renesas at gmail.com>
---
 drivers/clk/renesas/clk-rcar-gen3.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/clk/renesas/clk-rcar-gen3.c b/drivers/clk/renesas/clk-rcar-gen3.c
index 3223becd75..09d84c44e1 100644
--- a/drivers/clk/renesas/clk-rcar-gen3.c
+++ b/drivers/clk/renesas/clk-rcar-gen3.c
@@ -310,7 +310,7 @@ static u64 gen3_clk_get_rate64(struct clk *clk)
 		      __func__, __LINE__,
 		      core->parent, prediv, postdiv, rate);
 
-		return -EINVAL;
+		return rate;
 
 	}
 
-- 
2.30.2



More information about the U-Boot mailing list