]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/blame - arch/arm/plat-omap/include/plat/cpu.h
ARM: OMAP: id: add chip id recognition for omap4430 es2.3
[mirror_ubuntu-artful-kernel.git] / arch / arm / plat-omap / include / plat / cpu.h
CommitLineData
1da177e4 1/*
a09e64fb 2 * arch/arm/plat-omap/include/mach/cpu.h
1da177e4
LT
3 *
4 * OMAP cpu type detection
5 *
097c584c 6 * Copyright (C) 2004, 2008 Nokia Corporation
1da177e4 7 *
e49c4d27 8 * Copyright (C) 2009-11 Texas Instruments.
44169075 9 *
1da177e4
LT
10 * Written by Tony Lindgren <tony.lindgren@nokia.com>
11 *
44169075
SS
12 * Added OMAP4 specific defines - Santosh Shilimkar<santosh.shilimkar@ti.com>
13 *
1da177e4
LT
14 * This program is free software; you can redistribute it and/or modify
15 * it under the terms of the GNU General Public License as published by
16 * the Free Software Foundation; either version 2 of the License, or
17 * (at your option) any later version.
18 *
19 * This program is distributed in the hope that it will be useful,
20 * but WITHOUT ANY WARRANTY; without even the implied warranty of
21 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22 * GNU General Public License for more details.
23 *
24 * You should have received a copy of the GNU General Public License
25 * along with this program; if not, write to the Free Software
26 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
27 *
28 */
29
30#ifndef __ASM_ARCH_OMAP_CPU_H
31#define __ASM_ARCH_OMAP_CPU_H
32
8384ce07 33#include <linux/bitops.h>
1cf9d079 34#include <plat/multi.h>
8384ce07 35
8e25ad96
KH
36/*
37 * Omap device type i.e. EMU/HS/TST/GP/BAD
38 */
39#define OMAP2_DEVICE_TYPE_TEST 0
40#define OMAP2_DEVICE_TYPE_EMU 1
41#define OMAP2_DEVICE_TYPE_SEC 2
42#define OMAP2_DEVICE_TYPE_GP 3
43#define OMAP2_DEVICE_TYPE_BAD 4
44
45int omap_type(void);
46
a8823143 47/*
84a34344 48 * omap_rev bits:
a8823143
TL
49 * CPU id bits (0730, 1510, 1710, 2422...) [31:16]
50 * CPU revision (See _REV_ defined in cpu.h) [15:08]
51 * CPU class bits (15xx, 16xx, 24xx, 34xx...) [07:00]
52 */
84a34344 53unsigned int omap_rev(void);
1da177e4 54
048f4bd7
SP
55/*
56 * Get the CPU revision for OMAP devices
57 */
58#define GET_OMAP_REVISION() ((omap_rev() >> 8) & 0xff)
59
1da177e4 60/*
9839c6b8
TL
61 * Macros to group OMAP into cpu classes.
62 * These can be used in most places.
ae302f40 63 * cpu_is_omap7xx(): True for OMAP730, OMAP850
9ad5897c 64 * cpu_is_omap15xx(): True for OMAP1510, OMAP5910 and OMAP310
9839c6b8 65 * cpu_is_omap16xx(): True for OMAP1610, OMAP5912 and OMAP1710
9ad5897c
TL
66 * cpu_is_omap24xx(): True for OMAP2420, OMAP2422, OMAP2423, OMAP2430
67 * cpu_is_omap242x(): True for OMAP2420, OMAP2422, OMAP2423
68 * cpu_is_omap243x(): True for OMAP2430
2c17f615 69 * cpu_is_omap343x(): True for OMAP3430
c6a6e6e2 70 * cpu_is_omap443x(): True for OMAP4430
fa54dccd 71 * cpu_is_omap446x(): True for OMAP4460
1da177e4 72 */
84a34344 73#define GET_OMAP_CLASS (omap_rev() & 0xff)
1da177e4 74
1da177e4
LT
75#define IS_OMAP_CLASS(class, id) \
76static inline int is_omap ##class (void) \
77{ \
78 return (GET_OMAP_CLASS == (id)) ? 1 : 0; \
79}
80
99541195
AM
81#define GET_AM_CLASS ((omap_rev() >> 24) & 0xff)
82
83#define IS_AM_CLASS(class, id) \
84static inline int is_am ##class (void) \
85{ \
86 return (GET_AM_CLASS == (id)) ? 1 : 0; \
87}
88
84a34344 89#define GET_OMAP_SUBCLASS ((omap_rev() >> 20) & 0x0fff)
9ad5897c
TL
90
91#define IS_OMAP_SUBCLASS(subclass, id) \
92static inline int is_omap ##subclass (void) \
93{ \
94 return (GET_OMAP_SUBCLASS == (id)) ? 1 : 0; \
95}
96
4bd7be22
HP
97#define IS_TI_SUBCLASS(subclass, id) \
98static inline int is_ti ##subclass (void) \
99{ \
100 return (GET_OMAP_SUBCLASS == (id)) ? 1 : 0; \
101}
102
99541195
AM
103#define IS_AM_SUBCLASS(subclass, id) \
104static inline int is_am ##subclass (void) \
105{ \
106 return (GET_OMAP_SUBCLASS == (id)) ? 1 : 0; \
107}
108
1da177e4
LT
109IS_OMAP_CLASS(7xx, 0x07)
110IS_OMAP_CLASS(15xx, 0x15)
111IS_OMAP_CLASS(16xx, 0x16)
112IS_OMAP_CLASS(24xx, 0x24)
2c17f615 113IS_OMAP_CLASS(34xx, 0x34)
b570e0ec 114IS_OMAP_CLASS(44xx, 0x44)
99541195 115IS_AM_CLASS(33xx, 0x33)
1da177e4 116
9ad5897c
TL
117IS_OMAP_SUBCLASS(242x, 0x242)
118IS_OMAP_SUBCLASS(243x, 0x243)
2c17f615 119IS_OMAP_SUBCLASS(343x, 0x343)
2456a10f 120IS_OMAP_SUBCLASS(363x, 0x363)
b570e0ec 121IS_OMAP_SUBCLASS(443x, 0x443)
fa54dccd 122IS_OMAP_SUBCLASS(446x, 0x446)
9ad5897c 123
4bd7be22 124IS_TI_SUBCLASS(816x, 0x816)
99541195 125IS_AM_SUBCLASS(335x, 0x335)
4bd7be22 126
9839c6b8
TL
127#define cpu_is_omap7xx() 0
128#define cpu_is_omap15xx() 0
129#define cpu_is_omap16xx() 0
130#define cpu_is_omap24xx() 0
9ad5897c
TL
131#define cpu_is_omap242x() 0
132#define cpu_is_omap243x() 0
2c17f615
SMK
133#define cpu_is_omap34xx() 0
134#define cpu_is_omap343x() 0
4bd7be22 135#define cpu_is_ti816x() 0
99541195
AM
136#define cpu_is_am33xx() 0
137#define cpu_is_am335x() 0
44169075
SS
138#define cpu_is_omap44xx() 0
139#define cpu_is_omap443x() 0
fa54dccd 140#define cpu_is_omap446x() 0
9839c6b8
TL
141
142#if defined(MULTI_OMAP1)
143# if defined(CONFIG_ARCH_OMAP730)
144# undef cpu_is_omap7xx
145# define cpu_is_omap7xx() is_omap7xx()
146# endif
ae302f40
ZM
147# if defined(CONFIG_ARCH_OMAP850)
148# undef cpu_is_omap7xx
149# define cpu_is_omap7xx() is_omap7xx()
150# endif
9ad5897c 151# if defined(CONFIG_ARCH_OMAP15XX)
9839c6b8
TL
152# undef cpu_is_omap15xx
153# define cpu_is_omap15xx() is_omap15xx()
154# endif
155# if defined(CONFIG_ARCH_OMAP16XX)
156# undef cpu_is_omap16xx
1da177e4
LT
157# define cpu_is_omap16xx() is_omap16xx()
158# endif
159#else
160# if defined(CONFIG_ARCH_OMAP730)
9839c6b8 161# undef cpu_is_omap7xx
1da177e4 162# define cpu_is_omap7xx() 1
1da177e4 163# endif
ae302f40
ZM
164# if defined(CONFIG_ARCH_OMAP850)
165# undef cpu_is_omap7xx
166# define cpu_is_omap7xx() 1
167# endif
9ad5897c 168# if defined(CONFIG_ARCH_OMAP15XX)
9839c6b8 169# undef cpu_is_omap15xx
1da177e4 170# define cpu_is_omap15xx() 1
1da177e4
LT
171# endif
172# if defined(CONFIG_ARCH_OMAP16XX)
9839c6b8 173# undef cpu_is_omap16xx
1da177e4 174# define cpu_is_omap16xx() 1
9839c6b8 175# endif
2c17f615
SMK
176#endif
177
178#if defined(MULTI_OMAP2)
088ef950 179# if defined(CONFIG_ARCH_OMAP2)
9839c6b8 180# undef cpu_is_omap24xx
2c17f615 181# define cpu_is_omap24xx() is_omap24xx()
54c44fb7 182# endif
59b479e0 183# if defined (CONFIG_SOC_OMAP2420)
54c44fb7 184# undef cpu_is_omap242x
9ad5897c 185# define cpu_is_omap242x() is_omap242x()
54c44fb7 186# endif
59b479e0 187# if defined (CONFIG_SOC_OMAP2430)
54c44fb7 188# undef cpu_is_omap243x
9ad5897c 189# define cpu_is_omap243x() is_omap243x()
1da177e4 190# endif
a8eb7ca0 191# if defined(CONFIG_ARCH_OMAP3)
2c17f615
SMK
192# undef cpu_is_omap34xx
193# undef cpu_is_omap343x
194# define cpu_is_omap34xx() is_omap34xx()
195# define cpu_is_omap343x() is_omap343x()
196# endif
197#else
088ef950 198# if defined(CONFIG_ARCH_OMAP2)
2c17f615
SMK
199# undef cpu_is_omap24xx
200# define cpu_is_omap24xx() 1
201# endif
59b479e0 202# if defined(CONFIG_SOC_OMAP2420)
2c17f615
SMK
203# undef cpu_is_omap242x
204# define cpu_is_omap242x() 1
205# endif
59b479e0 206# if defined(CONFIG_SOC_OMAP2430)
2c17f615
SMK
207# undef cpu_is_omap243x
208# define cpu_is_omap243x() 1
209# endif
a8eb7ca0 210# if defined(CONFIG_ARCH_OMAP3)
2c17f615
SMK
211# undef cpu_is_omap34xx
212# define cpu_is_omap34xx() 1
213# endif
59b479e0 214# if defined(CONFIG_SOC_OMAP3430)
2c17f615
SMK
215# undef cpu_is_omap343x
216# define cpu_is_omap343x() 1
217# endif
1da177e4
LT
218#endif
219
9839c6b8
TL
220/*
221 * Macros to detect individual cpu types.
222 * These are only rarely needed.
9ad5897c 223 * cpu_is_omap330(): True for OMAP330
9839c6b8 224 * cpu_is_omap730(): True for OMAP730
ae302f40 225 * cpu_is_omap850(): True for OMAP850
9839c6b8
TL
226 * cpu_is_omap1510(): True for OMAP1510
227 * cpu_is_omap1610(): True for OMAP1610
228 * cpu_is_omap1611(): True for OMAP1611
229 * cpu_is_omap5912(): True for OMAP5912
230 * cpu_is_omap1621(): True for OMAP1621
231 * cpu_is_omap1710(): True for OMAP1710
232 * cpu_is_omap2420(): True for OMAP2420
9ad5897c
TL
233 * cpu_is_omap2422(): True for OMAP2422
234 * cpu_is_omap2423(): True for OMAP2423
235 * cpu_is_omap2430(): True for OMAP2430
2c17f615 236 * cpu_is_omap3430(): True for OMAP3430
c6a6e6e2 237 * cpu_is_omap4430(): True for OMAP4430
4cac6018
SP
238 * cpu_is_omap3505(): True for OMAP3505
239 * cpu_is_omap3517(): True for OMAP3517
9839c6b8 240 */
84a34344 241#define GET_OMAP_TYPE ((omap_rev() >> 16) & 0xffff)
9839c6b8
TL
242
243#define IS_OMAP_TYPE(type, id) \
244static inline int is_omap ##type (void) \
245{ \
246 return (GET_OMAP_TYPE == (id)) ? 1 : 0; \
247}
248
9ad5897c 249IS_OMAP_TYPE(310, 0x0310)
9839c6b8 250IS_OMAP_TYPE(730, 0x0730)
ae302f40 251IS_OMAP_TYPE(850, 0x0850)
9839c6b8
TL
252IS_OMAP_TYPE(1510, 0x1510)
253IS_OMAP_TYPE(1610, 0x1610)
254IS_OMAP_TYPE(1611, 0x1611)
255IS_OMAP_TYPE(5912, 0x1611)
256IS_OMAP_TYPE(1621, 0x1621)
257IS_OMAP_TYPE(1710, 0x1710)
258IS_OMAP_TYPE(2420, 0x2420)
9ad5897c
TL
259IS_OMAP_TYPE(2422, 0x2422)
260IS_OMAP_TYPE(2423, 0x2423)
261IS_OMAP_TYPE(2430, 0x2430)
2c17f615 262IS_OMAP_TYPE(3430, 0x3430)
1f1b0353 263IS_OMAP_TYPE(3505, 0x3517)
4cac6018 264IS_OMAP_TYPE(3517, 0x3517)
9839c6b8 265
9ad5897c 266#define cpu_is_omap310() 0
9839c6b8 267#define cpu_is_omap730() 0
ae302f40 268#define cpu_is_omap850() 0
9839c6b8
TL
269#define cpu_is_omap1510() 0
270#define cpu_is_omap1610() 0
271#define cpu_is_omap5912() 0
272#define cpu_is_omap1611() 0
273#define cpu_is_omap1621() 0
274#define cpu_is_omap1710() 0
275#define cpu_is_omap2420() 0
9ad5897c
TL
276#define cpu_is_omap2422() 0
277#define cpu_is_omap2423() 0
278#define cpu_is_omap2430() 0
048f4bd7
SP
279#define cpu_is_omap3503() 0
280#define cpu_is_omap3515() 0
281#define cpu_is_omap3525() 0
282#define cpu_is_omap3530() 0
4cac6018
SP
283#define cpu_is_omap3505() 0
284#define cpu_is_omap3517() 0
2c17f615 285#define cpu_is_omap3430() 0
c6a6e6e2 286#define cpu_is_omap4430() 0
2456a10f 287#define cpu_is_omap3630() 0
9839c6b8 288
9839c6b8
TL
289/*
290 * Whether we have MULTI_OMAP1 or not, we still need to distinguish
a9f82d10 291 * between 730 vs 850, 330 vs. 1510 and 1611B/5912 vs. 1710.
9839c6b8 292 */
a9f82d10
TL
293
294#if defined(CONFIG_ARCH_OMAP730)
295# undef cpu_is_omap730
296# define cpu_is_omap730() is_omap730()
297#endif
298
299#if defined(CONFIG_ARCH_OMAP850)
300# undef cpu_is_omap850
301# define cpu_is_omap850() is_omap850()
302#endif
303
9ad5897c
TL
304#if defined(CONFIG_ARCH_OMAP15XX)
305# undef cpu_is_omap310
306# undef cpu_is_omap1510
307# define cpu_is_omap310() is_omap310()
308# define cpu_is_omap1510() is_omap1510()
309#endif
310
9839c6b8
TL
311#if defined(CONFIG_ARCH_OMAP16XX)
312# undef cpu_is_omap1610
313# undef cpu_is_omap1611
314# undef cpu_is_omap5912
315# undef cpu_is_omap1621
316# undef cpu_is_omap1710
1da177e4 317# define cpu_is_omap1610() is_omap1610()
9839c6b8 318# define cpu_is_omap1611() is_omap1611()
1da177e4 319# define cpu_is_omap5912() is_omap5912()
9839c6b8 320# define cpu_is_omap1621() is_omap1621()
1da177e4 321# define cpu_is_omap1710() is_omap1710()
9839c6b8
TL
322#endif
323
088ef950 324#if defined(CONFIG_ARCH_OMAP2)
9ad5897c
TL
325# undef cpu_is_omap2420
326# undef cpu_is_omap2422
327# undef cpu_is_omap2423
328# undef cpu_is_omap2430
329# define cpu_is_omap2420() is_omap2420()
330# define cpu_is_omap2422() is_omap2422()
331# define cpu_is_omap2423() is_omap2423()
332# define cpu_is_omap2430() is_omap2430()
1da177e4
LT
333#endif
334
a8eb7ca0 335#if defined(CONFIG_ARCH_OMAP3)
2c17f615 336# undef cpu_is_omap3430
048f4bd7
SP
337# undef cpu_is_omap3503
338# undef cpu_is_omap3515
339# undef cpu_is_omap3525
340# undef cpu_is_omap3530
4cac6018
SP
341# undef cpu_is_omap3505
342# undef cpu_is_omap3517
4bd7be22 343# undef cpu_is_ti816x
99541195
AM
344# undef cpu_is_am33xx
345# undef cpu_is_am335x
2c17f615 346# define cpu_is_omap3430() is_omap3430()
048f4bd7
SP
347# define cpu_is_omap3503() (cpu_is_omap3430() && \
348 (!omap3_has_iva()) && \
349 (!omap3_has_sgx()))
350# define cpu_is_omap3515() (cpu_is_omap3430() && \
0712fb39
SL
351 (!omap3_has_iva()) && \
352 (omap3_has_sgx()))
048f4bd7 353# define cpu_is_omap3525() (cpu_is_omap3430() && \
0712fb39
SL
354 (!omap3_has_sgx()) && \
355 (omap3_has_iva()))
048f4bd7 356# define cpu_is_omap3530() (cpu_is_omap3430())
4cac6018 357# define cpu_is_omap3517() is_omap3517()
1f1b0353
PW
358# define cpu_is_omap3505() (cpu_is_omap3517() && \
359 !omap3_has_sgx())
2456a10f
NM
360# undef cpu_is_omap3630
361# define cpu_is_omap3630() is_omap363x()
4bd7be22 362# define cpu_is_ti816x() is_ti816x()
99541195
AM
363# define cpu_is_am33xx() is_am33xx()
364# define cpu_is_am335x() is_am335x()
2c17f615
SMK
365#endif
366
44169075
SS
367# if defined(CONFIG_ARCH_OMAP4)
368# undef cpu_is_omap44xx
369# undef cpu_is_omap443x
fa54dccd 370# undef cpu_is_omap446x
b570e0ec
SS
371# define cpu_is_omap44xx() is_omap44xx()
372# define cpu_is_omap443x() is_omap443x()
fa54dccd 373# define cpu_is_omap446x() is_omap446x()
44169075
SS
374# endif
375
9ad5897c 376/* Macros to detect if we have OMAP1 or OMAP2 */
ae302f40 377#define cpu_class_is_omap1() (cpu_is_omap7xx() || cpu_is_omap15xx() || \
9ad5897c 378 cpu_is_omap16xx())
44169075
SS
379#define cpu_class_is_omap2() (cpu_is_omap24xx() || cpu_is_omap34xx() || \
380 cpu_is_omap44xx())
2c17f615 381
a8823143
TL
382/* Various silicon revisions for omap2 */
383#define OMAP242X_CLASS 0x24200024
76abab21 384#define OMAP2420_REV_ES1_0 OMAP242X_CLASS
057673d8 385#define OMAP2420_REV_ES2_0 (OMAP242X_CLASS | (0x1 << 8))
2c17f615 386
a8823143 387#define OMAP243X_CLASS 0x24300024
76abab21 388#define OMAP2430_REV_ES1_0 OMAP243X_CLASS
2c17f615 389
a8823143 390#define OMAP343X_CLASS 0x34300034
76abab21 391#define OMAP3430_REV_ES1_0 OMAP343X_CLASS
057673d8
PW
392#define OMAP3430_REV_ES2_0 (OMAP343X_CLASS | (0x1 << 8))
393#define OMAP3430_REV_ES2_1 (OMAP343X_CLASS | (0x2 << 8))
394#define OMAP3430_REV_ES3_0 (OMAP343X_CLASS | (0x3 << 8))
395#define OMAP3430_REV_ES3_1 (OMAP343X_CLASS | (0x4 << 8))
396#define OMAP3430_REV_ES3_1_2 (OMAP343X_CLASS | (0x5 << 8))
76abab21
SP
397
398#define OMAP363X_CLASS 0x36300034
399#define OMAP3630_REV_ES1_0 OMAP363X_CLASS
057673d8
PW
400#define OMAP3630_REV_ES1_1 (OMAP363X_CLASS | (0x1 << 8))
401#define OMAP3630_REV_ES1_2 (OMAP363X_CLASS | (0x2 << 8))
2456a10f 402
1f1b0353 403#define OMAP3517_CLASS 0x35170034
9ed2ba7a 404#define OMAP3517_REV_ES1_0 OMAP3517_CLASS
057673d8 405#define OMAP3517_REV_ES1_1 (OMAP3517_CLASS | (0x1 << 8))
048f4bd7 406
4bd7be22
HP
407#define TI816X_CLASS 0x81600034
408#define TI8168_REV_ES1_0 TI816X_CLASS
057673d8 409#define TI8168_REV_ES1_1 (TI816X_CLASS | (0x1 << 8))
4bd7be22 410
99541195
AM
411#define AM335X_CLASS 0x33500034
412#define AM335X_REV_ES1_0 AM335X_CLASS
413
b570e0ec 414#define OMAP443X_CLASS 0x44300044
e49c4d27
NK
415#define OMAP4430_REV_ES1_0 (OMAP443X_CLASS | (0x10 << 8))
416#define OMAP4430_REV_ES2_0 (OMAP443X_CLASS | (0x20 << 8))
417#define OMAP4430_REV_ES2_1 (OMAP443X_CLASS | (0x21 << 8))
418#define OMAP4430_REV_ES2_2 (OMAP443X_CLASS | (0x22 << 8))
55035c15 419#define OMAP4430_REV_ES2_3 (OMAP443X_CLASS | (0x23 << 8))
44169075 420
fa54dccd
A
421#define OMAP446X_CLASS 0x44600044
422#define OMAP4460_REV_ES1_0 (OMAP446X_CLASS | (0x10 << 8))
423
097c584c 424void omap2_check_revision(void);
a9f82d10 425
8384ce07
SP
426/*
427 * Runtime detection of OMAP3 features
b02b9172
PW
428 *
429 * OMAP3_HAS_IO_CHAIN_CTRL: Some later members of the OMAP3 chip
430 * family have OS-level control over the I/O chain clock. This is
431 * to avoid a window during which wakeups could potentially be lost
432 * during powerdomain transitions. If this bit is set, it
433 * indicates that the chip does support OS-level control of this
434 * feature.
8384ce07 435 */
cc0170b2 436extern u32 omap_features;
8384ce07
SP
437
438#define OMAP3_HAS_L2CACHE BIT(0)
439#define OMAP3_HAS_IVA BIT(1)
440#define OMAP3_HAS_SGX BIT(2)
441#define OMAP3_HAS_NEON BIT(3)
442#define OMAP3_HAS_ISP BIT(4)
7356f0b2 443#define OMAP3_HAS_192MHZ_CLK BIT(5)
ad0c63f1 444#define OMAP3_HAS_IO_WAKEUP BIT(6)
4bd7be22 445#define OMAP3_HAS_SDRC BIT(7)
b02b9172
PW
446#define OMAP3_HAS_IO_CHAIN_CTRL BIT(8)
447#define OMAP4_HAS_MPU_1GHZ BIT(9)
448#define OMAP4_HAS_MPU_1_2GHZ BIT(10)
449#define OMAP4_HAS_MPU_1_5GHZ BIT(11)
cc0170b2 450
8384ce07
SP
451
452#define OMAP3_HAS_FEATURE(feat,flag) \
453static inline unsigned int omap3_has_ ##feat(void) \
454{ \
cc0170b2 455 return omap_features & OMAP3_HAS_ ##flag; \
8384ce07
SP
456} \
457
458OMAP3_HAS_FEATURE(l2cache, L2CACHE)
459OMAP3_HAS_FEATURE(sgx, SGX)
460OMAP3_HAS_FEATURE(iva, IVA)
461OMAP3_HAS_FEATURE(neon, NEON)
462OMAP3_HAS_FEATURE(isp, ISP)
7356f0b2 463OMAP3_HAS_FEATURE(192mhz_clk, 192MHZ_CLK)
ad0c63f1 464OMAP3_HAS_FEATURE(io_wakeup, IO_WAKEUP)
4bd7be22 465OMAP3_HAS_FEATURE(sdrc, SDRC)
b02b9172 466OMAP3_HAS_FEATURE(io_chain_ctrl, IO_CHAIN_CTRL)
8384ce07 467
cc0170b2
A
468/*
469 * Runtime detection of OMAP4 features
470 */
cc0170b2
A
471#define OMAP4_HAS_FEATURE(feat, flag) \
472static inline unsigned int omap4_has_ ##feat(void) \
473{ \
474 return omap_features & OMAP4_HAS_ ##flag; \
475} \
476
477OMAP4_HAS_FEATURE(mpu_1ghz, MPU_1GHZ)
478OMAP4_HAS_FEATURE(mpu_1_2ghz, MPU_1_2GHZ)
479OMAP4_HAS_FEATURE(mpu_1_5ghz, MPU_1_5GHZ)
480
a9f82d10 481#endif