public inbox for linux-omap@vger.kernel.org
 help / color / mirror / Atom feed
* [RFC/PATCH] ARM: OMAP: Fix build for OMAP3 only builds
@ 2011-10-12 12:03 Thomas Weber
  2011-10-27  5:32 ` Nori, Sekhar
  0 siblings, 1 reply; 9+ messages in thread
From: Thomas Weber @ 2011-10-12 12:03 UTC (permalink / raw)
  To: linux-omap; +Cc: Thomas Weber, Tony Lindgren, Russell King

When building for OMAP3 only I get the
following errors:

In function `omap2420_init_early':
undefined reference to `omap2_set_globals_242x'
undefined reference to `omap2xxx_voltagedomains_init'
undefined reference to `omap242x_powerdomains_init'
undefined reference to `omap242x_clockdomains_init'
undefined reference to `omap2420_hwmod_init'

In function `omap2430_init_early':
undefined reference to `omap2_set_globals_243x'
undefined reference to `omap2xxx_voltagedomains_init'
undefined reference to `omap243x_powerdomains_init'
undefined reference to `omap243x_clockdomains_init'
undefined reference to `omap2430_hwmod_init'

In function `omap4430_init_early':
undefined reference to `omap2_set_globals_443x'
undefined reference to `omap44xx_voltagedomains_init'
undefined reference to `omap44xx_powerdomains_init'
undefined reference to `omap44xx_clockdomains_init'
undefined reference to `omap44xx_hwmod_init'
undefined reference to `omap4xxx_clk_init'

With this patch the omapXXXX_init_early will be compiled only
when their SOC's are selected.

Signed-off-by: Thomas Weber <weber@corscience.de>
---
 arch/arm/mach-omap2/io.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/arch/arm/mach-omap2/io.c b/arch/arm/mach-omap2/io.c
index aa96538..f8b9cfa 100644
--- a/arch/arm/mach-omap2/io.c
+++ b/arch/arm/mach-omap2/io.c
@@ -359,6 +359,7 @@ static void __init omap_hwmod_init_postsetup(void)
 	omap_pm_if_early_init();
 }
 
+#ifdef CONFIG_SOC_OMAP2420
 void __init omap2420_init_early(void)
 {
 	omap2_set_globals_242x();
@@ -370,7 +371,9 @@ void __init omap2420_init_early(void)
 	omap_hwmod_init_postsetup();
 	omap2420_clk_init();
 }
+#endif
 
+#ifdef CONFIG_SOC_OMAP2430
 void __init omap2430_init_early(void)
 {
 	omap2_set_globals_243x();
@@ -382,7 +385,9 @@ void __init omap2430_init_early(void)
 	omap_hwmod_init_postsetup();
 	omap2430_clk_init();
 }
+#endif
 
+#ifdef CONFIG_ARCH_OMAP3
 /*
  * Currently only board-omap3beagle.c should call this because of the
  * same machine_id for 34xx and 36xx beagle.. Will get fixed with DT.
@@ -430,7 +435,9 @@ void __init ti816x_init_early(void)
 	omap_hwmod_init_postsetup();
 	omap3xxx_clk_init();
 }
+#endif
 
+#ifdef CONFIG_ARCH_OMAP4
 void __init omap4430_init_early(void)
 {
 	omap2_set_globals_443x();
@@ -442,6 +449,7 @@ void __init omap4430_init_early(void)
 	omap_hwmod_init_postsetup();
 	omap4xxx_clk_init();
 }
+#endif
 
 void __init omap_sdrc_init(struct omap_sdrc_params *sdrc_cs0,
 				      struct omap_sdrc_params *sdrc_cs1)
-- 
1.7.7


^ permalink raw reply related	[flat|nested] 9+ messages in thread
* RE: [RFC/PATCH] ARM: OMAP: Fix build for OMAP3 only builds
@ 2011-10-29  4:42 Thomas Weber
  0 siblings, 0 replies; 9+ messages in thread
From: Thomas Weber @ 2011-10-29  4:42 UTC (permalink / raw)
  To: Nori, Sekhar, Thomas Weber,  linux-omap@vger.kernel.org
  Cc: Tony Lindgren, Russell King

Thank you Sekhar,

Can you please test the following patch

[PATCH v2] arm: omap: Fix errors and warnings when building for one board

Thomas

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

end of thread, other threads:[~2011-11-07 17:29 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-10-12 12:03 [RFC/PATCH] ARM: OMAP: Fix build for OMAP3 only builds Thomas Weber
2011-10-27  5:32 ` Nori, Sekhar
2011-11-02 12:37   ` Thomas Weber
2011-11-02 17:16     ` Tony Lindgren
2011-11-03 18:30       ` Tony Lindgren
2011-11-03 21:24         ` Thomas Weber
2011-11-07 17:06         ` Russell King - ARM Linux
2011-11-07 17:29           ` Tony Lindgren
  -- strict thread matches above, loose matches on Subject: below --
2011-10-29  4:42 Thomas Weber

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox