diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/mach-omap1/include/mach/soc.h | 1 | ||||
-rw-r--r-- | arch/arm/mach-omap2/id.c | 4 | ||||
-rw-r--r-- | arch/arm/mach-omap2/soc.h | 17 |
3 files changed, 20 insertions, 2 deletions
diff --git a/arch/arm/mach-omap1/include/mach/soc.h b/arch/arm/mach-omap1/include/mach/soc.h index 6cf9c1cc2bef..612bd1cc257c 100644 --- a/arch/arm/mach-omap1/include/mach/soc.h +++ b/arch/arm/mach-omap1/include/mach/soc.h | |||
@@ -195,6 +195,7 @@ IS_OMAP_TYPE(1710, 0x1710) | |||
195 | #define cpu_is_omap34xx() 0 | 195 | #define cpu_is_omap34xx() 0 |
196 | #define cpu_is_omap44xx() 0 | 196 | #define cpu_is_omap44xx() 0 |
197 | #define soc_is_omap54xx() 0 | 197 | #define soc_is_omap54xx() 0 |
198 | #define soc_is_dra7xx() 0 | ||
198 | #define soc_is_am33xx() 0 | 199 | #define soc_is_am33xx() 0 |
199 | #define cpu_class_is_omap1() 1 | 200 | #define cpu_class_is_omap1() 1 |
200 | #define cpu_class_is_omap2() 0 | 201 | #define cpu_class_is_omap2() 0 |
diff --git a/arch/arm/mach-omap2/id.c b/arch/arm/mach-omap2/id.c index 2dc62a25f2c3..0289adcb6efb 100644 --- a/arch/arm/mach-omap2/id.c +++ b/arch/arm/mach-omap2/id.c | |||
@@ -61,7 +61,7 @@ int omap_type(void) | |||
61 | val = omap_ctrl_readl(OMAP343X_CONTROL_STATUS); | 61 | val = omap_ctrl_readl(OMAP343X_CONTROL_STATUS); |
62 | } else if (cpu_is_omap44xx()) { | 62 | } else if (cpu_is_omap44xx()) { |
63 | val = omap_ctrl_readl(OMAP4_CTRL_MODULE_CORE_STATUS); | 63 | val = omap_ctrl_readl(OMAP4_CTRL_MODULE_CORE_STATUS); |
64 | } else if (soc_is_omap54xx()) { | 64 | } else if (soc_is_omap54xx() || soc_is_dra7xx()) { |
65 | val = omap_ctrl_readl(OMAP5XXX_CONTROL_STATUS); | 65 | val = omap_ctrl_readl(OMAP5XXX_CONTROL_STATUS); |
66 | val &= OMAP5_DEVICETYPE_MASK; | 66 | val &= OMAP5_DEVICETYPE_MASK; |
67 | val >>= 6; | 67 | val >>= 6; |
@@ -116,7 +116,7 @@ static u16 tap_prod_id; | |||
116 | 116 | ||
117 | void omap_get_die_id(struct omap_die_id *odi) | 117 | void omap_get_die_id(struct omap_die_id *odi) |
118 | { | 118 | { |
119 | if (cpu_is_omap44xx() || soc_is_omap54xx()) { | 119 | if (cpu_is_omap44xx() || soc_is_omap54xx() || soc_is_dra7xx()) { |
120 | odi->id_0 = read_tap_reg(OMAP_TAP_DIE_ID_44XX_0); | 120 | odi->id_0 = read_tap_reg(OMAP_TAP_DIE_ID_44XX_0); |
121 | odi->id_1 = read_tap_reg(OMAP_TAP_DIE_ID_44XX_1); | 121 | odi->id_1 = read_tap_reg(OMAP_TAP_DIE_ID_44XX_1); |
122 | odi->id_2 = read_tap_reg(OMAP_TAP_DIE_ID_44XX_2); | 122 | odi->id_2 = read_tap_reg(OMAP_TAP_DIE_ID_44XX_2); |
diff --git a/arch/arm/mach-omap2/soc.h b/arch/arm/mach-omap2/soc.h index 8c616e436bc7..4588df1447ed 100644 --- a/arch/arm/mach-omap2/soc.h +++ b/arch/arm/mach-omap2/soc.h | |||
@@ -8,6 +8,7 @@ | |||
8 | * Written by Tony Lindgren <tony.lindgren@nokia.com> | 8 | * Written by Tony Lindgren <tony.lindgren@nokia.com> |
9 | * | 9 | * |
10 | * Added OMAP4/5 specific defines - Santosh Shilimkar<santosh.shilimkar@ti.com> | 10 | * Added OMAP4/5 specific defines - Santosh Shilimkar<santosh.shilimkar@ti.com> |
11 | * Added DRA7xxx specific defines - Sricharan R<r.sricharan@ti.com> | ||
11 | * | 12 | * |
12 | * This program is free software; you can redistribute it and/or modify | 13 | * This program is free software; you can redistribute it and/or modify |
13 | * it under the terms of the GNU General Public License as published by | 14 | * it under the terms of the GNU General Public License as published by |
@@ -35,6 +36,7 @@ | |||
35 | #ifndef __ASSEMBLY__ | 36 | #ifndef __ASSEMBLY__ |
36 | 37 | ||
37 | #include <linux/bitops.h> | 38 | #include <linux/bitops.h> |
39 | #include <linux/of.h> | ||
38 | 40 | ||
39 | /* | 41 | /* |
40 | * Test if multicore OMAP support is needed | 42 | * Test if multicore OMAP support is needed |
@@ -105,6 +107,15 @@ | |||
105 | # endif | 107 | # endif |
106 | #endif | 108 | #endif |
107 | 109 | ||
110 | #ifdef CONFIG_SOC_DRA7XX | ||
111 | # ifdef OMAP_NAME | ||
112 | # undef MULTI_OMAP2 | ||
113 | # define MULTI_OMAP2 | ||
114 | # else | ||
115 | # define OMAP_NAME DRA7XX | ||
116 | # endif | ||
117 | #endif | ||
118 | |||
108 | /* | 119 | /* |
109 | * Omap device type i.e. EMU/HS/TST/GP/BAD | 120 | * Omap device type i.e. EMU/HS/TST/GP/BAD |
110 | */ | 121 | */ |
@@ -233,6 +244,7 @@ IS_AM_SUBCLASS(437x, 0x437) | |||
233 | #define cpu_is_omap447x() 0 | 244 | #define cpu_is_omap447x() 0 |
234 | #define soc_is_omap54xx() 0 | 245 | #define soc_is_omap54xx() 0 |
235 | #define soc_is_omap543x() 0 | 246 | #define soc_is_omap543x() 0 |
247 | #define soc_is_dra7xx() 0 | ||
236 | 248 | ||
237 | #if defined(MULTI_OMAP2) | 249 | #if defined(MULTI_OMAP2) |
238 | # if defined(CONFIG_ARCH_OMAP2) | 250 | # if defined(CONFIG_ARCH_OMAP2) |
@@ -379,6 +391,11 @@ IS_OMAP_TYPE(3430, 0x3430) | |||
379 | # define soc_is_omap543x() is_omap543x() | 391 | # define soc_is_omap543x() is_omap543x() |
380 | #endif | 392 | #endif |
381 | 393 | ||
394 | #if defined(CONFIG_SOC_DRA7XX) | ||
395 | #undef soc_is_dra7xx | ||
396 | #define soc_is_dra7xx() (of_machine_is_compatible("ti,dra7")) | ||
397 | #endif | ||
398 | |||
382 | /* Various silicon revisions for omap2 */ | 399 | /* Various silicon revisions for omap2 */ |
383 | #define OMAP242X_CLASS 0x24200024 | 400 | #define OMAP242X_CLASS 0x24200024 |
384 | #define OMAP2420_REV_ES1_0 OMAP242X_CLASS | 401 | #define OMAP2420_REV_ES1_0 OMAP242X_CLASS |