* [PATCH] clk: renesas: mstp: Remove obsolete clkdev registration
@ 2024-01-22 13:49 Geert Uytterhoeven
2024-01-22 15:28 ` Niklas Söderlund
0 siblings, 1 reply; 3+ messages in thread
From: Geert Uytterhoeven @ 2024-01-22 13:49 UTC (permalink / raw)
To: Michael Turquette, Stephen Boyd
Cc: linux-clk, linux-renesas-soc, Geert Uytterhoeven
After the DT conversion of SH-Mobile and Armadillo-800-EVA display
support, all devices are registered from DT, so we can remove the
registration of clkdevs.
Add the missing #include <linux/slab.h>, which was included implicitly
through <linux/clkdev.h> before.
Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
Patch written in 2015 ;-)
To be queued in renesas-clk for v6.9.
---
drivers/clk/renesas/clk-mstp.c | 16 +++-------------
1 file changed, 3 insertions(+), 13 deletions(-)
diff --git a/drivers/clk/renesas/clk-mstp.c b/drivers/clk/renesas/clk-mstp.c
index e96457371b4cce88..cab4c89c4d657740 100644
--- a/drivers/clk/renesas/clk-mstp.c
+++ b/drivers/clk/renesas/clk-mstp.c
@@ -10,7 +10,6 @@
#include <linux/clk.h>
#include <linux/clk-provider.h>
-#include <linux/clkdev.h>
#include <linux/clk/renesas.h>
#include <linux/device.h>
#include <linux/io.h>
@@ -19,6 +18,7 @@
#include <linux/of_address.h>
#include <linux/pm_clock.h>
#include <linux/pm_domain.h>
+#include <linux/slab.h>
#include <linux/spinlock.h>
/*
@@ -238,22 +238,12 @@ static void __init cpg_mstp_clocks_init(struct device_node *np)
clks[clkidx] = cpg_mstp_clock_register(name, parent_name,
clkidx, group);
- if (!IS_ERR(clks[clkidx])) {
+ if (!IS_ERR(clks[clkidx]))
group->data.clk_num = max(group->data.clk_num,
clkidx + 1);
- /*
- * Register a clkdev to let board code retrieve the
- * clock by name and register aliases for non-DT
- * devices.
- *
- * FIXME: Remove this when all devices that require a
- * clock will be instantiated from DT.
- */
- clk_register_clkdev(clks[clkidx], name, NULL);
- } else {
+ else
pr_err("%s: failed to register %pOFn %s clock (%ld)\n",
__func__, np, name, PTR_ERR(clks[clkidx]));
- }
}
of_clk_add_provider(np, of_clk_src_onecell_get, &group->data);
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread* Re: [PATCH] clk: renesas: mstp: Remove obsolete clkdev registration
2024-01-22 13:49 [PATCH] clk: renesas: mstp: Remove obsolete clkdev registration Geert Uytterhoeven
@ 2024-01-22 15:28 ` Niklas Söderlund
2024-01-23 8:34 ` Geert Uytterhoeven
0 siblings, 1 reply; 3+ messages in thread
From: Niklas Söderlund @ 2024-01-22 15:28 UTC (permalink / raw)
To: Geert Uytterhoeven
Cc: Michael Turquette, Stephen Boyd, linux-clk, linux-renesas-soc
Hi Geert,
Thanks for your work.
On 2024-01-22 14:49:45 +0100, Geert Uytterhoeven wrote:
> After the DT conversion of SH-Mobile and Armadillo-800-EVA display
> support, all devices are registered from DT, so we can remove the
> registration of clkdevs.
>
> Add the missing #include <linux/slab.h>, which was included implicitly
> through <linux/clkdev.h> before.
>
> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
> ---
> Patch written in 2015 ;-)
I scratch my head reading some of these patches, I have seen some of
them before, but could not figure out when.
>
> To be queued in renesas-clk for v6.9.
> ---
> drivers/clk/renesas/clk-mstp.c | 16 +++-------------
> 1 file changed, 3 insertions(+), 13 deletions(-)
>
> diff --git a/drivers/clk/renesas/clk-mstp.c b/drivers/clk/renesas/clk-mstp.c
> index e96457371b4cce88..cab4c89c4d657740 100644
> --- a/drivers/clk/renesas/clk-mstp.c
> +++ b/drivers/clk/renesas/clk-mstp.c
> @@ -10,7 +10,6 @@
>
> #include <linux/clk.h>
> #include <linux/clk-provider.h>
> -#include <linux/clkdev.h>
> #include <linux/clk/renesas.h>
> #include <linux/device.h>
> #include <linux/io.h>
> @@ -19,6 +18,7 @@
> #include <linux/of_address.h>
> #include <linux/pm_clock.h>
> #include <linux/pm_domain.h>
> +#include <linux/slab.h>
> #include <linux/spinlock.h>
>
> /*
> @@ -238,22 +238,12 @@ static void __init cpg_mstp_clocks_init(struct device_node *np)
>
> clks[clkidx] = cpg_mstp_clock_register(name, parent_name,
> clkidx, group);
> - if (!IS_ERR(clks[clkidx])) {
> + if (!IS_ERR(clks[clkidx]))
> group->data.clk_num = max(group->data.clk_num,
> clkidx + 1);
> - /*
> - * Register a clkdev to let board code retrieve the
> - * clock by name and register aliases for non-DT
> - * devices.
> - *
> - * FIXME: Remove this when all devices that require a
> - * clock will be instantiated from DT.
> - */
> - clk_register_clkdev(clks[clkidx], name, NULL);
> - } else {
> + else
> pr_err("%s: failed to register %pOFn %s clock (%ld)\n",
> __func__, np, name, PTR_ERR(clks[clkidx]));
> - }
> }
>
> of_clk_add_provider(np, of_clk_src_onecell_get, &group->data);
> --
> 2.34.1
>
>
--
Kind Regards,
Niklas Söderlund
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] clk: renesas: mstp: Remove obsolete clkdev registration
2024-01-22 15:28 ` Niklas Söderlund
@ 2024-01-23 8:34 ` Geert Uytterhoeven
0 siblings, 0 replies; 3+ messages in thread
From: Geert Uytterhoeven @ 2024-01-23 8:34 UTC (permalink / raw)
To: Niklas Söderlund
Cc: Geert Uytterhoeven, Michael Turquette, Stephen Boyd, linux-clk,
linux-renesas-soc
Hi Niklas,
On Mon, Jan 22, 2024 at 4:28 PM Niklas Söderlund
<niklas.soderlund@ragnatech.se> wrote:
> On 2024-01-22 14:49:45 +0100, Geert Uytterhoeven wrote:
> > After the DT conversion of SH-Mobile and Armadillo-800-EVA display
> > support, all devices are registered from DT, so we can remove the
> > registration of clkdevs.
> >
> > Add the missing #include <linux/slab.h>, which was included implicitly
> > through <linux/clkdev.h> before.
> >
> > Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
>
> Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech
Thanks!
> > ---
> > Patch written in 2015 ;-)
>
> I scratch my head reading some of these patches, I have seen some of
> them before, but could not figure out when.
Probably it reminds you of "[PATCH/RFC 3/3] clk: renesas: emev2:
Remove obsolete clkdev registration"?
https://lore.kernel.org/all/f54a30d7a9e2aa075d462db701a60b0b59c6ad0b.1686325857.git.geert+renesas@glider.be
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-01-23 8:34 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-01-22 13:49 [PATCH] clk: renesas: mstp: Remove obsolete clkdev registration Geert Uytterhoeven
2024-01-22 15:28 ` Niklas Söderlund
2024-01-23 8:34 ` Geert Uytterhoeven
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox