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

Lad, Prabhakar prabhakar.csengg at gmail.com
Thu May 20 18:55:52 CEST 2021


Hi Marek,

Thank you for the patch.

On Wed, Apr 28, 2021 at 8:31 PM Marek Vasut <marek.vasut at gmail.com> wrote:
>
> 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(-)
>
Tested on RZ/G2E board

Tested-by: Lad Prabhakar <prabhakar.mahadev-lad.rj at bp.renesas.com>

Cheers,
Prabhakar

> 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