From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: Jonas Rebmann <jre@pengutronix.de>,
Sascha Hauer <s.hauer@pengutronix.de>,
BAREBOX <barebox@lists.infradead.org>
Cc: Alexander Shiyan <eagle.alexander923@gmail.com>
Subject: Re: [PATCH] clk: clk-gpio: Use clk_register instead of bclk_register
Date: Fri, 18 Jul 2025 19:07:19 +0200 [thread overview]
Message-ID: <a629c053-7446-405a-946c-d02174e12925@pengutronix.de> (raw)
In-Reply-To: <20250718-clk_register-v1-1-009e23a7da84@pengutronix.de>
On 18.07.25 15:37, Jonas Rebmann wrote:
> GPIO-gated clocks wrongfully used barebox clock interface which leads to
> bugs due to clk not being initialized from init->ops.
>
Fixes: b1fb0aac1ed5 ("gpio: clk-gpio: Updating the driver from the kernel repository")
> Signed-off-by: Jonas Rebmann <jre@pengutronix.de>
Reviewed-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
> ---
> drivers/clk/clk-gpio.c | 7 +------
> 1 file changed, 1 insertion(+), 6 deletions(-)
>
> diff --git a/drivers/clk/clk-gpio.c b/drivers/clk/clk-gpio.c
> index dc61c88b9f..3f9760c921 100644
> --- a/drivers/clk/clk-gpio.c
> +++ b/drivers/clk/clk-gpio.c
> @@ -96,7 +96,6 @@ static struct clk_hw *clk_register_gpio(struct device *dev, u8 num_parents,
> struct clk_hw *hw;
> struct clk_init_data init = {};
> const char *parent_names[2];
> - int err;
>
> clk_gpio = xzalloc(sizeof(*clk_gpio));
> if (!clk_gpio)
> @@ -116,11 +115,7 @@ static struct clk_hw *clk_register_gpio(struct device *dev, u8 num_parents,
> clk_gpio->hw.init = &init;
>
> hw = &clk_gpio->hw;
> - err = bclk_register(&clk_gpio->hw.clk);
> - if (err)
> - return ERR_PTR(err);
> -
> - return hw;
> + return clk_to_clk_hw(clk_register(dev, hw));
> }
>
> static struct clk_hw *clk_hw_register_gpio_gate(struct device *dev,
>
> ---
> base-commit: 89bf1fcc998fc5fea0ce613d9930dd9ee39c0fb2
> change-id: 20250717-clk_register-3ff98f73451e
>
> Best regards,
> --
> Jonas Rebmann <jre@pengutronix.de>
>
>
>
--
Pengutronix e.K. | |
Steuerwalder Str. 21 | http://www.pengutronix.de/ |
31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
next prev parent reply other threads:[~2025-07-18 17:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-18 13:37 Jonas Rebmann
2025-07-18 17:07 ` Ahmad Fatoum [this message]
2025-08-05 8:33 ` Sascha Hauer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a629c053-7446-405a-946c-d02174e12925@pengutronix.de \
--to=a.fatoum@pengutronix.de \
--cc=barebox@lists.infradead.org \
--cc=eagle.alexander923@gmail.com \
--cc=jre@pengutronix.de \
--cc=s.hauer@pengutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox