All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
@ 2012-03-27  0:19 ` Kevin Hilman
  0 siblings, 0 replies; 14+ messages in thread
From: Kevin Hilman @ 2012-03-27  0:19 UTC (permalink / raw)
  To: Dave Jones, cpufreq, Russell King
  Cc: linux-omap, linux-arm-kernel, Grazvydas Ignotas

The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
builds for OMAP2+ platforms.

This 'depends on' was in the original patch from Russell King, but was
erroneously removed by me when making this option user-selectable in
commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
patch remedies that.

Apologies to Russell King for breaking his originally working patch.

Also, thanks to Grazvydas Ignotas for reporting the same problem.

Cc: Russell King <rmk+kernel@arm.linux.org.uk>
Cc: Grazvydas Ignotas <notasas@gmail.com>
Signed-off-by: Kevin Hilman <khilman@ti.com>
---
Dave, this applies on top of your current fixes branch, and fixes a 
problem introduced there by me.  Please merge for v3.4-rc.  Thanks.

 drivers/cpufreq/Kconfig.arm |    1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
index 82f1aa9..555a57b 100644
--- a/drivers/cpufreq/Kconfig.arm
+++ b/drivers/cpufreq/Kconfig.arm
@@ -4,6 +4,7 @@
 
 config ARM_OMAP2PLUS_CPUFREQ
 	bool "TI OMAP2+"
+	depends on ARCH_OMAP2PLUS
 	default ARCH_OMAP2PLUS
 	select CPU_FREQ_TABLE
 
-- 
1.7.9.2


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
@ 2012-03-27  0:19 ` Kevin Hilman
  0 siblings, 0 replies; 14+ messages in thread
From: Kevin Hilman @ 2012-03-27  0:19 UTC (permalink / raw)
  To: linux-arm-kernel

The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
builds for OMAP2+ platforms.

This 'depends on' was in the original patch from Russell King, but was
erroneously removed by me when making this option user-selectable in
commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
patch remedies that.

Apologies to Russell King for breaking his originally working patch.

Also, thanks to Grazvydas Ignotas for reporting the same problem.

Cc: Russell King <rmk+kernel@arm.linux.org.uk>
Cc: Grazvydas Ignotas <notasas@gmail.com>
Signed-off-by: Kevin Hilman <khilman@ti.com>
---
Dave, this applies on top of your current fixes branch, and fixes a 
problem introduced there by me.  Please merge for v3.4-rc.  Thanks.

 drivers/cpufreq/Kconfig.arm |    1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
index 82f1aa9..555a57b 100644
--- a/drivers/cpufreq/Kconfig.arm
+++ b/drivers/cpufreq/Kconfig.arm
@@ -4,6 +4,7 @@
 
 config ARM_OMAP2PLUS_CPUFREQ
 	bool "TI OMAP2+"
+	depends on ARCH_OMAP2PLUS
 	default ARCH_OMAP2PLUS
 	select CPU_FREQ_TABLE
 
-- 
1.7.9.2

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
  2012-03-27  0:19 ` Kevin Hilman
@ 2012-03-30 13:12   ` Russell King - ARM Linux
  -1 siblings, 0 replies; 14+ messages in thread
From: Russell King - ARM Linux @ 2012-03-30 13:12 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: Dave Jones, cpufreq, linux-omap, linux-arm-kernel, Grazvydas Ignotas

On Mon, Mar 26, 2012 at 05:19:28PM -0700, Kevin Hilman wrote:
> The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
> builds for OMAP2+ platforms.
> 
> This 'depends on' was in the original patch from Russell King, but was
> erroneously removed by me when making this option user-selectable in
> commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
> patch remedies that.
> 
> Apologies to Russell King for breaking his originally working patch.
> 
> Also, thanks to Grazvydas Ignotas for reporting the same problem.
> 
> Cc: Russell King <rmk+kernel@arm.linux.org.uk>
> Cc: Grazvydas Ignotas <notasas@gmail.com>
> Signed-off-by: Kevin Hilman <khilman@ti.com>
> ---
> Dave, this applies on top of your current fixes branch, and fixes a 
> problem introduced there by me.  Please merge for v3.4-rc.  Thanks.

Can you please check that you've picked up everything that's necessary,
as I'm still seeing the below as outstanding from my original patch.

commit e55a42528cebb8fa7408dc95abb3859639a46750
Author: Russell King <rmk+kernel@arm.linux.org.uk>
Date:   Wed Feb 15 11:20:51 2012 +0000

    ARM: OMAP: fix cpufreq build
    
    OMAPs cpufreq requires the frequency table support, but nothing ensures
    that this is selected.  This can result in configurations which fail to
    build:
    
    drivers/built-in.o:(.data+0x5238): undefined reference to `cpufreq_freq_attr_scaling_available_freqs'
    drivers/cpufreq/omap-cpufreq.c:88: undefined reference to `cpufreq_frequency_table_target'
    drivers/cpufreq/omap-cpufreq.c:60: undefined reference to `cpufreq_frequency_table_verify'
    drivers/cpufreq/omap-cpufreq.c:186: undefined reference to `cpufreq_frequency_table_cpuinfo'
    drivers/cpufreq/omap-cpufreq.c:190: undefined reference to `cpufreq_frequency_table_get_attr'
    
    Fix this by introducing a new configuration variable and having that
    select CPU_FREQ_TABLE.
    
    Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>

diff --git a/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c b/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
index 7072e0d..ad35d4e 100644
--- a/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
+++ b/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
@@ -166,7 +166,7 @@ int omap2_select_table_rate(struct clk *clk, unsigned long rate)
 	return 0;
 }
 
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 /*
  * Walk PRCM rate table and fillout cpufreq freq_table
  * XXX This should be replaced by an OPP layer in the near future
diff --git a/arch/arm/mach-omap2/clock.c b/arch/arm/mach-omap2/clock.c
index f57ed5b..450feb0 100644
--- a/arch/arm/mach-omap2/clock.c
+++ b/arch/arm/mach-omap2/clock.c
@@ -536,7 +536,7 @@ struct clk_functions omap2_clk_functions = {
 	.clk_set_rate		= omap2_clk_set_rate,
 	.clk_set_parent		= omap2_clk_set_parent,
 	.clk_disable_unused	= omap2_clk_disable_unused,
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 	/* These will be removed when the OPP code is integrated */
 	.clk_init_cpufreq_table	= omap2_clk_init_cpufreq_table,
 	.clk_exit_cpufreq_table	= omap2_clk_exit_cpufreq_table,
diff --git a/arch/arm/mach-omap2/clock.h b/arch/arm/mach-omap2/clock.h
index b8c2a68..f331cfc 100644
--- a/arch/arm/mach-omap2/clock.h
+++ b/arch/arm/mach-omap2/clock.h
@@ -146,7 +146,7 @@ extern const struct clksel_rate gpt_sys_rates[];
 extern const struct clksel_rate gfx_l3_rates[];
 extern const struct clksel_rate dsp_ick_rates[];
 
-#if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_CPU_FREQ)
+#if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_ARM_OMAP2PLUS_CPUFREQ)
 extern void omap2_clk_init_cpufreq_table(struct cpufreq_frequency_table **table);
 extern void omap2_clk_exit_cpufreq_table(struct cpufreq_frequency_table **table);
 #else
diff --git a/arch/arm/plat-omap/clock.c b/arch/arm/plat-omap/clock.c
index 56b6f8b..618cf80 100644
--- a/arch/arm/plat-omap/clock.c
+++ b/arch/arm/plat-omap/clock.c
@@ -398,7 +398,7 @@ struct clk dummy_ck = {
 	.ops	= &clkops_null,
 };
 
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 void clk_init_cpufreq_table(struct cpufreq_frequency_table **table)
 {
 	unsigned long flags;
diff --git a/arch/arm/plat-omap/include/plat/clock.h b/arch/arm/plat-omap/include/plat/clock.h
index 240a7b9..879ba27 100644
--- a/arch/arm/plat-omap/include/plat/clock.h
+++ b/arch/arm/plat-omap/include/plat/clock.h
@@ -283,7 +283,7 @@ struct clk_functions {
 	void		(*clk_allow_idle)(struct clk *clk);
 	void		(*clk_deny_idle)(struct clk *clk);
 	void		(*clk_disable_unused)(struct clk *clk);
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 	void		(*clk_init_cpufreq_table)(struct cpufreq_frequency_table **);
 	void		(*clk_exit_cpufreq_table)(struct cpufreq_frequency_table **);
 #endif
@@ -301,7 +301,7 @@ extern void recalculate_root_clocks(void);
 extern unsigned long followparent_recalc(struct clk *clk);
 extern void clk_enable_init_clocks(void);
 unsigned long omap_fixed_divisor_recalc(struct clk *clk);
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 extern void clk_init_cpufreq_table(struct cpufreq_frequency_table **table);
 extern void clk_exit_cpufreq_table(struct cpufreq_frequency_table **table);
 #endif
diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
index 32d790d..587b578 100644
--- a/drivers/cpufreq/Kconfig.arm
+++ b/drivers/cpufreq/Kconfig.arm
@@ -3,8 +3,8 @@
 #
 
 config ARM_OMAP2PLUS_CPUFREQ
-	bool "TI OMAP2+"
-	default ARCH_OMAP2PLUS
+	def_bool y
+	depends on ARCH_OMAP2PLUS
 	select CPU_FREQ_TABLE
 
 config ARM_S3C2416_CPUFREQ


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
@ 2012-03-30 13:12   ` Russell King - ARM Linux
  0 siblings, 0 replies; 14+ messages in thread
From: Russell King - ARM Linux @ 2012-03-30 13:12 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Mar 26, 2012 at 05:19:28PM -0700, Kevin Hilman wrote:
> The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
> builds for OMAP2+ platforms.
> 
> This 'depends on' was in the original patch from Russell King, but was
> erroneously removed by me when making this option user-selectable in
> commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
> patch remedies that.
> 
> Apologies to Russell King for breaking his originally working patch.
> 
> Also, thanks to Grazvydas Ignotas for reporting the same problem.
> 
> Cc: Russell King <rmk+kernel@arm.linux.org.uk>
> Cc: Grazvydas Ignotas <notasas@gmail.com>
> Signed-off-by: Kevin Hilman <khilman@ti.com>
> ---
> Dave, this applies on top of your current fixes branch, and fixes a 
> problem introduced there by me.  Please merge for v3.4-rc.  Thanks.

Can you please check that you've picked up everything that's necessary,
as I'm still seeing the below as outstanding from my original patch.

commit e55a42528cebb8fa7408dc95abb3859639a46750
Author: Russell King <rmk+kernel@arm.linux.org.uk>
Date:   Wed Feb 15 11:20:51 2012 +0000

    ARM: OMAP: fix cpufreq build
    
    OMAPs cpufreq requires the frequency table support, but nothing ensures
    that this is selected.  This can result in configurations which fail to
    build:
    
    drivers/built-in.o:(.data+0x5238): undefined reference to `cpufreq_freq_attr_scaling_available_freqs'
    drivers/cpufreq/omap-cpufreq.c:88: undefined reference to `cpufreq_frequency_table_target'
    drivers/cpufreq/omap-cpufreq.c:60: undefined reference to `cpufreq_frequency_table_verify'
    drivers/cpufreq/omap-cpufreq.c:186: undefined reference to `cpufreq_frequency_table_cpuinfo'
    drivers/cpufreq/omap-cpufreq.c:190: undefined reference to `cpufreq_frequency_table_get_attr'
    
    Fix this by introducing a new configuration variable and having that
    select CPU_FREQ_TABLE.
    
    Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>

diff --git a/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c b/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
index 7072e0d..ad35d4e 100644
--- a/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
+++ b/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
@@ -166,7 +166,7 @@ int omap2_select_table_rate(struct clk *clk, unsigned long rate)
 	return 0;
 }
 
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 /*
  * Walk PRCM rate table and fillout cpufreq freq_table
  * XXX This should be replaced by an OPP layer in the near future
diff --git a/arch/arm/mach-omap2/clock.c b/arch/arm/mach-omap2/clock.c
index f57ed5b..450feb0 100644
--- a/arch/arm/mach-omap2/clock.c
+++ b/arch/arm/mach-omap2/clock.c
@@ -536,7 +536,7 @@ struct clk_functions omap2_clk_functions = {
 	.clk_set_rate		= omap2_clk_set_rate,
 	.clk_set_parent		= omap2_clk_set_parent,
 	.clk_disable_unused	= omap2_clk_disable_unused,
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 	/* These will be removed when the OPP code is integrated */
 	.clk_init_cpufreq_table	= omap2_clk_init_cpufreq_table,
 	.clk_exit_cpufreq_table	= omap2_clk_exit_cpufreq_table,
diff --git a/arch/arm/mach-omap2/clock.h b/arch/arm/mach-omap2/clock.h
index b8c2a68..f331cfc 100644
--- a/arch/arm/mach-omap2/clock.h
+++ b/arch/arm/mach-omap2/clock.h
@@ -146,7 +146,7 @@ extern const struct clksel_rate gpt_sys_rates[];
 extern const struct clksel_rate gfx_l3_rates[];
 extern const struct clksel_rate dsp_ick_rates[];
 
-#if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_CPU_FREQ)
+#if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_ARM_OMAP2PLUS_CPUFREQ)
 extern void omap2_clk_init_cpufreq_table(struct cpufreq_frequency_table **table);
 extern void omap2_clk_exit_cpufreq_table(struct cpufreq_frequency_table **table);
 #else
diff --git a/arch/arm/plat-omap/clock.c b/arch/arm/plat-omap/clock.c
index 56b6f8b..618cf80 100644
--- a/arch/arm/plat-omap/clock.c
+++ b/arch/arm/plat-omap/clock.c
@@ -398,7 +398,7 @@ struct clk dummy_ck = {
 	.ops	= &clkops_null,
 };
 
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 void clk_init_cpufreq_table(struct cpufreq_frequency_table **table)
 {
 	unsigned long flags;
diff --git a/arch/arm/plat-omap/include/plat/clock.h b/arch/arm/plat-omap/include/plat/clock.h
index 240a7b9..879ba27 100644
--- a/arch/arm/plat-omap/include/plat/clock.h
+++ b/arch/arm/plat-omap/include/plat/clock.h
@@ -283,7 +283,7 @@ struct clk_functions {
 	void		(*clk_allow_idle)(struct clk *clk);
 	void		(*clk_deny_idle)(struct clk *clk);
 	void		(*clk_disable_unused)(struct clk *clk);
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 	void		(*clk_init_cpufreq_table)(struct cpufreq_frequency_table **);
 	void		(*clk_exit_cpufreq_table)(struct cpufreq_frequency_table **);
 #endif
@@ -301,7 +301,7 @@ extern void recalculate_root_clocks(void);
 extern unsigned long followparent_recalc(struct clk *clk);
 extern void clk_enable_init_clocks(void);
 unsigned long omap_fixed_divisor_recalc(struct clk *clk);
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 extern void clk_init_cpufreq_table(struct cpufreq_frequency_table **table);
 extern void clk_exit_cpufreq_table(struct cpufreq_frequency_table **table);
 #endif
diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
index 32d790d..587b578 100644
--- a/drivers/cpufreq/Kconfig.arm
+++ b/drivers/cpufreq/Kconfig.arm
@@ -3,8 +3,8 @@
 #
 
 config ARM_OMAP2PLUS_CPUFREQ
-	bool "TI OMAP2+"
-	default ARCH_OMAP2PLUS
+	def_bool y
+	depends on ARCH_OMAP2PLUS
 	select CPU_FREQ_TABLE
 
 config ARM_S3C2416_CPUFREQ

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
  2012-03-30 13:12   ` Russell King - ARM Linux
