diff options
Diffstat (limited to 'arch/arm/mach-at91/include/mach/cpu.h')
-rw-r--r-- | arch/arm/mach-at91/include/mach/cpu.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/arch/arm/mach-at91/include/mach/cpu.h b/arch/arm/mach-at91/include/mach/cpu.h index dbfd9f73f80b..c554c3e4d553 100644 --- a/arch/arm/mach-at91/include/mach/cpu.h +++ b/arch/arm/mach-at91/include/mach/cpu.h | |||
@@ -49,6 +49,17 @@ static inline unsigned long at91_arch_identify(void) | |||
49 | return (at91_sys_read(AT91_DBGU_CIDR) & AT91_CIDR_ARCH); | 49 | return (at91_sys_read(AT91_DBGU_CIDR) & AT91_CIDR_ARCH); |
50 | } | 50 | } |
51 | 51 | ||
52 | #ifdef CONFIG_ARCH_AT91CAP9 | ||
53 | #include <mach/at91_pmc.h> | ||
54 | |||
55 | #define ARCH_REVISION_CAP9_B 0x399 | ||
56 | #define ARCH_REVISION_CAP9_C 0x601 | ||
57 | |||
58 | static inline unsigned long at91cap9_rev_identify(void) | ||
59 | { | ||
60 | return (at91_sys_read(AT91_PMC_VER)); | ||
61 | } | ||
62 | #endif | ||
52 | 63 | ||
53 | #ifdef CONFIG_ARCH_AT91RM9200 | 64 | #ifdef CONFIG_ARCH_AT91RM9200 |
54 | #define cpu_is_at91rm9200() (at91_cpu_identify() == ARCH_ID_AT91RM9200) | 65 | #define cpu_is_at91rm9200() (at91_cpu_identify() == ARCH_ID_AT91RM9200) |
@@ -90,8 +101,12 @@ static inline unsigned long at91_arch_identify(void) | |||
90 | 101 | ||
91 | #ifdef CONFIG_ARCH_AT91CAP9 | 102 | #ifdef CONFIG_ARCH_AT91CAP9 |
92 | #define cpu_is_at91cap9() (at91_cpu_identify() == ARCH_ID_AT91CAP9) | 103 | #define cpu_is_at91cap9() (at91_cpu_identify() == ARCH_ID_AT91CAP9) |
104 | #define cpu_is_at91cap9_revB() (at91cap9_rev_identify() == ARCH_REVISION_CAP9_B) | ||
105 | #define cpu_is_at91cap9_revC() (at91cap9_rev_identify() == ARCH_REVISION_CAP9_C) | ||
93 | #else | 106 | #else |
94 | #define cpu_is_at91cap9() (0) | 107 | #define cpu_is_at91cap9() (0) |
108 | #define cpu_is_at91cap9_revB() (0) | ||
109 | #define cpu_is_at91cap9_revC() (0) | ||
95 | #endif | 110 | #endif |
96 | 111 | ||
97 | /* | 112 | /* |