ARM: OMAP2+: am33xx: Make am33xx as a separate class
authorVaibhav Hiremath <hvaibhav@ti.com>
Thu, 5 Jul 2012 15:05:15 +0000 (08:05 -0700)
committerTony Lindgren <tony@atomide.com>
Thu, 5 Jul 2012 15:05:15 +0000 (08:05 -0700)
Initially, we decided to make am33xx family of device to fall
under omap3 class (cpu_is_omap34xx() = true), since it carries
Cortex-A8 core. But while adding complete baseport support
(like, clock, power and hwmod) support, it is observed that,
we are creating more and more problems by treating am33xx device
as omap3 family, as nothing matches between them
(except cortex-A8 mpu).

So,  after long discussion we have came to the conclusion that,
we should not consider am33xx device as omap3 family, instead
create separate class (SOC_AM33XX) under OMAP2PLUS.
This means, for am33xx device, cpu_is_omap34xx() will return false,
and only cpu_is_am33xx() will be true.

Please refer to the link below, for mailing-list discussion on this -

http://www.spinics.net/lists/linux-omap/msg69439.html

Signed-off-by: Vaibhav Hiremath <hvaibhav@ti.com>
Cc: Kevin Hilman <khilman@ti.com>
Cc: Paul Walmsley <paul@pwsan.com>
[tony@atomide.com: fixed typo, updated for soc_is changes]
Signed-off-by: Tony Lindgren <tony@atomide.com>
arch/arm/mach-omap2/Kconfig
arch/arm/mach-omap2/Makefile
arch/arm/mach-omap2/common.c
arch/arm/plat-omap/include/plat/cpu.h
arch/arm/plat-omap/sram.c

index 042f157a8f944e66216ed11fd58701d063743cab..3649a34db00d330f80a688054d66470514559a77 100644 (file)
@@ -82,8 +82,10 @@ config SOC_TI81XX
 
 config SOC_AM33XX
        bool "AM33XX support"
-       depends on ARCH_OMAP3
        default y
+       select CPU_V7
+       select ARM_CPU_SUSPEND if PM
+       select MULTI_IRQ_HANDLER
 
 config OMAP_PACKAGE_ZAF
        bool
index 54ad3a4b612c29820f0f6aa13c892a940b26d26b..846d44547fd3126565df6e3411bbecb930bb958e 100644 (file)
@@ -16,6 +16,7 @@ secure-common                         = omap-smc.o omap-secure.o
 obj-$(CONFIG_ARCH_OMAP2) += $(omap-2-3-common) $(hwmod-common)
 obj-$(CONFIG_ARCH_OMAP3) += $(omap-2-3-common) $(hwmod-common) $(secure-common)
 obj-$(CONFIG_ARCH_OMAP4) += prm44xx.o $(hwmod-common) $(secure-common)
+obj-$(CONFIG_SOC_AM33XX) += irq.o $(hwmod-common)
 
 ifneq ($(CONFIG_SND_OMAP_SOC_MCBSP),)
 obj-y += mcbsp.o
@@ -100,6 +101,7 @@ obj-$(CONFIG_ARCH_OMAP3)            += $(voltagedomain-common)
 obj-$(CONFIG_ARCH_OMAP3)               += voltagedomains3xxx_data.o
 obj-$(CONFIG_ARCH_OMAP4)               += $(voltagedomain-common)
 obj-$(CONFIG_ARCH_OMAP4)               += voltagedomains44xx_data.o
+obj-$(CONFIG_SOC_AM33XX)               += $(voltagedomain-common)
 obj-$(CONFIG_SOC_AM33XX)                += voltagedomains33xx_data.o
 
 # OMAP powerdomain framework
@@ -115,6 +117,7 @@ obj-$(CONFIG_ARCH_OMAP3)            += powerdomains2xxx_3xxx_data.o
 obj-$(CONFIG_ARCH_OMAP4)               += $(powerdomain-common)
 obj-$(CONFIG_ARCH_OMAP4)               += powerdomain44xx.o
 obj-$(CONFIG_ARCH_OMAP4)               += powerdomains44xx_data.o
+obj-$(CONFIG_SOC_AM33XX)               += $(powerdomain-common)
 obj-$(CONFIG_SOC_AM33XX)               += powerdomain33xx.o
 obj-$(CONFIG_SOC_AM33XX)               += powerdomains33xx_data.o
 
