]> bbs.cooldavid.org Git - net-next-2.6.git/commitdiff
omap2/3: Multiboot compile fixes to compile in omap2 and omap3
authorTony Lindgren <tony@atomide.com>
Fri, 12 Feb 2010 20:26:46 +0000 (12:26 -0800)
committerTony Lindgren <tony@atomide.com>
Mon, 15 Feb 2010 17:26:55 +0000 (09:26 -0800)
Allows compiling in omap2 and omap3.

Signed-off-by: Tony Lindgren <tony@atomide.com>
arch/arm/mach-omap2/Makefile
arch/arm/mach-omap2/clock.h
arch/arm/mach-omap2/opp2xxx.h
arch/arm/plat-omap/Kconfig
arch/arm/plat-omap/gpio.c

index 34c2867e0f6332d2f8bcbc76d676714359ec8b6e..f6f151c4f08984c88500ca8333bad39a827e1b6d 100644 (file)
@@ -34,6 +34,10 @@ obj-$(CONFIG_ARCH_OMAP2420)          += sram242x.o
 obj-$(CONFIG_ARCH_OMAP2430)            += sram243x.o
 obj-$(CONFIG_ARCH_OMAP3)               += sram34xx.o
 
+AFLAGS_sram242x.o                      :=-Wa,-march=armv6
+AFLAGS_sram243x.o                      :=-Wa,-march=armv6
+AFLAGS_sram34xx.o                      :=-Wa,-march=armv7-a
+
 # Pin multiplexing
 obj-$(CONFIG_ARCH_OMAP3)               += mux34xx.o
 
@@ -47,6 +51,10 @@ obj-$(CONFIG_ARCH_OMAP2)             += pm24xx.o
 obj-$(CONFIG_ARCH_OMAP24XX)            += sleep24xx.o
 obj-$(CONFIG_ARCH_OMAP3)               += pm34xx.o sleep34xx.o cpuidle34xx.o
 obj-$(CONFIG_PM_DEBUG)                 += pm-debug.o
+
+AFLAGS_sleep24xx.o                     :=-Wa,-march=armv6
+AFLAGS_sleep34xx.o                     :=-Wa,-march=armv7-a
+
 endif
 
 # PRCM
index 7bc344bcbb475e23624dcaab1f35ca0c7da429ff..a6e85f46a65c49a70c8b07ab7c45386e7f081e3c 100644 (file)
@@ -83,6 +83,32 @@ int omap2_clksel_set_parent(struct clk *clk, struct clk *new_parent);
 u32 omap2_get_dpll_rate(struct clk *clk);
 void omap2_init_dpll_parent(struct clk *clk);
 int omap2_wait_clock_ready(void __iomem *reg, u32 cval, const char *name);
+
+
+#ifdef CONFIG_ARCH_OMAP2
+void omap2xxx_clk_prepare_for_reboot(void);
+#else
+static inline void omap2xxx_clk_prepare_for_reboot(void)
+{
+}
+#endif
+
+#ifdef CONFIG_ARCH_OMAP3
+void omap3_clk_prepare_for_reboot(void);
+#else
+static inline void omap3_clk_prepare_for_reboot(void)
+{
+}
+#endif
+
+#ifdef CONFIG_ARCH_OMAP4
+void omap4_clk_prepare_for_reboot(void);
+#else
+static inline void omap4_clk_prepare_for_reboot(void)
+{
+}
+#endif
+
 int omap2_dflt_clk_enable(struct clk *clk);
 void omap2_dflt_clk_disable(struct clk *clk);
 void omap2_clk_dflt_find_companion(struct clk *clk, void __iomem **other_reg,
index ed6df04e2f291acaad717b03eed4b842d0778fce..38b730550506d386ad07136b52143aaaeffff802 100644 (file)
@@ -417,7 +417,12 @@ struct prcm_config {
 
 
 extern const struct prcm_config omap2420_rate_table[];
+
+#ifdef CONFIG_ARCH_OMAP2430
 extern const struct prcm_config omap2430_rate_table[];
+#else
+#define omap2430_rate_table    NULL
+#endif
 extern const struct prcm_config *rate_table;
 extern const struct prcm_config *curr_prcm_set;
 
index 484d6a91524ffbcb626592c366b8bb9d6210b6c8..f195457d1b038f4f1c32d302f22f20c851c2da26 100644 (file)
@@ -7,27 +7,35 @@ config ARCH_OMAP_OTG
 
 choice
        prompt "OMAP System Type"
-       default ARCH_OMAP1
+       default ARCH_OMAP2PLUS
 
 config ARCH_OMAP1
        bool "TI OMAP1"
        select COMMON_CLKDEV
+       help
+         "Systems based on omap7xx, omap15xx or omap16xx"
+
+config ARCH_OMAP2PLUS
+       bool "TI OMAP2/3/4"
+       select COMMON_CLKDEV
+       help
+         "Systems based on omap24xx, omap34xx or omap44xx"
 
 config ARCH_OMAP2
        bool "TI OMAP2"
+       depends on ARCH_OMAP2PLUS
        select CPU_V6
-       select COMMON_CLKDEV
 
 config ARCH_OMAP3
        bool "TI OMAP3"
+       depends on ARCH_OMAP2PLUS
        select CPU_V7
-       select COMMON_CLKDEV
 
 config ARCH_OMAP4
        bool "TI OMAP4"
+       depends on ARCH_OMAP2PLUS
        select CPU_V7
        select ARM_GIC
-       select COMMON_CLKDEV
 
 endchoice
 
index d2422c766cca215ecd6f51bfbfaa5ceeca303ac4..c09b3d9bcd3b176f7e720494bc7d1c07a24579d1 100644 (file)
@@ -1630,7 +1630,7 @@ static int gpio_2irq(struct gpio_chip *chip, unsigned offset)
 /*---------------------------------------------------------------------*/
 
 static int initialized;
-#if !(defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4))
+#if defined(CONFIG_ARCH_OMAP1) || defined(CONFIG_ARCH_OMAP2)
 static struct clk * gpio_ick;
 #endif