diff options
author | Rabin Vincent <rabin.vincent@stericsson.com> | 2010-12-08 11:07:59 +0530 |
---|---|---|
committer | Linus Walleij <linus.walleij@stericsson.com> | 2011-01-10 18:34:53 +0100 |
commit | abf12d719a2c9e45f7f90c02a3a25107206ed57a (patch) | |
tree | 0aa9d9ecc7188b748eeda954b609dd74a8f5d24f /arch/arm/mach-ux500/include/mach/hardware.h | |
parent | 5dc55e0a39434ec8bec7978aef2dc00c91a530ba (diff) | |
download | op-kernel-dev-abf12d719a2c9e45f7f90c02a3a25107206ed57a.zip op-kernel-dev-abf12d719a2c9e45f7f90c02a3a25107206ed57a.tar.gz |
ux500: dynamic SOC detection
Dynamically detect the DBx500 SOC an revision based on the ASIC ID.
Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com>
Signed-off-by: Linus Walleij <linus.walleij@stericsson.com>
Diffstat (limited to 'arch/arm/mach-ux500/include/mach/hardware.h')
-rw-r--r-- | arch/arm/mach-ux500/include/mach/hardware.h | 50 |
1 files changed, 1 insertions, 49 deletions
diff --git a/arch/arm/mach-ux500/include/mach/hardware.h b/arch/arm/mach-ux500/include/mach/hardware.h index bced4a8..bf63f26 100644 --- a/arch/arm/mach-ux500/include/mach/hardware.h +++ b/arch/arm/mach-ux500/include/mach/hardware.h @@ -34,57 +34,9 @@ #ifndef __ASSEMBLY__ -#include <asm/cputype.h> - -static inline bool cpu_is_u8500(void) -{ -#ifdef CONFIG_UX500_SOC_DB8500 - return 1; -#else - return 0; -#endif -} - -#define CPUID_DB8500ED 0x410fc090 -#define CPUID_DB8500V1 0x411fc091 -#define CPUID_DB8500V2 0x412fc091 - -static inline bool cpu_is_u8500ed(void) -{ - return cpu_is_u8500() && (read_cpuid_id() == CPUID_DB8500ED); -} - -static inline bool cpu_is_u8500v1(void) -{ - return cpu_is_u8500() && (read_cpuid_id() == CPUID_DB8500V1); -} - -static inline bool cpu_is_u8500v2(void) -{ - return cpu_is_u8500() && (read_cpuid_id() == CPUID_DB8500V2); -} - -#ifdef CONFIG_UX500_SOC_DB8500 -bool cpu_is_u8500v10(void); -bool cpu_is_u8500v11(void); -bool cpu_is_u8500v20(void); -#else -static inline bool cpu_is_u8500v10(void) { return false; } -static inline bool cpu_is_u8500v11(void) { return false; } -static inline bool cpu_is_u8500v20(void) { return false; } -#endif - -static inline bool cpu_is_u5500(void) -{ -#ifdef CONFIG_UX500_SOC_DB5500 - return 1; -#else - return 0; -#endif -} +#include <mach/id.h> #define ARRAY_AND_SIZE(x) (x), ARRAY_SIZE(x) -#define ux500_unknown_soc() BUG() #endif |