@ 2012-03-30 14:24     ` Kevin Hilman
  -1 siblings, 0 replies; 14+ messages in thread
From: Kevin Hilman @ 2012-03-30 14:24 UTC (permalink / raw)
  To: Russell King - ARM Linux, Paul Walmsley, Tony Lindgren
  Cc: Dave Jones, cpufreq, linux-omap, linux-arm-kernel, Grazvydas Ignotas

Russell King - ARM Linux <linux@arm.linux.org.uk> writes:

> On Mon, Mar 26, 2012 at 05:19:28PM -0700, Kevin Hilman wrote:
>> The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
>> builds for OMAP2+ platforms.
>> 
>> This 'depends on' was in the original patch from Russell King, but was
>> erroneously removed by me when making this option user-selectable in
>> commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
>> patch remedies that.
>> 
>> Apologies to Russell King for breaking his originally working patch.
>> 
>> Also, thanks to Grazvydas Ignotas for reporting the same problem.
>> 
>> Cc: Russell King <rmk+kernel@arm.linux.org.uk>
>> Cc: Grazvydas Ignotas <notasas@gmail.com>
>> Signed-off-by: Kevin Hilman <khilman@ti.com>
>> ---
>> Dave, this applies on top of your current fixes branch, and fixes a 
>> problem introduced there by me.  Please merge for v3.4-rc.  Thanks.
>
> Can you please check that you've picked up everything that's necessary,
> as I'm still seeing the below as outstanding from my original patch.

Yes, all the code you touch below is now removed, and queued by Paul,
but unfortunately, that branch didn't make it in time for v3.4. :(

Paul, maybe you can pull out my "cleanup cpufreq leftovers" patch and
submit for v3.4-rc?

Thanks,

Kevin

>
> commit e55a42528cebb8fa7408dc95abb3859639a46750
> Author: Russell King <rmk+kernel@arm.linux.org.uk>
> Date:   Wed Feb 15 11:20:51 2012 +0000
>
>     ARM: OMAP: fix cpufreq build
>     
>     OMAPs cpufreq requires the frequency table support, but nothing ensures
>     that this is selected.  This can result in configurations which fail to
>     build:
>     
>     drivers/built-in.o:(.data+0x5238): undefined reference to `cpufreq_freq_attr_scaling_available_freqs'
>     drivers/cpufreq/omap-cpufreq.c:88: undefined reference to `cpufreq_frequency_table_target'
>     drivers/cpufreq/omap-cpufreq.c:60: undefined reference to `cpufreq_frequency_table_verify'
>     drivers/cpufreq/omap-cpufreq.c:186: undefined reference to `cpufreq_frequency_table_cpuinfo'
>     drivers/cpufreq/omap-cpufreq.c:190: undefined reference to `cpufreq_frequency_table_get_attr'
>     
>     Fix this by introducing a new configuration variable and having that
>     select CPU_FREQ_TABLE.
>     
>     Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
>
> diff --git a/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c b/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
> index 7072e0d..ad35d4e 100644
> --- a/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
> +++ b/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
> @@ -166,7 +166,7 @@ int omap2_select_table_rate(struct clk *clk, unsigned long rate)
>  	return 0;
>  }
>  
> -#ifdef CONFIG_CPU_FREQ
> +#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
>  /*
>   * Walk PRCM rate table and fillout cpufreq freq_table
>   * XXX This should be replaced by an OPP layer in the near future
> diff --git a/arch/arm/mach-omap2/clock.c b/arch/arm/mach-omap2/clock.c
> index f57ed5b..450feb0 100644
> --- a/arch/arm/mach-omap2/clock.c
> +++ b/arch/arm/mach-omap2/clock.c
> @@ -536,7 +536,7 @@ struct clk_functions omap2_clk_functions = {
>  	.clk_set_rate		= omap2_clk_set_rate,
>  	.clk_set_parent		= omap2_clk_set_parent,
>  	.clk_disable_unused	= omap2_clk_disable_unused,
> -#ifdef CONFIG_CPU_FREQ
> +#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
>  	/* These will be removed when the OPP code is integrated */
>  	.clk_init_cpufreq_table	= omap2_clk_init_cpufreq_table,
>  	.clk_exit_cpufreq_table	= omap2_clk_exit_cpufreq_table,
> diff --git a/arch/arm/mach-omap2/clock.h b/arch/arm/mach-omap2/clock.h
> index b8c2a68..f331cfc 100644
> --- a/arch/arm/mach-omap2/clock.h
> +++ b/arch/arm/mach-omap2/clock.h
> @@ -146,7 +146,7 @@ extern const struct clksel_rate gpt_sys_rates[];
>  extern const struct clksel_rate gfx_l3_rates[];
>  extern const struct clksel_rate dsp_ick_rates[];
>  
> -#if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_CPU_FREQ)
> +#if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_ARM_OMAP2PLUS_CPUFREQ)
>  extern void omap2_clk_init_cpufreq_table(struct cpufreq_frequency_table **table);
>  extern void omap2_clk_exit_cpufreq_table(struct cpufreq_frequency_table **table);
>  #else
> diff --git a/arch/arm/plat-omap/clock.c b/arch/arm/plat-omap/clock.c
> index 56b6f8b..618cf80 100644
> --- a/arch/arm/plat-omap/clock.c
> +++ b/arch/arm/plat-omap/clock.c
> @@ -398,7 +398,7 @@ struct clk dummy_ck = {
>  	.ops	= &clkops_null,
>  };
>  
> -#ifdef CONFIG_CPU_FREQ
> +#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
>  void clk_init_cpufreq_table(struct cpufreq_frequency_table **table)
>  {
>  	unsigned long flags;
> diff --git a/arch/arm/plat-omap/include/plat/clock.h b/arch/arm/plat-omap/include/plat/clock.h
> index 240a7b9..879ba27 100644
> --- a/arch/arm/plat-omap/include/plat/clock.h
> +++ b/arch/arm/plat-omap/include/plat/clock.h
> @@ -283,7 +283,7 @@ struct clk_functions {
>  	void		(*clk_allow_idle)(struct clk *clk);
>  	void		(*clk_deny_idle)(struct clk *clk);
>  	void		(*clk_disable_unused)(struct clk *clk);
> -#ifdef CONFIG_CPU_FREQ
> +#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
>  	void		(*clk_init_cpufreq_table)(struct cpufreq_frequency_table **);
>  	void		(*clk_exit_cpufreq_table)(struct cpufreq_frequency_table **);
>  #endif
> @@ -301,7 +301,7 @@ extern void recalculate_root_clocks(void);
>  extern unsigned long followparent_recalc(struct clk *clk);
>  extern void clk_enable_init_clocks(void);
>  unsigned long omap_fixed_divisor_recalc(struct clk *clk);
> -#ifdef CONFIG_CPU_FREQ
> +#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
>  extern void clk_init_cpufreq_table(struct cpufreq_frequency_table **table);
>  extern void clk_exit_cpufreq_table(struct cpufreq_frequency_table **table);
>  #endif
> diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
> index 32d790d..587b578 100644
> --- a/drivers/cpufreq/Kconfig.arm
> +++ b/drivers/cpufreq/Kconfig.arm
> @@ -3,8 +3,8 @@
>  #
>  
>  config ARM_OMAP2PLUS_CPUFREQ
> -	bool "TI OMAP2+"
> -	default ARCH_OMAP2PLUS
> +	def_bool y
> +	depends on ARCH_OMAP2PLUS
>  	select CPU_FREQ_TABLE
>  
>  config ARM_S3C2416_CPUFREQ
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
@ 2012-03-30 14:24     ` Kevin Hilman
  0 siblings, 0 replies; 14+ messages in thread
From: Kevin Hilman @ 2012-03-30 14:24 UTC (permalink / raw)
  To: linux-arm-kernel

Russell King - ARM Linux <linux@arm.linux.org.uk> writes:

> On Mon, Mar 26, 2012 at 05:19:28PM -0700, Kevin Hilman wrote:
>> The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
>> builds for OMAP2+ platforms.
>> 
>> This 'depends on' was in the original patch from Russell King, but was
>> erroneously removed by me when making this option user-selectable in
>> commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
>> patch remedies that.
>> 
>> Apologies to Russell King for breaking his originally working patch.
>> 
>> Also, thanks to Grazvydas Ignotas for reporting the same problem.
>> 
>> Cc: Russell King <rmk+kernel@arm.linux.org.uk>
>> Cc: Grazvydas Ignotas <notasas@gmail.com>
>> Signed-off-by: Kevin Hilman <khilman@ti.com>
>> ---
>> Dave, this applies on top of your current fixes branch, and fixes a 
>> problem introduced there by me.  Please merge for v3.4-rc.  Thanks.
>
> Can you please check that you've picked up everything that's necessary,
> as I'm still seeing the below as outstanding from my original patch.

Yes, all the code you touch below is now removed, and queued by Paul,
but unfortunately, that branch didn't make it in time for v3.4. :(

Paul, maybe you can pull out my "cleanup cpufreq leftovers" patch and
submit for v3.4-rc?

Thanks,

Kevin

>
> commit e55a42528cebb8fa7408dc95abb3859639a46750
> Author: Russell King <rmk+kernel@arm.linux.org.uk>
> Date:   Wed Feb 15 11:20:51 2012 +0000
>
>     ARM: OMAP: fix cpufreq build
>     
>     OMAPs cpufreq requires the frequency table support, but nothing ensures
>     that this is selected.  This can result in configurations which fail to
>     build:
>     
>     drivers/built-in.o:(.data+0x5238): undefined reference to `cpufreq_freq_attr_scaling_available_freqs'
>     drivers/cpufreq/omap-cpufreq.c:88: undefined reference to `cpufreq_frequency_table_target'
>     drivers/cpufreq/omap-cpufreq.c:60: undefined reference to `cpufreq_frequency_table_verify'
>     drivers/cpufreq/omap-cpufreq.c:186: undefined reference to `cpufreq_frequency_table_cpuinfo'
>     drivers/cpufreq/omap-cpufreq.c:190: undefined reference to `cpufreq_frequency_table_get_attr'
>     
>     Fix this by introducing a new configuration variable and having that
>     select CPU_FREQ_TABLE.
>     
>     Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
>
> diff --git a/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c b/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
> index 7072e0d..ad35d4e 100644
> --- a/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
> +++ b/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
> @@ -166,7 +166,7 @@ int omap2_select_table_rate(struct clk *clk, unsigned long rate)
>  	return 0;
>  }
>  
> -#ifdef CONFIG_CPU_FREQ
> +#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
>  /*
>   * Walk PRCM rate table and fillout cpufreq freq_table
>   * XXX This should be replaced by an OPP layer in the near future
> diff --git a/arch/arm/mach-omap2/clock.c b/arch/arm/mach-omap2/clock.c
> index f57ed5b..450feb0 100644
> --- a/arch/arm/mach-omap2/clock.c
> +++ b/arch/arm/mach-omap2/clock.c
> @@ -536,7 +536,7 @@ struct clk_functions omap2_clk_functions = {
>  	.clk_set_rate		= omap2_clk_set_rate,
>  	.clk_set_parent		= omap2_clk_set_parent,
>  	.clk_disable_unused	= omap2_clk_disable_unused,
> -#ifdef CONFIG_CPU_FREQ
> +#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
>  	/* These will be removed when the OPP code is integrated */
>  	.clk_init_cpufreq_table	= omap2_clk_init_cpufreq_table,
>  	.clk_exit_cpufreq_table	= omap2_clk_exit_cpufreq_table,
> diff --git a/arch/arm/mach-omap2/clock.h b/arch/arm/mach-omap2/clock.h
> index b8c2a68..f331cfc 100644
> --- a/arch/arm/mach-omap2/clock.h
> +++ b/arch/arm/mach-omap2/clock.h
> @@ -146,7 +146,7 @@ extern const struct clksel_rate gpt_sys_rates[];
>  extern const struct clksel_rate gfx_l3_rates[];
>  extern const struct clksel_rate dsp_ick_rates[];
>  
> -#if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_CPU_FREQ)
> +#if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_ARM_OMAP2PLUS_CPUFREQ)
>  extern void omap2_clk_init_cpufreq_table(struct cpufreq_frequency_table **table);
>  extern void omap2_clk_exit_cpufreq_table(struct cpufreq_frequency_table **table);
>  #else
> diff --git a/arch/arm/plat-omap/clock.c b/arch/arm/plat-omap/clock.c
> index 56b6f8b..618cf80 100644
> --- a/arch/arm/plat-omap/clock.c
> +++ b/arch/arm/plat-omap/clock.c
> @@ -398,7 +398,7 @@ struct clk dummy_ck = {
>  	.ops	= &clkops_null,
>  };
>  
> -#ifdef CONFIG_CPU_FREQ
> +#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
>  void clk_init_cpufreq_table(struct cpufreq_frequency_table **table)
>  {
>  	unsigned long flags;
> diff --git a/arch/arm/plat-omap/include/plat/clock.h b/arch/arm/plat-omap/include/plat/clock.h
> index 240a7b9..879ba27 100644
> --- a/arch/arm/plat-omap/include/plat/clock.h
> +++ b/arch/arm/plat-omap/include/plat/clock.h
> @@ -283,7 +283,7 @@ struct clk_functions {
>  	void		(*clk_allow_idle)(struct clk *clk);
>  	void		(*clk_deny_idle)(struct clk *clk);
>  	void		(*clk_disable_unused)(struct clk *clk);
> -#ifdef CONFIG_CPU_FREQ
> +#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
>  	void		(*clk_init_cpufreq_table)(struct cpufreq_frequency_table **);
>  	void		(*clk_exit_cpufreq_table)(struct cpufreq_frequency_table **);
>  #endif
> @@ -301,7 +301,7 @@ extern void recalculate_root_clocks(void);
>  extern unsigned long followparent_recalc(struct clk *clk);
>  extern void clk_enable_init_clocks(void);
>  unsigned long omap_fixed_divisor_recalc(struct clk *clk);
> -#ifdef CONFIG_CPU_FREQ
> +#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
>  extern void clk_init_cpufreq_table(struct cpufreq_frequency_table **table);
>  extern void clk_exit_cpufreq_table(struct cpufreq_frequency_table **table);
>  #endif
> diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
> index 32d790d..587b578 100644
> --- a/drivers/cpufreq/Kconfig.arm
> +++ b/drivers/cpufreq/Kconfig.arm
> @@ -3,8 +3,8 @@
>  #
>  
>  config ARM_OMAP2PLUS_CPUFREQ
> -	bool "TI OMAP2+"
> -	default ARCH_OMAP2PLUS
> +	def_bool y
> +	depends on ARCH_OMAP2PLUS
>  	select CPU_FREQ_TABLE
>  
>  config ARM_S3C2416_CPUFREQ
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo at vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
  2012-03-27  0:19 ` Kevin Hilman
@ 2012-04-04 22:20   ` Kevin Hilman
  -1 siblings, 0 replies; 14+ messages in thread
From: Kevin Hilman @ 2012-04-04 22:20 UTC (permalink / raw)
  To: Dave Jones, cpufreq, Russell King
  Cc: linux-omap, linux-arm-kernel, Grazvydas Ignotas

Hi Dave,

On 03/26/2012 05:19 PM, Kevin Hilman wrote:
> The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
> builds for OMAP2+ platforms.
>
> This 'depends on' was in the original patch from Russell King, but was
> erroneously removed by me when making this option user-selectable in
> commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
> patch remedies that.
>
> Apologies to Russell King for breaking his originally working patch.
>
> Also, thanks to Grazvydas Ignotas for reporting the same problem.
>
> Cc: Russell King<rmk+kernel@arm.linux.org.uk>
> Cc: Grazvydas Ignotas<notasas@gmail.com>
> Signed-off-by: Kevin Hilman<khilman@ti.com>
> ---
> Dave, this applies on top of your current fixes branch, and fixes a
> problem introduced there by me.  Please merge for v3.4-rc.  Thanks.

Can you pick this up for v3.4-rc?

Thanks,

Kevin

>   drivers/cpufreq/Kconfig.arm |    1 +
>   1 file changed, 1 insertion(+)
>
> diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
> index 82f1aa9..555a57b 100644
> --- a/drivers/cpufreq/Kconfig.arm
> +++ b/drivers/cpufreq/Kconfig.arm
> @@ -4,6 +4,7 @@
>
>   config ARM_OMAP2PLUS_CPUFREQ
>   	bool "TI OMAP2+"
> +	depends on ARCH_OMAP2PLUS
>   	default ARCH_OMAP2PLUS
>   	select CPU_FREQ_TABLE
>

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
@ 2012-04-04 22:20   ` Kevin Hilman
  0 siblings, 0 replies; 14+ messages in thread
From: Kevin Hilman @ 2012-04-04 22:20 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Dave,

On 03/26/2012 05:19 PM, Kevin Hilman wrote:
> The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
> builds for OMAP2+ platforms.
>
> This 'depends on' was in the original patch from Russell King, but was
> erroneously removed by me when making this option user-selectable in
> commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
> patch remedies that.
>
> Apologies to Russell King for breaking his originally working patch.
>
> Also, thanks to Grazvydas Ignotas for reporting the same problem.
>
> Cc: Russell King<rmk+kernel@arm.linux.org.uk>
> Cc: Grazvydas Ignotas<notasas@gmail.com>
> Signed-off-by: Kevin Hilman<khilman@ti.com>
> ---
> Dave, this applies on top of your current fixes branch, and fixes a
> problem introduced there by me.  Please merge for v3.4-rc.  Thanks.

Can you pick this up for v3.4-rc?

Thanks,

Kevin

>   drivers/cpufreq/Kconfig.arm |    1 +
>   1 file changed, 1 insertion(+)
>
> diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
> index 82f1aa9..555a57b 100644
> --- a/drivers/cpufreq/Kconfig.arm
> +++ b/drivers/cpufreq/Kconfig.arm
> @@ -4,6 +4,7 @@
>
>   config ARM_OMAP2PLUS_CPUFREQ
>   	bool "TI OMAP2+"
> +	depends on ARCH_OMAP2PLUS
>   	default ARCH_OMAP2PLUS
>   	select CPU_FREQ_TABLE
>

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
  2012-04-04 22:20   ` Kevin Hilman
@ 2012-04-13 18:53     ` Russell King - ARM Linux
  -1 siblings, 0 replies; 14+ messages in thread
From: Russell King - ARM Linux @ 2012-04-13 18:53 UTC (permalink / raw)
  To: Kevin Hilman, Dave Jones
  Cc: cpufreq, linux-omap, linux-arm-kernel, Grazvydas Ignotas

On Wed, Apr 04, 2012 at 03:20:22PM -0700, Kevin Hilman wrote:
> Hi Dave,
>
> On 03/26/2012 05:19 PM, Kevin Hilman wrote:
>> The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
>> builds for OMAP2+ platforms.
>>
>> This 'depends on' was in the original patch from Russell King, but was
>> erroneously removed by me when making this option user-selectable in
>> commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
>> patch remedies that.
>>
>> Apologies to Russell King for breaking his originally working patch.
>>
>> Also, thanks to Grazvydas Ignotas for reporting the same problem.
>>
>> Cc: Russell King<rmk+kernel@arm.linux.org.uk>
>> Cc: Grazvydas Ignotas<notasas@gmail.com>
>> Signed-off-by: Kevin Hilman<khilman@ti.com>
>> ---
>> Dave, this applies on top of your current fixes branch, and fixes a
>> problem introduced there by me.  Please merge for v3.4-rc.  Thanks.
>
> Can you pick this up for v3.4-rc?

Right, I'm fed up with chasing over this trivial patch.  It's been almost
a full month since the problem was first reported and it _still_ remains
unfixed in mainline, despite me chasing over it.  So, sorry, you lose.

I'm merging my fix (attached) which I've been running against the nightly
builds into my fixes branch and will ask Linus to pull it this weekend.
If you want something else, then please send a patch on top of my fix to
do what you want.

Alternatively, send a replacement fix to Linus _before_ Sunday evening
copying me with it and I'll drop this from my tree.  But I want to see
an alternative going to Linus for that to happen.

8<===
From: Russell King <rmk+kernel@arm.linux.org.uk>
Subject: [PATCH] ARM: OMAP: fix cpufreq build

OMAPs cpufreq requires the frequency table support, but nothing ensures
that this is selected.  This can result in configurations which fail to
build:

drivers/built-in.o:(.data+0x5238): undefined reference to `cpufreq_freq_attr_scaling_available_freqs'
drivers/cpufreq/omap-cpufreq.c:88: undefined reference to `cpufreq_frequency_table_target'
drivers/cpufreq/omap-cpufreq.c:60: undefined reference to `cpufreq_frequency_table_verify'
drivers/cpufreq/omap-cpufreq.c:186: undefined reference to `cpufreq_frequency_table_cpuinfo'
drivers/cpufreq/omap-cpufreq.c:190: undefined reference to `cpufreq_frequency_table_get_attr'

Fix this by introducing a new configuration variable and having that
select CPU_FREQ_TABLE.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
---
 arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c |    2 +-
 arch/arm/mach-omap2/clock.c                  |    2 +-
 arch/arm/mach-omap2/clock.h                  |    2 +-
 arch/arm/plat-omap/clock.c                   |    2 +-
 arch/arm/plat-omap/include/plat/clock.h      |    4 ++--
 drivers/cpufreq/Kconfig.arm                  |    4 ++--
 6 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c b/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
index 7072e0d..ad35d4e 100644
--- a/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
+++ b/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
@@ -166,7 +166,7 @@ int omap2_select_table_rate(struct clk *clk, unsigned long rate)
 	return 0;
 }
 
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 /*
  * Walk PRCM rate table and fillout cpufreq freq_table
  * XXX This should be replaced by an OPP layer in the near future
diff --git a/arch/arm/mach-omap2/clock.c b/arch/arm/mach-omap2/clock.c
index f57ed5b..450feb0 100644
--- a/arch/arm/mach-omap2/clock.c
+++ b/arch/arm/mach-omap2/clock.c
@@ -536,7 +536,7 @@ struct clk_functions omap2_clk_functions = {
 	.clk_set_rate		= omap2_clk_set_rate,
 	.clk_set_parent		= omap2_clk_set_parent,
 	.clk_disable_unused	= omap2_clk_disable_unused,
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 	/* These will be removed when the OPP code is integrated */
 	.clk_init_cpufreq_table	= omap2_clk_init_cpufreq_table,
 	.clk_exit_cpufreq_table	= omap2_clk_exit_cpufreq_table,
diff --git a/arch/arm/mach-omap2/clock.h b/arch/arm/mach-omap2/clock.h
index b8c2a68..f331cfc 100644
--- a/arch/arm/mach-omap2/clock.h
+++ b/arch/arm/mach-omap2/clock.h
@@ -146,7 +146,7 @@ extern const struct clksel_rate gpt_sys_rates[];
 extern const struct clksel_rate gfx_l3_rates[];
 extern const struct clksel_rate dsp_ick_rates[];
 
-#if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_CPU_FREQ)
+#if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_ARM_OMAP2PLUS_CPUFREQ)
 extern void omap2_clk_init_cpufreq_table(struct cpufreq_frequency_table **table);
 extern void omap2_clk_exit_cpufreq_table(struct cpufreq_frequency_table **table);
 #else
diff --git a/arch/arm/plat-omap/clock.c b/arch/arm/plat-omap/clock.c
index 8506cbb..304bf4e 100644
--- a/arch/arm/plat-omap/clock.c
+++ b/arch/arm/plat-omap/clock.c
@@ -398,7 +398,7 @@ struct clk dummy_ck = {
 	.ops	= &clkops_null,
 };
 
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 void clk_init_cpufreq_table(struct cpufreq_frequency_table **table)
 {
 	unsigned long flags;
diff --git a/arch/arm/plat-omap/include/plat/clock.h b/arch/arm/plat-omap/include/plat/clock.h
index 240a7b9..879ba27 100644
--- a/arch/arm/plat-omap/include/plat/clock.h
+++ b/arch/arm/plat-omap/include/plat/clock.h
@@ -283,7 +283,7 @@ struct clk_functions {
 	void		(*clk_allow_idle)(struct clk *clk);
 	void		(*clk_deny_idle)(struct clk *clk);
 	void		(*clk_disable_unused)(struct clk *clk);
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 	void		(*clk_init_cpufreq_table)(struct cpufreq_frequency_table **);
 	void		(*clk_exit_cpufreq_table)(struct cpufreq_frequency_table **);
 #endif
@@ -301,7 +301,7 @@ extern void recalculate_root_clocks(void);
 extern unsigned long followparent_recalc(struct clk *clk);
 extern void clk_enable_init_clocks(void);
 unsigned long omap_fixed_divisor_recalc(struct clk *clk);
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 extern void clk_init_cpufreq_table(struct cpufreq_frequency_table **table);
 extern void clk_exit_cpufreq_table(struct cpufreq_frequency_table **table);
 #endif
diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
index ffbb446..9e8f7a9 100644
--- a/drivers/cpufreq/Kconfig.arm
+++ b/drivers/cpufreq/Kconfig.arm
@@ -3,8 +3,8 @@
 #
 
 config ARM_OMAP2PLUS_CPUFREQ
-	bool "TI OMAP2+"
-	default ARCH_OMAP2PLUS
+	def_bool y
+	depends on ARCH_OMAP2PLUS
 	select CPU_FREQ_TABLE
 
 config ARM_S3C2416_CPUFREQ
-- 
1.7.4.4


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
@ 2012-04-13 18:53     ` Russell King - ARM Linux
  0 siblings, 0 replies; 14+ messages in thread
From: Russell King - ARM Linux @ 2012-04-13 18:53 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, Apr 04, 2012 at 03:20:22PM -0700, Kevin Hilman wrote:
> Hi Dave,
>
> On 03/26/2012 05:19 PM, Kevin Hilman wrote:
>> The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
>> builds for OMAP2+ platforms.
>>
>> This 'depends on' was in the original patch from Russell King, but was
>> erroneously removed by me when making this option user-selectable in
>> commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
>> patch remedies that.
>>
>> Apologies to Russell King for breaking his originally working patch.
>>
>> Also, thanks to Grazvydas Ignotas for reporting the same problem.
>>
>> Cc: Russell King<rmk+kernel@arm.linux.org.uk>
>> Cc: Grazvydas Ignotas<notasas@gmail.com>
>> Signed-off-by: Kevin Hilman<khilman@ti.com>
>> ---
>> Dave, this applies on top of your current fixes branch, and fixes a
>> problem introduced there by me.  Please merge for v3.4-rc.  Thanks.
>
> Can you pick this up for v3.4-rc?

Right, I'm fed up with chasing over this trivial patch.  It's been almost
a full month since the problem was first reported and it _still_ remains
unfixed in mainline, despite me chasing over it.  So, sorry, you lose.

I'm merging my fix (attached) which I've been running against the nightly
builds into my fixes branch and will ask Linus to pull it this weekend.
If you want something else, then please send a patch on top of my fix to
do what you want.

Alternatively, send a replacement fix to Linus _before_ Sunday evening
copying me with it and I'll drop this from my tree.  But I want to see
an alternative going to Linus for that to happen.

8<===
From: Russell King <rmk+kernel@arm.linux.org.uk>
Subject: [PATCH] ARM: OMAP: fix cpufreq build

OMAPs cpufreq requires the frequency table support, but nothing ensures
that this is selected.  This can result in configurations which fail to
build:

drivers/built-in.o:(.data+0x5238): undefined reference to `cpufreq_freq_attr_scaling_available_freqs'
drivers/cpufreq/omap-cpufreq.c:88: undefined reference to `cpufreq_frequency_table_target'
drivers/cpufreq/omap-cpufreq.c:60: undefined reference to `cpufreq_frequency_table_verify'
drivers/cpufreq/omap-cpufreq.c:186: undefined reference to `cpufreq_frequency_table_cpuinfo'
drivers/cpufreq/omap-cpufreq.c:190: undefined reference to `cpufreq_frequency_table_get_attr'

Fix this by introducing a new configuration variable and having that
select CPU_FREQ_TABLE.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
---
 arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c |    2 +-
 arch/arm/mach-omap2/clock.c                  |    2 +-
 arch/arm/mach-omap2/clock.h                  |    2 +-
 arch/arm/plat-omap/clock.c                   |    2 +-
 arch/arm/plat-omap/include/plat/clock.h      |    4 ++--
 drivers/cpufreq/Kconfig.arm                  |    4 ++--
 6 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c b/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
index 7072e0d..ad35d4e 100644
--- a/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
+++ b/arch/arm/mach-omap2/clkt2xxx_virt_prcm_set.c
@@ -166,7 +166,7 @@ int omap2_select_table_rate(struct clk *clk, unsigned long rate)
 	return 0;
 }
 
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 /*
  * Walk PRCM rate table and fillout cpufreq freq_table
  * XXX This should be replaced by an OPP layer in the near future
diff --git a/arch/arm/mach-omap2/clock.c b/arch/arm/mach-omap2/clock.c
index f57ed5b..450feb0 100644
--- a/arch/arm/mach-omap2/clock.c
+++ b/arch/arm/mach-omap2/clock.c
@@ -536,7 +536,7 @@ struct clk_functions omap2_clk_functions = {
 	.clk_set_rate		= omap2_clk_set_rate,
 	.clk_set_parent		= omap2_clk_set_parent,
 	.clk_disable_unused	= omap2_clk_disable_unused,
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 	/* These will be removed when the OPP code is integrated */
 	.clk_init_cpufreq_table	= omap2_clk_init_cpufreq_table,
 	.clk_exit_cpufreq_table	= omap2_clk_exit_cpufreq_table,
diff --git a/arch/arm/mach-omap2/clock.h b/arch/arm/mach-omap2/clock.h
index b8c2a68..f331cfc 100644
--- a/arch/arm/mach-omap2/clock.h
+++ b/arch/arm/mach-omap2/clock.h
@@ -146,7 +146,7 @@ extern const struct clksel_rate gpt_sys_rates[];
 extern const struct clksel_rate gfx_l3_rates[];
 extern const struct clksel_rate dsp_ick_rates[];
 
-#if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_CPU_FREQ)
+#if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_ARM_OMAP2PLUS_CPUFREQ)
 extern void omap2_clk_init_cpufreq_table(struct cpufreq_frequency_table **table);
 extern void omap2_clk_exit_cpufreq_table(struct cpufreq_frequency_table **table);
 #else
diff --git a/arch/arm/plat-omap/clock.c b/arch/arm/plat-omap/clock.c
index 8506cbb..304bf4e 100644
--- a/arch/arm/plat-omap/clock.c
+++ b/arch/arm/plat-omap/clock.c
@@ -398,7 +398,7 @@ struct clk dummy_ck = {
 	.ops	= &clkops_null,
 };
 
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 void clk_init_cpufreq_table(struct cpufreq_frequency_table **table)
 {
 	unsigned long flags;
diff --git a/arch/arm/plat-omap/include/plat/clock.h b/arch/arm/plat-omap/include/plat/clock.h
index 240a7b9..879ba27 100644
--- a/arch/arm/plat-omap/include/plat/clock.h
+++ b/arch/arm/plat-omap/include/plat/clock.h
@@ -283,7 +283,7 @@ struct clk_functions {
 	void		(*clk_allow_idle)(struct clk *clk);
 	void		(*clk_deny_idle)(struct clk *clk);
 	void		(*clk_disable_unused)(struct clk *clk);
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 	void		(*clk_init_cpufreq_table)(struct cpufreq_frequency_table **);
 	void		(*clk_exit_cpufreq_table)(struct cpufreq_frequency_table **);
 #endif
@@ -301,7 +301,7 @@ extern void recalculate_root_clocks(void);
 extern unsigned long followparent_recalc(struct clk *clk);
 extern void clk_enable_init_clocks(void);
 unsigned long omap_fixed_divisor_recalc(struct clk *clk);
-#ifdef CONFIG_CPU_FREQ
+#ifdef CONFIG_ARM_OMAP2PLUS_CPUFREQ
 extern void clk_init_cpufreq_table(struct cpufreq_frequency_table **table);
 extern void clk_exit_cpufreq_table(struct cpufreq_frequency_table **table);
 #endif
diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
index ffbb446..9e8f7a9 100644
--- a/drivers/cpufreq/Kconfig.arm
+++ b/drivers/cpufreq/Kconfig.arm
@@ -3,8 +3,8 @@
 #
 
 config ARM_OMAP2PLUS_CPUFREQ
-	bool "TI OMAP2+"
-	default ARCH_OMAP2PLUS
+	def_bool y
+	depends on ARCH_OMAP2PLUS
 	select CPU_FREQ_TABLE
 
 config ARM_S3C2416_CPUFREQ
-- 
1.7.4.4

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
  2012-04-13 18:53     ` Russell King - ARM Linux
@ 2012-04-13 21:31       ` Kevin Hilman
  -1 siblings, 0 replies; 14+ messages in thread
From: Kevin Hilman @ 2012-04-13 21:31 UTC (permalink / raw)
  To: Russell King - ARM Linux
  Cc: Dave Jones, cpufreq, linux-omap, linux-arm-kernel, Grazvydas Ignotas

Russell King - ARM Linux <linux@arm.linux.org.uk> writes:

> On Wed, Apr 04, 2012 at 03:20:22PM -0700, Kevin Hilman wrote:
>> Hi Dave,
>>
>> On 03/26/2012 05:19 PM, Kevin Hilman wrote:
>>> The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
>>> builds for OMAP2+ platforms.
>>>
>>> This 'depends on' was in the original patch from Russell King, but was
>>> erroneously removed by me when making this option user-selectable in
>>> commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
>>> patch remedies that.
>>>
>>> Apologies to Russell King for breaking his originally working patch.
>>>
>>> Also, thanks to Grazvydas Ignotas for reporting the same problem.
>>>
>>> Cc: Russell King<rmk+kernel@arm.linux.org.uk>
>>> Cc: Grazvydas Ignotas<notasas@gmail.com>
>>> Signed-off-by: Kevin Hilman<khilman@ti.com>
>>> ---
>>> Dave, this applies on top of your current fixes branch, and fixes a
>>> problem introduced there by me.  Please merge for v3.4-rc.  Thanks.
>>
>> Can you pick this up for v3.4-rc?
>
> Right, I'm fed up with chasing over this trivial patch.  It's been almost
> a full month since the problem was first reported and it _still_ remains
> unfixed in mainline, despite me chasing over it.  So, sorry, you lose.
>
> I'm merging my fix (attached) which I've been running against the nightly
> builds into my fixes branch and will ask Linus to pull it this weekend.
> If you want something else, then please send a patch on top of my fix to
> do what you want.
>
> Alternatively, send a replacement fix to Linus _before_ Sunday evening
> copying me with it and I'll drop this from my tree.  But I want to see
> an alternative going to Linus for that to happen.

I've (re)sent the patches now.

I just resent the CPUfreq driver Kconfig fix, this time directly to Linus.

I also just resent the arch/arm/mach-omap2 one to Tony/Paul with a
slightly updated changelog making it clear that removing that dead code
also fixes build errors so it can be queued ASAP for v3.4-rc.

Combined, those fix the problems your patch addresses.

Kevin


^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
@ 2012-04-13 21:31       ` Kevin Hilman
  0 siblings, 0 replies; 14+ messages in thread
From: Kevin Hilman @ 2012-04-13 21:31 UTC (permalink / raw)
  To: linux-arm-kernel

Russell King - ARM Linux <linux@arm.linux.org.uk> writes:

> On Wed, Apr 04, 2012 at 03:20:22PM -0700, Kevin Hilman wrote:
>> Hi Dave,
>>
>> On 03/26/2012 05:19 PM, Kevin Hilman wrote:
>>> The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
>>> builds for OMAP2+ platforms.
>>>
>>> This 'depends on' was in the original patch from Russell King, but was
>>> erroneously removed by me when making this option user-selectable in
>>> commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
>>> patch remedies that.
>>>
>>> Apologies to Russell King for breaking his originally working patch.
>>>
>>> Also, thanks to Grazvydas Ignotas for reporting the same problem.
>>>
>>> Cc: Russell King<rmk+kernel@arm.linux.org.uk>
>>> Cc: Grazvydas Ignotas<notasas@gmail.com>
>>> Signed-off-by: Kevin Hilman<khilman@ti.com>
>>> ---
>>> Dave, this applies on top of your current fixes branch, and fixes a
>>> problem introduced there by me.  Please merge for v3.4-rc.  Thanks.
>>
>> Can you pick this up for v3.4-rc?
>
> Right, I'm fed up with chasing over this trivial patch.  It's been almost
> a full month since the problem was first reported and it _still_ remains
> unfixed in mainline, despite me chasing over it.  So, sorry, you lose.
>
> I'm merging my fix (attached) which I've been running against the nightly
> builds into my fixes branch and will ask Linus to pull it this weekend.
> If you want something else, then please send a patch on top of my fix to
> do what you want.
>
> Alternatively, send a replacement fix to Linus _before_ Sunday evening
> copying me with it and I'll drop this from my tree.  But I want to see
> an alternative going to Linus for that to happen.

I've (re)sent the patches now.

I just resent the CPUfreq driver Kconfig fix, this time directly to Linus.

I also just resent the arch/arm/mach-omap2 one to Tony/Paul with a
slightly updated changelog making it clear that removing that dead code
also fixes build errors so it can be queued ASAP for v3.4-rc.

Combined, those fix the problems your patch addresses.

Kevin

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
@ 2012-04-13 20:32 ` Kevin Hilman
  0 siblings, 0 replies; 14+ messages in thread
From: Kevin Hilman @ 2012-04-13 20:32 UTC (permalink / raw)
  To: Linus Torvalds
  Cc: Dave Jones, cpufreq, Russell King, linux-omap, linux-arm-kernel,
	Grazvydas Ignotas

The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
builds for OMAP2+ platforms.

This 'depends on' was in the original patch from Russell King, but was
erroneously removed by me when making this option user-selectable in
commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
patch remedies that.

Apologies to Russell King for breaking his originally working patch.

Also, thanks to Grazvydas Ignotas for reporting the same problem.

Cc: Russell King <rmk+kernel@arm.linux.org.uk>
Cc: Grazvydas Ignotas <notasas@gmail.com>
Signed-off-by: Kevin Hilman <khilman@ti.com>
---
Linus, can you apply this for v3.4-rc?  I haven't got a response from
the CPUfreq maintainers after several weeks and a couple tries, so
hopefully you can take this simple fix.   Thanks.

 drivers/cpufreq/Kconfig.arm |    1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
index 82f1aa9..555a57b 100644
--- a/drivers/cpufreq/Kconfig.arm
+++ b/drivers/cpufreq/Kconfig.arm
@@ -4,6 +4,7 @@
 
 config ARM_OMAP2PLUS_CPUFREQ
 	bool "TI OMAP2+"
+	depends on ARCH_OMAP2PLUS
 	default ARCH_OMAP2PLUS
 	select CPU_FREQ_TABLE
 
-- 
1.7.9.2


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
@ 2012-04-13 20:32 ` Kevin Hilman
  0 siblings, 0 replies; 14+ messages in thread
From: Kevin Hilman @ 2012-04-13 20:32 UTC (permalink / raw)
  To: linux-arm-kernel

The OMAP driver needs a 'depends on ARCH_OMAP2PLUS' since it only
builds for OMAP2+ platforms.

This 'depends on' was in the original patch from Russell King, but was
erroneously removed by me when making this option user-selectable in
commit b09db45c (cpufreq: OMAP driver depends CPUfreq tables.)  This
patch remedies that.

Apologies to Russell King for breaking his originally working patch.

Also, thanks to Grazvydas Ignotas for reporting the same problem.

Cc: Russell King <rmk+kernel@arm.linux.org.uk>
Cc: Grazvydas Ignotas <notasas@gmail.com>
Signed-off-by: Kevin Hilman <khilman@ti.com>
---
Linus, can you apply this for v3.4-rc?  I haven't got a response from
the CPUfreq maintainers after several weeks and a couple tries, so
hopefully you can take this simple fix.   Thanks.

 drivers/cpufreq/Kconfig.arm |    1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/Kconfig.arm b/drivers/cpufreq/Kconfig.arm
index 82f1aa9..555a57b 100644
--- a/drivers/cpufreq/Kconfig.arm
+++ b/drivers/cpufreq/Kconfig.arm
@@ -4,6 +4,7 @@
 
 config ARM_OMAP2PLUS_CPUFREQ
 	bool "TI OMAP2+"
+	depends on ARCH_OMAP2PLUS
 	default ARCH_OMAP2PLUS
 	select CPU_FREQ_TABLE
 
-- 
1.7.9.2

^ permalink raw reply related	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2012-04-13 21:31 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-03-27  0:19 [PATCH] cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS Kevin Hilman
2012-03-27  0:19 ` Kevin Hilman
2012-03-30 13:12 ` Russell King - ARM Linux
2012-03-30 13:12   ` Russell King - ARM Linux
2012-03-30 14:24   ` Kevin Hilman
2012-03-30 14:24     ` Kevin Hilman
2012-04-04 22:20 ` Kevin Hilman
2012-04-04 22:20   ` Kevin Hilman
2012-04-13 18:53   ` Russell King - ARM Linux
2012-04-13 18:53     ` Russell King - ARM Linux
2012-04-13 21:31     ` Kevin Hilman
2012-04-13 21:31       ` Kevin Hilman
2012-04-13 20:32 Kevin Hilman
2012-04-13 20:32 ` Kevin Hilman

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.