@@ -132,6 +135,7 @@ obj-$(CONFIG_ARCH_OMAP3)            += clockdomains3xxx_data.o
 obj-$(CONFIG_ARCH_OMAP4)               += $(clockdomain-common)
 obj-$(CONFIG_ARCH_OMAP4)               += clockdomain44xx.o
 obj-$(CONFIG_ARCH_OMAP4)               += clockdomains44xx_data.o
+obj-$(CONFIG_SOC_AM33XX)               += $(clockdomain-common)
 obj-$(CONFIG_SOC_AM33XX)               += clockdomain33xx.o
 obj-$(CONFIG_SOC_AM33XX)               += clockdomains33xx_data.o
 
@@ -151,6 +155,7 @@ obj-$(CONFIG_ARCH_OMAP3)            += dpll3xxx.o clock3xxx_data.o
 obj-$(CONFIG_ARCH_OMAP3)               += clkt_iclk.o
 obj-$(CONFIG_ARCH_OMAP4)               += $(clock-common) clock44xx_data.o
 obj-$(CONFIG_ARCH_OMAP4)               += dpll3xxx.o dpll44xx.o
+obj-$(CONFIG_SOC_AM33XX)               += $(clock-common) dpll3xxx.o
 
 # OMAP2 clock rate set data (old "OPP" data)
 obj-$(CONFIG_SOC_OMAP2420)             += opp2420_data.o
index 8a6953a34fe2b01d159ba40a296a343818236a76..a7aa538e681d4d5ba4b73f1c04a44505fd15ac6a 100644 (file)
@@ -134,7 +134,9 @@ void __init ti81xx_map_io(void)
 {
        omapti81xx_map_common_io();
 }
+#endif
 
+#if defined(CONFIG_SOC_AM33XX)
 #define AM33XX_TAP_BASE                (AM33XX_CTRL_BASE + \
                                TI81XX_CONTROL_DEVICE_ID - 0x204)
 
index de6c0a08f4615d6fba3f07b316285f9a9b47095a..4f9d60192ef42329b59a2b2ccdc7b878c11980d7 100644 (file)
@@ -344,8 +344,6 @@ IS_OMAP_TYPE(3430, 0x3430)
 # undef cpu_is_ti816x
 # undef cpu_is_ti814x
 # undef soc_is_am35xx
-# undef cpu_is_am33xx
-# undef cpu_is_am335x
 # define cpu_is_omap3430()             is_omap3430()
 # undef cpu_is_omap3630
 # define cpu_is_omap3630()             is_omap363x()
@@ -353,6 +351,11 @@ IS_OMAP_TYPE(3430, 0x3430)
 # define cpu_is_ti816x()               is_ti816x()
 # define cpu_is_ti814x()               is_ti814x()
 # define soc_is_am35xx()               is_am35xx()
+#endif
+
+# if defined(CONFIG_SOC_AM33XX)
+# undef cpu_is_am33xx
+# undef cpu_is_am335x
 # define cpu_is_am33xx()               is_am33xx()
 # define cpu_is_am335x()               is_am335x()
 #endif
@@ -408,7 +411,7 @@ IS_OMAP_TYPE(3430, 0x3430)
 #define AM35XX_REV_ES1_0       AM35XX_CLASS
 #define AM35XX_REV_ES1_1       (AM35XX_CLASS | (0x1 << 8))
 
-#define AM335X_CLASS           0x33500034
+#define AM335X_CLASS           0x33500033
 #define AM335X_REV_ES1_0       AM335X_CLASS
 
 #define OMAP443X_CLASS         0x44300044
index 477363c163ec5b3fc12b3f4de942673ce213c999..564cb4c84b1156d569c09955affada9eafd4a91b 100644 (file)
@@ -85,7 +85,7 @@ static int is_sram_locked(void)
                        __raw_writel(0xCFDE, OMAP24XX_VA_READPERM0);  /* all i-read */
                        __raw_writel(0xCFDE, OMAP24XX_VA_WRITEPERM0); /* all i-write */
                }
-               if (cpu_is_omap34xx() && !cpu_is_am33xx()) {
+               if (cpu_is_omap34xx()) {
                        __raw_writel(0xFFFF, OMAP34XX_VA_REQINFOPERM0); /* all q-vects */
                        __raw_writel(0xFFFF, OMAP34XX_VA_READPERM0);  /* all i-read */
                        __raw_writel(0xFFFF, OMAP34XX_VA_WRITEPERM0); /* all i-write */
This page took 0.02833 seconds and 5 git commands to generate.