On Sun, Oct 06, 2024 at 05:38:25PM +0800, [email protected] wrote:
> From: Ye Li <[email protected]>
> 
> Add workaround to set_rate/enable/disable to bus clock that SM
> will reply DENIED error.
> 
> Signed-off-by: Ye Li <[email protected]>
> Signed-off-by: Alice Guo <[email protected]>
> Reviewed-by: Peng Fan <[email protected]>

In general, please include a cover letter so it will be clearer what the
overall goal is, especially once merged.

> ---
>  drivers/clk/clk_scmi.c | 21 +++++++++++++++++++--
>  1 file changed, 19 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/clk/clk_scmi.c b/drivers/clk/clk_scmi.c
> index a01292c479..a860a653ba 100644
> --- a/drivers/clk/clk_scmi.c
> +++ b/drivers/clk/clk_scmi.c
> @@ -73,7 +73,13 @@ static int scmi_clk_gate(struct clk *clk, int enable)
>       if (ret)
>               return ret;
>  
> -     return scmi_to_linux_errno(out.status);
> +     ret = scmi_to_linux_errno(out.status);
> +     if (ret == -EACCES) {
> +             debug("Ignore %s enable failure\n", clk_hw_get_name(clk));
> +             ret = 0;
> +     }
> +
> +     return ret;
>  }

This seems like a generic change being made globally and not a
work-around for a specific problem on (some?) iMX families. Has this
been tested on other platforms?

-- 
Tom

Attachment: signature.asc
Description: PGP signature

Reply via email to