[PATCH 4/4] clk: scmi: Add workaround for set_rate/enable/disable
Tom Rini
trini at konsulko.com
Mon Oct 7 19:02:44 CEST 2024
On Sun, Oct 06, 2024 at 05:38:25PM +0800, alice.guo at oss.nxp.com wrote:
> From: Ye Li <ye.li at nxp.com>
>
> Add workaround to set_rate/enable/disable to bus clock that SM
> will reply DENIED error.
>
> Signed-off-by: Ye Li <ye.li at nxp.com>
> Signed-off-by: Alice Guo <alice.guo at nxp.com>
> Reviewed-by: Peng Fan <peng.fan at nxp.com>
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
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20241007/7b2d1b6a/attachment.sig>
More information about the U-Boot
mailing list