* [PATCH] ARM: omap2: register cpufreq-cpu0 device for am33xx
@ 2013-01-30 14:32 Shawn Guo
2013-01-31 9:40 ` AnilKumar, Chimata
0 siblings, 1 reply; 3+ messages in thread
From: Shawn Guo @ 2013-01-30 14:32 UTC (permalink / raw)
To: linux-arm-kernel
The cpufreq-cpu0 driver changes to instantiate use platform_driver
mechanism. The patch is an am33xx platform level adaptation for it.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
---
arch/arm/mach-omap2/board-generic.c | 1 +
arch/arm/mach-omap2/cclock33xx_data.c | 2 +-
arch/arm/mach-omap2/common.h | 1 +
arch/arm/mach-omap2/io.c | 8 ++++++++
4 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/arch/arm/mach-omap2/board-generic.c b/arch/arm/mach-omap2/board-generic.c
index 53cb380b..b945480 100644
--- a/arch/arm/mach-omap2/board-generic.c
+++ b/arch/arm/mach-omap2/board-generic.c
@@ -139,6 +139,7 @@ DT_MACHINE_START(AM33XX_DT, "Generic AM33XX (Flattened Device Tree)")
.init_irq = omap_intc_of_init,
.handle_irq = omap3_intc_handle_irq,
.init_machine = omap_generic_init,
+ .init_late = am33xx_init_late,
.timer = &omap3_am33xx_timer,
.dt_compat = am33xx_boards_compat,
MACHINE_END
diff --git a/arch/arm/mach-omap2/cclock33xx_data.c b/arch/arm/mach-omap2/cclock33xx_data.c
index ea64ad6..acb1620 100644
--- a/arch/arm/mach-omap2/cclock33xx_data.c
+++ b/arch/arm/mach-omap2/cclock33xx_data.c
@@ -850,7 +850,7 @@ static struct omap_clk am33xx_clks[] = {
CLK(NULL, "dpll_core_m5_ck", &dpll_core_m5_ck, CK_AM33XX),
CLK(NULL, "dpll_core_m6_ck", &dpll_core_m6_ck, CK_AM33XX),
CLK(NULL, "dpll_mpu_ck", &dpll_mpu_ck, CK_AM33XX),
- CLK("cpu0", NULL, &dpll_mpu_ck, CK_AM33XX),
+ CLK("cpufreq-cpu0.0", NULL, &dpll_mpu_ck, CK_AM33XX),
CLK(NULL, "dpll_mpu_m2_ck", &dpll_mpu_m2_ck, CK_AM33XX),
CLK(NULL, "dpll_ddr_ck", &dpll_ddr_ck, CK_AM33XX),
CLK(NULL, "dpll_ddr_m2_ck", &dpll_ddr_m2_ck, CK_AM33XX),
diff --git a/arch/arm/mach-omap2/common.h b/arch/arm/mach-omap2/common.h
index 948bcaa..e3355df5 100644
--- a/arch/arm/mach-omap2/common.h
+++ b/arch/arm/mach-omap2/common.h
@@ -106,6 +106,7 @@ void omap2430_init_late(void);
void omap3430_init_late(void);
void omap35xx_init_late(void);
void omap3630_init_late(void);
+void am33xx_init_late(void);
void am35xx_init_late(void);
void ti81xx_init_late(void);
void omap4430_init_late(void);
diff --git a/arch/arm/mach-omap2/io.c b/arch/arm/mach-omap2/io.c
index 2c3fdd6..0e67711 100644
--- a/arch/arm/mach-omap2/io.c
+++ b/arch/arm/mach-omap2/io.c
@@ -535,6 +535,14 @@ void __init omap3630_init_late(void)
omap2_clk_enable_autoidle_all();
}
+void __init am33xx_init_late(void)
+{
+ struct platform_device_info devinfo = { .name = "cpufreq-cpu0", };
+
+ if (IS_ENABLED(CONFIG_GENERIC_CPUFREQ_CPU0))
+ platform_device_register_full(&devinfo);
+}
+
void __init am35xx_init_late(void)
{
omap_mux_late_init();
--
1.7.9.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH] ARM: omap2: register cpufreq-cpu0 device for am33xx
2013-01-30 14:32 [PATCH] ARM: omap2: register cpufreq-cpu0 device for am33xx Shawn Guo
@ 2013-01-31 9:40 ` AnilKumar, Chimata
2013-01-31 12:31 ` Shawn Guo
0 siblings, 1 reply; 3+ messages in thread
From: AnilKumar, Chimata @ 2013-01-31 9:40 UTC (permalink / raw)
To: linux-arm-kernel
On Wed, Jan 30, 2013 at 20:02:22, Shawn Guo wrote:
> The cpufreq-cpu0 driver changes to instantiate use platform_driver
> mechanism. The patch is an am33xx platform level adaptation for it.
Tested-by: AnilKumar Ch <anilkumar@ti.com>
Hi Shawn,
I have tested your patch on AM335x-EVM, no issues observed.
I think, better post v3 version which contains this patch
and cpu0-cpufreq driver changes.
Or
Post v3 of cpufreq-cpu0 driver changes.
Thanks
AnilKumar
> Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
> ---
> arch/arm/mach-omap2/board-generic.c | 1 +
> arch/arm/mach-omap2/cclock33xx_data.c | 2 +-
> arch/arm/mach-omap2/common.h | 1 +
> arch/arm/mach-omap2/io.c | 8 ++++++++
> 4 files changed, 11 insertions(+), 1 deletion(-)
>
> diff --git a/arch/arm/mach-omap2/board-generic.c b/arch/arm/mach-omap2/board-generic.c
> index 53cb380b..b945480 100644
> --- a/arch/arm/mach-omap2/board-generic.c
> +++ b/arch/arm/mach-omap2/board-generic.c
> @@ -139,6 +139,7 @@ DT_MACHINE_START(AM33XX_DT, "Generic AM33XX (Flattened Device Tree)")
> .init_irq = omap_intc_of_init,
> .handle_irq = omap3_intc_handle_irq,
> .init_machine = omap_generic_init,
> + .init_late = am33xx_init_late,
> .timer = &omap3_am33xx_timer,
> .dt_compat = am33xx_boards_compat,
> MACHINE_END
> diff --git a/arch/arm/mach-omap2/cclock33xx_data.c b/arch/arm/mach-omap2/cclock33xx_data.c
> index ea64ad6..acb1620 100644
> --- a/arch/arm/mach-omap2/cclock33xx_data.c
> +++ b/arch/arm/mach-omap2/cclock33xx_data.c
> @@ -850,7 +850,7 @@ static struct omap_clk am33xx_clks[] = {
> CLK(NULL, "dpll_core_m5_ck", &dpll_core_m5_ck, CK_AM33XX),
> CLK(NULL, "dpll_core_m6_ck", &dpll_core_m6_ck, CK_AM33XX),
> CLK(NULL, "dpll_mpu_ck", &dpll_mpu_ck, CK_AM33XX),
> - CLK("cpu0", NULL, &dpll_mpu_ck, CK_AM33XX),
> + CLK("cpufreq-cpu0.0", NULL, &dpll_mpu_ck, CK_AM33XX),
> CLK(NULL, "dpll_mpu_m2_ck", &dpll_mpu_m2_ck, CK_AM33XX),
> CLK(NULL, "dpll_ddr_ck", &dpll_ddr_ck, CK_AM33XX),
> CLK(NULL, "dpll_ddr_m2_ck", &dpll_ddr_m2_ck, CK_AM33XX),
> diff --git a/arch/arm/mach-omap2/common.h b/arch/arm/mach-omap2/common.h
> index 948bcaa..e3355df5 100644
> --- a/arch/arm/mach-omap2/common.h
> +++ b/arch/arm/mach-omap2/common.h
> @@ -106,6 +106,7 @@ void omap2430_init_late(void);
> void omap3430_init_late(void);
> void omap35xx_init_late(void);
> void omap3630_init_late(void);
> +void am33xx_init_late(void);
> void am35xx_init_late(void);
> void ti81xx_init_late(void);
> void omap4430_init_late(void);
> diff --git a/arch/arm/mach-omap2/io.c b/arch/arm/mach-omap2/io.c
> index 2c3fdd6..0e67711 100644
> --- a/arch/arm/mach-omap2/io.c
> +++ b/arch/arm/mach-omap2/io.c
> @@ -535,6 +535,14 @@ void __init omap3630_init_late(void)
> omap2_clk_enable_autoidle_all();
> }
>
> +void __init am33xx_init_late(void)
> +{
> + struct platform_device_info devinfo = { .name = "cpufreq-cpu0", };
> +
> + if (IS_ENABLED(CONFIG_GENERIC_CPUFREQ_CPU0))
> + platform_device_register_full(&devinfo);
> +}
> +
> void __init am35xx_init_late(void)
> {
> omap_mux_late_init();
> --
> 1.7.9.5
>
>
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH] ARM: omap2: register cpufreq-cpu0 device for am33xx
2013-01-31 9:40 ` AnilKumar, Chimata
@ 2013-01-31 12:31 ` Shawn Guo
0 siblings, 0 replies; 3+ messages in thread
From: Shawn Guo @ 2013-01-31 12:31 UTC (permalink / raw)
To: linux-arm-kernel
On Thu, Jan 31, 2013 at 09:40:43AM +0000, AnilKumar, Chimata wrote:
> On Wed, Jan 30, 2013 at 20:02:22, Shawn Guo wrote:
> > The cpufreq-cpu0 driver changes to instantiate use platform_driver
> > mechanism. The patch is an am33xx platform level adaptation for it.
>
> Tested-by: AnilKumar Ch <anilkumar@ti.com>
>
Thanks, AnilKumar.
> Hi Shawn,
>
> I have tested your patch on AM335x-EVM, no issues observed.
>
> I think, better post v3 version which contains this patch
> and cpu0-cpufreq driver changes.
>
> Or
>
> Post v3 of cpufreq-cpu0 driver changes.
>
Sorry for forgetting copying you guys. It's been posted as below.
http://www.spinics.net/lists/arm-kernel/msg221209.html
Shawn
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-01-31 12:31 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-30 14:32 [PATCH] ARM: omap2: register cpufreq-cpu0 device for am33xx Shawn Guo
2013-01-31 9:40 ` AnilKumar, Chimata
2013-01-31 12:31 ` Shawn Guo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).