diff options
Diffstat (limited to 'arch/arm/plat-mxc/include/mach/mxc.h')
-rw-r--r-- | arch/arm/plat-mxc/include/mach/mxc.h | 28 |
1 files changed, 27 insertions, 1 deletions
diff --git a/arch/arm/plat-mxc/include/mach/mxc.h b/arch/arm/plat-mxc/include/mach/mxc.h index 5fa2a07f4ea..51990536b84 100644 --- a/arch/arm/plat-mxc/include/mach/mxc.h +++ b/arch/arm/plat-mxc/include/mach/mxc.h | |||
@@ -26,9 +26,11 @@ | |||
26 | 26 | ||
27 | #define MXC_CPU_MX1 1 | 27 | #define MXC_CPU_MX1 1 |
28 | #define MXC_CPU_MX21 21 | 28 | #define MXC_CPU_MX21 21 |
29 | #define MXC_CPU_MX25 25 | ||
29 | #define MXC_CPU_MX27 27 | 30 | #define MXC_CPU_MX27 27 |
30 | #define MXC_CPU_MX31 31 | 31 | #define MXC_CPU_MX31 31 |
31 | #define MXC_CPU_MX35 35 | 32 | #define MXC_CPU_MX35 35 |
33 | #define MXC_CPU_MXC91231 91231 | ||
32 | 34 | ||
33 | #ifndef __ASSEMBLY__ | 35 | #ifndef __ASSEMBLY__ |
34 | extern unsigned int __mxc_cpu_type; | 36 | extern unsigned int __mxc_cpu_type; |
@@ -58,6 +60,18 @@ extern unsigned int __mxc_cpu_type; | |||
58 | # define cpu_is_mx21() (0) | 60 | # define cpu_is_mx21() (0) |
59 | #endif | 61 | #endif |
60 | 62 | ||
63 | #ifdef CONFIG_ARCH_MX25 | ||
64 | # ifdef mxc_cpu_type | ||
65 | # undef mxc_cpu_type | ||
66 | # define mxc_cpu_type __mxc_cpu_type | ||
67 | # else | ||
68 | # define mxc_cpu_type MXC_CPU_MX25 | ||
69 | # endif | ||
70 | # define cpu_is_mx25() (mxc_cpu_type == MXC_CPU_MX25) | ||
71 | #else | ||
72 | # define cpu_is_mx25() (0) | ||
73 | #endif | ||
74 | |||
61 | #ifdef CONFIG_MACH_MX27 | 75 | #ifdef CONFIG_MACH_MX27 |
62 | # ifdef mxc_cpu_type | 76 | # ifdef mxc_cpu_type |
63 | # undef mxc_cpu_type | 77 | # undef mxc_cpu_type |
@@ -94,13 +108,25 @@ extern unsigned int __mxc_cpu_type; | |||
94 | # define cpu_is_mx35() (0) | 108 | # define cpu_is_mx35() (0) |
95 | #endif | 109 | #endif |
96 | 110 | ||
111 | #ifdef CONFIG_ARCH_MXC91231 | ||
112 | # ifdef mxc_cpu_type | ||
113 | # undef mxc_cpu_type | ||
114 | # define mxc_cpu_type __mxc_cpu_type | ||
115 | # else | ||
116 | # define mxc_cpu_type MXC_CPU_MXC91231 | ||
117 | # endif | ||
118 | # define cpu_is_mxc91231() (mxc_cpu_type == MXC_CPU_MXC91231) | ||
119 | #else | ||
120 | # define cpu_is_mxc91231() (0) | ||
121 | #endif | ||
122 | |||
97 | #if defined(CONFIG_ARCH_MX3) || defined(CONFIG_ARCH_MX2) | 123 | #if defined(CONFIG_ARCH_MX3) || defined(CONFIG_ARCH_MX2) |
98 | #define CSCR_U(n) (IO_ADDRESS(WEIM_BASE_ADDR) + n * 0x10) | 124 | #define CSCR_U(n) (IO_ADDRESS(WEIM_BASE_ADDR) + n * 0x10) |
99 | #define CSCR_L(n) (IO_ADDRESS(WEIM_BASE_ADDR) + n * 0x10 + 0x4) | 125 | #define CSCR_L(n) (IO_ADDRESS(WEIM_BASE_ADDR) + n * 0x10 + 0x4) |
100 | #define CSCR_A(n) (IO_ADDRESS(WEIM_BASE_ADDR) + n * 0x10 + 0x8) | 126 | #define CSCR_A(n) (IO_ADDRESS(WEIM_BASE_ADDR) + n * 0x10 + 0x8) |
101 | #endif | 127 | #endif |
102 | 128 | ||
103 | #define cpu_is_mx3() (cpu_is_mx31() || cpu_is_mx35()) | 129 | #define cpu_is_mx3() (cpu_is_mx31() || cpu_is_mx35() || cpu_is_mxc91231()) |
104 | #define cpu_is_mx2() (cpu_is_mx21() || cpu_is_mx27()) | 130 | #define cpu_is_mx2() (cpu_is_mx21() || cpu_is_mx27()) |
105 | 131 | ||
106 | #endif /* __ASM_ARCH_MXC_H__ */ | 132 | #endif /* __ASM_ARCH_MXC_H__ */ |