2 * Copyright (C) 2001 Ben. Herrenschmidt (benh@kernel.crashing.org)
4 * Modifications for ppc64:
5 * Copyright (C) 2003 Dave Engebretsen <engebret@us.ibm.com>
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation; either version
10 * 2 of the License, or (at your option) any later version.
13 #include <linux/string.h>
14 #include <linux/sched.h>
15 #include <linux/threads.h>
16 #include <linux/init.h>
17 #include <linux/module.h>
19 #include <asm/oprofile_impl.h>
20 #include <asm/cputable.h>
21 #include <asm/prom.h> /* for PTRRELOC on ARCH=ppc */
24 struct cpu_spec* cur_cpu_spec = NULL;
25 EXPORT_SYMBOL(cur_cpu_spec);
27 /* The platform string corresponding to the real PVR */
28 const char *powerpc_base_platform;
31 * Unlike ppc32, ppc64 will only call this once for the boot CPU, it's
32 * the responsibility of the appropriate CPU save/restore functions to
33 * eventually copy these settings over. Those save/restore aren't yet
34 * part of the cputable though. That has to be fixed for both ppc32
38 extern void __setup_cpu_e200(unsigned long offset, struct cpu_spec* spec);
39 extern void __setup_cpu_e500v1(unsigned long offset, struct cpu_spec* spec);
40 extern void __setup_cpu_e500v2(unsigned long offset, struct cpu_spec* spec);
41 extern void __setup_cpu_e500mc(unsigned long offset, struct cpu_spec* spec);
42 extern void __setup_cpu_440ep(unsigned long offset, struct cpu_spec* spec);
43 extern void __setup_cpu_440epx(unsigned long offset, struct cpu_spec* spec);
44 extern void __setup_cpu_440gx(unsigned long offset, struct cpu_spec* spec);
45 extern void __setup_cpu_440grx(unsigned long offset, struct cpu_spec* spec);
46 extern void __setup_cpu_440spe(unsigned long offset, struct cpu_spec* spec);
47 extern void __setup_cpu_440x5(unsigned long offset, struct cpu_spec* spec);
48 extern void __setup_cpu_460ex(unsigned long offset, struct cpu_spec* spec);
49 extern void __setup_cpu_460gt(unsigned long offset, struct cpu_spec* spec);
50 extern void __setup_cpu_460sx(unsigned long offset, struct cpu_spec *spec);
51 extern void __setup_cpu_apm821xx(unsigned long offset, struct cpu_spec *spec);
52 extern void __setup_cpu_603(unsigned long offset, struct cpu_spec* spec);
53 extern void __setup_cpu_604(unsigned long offset, struct cpu_spec* spec);
54 extern void __setup_cpu_750(unsigned long offset, struct cpu_spec* spec);
55 extern void __setup_cpu_750cx(unsigned long offset, struct cpu_spec* spec);
56 extern void __setup_cpu_750fx(unsigned long offset, struct cpu_spec* spec);
57 extern void __setup_cpu_7400(unsigned long offset, struct cpu_spec* spec);
58 extern void __setup_cpu_7410(unsigned long offset, struct cpu_spec* spec);
59 extern void __setup_cpu_745x(unsigned long offset, struct cpu_spec* spec);
60 #endif /* CONFIG_PPC32 */
62 extern void __setup_cpu_ppc970(unsigned long offset, struct cpu_spec* spec);
63 extern void __setup_cpu_ppc970MP(unsigned long offset, struct cpu_spec* spec);
64 extern void __setup_cpu_pa6t(unsigned long offset, struct cpu_spec* spec);
65 extern void __restore_cpu_pa6t(void);
66 extern void __restore_cpu_ppc970(void);
67 extern void __setup_cpu_power7(unsigned long offset, struct cpu_spec* spec);
68 extern void __restore_cpu_power7(void);
69 #endif /* CONFIG_PPC64 */
70 #if defined(CONFIG_E500)
71 extern void __setup_cpu_e5500(unsigned long offset, struct cpu_spec* spec);
72 extern void __restore_cpu_e5500(void);
73 #endif /* CONFIG_E500 */
75 /* This table only contains "desktop" CPUs, it need to be filled with embedded
78 #define COMMON_USER (PPC_FEATURE_32 | PPC_FEATURE_HAS_FPU | \
80 #define COMMON_USER_PPC64 (COMMON_USER | PPC_FEATURE_64)
81 #define COMMON_USER_POWER4 (COMMON_USER_PPC64 | PPC_FEATURE_POWER4)
82 #define COMMON_USER_POWER5 (COMMON_USER_PPC64 | PPC_FEATURE_POWER5 |\
83 PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP)
84 #define COMMON_USER_POWER5_PLUS (COMMON_USER_PPC64 | PPC_FEATURE_POWER5_PLUS|\
85 PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP)
86 #define COMMON_USER_POWER6 (COMMON_USER_PPC64 | PPC_FEATURE_ARCH_2_05 |\
87 PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP | \
88 PPC_FEATURE_TRUE_LE | \
89 PPC_FEATURE_PSERIES_PERFMON_COMPAT)
90 #define COMMON_USER_POWER7 (COMMON_USER_PPC64 | PPC_FEATURE_ARCH_2_06 |\
91 PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP | \
92 PPC_FEATURE_TRUE_LE | \
93 PPC_FEATURE_PSERIES_PERFMON_COMPAT)
94 #define COMMON_USER_PA6T (COMMON_USER_PPC64 | PPC_FEATURE_PA6T |\
95 PPC_FEATURE_TRUE_LE | \
96 PPC_FEATURE_HAS_ALTIVEC_COMP)
97 #ifdef CONFIG_PPC_BOOK3E_64
98 #define COMMON_USER_BOOKE (COMMON_USER_PPC64 | PPC_FEATURE_BOOKE)
100 #define COMMON_USER_BOOKE (PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU | \
104 static struct cpu_spec __initdata cpu_specs[] = {
105 #ifdef CONFIG_PPC_BOOK3S_64
107 .pvr_mask = 0xffff0000,
108 .pvr_value = 0x00400000,
109 .cpu_name = "POWER3 (630)",
110 .cpu_features = CPU_FTRS_POWER3,
111 .cpu_user_features = COMMON_USER_PPC64|PPC_FEATURE_PPC_LE,
112 .mmu_features = MMU_FTR_HPTE_TABLE,
116 .pmc_type = PPC_PMC_IBM,
117 .oprofile_cpu_type = "ppc64/power3",
118 .oprofile_type = PPC_OPROFILE_RS64,
119 .platform = "power3",
122 .pvr_mask = 0xffff0000,
123 .pvr_value = 0x00410000,
124 .cpu_name = "POWER3 (630+)",
125 .cpu_features = CPU_FTRS_POWER3,
126 .cpu_user_features = COMMON_USER_PPC64|PPC_FEATURE_PPC_LE,
127 .mmu_features = MMU_FTR_HPTE_TABLE,
131 .pmc_type = PPC_PMC_IBM,
132 .oprofile_cpu_type = "ppc64/power3",
133 .oprofile_type = PPC_OPROFILE_RS64,
134 .platform = "power3",
137 .pvr_mask = 0xffff0000,
138 .pvr_value = 0x00330000,
139 .cpu_name = "RS64-II (northstar)",
140 .cpu_features = CPU_FTRS_RS64,
141 .cpu_user_features = COMMON_USER_PPC64,
142 .mmu_features = MMU_FTR_HPTE_TABLE,
146 .pmc_type = PPC_PMC_IBM,
147 .oprofile_cpu_type = "ppc64/rs64",
148 .oprofile_type = PPC_OPROFILE_RS64,
152 .pvr_mask = 0xffff0000,
153 .pvr_value = 0x00340000,
154 .cpu_name = "RS64-III (pulsar)",
155 .cpu_features = CPU_FTRS_RS64,
156 .cpu_user_features = COMMON_USER_PPC64,
157 .mmu_features = MMU_FTR_HPTE_TABLE,
161 .pmc_type = PPC_PMC_IBM,
162 .oprofile_cpu_type = "ppc64/rs64",
163 .oprofile_type = PPC_OPROFILE_RS64,
167 .pvr_mask = 0xffff0000,
168 .pvr_value = 0x00360000,
169 .cpu_name = "RS64-III (icestar)",
170 .cpu_features = CPU_FTRS_RS64,
171 .cpu_user_features = COMMON_USER_PPC64,
172 .mmu_features = MMU_FTR_HPTE_TABLE,
176 .pmc_type = PPC_PMC_IBM,
177 .oprofile_cpu_type = "ppc64/rs64",
178 .oprofile_type = PPC_OPROFILE_RS64,
182 .pvr_mask = 0xffff0000,
183 .pvr_value = 0x00370000,
184 .cpu_name = "RS64-IV (sstar)",
185 .cpu_features = CPU_FTRS_RS64,
186 .cpu_user_features = COMMON_USER_PPC64,
187 .mmu_features = MMU_FTR_HPTE_TABLE,
191 .pmc_type = PPC_PMC_IBM,
192 .oprofile_cpu_type = "ppc64/rs64",
193 .oprofile_type = PPC_OPROFILE_RS64,
197 .pvr_mask = 0xffff0000,
198 .pvr_value = 0x00350000,
199 .cpu_name = "POWER4 (gp)",
200 .cpu_features = CPU_FTRS_POWER4,
201 .cpu_user_features = COMMON_USER_POWER4,
202 .mmu_features = MMU_FTR_HPTE_TABLE,
206 .pmc_type = PPC_PMC_IBM,
207 .oprofile_cpu_type = "ppc64/power4",
208 .oprofile_type = PPC_OPROFILE_POWER4,
209 .platform = "power4",
212 .pvr_mask = 0xffff0000,
213 .pvr_value = 0x00380000,
214 .cpu_name = "POWER4+ (gq)",
215 .cpu_features = CPU_FTRS_POWER4,
216 .cpu_user_features = COMMON_USER_POWER4,
217 .mmu_features = MMU_FTR_HPTE_TABLE,
221 .pmc_type = PPC_PMC_IBM,
222 .oprofile_cpu_type = "ppc64/power4",
223 .oprofile_type = PPC_OPROFILE_POWER4,
224 .platform = "power4",
227 .pvr_mask = 0xffff0000,
228 .pvr_value = 0x00390000,
229 .cpu_name = "PPC970",
230 .cpu_features = CPU_FTRS_PPC970,
231 .cpu_user_features = COMMON_USER_POWER4 |
232 PPC_FEATURE_HAS_ALTIVEC_COMP,
233 .mmu_features = MMU_FTR_HPTE_TABLE,
237 .pmc_type = PPC_PMC_IBM,
238 .cpu_setup = __setup_cpu_ppc970,
239 .cpu_restore = __restore_cpu_ppc970,
240 .oprofile_cpu_type = "ppc64/970",
241 .oprofile_type = PPC_OPROFILE_POWER4,
242 .platform = "ppc970",
245 .pvr_mask = 0xffff0000,
246 .pvr_value = 0x003c0000,
247 .cpu_name = "PPC970FX",
248 .cpu_features = CPU_FTRS_PPC970,
249 .cpu_user_features = COMMON_USER_POWER4 |
250 PPC_FEATURE_HAS_ALTIVEC_COMP,
251 .mmu_features = MMU_FTR_HPTE_TABLE,
255 .pmc_type = PPC_PMC_IBM,
256 .cpu_setup = __setup_cpu_ppc970,
257 .cpu_restore = __restore_cpu_ppc970,
258 .oprofile_cpu_type = "ppc64/970",
259 .oprofile_type = PPC_OPROFILE_POWER4,
260 .platform = "ppc970",
262 { /* PPC970MP DD1.0 - no DEEPNAP, use regular 970 init */
263 .pvr_mask = 0xffffffff,
264 .pvr_value = 0x00440100,
265 .cpu_name = "PPC970MP",
266 .cpu_features = CPU_FTRS_PPC970,
267 .cpu_user_features = COMMON_USER_POWER4 |
268 PPC_FEATURE_HAS_ALTIVEC_COMP,
269 .mmu_features = MMU_FTR_HPTE_TABLE,
273 .pmc_type = PPC_PMC_IBM,
274 .cpu_setup = __setup_cpu_ppc970,
275 .cpu_restore = __restore_cpu_ppc970,
276 .oprofile_cpu_type = "ppc64/970MP",
277 .oprofile_type = PPC_OPROFILE_POWER4,
278 .platform = "ppc970",
281 .pvr_mask = 0xffff0000,
282 .pvr_value = 0x00440000,
283 .cpu_name = "PPC970MP",
284 .cpu_features = CPU_FTRS_PPC970,
285 .cpu_user_features = COMMON_USER_POWER4 |
286 PPC_FEATURE_HAS_ALTIVEC_COMP,
287 .mmu_features = MMU_FTR_HPTE_TABLE,
291 .pmc_type = PPC_PMC_IBM,
292 .cpu_setup = __setup_cpu_ppc970MP,
293 .cpu_restore = __restore_cpu_ppc970,
294 .oprofile_cpu_type = "ppc64/970MP",
295 .oprofile_type = PPC_OPROFILE_POWER4,
296 .platform = "ppc970",
299 .pvr_mask = 0xffff0000,
300 .pvr_value = 0x00450000,
301 .cpu_name = "PPC970GX",
302 .cpu_features = CPU_FTRS_PPC970,
303 .cpu_user_features = COMMON_USER_POWER4 |
304 PPC_FEATURE_HAS_ALTIVEC_COMP,
305 .mmu_features = MMU_FTR_HPTE_TABLE,
309 .pmc_type = PPC_PMC_IBM,
310 .cpu_setup = __setup_cpu_ppc970,
311 .oprofile_cpu_type = "ppc64/970",
312 .oprofile_type = PPC_OPROFILE_POWER4,
313 .platform = "ppc970",
316 .pvr_mask = 0xffff0000,
317 .pvr_value = 0x003a0000,
318 .cpu_name = "POWER5 (gr)",
319 .cpu_features = CPU_FTRS_POWER5,
320 .cpu_user_features = COMMON_USER_POWER5,
321 .mmu_features = MMU_FTR_HPTE_TABLE,
325 .pmc_type = PPC_PMC_IBM,
326 .oprofile_cpu_type = "ppc64/power5",
327 .oprofile_type = PPC_OPROFILE_POWER4,
328 /* SIHV / SIPR bits are implemented on POWER4+ (GQ)
329 * and above but only works on POWER5 and above
331 .oprofile_mmcra_sihv = MMCRA_SIHV,
332 .oprofile_mmcra_sipr = MMCRA_SIPR,
333 .platform = "power5",
336 .pvr_mask = 0xffffff00,
337 .pvr_value = 0x003b0300,
338 .cpu_name = "POWER5+ (gs)",
339 .cpu_features = CPU_FTRS_POWER5,
340 .cpu_user_features = COMMON_USER_POWER5_PLUS,
341 .mmu_features = MMU_FTR_HPTE_TABLE,
345 .oprofile_cpu_type = "ppc64/power5++",
346 .oprofile_type = PPC_OPROFILE_POWER4,
347 .oprofile_mmcra_sihv = MMCRA_SIHV,
348 .oprofile_mmcra_sipr = MMCRA_SIPR,
349 .platform = "power5+",
352 .pvr_mask = 0xffff0000,
353 .pvr_value = 0x003b0000,
354 .cpu_name = "POWER5+ (gs)",
355 .cpu_features = CPU_FTRS_POWER5,
356 .cpu_user_features = COMMON_USER_POWER5_PLUS,
357 .mmu_features = MMU_FTR_HPTE_TABLE,
361 .pmc_type = PPC_PMC_IBM,
362 .oprofile_cpu_type = "ppc64/power5+",
363 .oprofile_type = PPC_OPROFILE_POWER4,
364 .oprofile_mmcra_sihv = MMCRA_SIHV,
365 .oprofile_mmcra_sipr = MMCRA_SIPR,
366 .platform = "power5+",
368 { /* POWER6 in P5+ mode; 2.04-compliant processor */
369 .pvr_mask = 0xffffffff,
370 .pvr_value = 0x0f000001,
371 .cpu_name = "POWER5+",
372 .cpu_features = CPU_FTRS_POWER5,
373 .cpu_user_features = COMMON_USER_POWER5_PLUS,
374 .mmu_features = MMU_FTR_HPTE_TABLE,
377 .oprofile_cpu_type = "ppc64/ibm-compat-v1",
378 .oprofile_type = PPC_OPROFILE_POWER4,
379 .platform = "power5+",
382 .pvr_mask = 0xffff0000,
383 .pvr_value = 0x003e0000,
384 .cpu_name = "POWER6 (raw)",
385 .cpu_features = CPU_FTRS_POWER6,
386 .cpu_user_features = COMMON_USER_POWER6 |
387 PPC_FEATURE_POWER6_EXT,
388 .mmu_features = MMU_FTR_HPTE_TABLE,
392 .pmc_type = PPC_PMC_IBM,
393 .oprofile_cpu_type = "ppc64/power6",
394 .oprofile_type = PPC_OPROFILE_POWER4,
395 .oprofile_mmcra_sihv = POWER6_MMCRA_SIHV,
396 .oprofile_mmcra_sipr = POWER6_MMCRA_SIPR,
397 .oprofile_mmcra_clear = POWER6_MMCRA_THRM |
399 .platform = "power6x",
401 { /* 2.05-compliant processor, i.e. Power6 "architected" mode */
402 .pvr_mask = 0xffffffff,
403 .pvr_value = 0x0f000002,
404 .cpu_name = "POWER6 (architected)",
405 .cpu_features = CPU_FTRS_POWER6,
406 .cpu_user_features = COMMON_USER_POWER6,
407 .mmu_features = MMU_FTR_HPTE_TABLE,
410 .oprofile_cpu_type = "ppc64/ibm-compat-v1",
411 .oprofile_type = PPC_OPROFILE_POWER4,
412 .platform = "power6",
414 { /* 2.06-compliant processor, i.e. Power7 "architected" mode */
415 .pvr_mask = 0xffffffff,
416 .pvr_value = 0x0f000003,
417 .cpu_name = "POWER7 (architected)",
418 .cpu_features = CPU_FTRS_POWER7,
419 .cpu_user_features = COMMON_USER_POWER7,
420 .mmu_features = MMU_FTR_HPTE_TABLE |
424 .oprofile_type = PPC_OPROFILE_POWER4,
425 .oprofile_cpu_type = "ppc64/ibm-compat-v1",
426 .cpu_setup = __setup_cpu_power7,
427 .cpu_restore = __restore_cpu_power7,
428 .platform = "power7",
431 .pvr_mask = 0xffff0000,
432 .pvr_value = 0x003f0000,
433 .cpu_name = "POWER7 (raw)",
434 .cpu_features = CPU_FTRS_POWER7,
435 .cpu_user_features = COMMON_USER_POWER7,
436 .mmu_features = MMU_FTR_HPTE_TABLE |
441 .pmc_type = PPC_PMC_IBM,
442 .oprofile_cpu_type = "ppc64/power7",
443 .oprofile_type = PPC_OPROFILE_POWER4,
444 .cpu_setup = __setup_cpu_power7,
445 .cpu_restore = __restore_cpu_power7,
446 .platform = "power7",
449 .pvr_mask = 0xffff0000,
450 .pvr_value = 0x004A0000,
451 .cpu_name = "POWER7+ (raw)",
452 .cpu_features = CPU_FTRS_POWER7,
453 .cpu_user_features = COMMON_USER_POWER7,
454 .mmu_features = MMU_FTR_HPTE_TABLE |
459 .pmc_type = PPC_PMC_IBM,
460 .oprofile_cpu_type = "ppc64/power7",
461 .oprofile_type = PPC_OPROFILE_POWER4,
462 .cpu_setup = __setup_cpu_power7,
463 .cpu_restore = __restore_cpu_power7,
464 .platform = "power7+",
466 { /* Cell Broadband Engine */
467 .pvr_mask = 0xffff0000,
468 .pvr_value = 0x00700000,
469 .cpu_name = "Cell Broadband Engine",
470 .cpu_features = CPU_FTRS_CELL,
471 .cpu_user_features = COMMON_USER_PPC64 |
472 PPC_FEATURE_CELL | PPC_FEATURE_HAS_ALTIVEC_COMP |
474 .mmu_features = MMU_FTR_HPTE_TABLE,
478 .pmc_type = PPC_PMC_IBM,
479 .oprofile_cpu_type = "ppc64/cell-be",
480 .oprofile_type = PPC_OPROFILE_CELL,
481 .platform = "ppc-cell-be",
484 .pvr_mask = 0x7fff0000,
485 .pvr_value = 0x00900000,
487 .cpu_features = CPU_FTRS_PA6T,
488 .cpu_user_features = COMMON_USER_PA6T,
489 .mmu_features = MMU_FTR_HPTE_TABLE,
493 .pmc_type = PPC_PMC_PA6T,
494 .cpu_setup = __setup_cpu_pa6t,
495 .cpu_restore = __restore_cpu_pa6t,
496 .oprofile_cpu_type = "ppc64/pa6t",
497 .oprofile_type = PPC_OPROFILE_PA6T,
500 { /* default match */
501 .pvr_mask = 0x00000000,
502 .pvr_value = 0x00000000,
503 .cpu_name = "POWER4 (compatible)",
504 .cpu_features = CPU_FTRS_COMPATIBLE,
505 .cpu_user_features = COMMON_USER_PPC64,
506 .mmu_features = MMU_FTR_HPTE_TABLE,
510 .pmc_type = PPC_PMC_IBM,
511 .platform = "power4",
513 #endif /* CONFIG_PPC_BOOK3S_64 */
518 .pvr_mask = 0xffff0000,
519 .pvr_value = 0x00010000,
521 .cpu_features = CPU_FTRS_PPC601,
522 .cpu_user_features = COMMON_USER | PPC_FEATURE_601_INSTR |
523 PPC_FEATURE_UNIFIED_CACHE | PPC_FEATURE_NO_TB,
524 .mmu_features = MMU_FTR_HPTE_TABLE,
527 .machine_check = machine_check_generic,
528 .platform = "ppc601",
531 .pvr_mask = 0xffff0000,
532 .pvr_value = 0x00030000,
534 .cpu_features = CPU_FTRS_603,
535 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
539 .cpu_setup = __setup_cpu_603,
540 .machine_check = machine_check_generic,
541 .platform = "ppc603",
544 .pvr_mask = 0xffff0000,
545 .pvr_value = 0x00060000,
547 .cpu_features = CPU_FTRS_603,
548 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
552 .cpu_setup = __setup_cpu_603,
553 .machine_check = machine_check_generic,
554 .platform = "ppc603",
557 .pvr_mask = 0xffff0000,
558 .pvr_value = 0x00070000,
560 .cpu_features = CPU_FTRS_603,
561 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
565 .cpu_setup = __setup_cpu_603,
566 .machine_check = machine_check_generic,
567 .platform = "ppc603",
570 .pvr_mask = 0xffff0000,
571 .pvr_value = 0x00040000,
573 .cpu_features = CPU_FTRS_604,
574 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
575 .mmu_features = MMU_FTR_HPTE_TABLE,
579 .cpu_setup = __setup_cpu_604,
580 .machine_check = machine_check_generic,
581 .platform = "ppc604",
584 .pvr_mask = 0xfffff000,
585 .pvr_value = 0x00090000,
587 .cpu_features = CPU_FTRS_604,
588 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
589 .mmu_features = MMU_FTR_HPTE_TABLE,
593 .cpu_setup = __setup_cpu_604,
594 .machine_check = machine_check_generic,
595 .platform = "ppc604",
598 .pvr_mask = 0xffff0000,
599 .pvr_value = 0x00090000,
601 .cpu_features = CPU_FTRS_604,
602 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
603 .mmu_features = MMU_FTR_HPTE_TABLE,
607 .cpu_setup = __setup_cpu_604,
608 .machine_check = machine_check_generic,
609 .platform = "ppc604",
612 .pvr_mask = 0xffff0000,
613 .pvr_value = 0x000a0000,
615 .cpu_features = CPU_FTRS_604,
616 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
617 .mmu_features = MMU_FTR_HPTE_TABLE,
621 .cpu_setup = __setup_cpu_604,
622 .machine_check = machine_check_generic,
623 .platform = "ppc604",
625 { /* 740/750 (0x4202, don't support TAU ?) */
626 .pvr_mask = 0xffffffff,
627 .pvr_value = 0x00084202,
628 .cpu_name = "740/750",
629 .cpu_features = CPU_FTRS_740_NOTAU,
630 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
631 .mmu_features = MMU_FTR_HPTE_TABLE,
635 .cpu_setup = __setup_cpu_750,
636 .machine_check = machine_check_generic,
637 .platform = "ppc750",
639 { /* 750CX (80100 and 8010x?) */
640 .pvr_mask = 0xfffffff0,
641 .pvr_value = 0x00080100,
643 .cpu_features = CPU_FTRS_750,
644 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
645 .mmu_features = MMU_FTR_HPTE_TABLE,
649 .cpu_setup = __setup_cpu_750cx,
650 .machine_check = machine_check_generic,
651 .platform = "ppc750",
653 { /* 750CX (82201 and 82202) */
654 .pvr_mask = 0xfffffff0,
655 .pvr_value = 0x00082200,
657 .cpu_features = CPU_FTRS_750,
658 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
659 .mmu_features = MMU_FTR_HPTE_TABLE,
663 .pmc_type = PPC_PMC_IBM,
664 .cpu_setup = __setup_cpu_750cx,
665 .machine_check = machine_check_generic,
666 .platform = "ppc750",
668 { /* 750CXe (82214) */
669 .pvr_mask = 0xfffffff0,
670 .pvr_value = 0x00082210,
671 .cpu_name = "750CXe",
672 .cpu_features = CPU_FTRS_750,
673 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
674 .mmu_features = MMU_FTR_HPTE_TABLE,
678 .pmc_type = PPC_PMC_IBM,
679 .cpu_setup = __setup_cpu_750cx,
680 .machine_check = machine_check_generic,
681 .platform = "ppc750",
683 { /* 750CXe "Gekko" (83214) */
684 .pvr_mask = 0xffffffff,
685 .pvr_value = 0x00083214,
686 .cpu_name = "750CXe",
687 .cpu_features = CPU_FTRS_750,
688 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
689 .mmu_features = MMU_FTR_HPTE_TABLE,
693 .pmc_type = PPC_PMC_IBM,
694 .cpu_setup = __setup_cpu_750cx,
695 .machine_check = machine_check_generic,
696 .platform = "ppc750",
698 { /* 750CL (and "Broadway") */
699 .pvr_mask = 0xfffff0e0,
700 .pvr_value = 0x00087000,
702 .cpu_features = CPU_FTRS_750CL,
703 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
704 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
708 .pmc_type = PPC_PMC_IBM,
709 .cpu_setup = __setup_cpu_750,
710 .machine_check = machine_check_generic,
711 .platform = "ppc750",
712 .oprofile_cpu_type = "ppc/750",
713 .oprofile_type = PPC_OPROFILE_G4,
716 .pvr_mask = 0xfffff000,
717 .pvr_value = 0x00083000,
718 .cpu_name = "745/755",
719 .cpu_features = CPU_FTRS_750,
720 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
721 .mmu_features = MMU_FTR_HPTE_TABLE,
725 .pmc_type = PPC_PMC_IBM,
726 .cpu_setup = __setup_cpu_750,
727 .machine_check = machine_check_generic,
728 .platform = "ppc750",
730 { /* 750FX rev 1.x */
731 .pvr_mask = 0xffffff00,
732 .pvr_value = 0x70000100,
734 .cpu_features = CPU_FTRS_750FX1,
735 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
736 .mmu_features = MMU_FTR_HPTE_TABLE,
740 .pmc_type = PPC_PMC_IBM,
741 .cpu_setup = __setup_cpu_750,
742 .machine_check = machine_check_generic,
743 .platform = "ppc750",
744 .oprofile_cpu_type = "ppc/750",
745 .oprofile_type = PPC_OPROFILE_G4,
747 { /* 750FX rev 2.0 must disable HID0[DPM] */
748 .pvr_mask = 0xffffffff,
749 .pvr_value = 0x70000200,
751 .cpu_features = CPU_FTRS_750FX2,
752 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
753 .mmu_features = MMU_FTR_HPTE_TABLE,
757 .pmc_type = PPC_PMC_IBM,
758 .cpu_setup = __setup_cpu_750,
759 .machine_check = machine_check_generic,
760 .platform = "ppc750",
761 .oprofile_cpu_type = "ppc/750",
762 .oprofile_type = PPC_OPROFILE_G4,
764 { /* 750FX (All revs except 2.0) */
765 .pvr_mask = 0xffff0000,
766 .pvr_value = 0x70000000,
768 .cpu_features = CPU_FTRS_750FX,
769 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
770 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
774 .pmc_type = PPC_PMC_IBM,
775 .cpu_setup = __setup_cpu_750fx,
776 .machine_check = machine_check_generic,
777 .platform = "ppc750",
778 .oprofile_cpu_type = "ppc/750",
779 .oprofile_type = PPC_OPROFILE_G4,
782 .pvr_mask = 0xffff0000,
783 .pvr_value = 0x70020000,
785 .cpu_features = CPU_FTRS_750GX,
786 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
787 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
791 .pmc_type = PPC_PMC_IBM,
792 .cpu_setup = __setup_cpu_750fx,
793 .machine_check = machine_check_generic,
794 .platform = "ppc750",
795 .oprofile_cpu_type = "ppc/750",
796 .oprofile_type = PPC_OPROFILE_G4,
798 { /* 740/750 (L2CR bit need fixup for 740) */
799 .pvr_mask = 0xffff0000,
800 .pvr_value = 0x00080000,
801 .cpu_name = "740/750",
802 .cpu_features = CPU_FTRS_740,
803 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
804 .mmu_features = MMU_FTR_HPTE_TABLE,
808 .pmc_type = PPC_PMC_IBM,
809 .cpu_setup = __setup_cpu_750,
810 .machine_check = machine_check_generic,
811 .platform = "ppc750",
813 { /* 7400 rev 1.1 ? (no TAU) */
814 .pvr_mask = 0xffffffff,
815 .pvr_value = 0x000c1101,
816 .cpu_name = "7400 (1.1)",
817 .cpu_features = CPU_FTRS_7400_NOTAU,
818 .cpu_user_features = COMMON_USER |
819 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
820 .mmu_features = MMU_FTR_HPTE_TABLE,
824 .pmc_type = PPC_PMC_G4,
825 .cpu_setup = __setup_cpu_7400,
826 .machine_check = machine_check_generic,
827 .platform = "ppc7400",
830 .pvr_mask = 0xffff0000,
831 .pvr_value = 0x000c0000,
833 .cpu_features = CPU_FTRS_7400,
834 .cpu_user_features = COMMON_USER |
835 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
836 .mmu_features = MMU_FTR_HPTE_TABLE,
840 .pmc_type = PPC_PMC_G4,
841 .cpu_setup = __setup_cpu_7400,
842 .machine_check = machine_check_generic,
843 .platform = "ppc7400",
846 .pvr_mask = 0xffff0000,
847 .pvr_value = 0x800c0000,
849 .cpu_features = CPU_FTRS_7400,
850 .cpu_user_features = COMMON_USER |
851 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
852 .mmu_features = MMU_FTR_HPTE_TABLE,
856 .pmc_type = PPC_PMC_G4,
857 .cpu_setup = __setup_cpu_7410,
858 .machine_check = machine_check_generic,
859 .platform = "ppc7400",
861 { /* 7450 2.0 - no doze/nap */
862 .pvr_mask = 0xffffffff,
863 .pvr_value = 0x80000200,
865 .cpu_features = CPU_FTRS_7450_20,
866 .cpu_user_features = COMMON_USER |
867 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
868 .mmu_features = MMU_FTR_HPTE_TABLE,
872 .pmc_type = PPC_PMC_G4,
873 .cpu_setup = __setup_cpu_745x,
874 .oprofile_cpu_type = "ppc/7450",
875 .oprofile_type = PPC_OPROFILE_G4,
876 .machine_check = machine_check_generic,
877 .platform = "ppc7450",
880 .pvr_mask = 0xffffffff,
881 .pvr_value = 0x80000201,
883 .cpu_features = CPU_FTRS_7450_21,
884 .cpu_user_features = COMMON_USER |
885 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
886 .mmu_features = MMU_FTR_HPTE_TABLE,
890 .pmc_type = PPC_PMC_G4,
891 .cpu_setup = __setup_cpu_745x,
892 .oprofile_cpu_type = "ppc/7450",
893 .oprofile_type = PPC_OPROFILE_G4,
894 .machine_check = machine_check_generic,
895 .platform = "ppc7450",
897 { /* 7450 2.3 and newer */
898 .pvr_mask = 0xffff0000,
899 .pvr_value = 0x80000000,
901 .cpu_features = CPU_FTRS_7450_23,
902 .cpu_user_features = COMMON_USER |
903 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
904 .mmu_features = MMU_FTR_HPTE_TABLE,
908 .pmc_type = PPC_PMC_G4,
909 .cpu_setup = __setup_cpu_745x,
910 .oprofile_cpu_type = "ppc/7450",
911 .oprofile_type = PPC_OPROFILE_G4,
912 .machine_check = machine_check_generic,
913 .platform = "ppc7450",
916 .pvr_mask = 0xffffff00,
917 .pvr_value = 0x80010100,
919 .cpu_features = CPU_FTRS_7455_1,
920 .cpu_user_features = COMMON_USER |
921 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
922 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
926 .pmc_type = PPC_PMC_G4,
927 .cpu_setup = __setup_cpu_745x,
928 .oprofile_cpu_type = "ppc/7450",
929 .oprofile_type = PPC_OPROFILE_G4,
930 .machine_check = machine_check_generic,
931 .platform = "ppc7450",
934 .pvr_mask = 0xffffffff,
935 .pvr_value = 0x80010200,
937 .cpu_features = CPU_FTRS_7455_20,
938 .cpu_user_features = COMMON_USER |
939 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
940 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
944 .pmc_type = PPC_PMC_G4,
945 .cpu_setup = __setup_cpu_745x,
946 .oprofile_cpu_type = "ppc/7450",
947 .oprofile_type = PPC_OPROFILE_G4,
948 .machine_check = machine_check_generic,
949 .platform = "ppc7450",
952 .pvr_mask = 0xffff0000,
953 .pvr_value = 0x80010000,
955 .cpu_features = CPU_FTRS_7455,
956 .cpu_user_features = COMMON_USER |
957 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
958 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
962 .pmc_type = PPC_PMC_G4,
963 .cpu_setup = __setup_cpu_745x,
964 .oprofile_cpu_type = "ppc/7450",
965 .oprofile_type = PPC_OPROFILE_G4,
966 .machine_check = machine_check_generic,
967 .platform = "ppc7450",
969 { /* 7447/7457 Rev 1.0 */
970 .pvr_mask = 0xffffffff,
971 .pvr_value = 0x80020100,
972 .cpu_name = "7447/7457",
973 .cpu_features = CPU_FTRS_7447_10,
974 .cpu_user_features = COMMON_USER |
975 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
976 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
980 .pmc_type = PPC_PMC_G4,
981 .cpu_setup = __setup_cpu_745x,
982 .oprofile_cpu_type = "ppc/7450",
983 .oprofile_type = PPC_OPROFILE_G4,
984 .machine_check = machine_check_generic,
985 .platform = "ppc7450",
987 { /* 7447/7457 Rev 1.1 */
988 .pvr_mask = 0xffffffff,
989 .pvr_value = 0x80020101,
990 .cpu_name = "7447/7457",
991 .cpu_features = CPU_FTRS_7447_10,
992 .cpu_user_features = COMMON_USER |
993 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
994 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
998 .pmc_type = PPC_PMC_G4,
999 .cpu_setup = __setup_cpu_745x,
1000 .oprofile_cpu_type = "ppc/7450",
1001 .oprofile_type = PPC_OPROFILE_G4,
1002 .machine_check = machine_check_generic,
1003 .platform = "ppc7450",
1005 { /* 7447/7457 Rev 1.2 and later */
1006 .pvr_mask = 0xffff0000,
1007 .pvr_value = 0x80020000,
1008 .cpu_name = "7447/7457",
1009 .cpu_features = CPU_FTRS_7447,
1010 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
1011 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
1015 .pmc_type = PPC_PMC_G4,
1016 .cpu_setup = __setup_cpu_745x,
1017 .oprofile_cpu_type = "ppc/7450",
1018 .oprofile_type = PPC_OPROFILE_G4,
1019 .machine_check = machine_check_generic,
1020 .platform = "ppc7450",
1023 .pvr_mask = 0xffff0000,
1024 .pvr_value = 0x80030000,
1025 .cpu_name = "7447A",
1026 .cpu_features = CPU_FTRS_7447A,
1027 .cpu_user_features = COMMON_USER |
1028 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
1029 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
1033 .pmc_type = PPC_PMC_G4,
1034 .cpu_setup = __setup_cpu_745x,
1035 .oprofile_cpu_type = "ppc/7450",
1036 .oprofile_type = PPC_OPROFILE_G4,
1037 .machine_check = machine_check_generic,
1038 .platform = "ppc7450",
1041 .pvr_mask = 0xffff0000,
1042 .pvr_value = 0x80040000,
1044 .cpu_features = CPU_FTRS_7448,
1045 .cpu_user_features = COMMON_USER |
1046 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
1047 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
1051 .pmc_type = PPC_PMC_G4,
1052 .cpu_setup = __setup_cpu_745x,
1053 .oprofile_cpu_type = "ppc/7450",
1054 .oprofile_type = PPC_OPROFILE_G4,
1055 .machine_check = machine_check_generic,
1056 .platform = "ppc7450",
1058 { /* 82xx (8240, 8245, 8260 are all 603e cores) */
1059 .pvr_mask = 0x7fff0000,
1060 .pvr_value = 0x00810000,
1062 .cpu_features = CPU_FTRS_82XX,
1063 .cpu_user_features = COMMON_USER,
1067 .cpu_setup = __setup_cpu_603,
1068 .machine_check = machine_check_generic,
1069 .platform = "ppc603",
1071 { /* All G2_LE (603e core, plus some) have the same pvr */
1072 .pvr_mask = 0x7fff0000,
1073 .pvr_value = 0x00820000,
1074 .cpu_name = "G2_LE",
1075 .cpu_features = CPU_FTRS_G2_LE,
1076 .cpu_user_features = COMMON_USER,
1077 .mmu_features = MMU_FTR_USE_HIGH_BATS,
1080 .cpu_setup = __setup_cpu_603,
1081 .machine_check = machine_check_generic,
1082 .platform = "ppc603",
1084 { /* e300c1 (a 603e core, plus some) on 83xx */
1085 .pvr_mask = 0x7fff0000,
1086 .pvr_value = 0x00830000,
1087 .cpu_name = "e300c1",
1088 .cpu_features = CPU_FTRS_E300,
1089 .cpu_user_features = COMMON_USER,
1090 .mmu_features = MMU_FTR_USE_HIGH_BATS,
1093 .cpu_setup = __setup_cpu_603,
1094 .machine_check = machine_check_generic,
1095 .platform = "ppc603",
1097 { /* e300c2 (an e300c1 core, plus some, minus FPU) on 83xx */
1098 .pvr_mask = 0x7fff0000,
1099 .pvr_value = 0x00840000,
1100 .cpu_name = "e300c2",
1101 .cpu_features = CPU_FTRS_E300C2,
1102 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
1103 .mmu_features = MMU_FTR_USE_HIGH_BATS |
1104 MMU_FTR_NEED_DTLB_SW_LRU,
1107 .cpu_setup = __setup_cpu_603,
1108 .machine_check = machine_check_generic,
1109 .platform = "ppc603",
1111 { /* e300c3 (e300c1, plus one IU, half cache size) on 83xx */
1112 .pvr_mask = 0x7fff0000,
1113 .pvr_value = 0x00850000,
1114 .cpu_name = "e300c3",
1115 .cpu_features = CPU_FTRS_E300,
1116 .cpu_user_features = COMMON_USER,
1117 .mmu_features = MMU_FTR_USE_HIGH_BATS |
1118 MMU_FTR_NEED_DTLB_SW_LRU,
1121 .cpu_setup = __setup_cpu_603,
1123 .oprofile_cpu_type = "ppc/e300",
1124 .oprofile_type = PPC_OPROFILE_FSL_EMB,
1125 .platform = "ppc603",
1127 { /* e300c4 (e300c1, plus one IU) */
1128 .pvr_mask = 0x7fff0000,
1129 .pvr_value = 0x00860000,
1130 .cpu_name = "e300c4",
1131 .cpu_features = CPU_FTRS_E300,
1132 .cpu_user_features = COMMON_USER,
1133 .mmu_features = MMU_FTR_USE_HIGH_BATS |
1134 MMU_FTR_NEED_DTLB_SW_LRU,
1137 .cpu_setup = __setup_cpu_603,
1138 .machine_check = machine_check_generic,
1140 .oprofile_cpu_type = "ppc/e300",
1141 .oprofile_type = PPC_OPROFILE_FSL_EMB,
1142 .platform = "ppc603",
1144 { /* default match, we assume split I/D cache & TB (non-601)... */
1145 .pvr_mask = 0x00000000,
1146 .pvr_value = 0x00000000,
1147 .cpu_name = "(generic PPC)",
1148 .cpu_features = CPU_FTRS_CLASSIC32,
1149 .cpu_user_features = COMMON_USER,
1150 .mmu_features = MMU_FTR_HPTE_TABLE,
1153 .machine_check = machine_check_generic,
1154 .platform = "ppc603",
1156 #endif /* CLASSIC_PPC */
1159 .pvr_mask = 0xffff0000,
1160 .pvr_value = 0x00500000,
1162 /* CPU_FTR_MAYBE_CAN_DOZE is possible,
1163 * if the 8xx code is there.... */
1164 .cpu_features = CPU_FTRS_8XX,
1165 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
1166 .mmu_features = MMU_FTR_TYPE_8xx,
1169 .platform = "ppc823",
1171 #endif /* CONFIG_8xx */
1174 .pvr_mask = 0xffffff00,
1175 .pvr_value = 0x00200200,
1176 .cpu_name = "403GC",
1177 .cpu_features = CPU_FTRS_40X,
1178 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
1179 .mmu_features = MMU_FTR_TYPE_40x,
1182 .machine_check = machine_check_4xx,
1183 .platform = "ppc403",
1186 .pvr_mask = 0xffffff00,
1187 .pvr_value = 0x00201400,
1188 .cpu_name = "403GCX",
1189 .cpu_features = CPU_FTRS_40X,
1190 .cpu_user_features = PPC_FEATURE_32 |
1191 PPC_FEATURE_HAS_MMU | PPC_FEATURE_NO_TB,
1192 .mmu_features = MMU_FTR_TYPE_40x,
1195 .machine_check = machine_check_4xx,
1196 .platform = "ppc403",
1199 .pvr_mask = 0xffff0000,
1200 .pvr_value = 0x00200000,
1201 .cpu_name = "403G ??",
1202 .cpu_features = CPU_FTRS_40X,
1203 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
1204 .mmu_features = MMU_FTR_TYPE_40x,
1207 .machine_check = machine_check_4xx,
1208 .platform = "ppc403",
1211 .pvr_mask = 0xffff0000,
1212 .pvr_value = 0x40110000,
1213 .cpu_name = "405GP",
1214 .cpu_features = CPU_FTRS_40X,
1215 .cpu_user_features = PPC_FEATURE_32 |
1216 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1217 .mmu_features = MMU_FTR_TYPE_40x,
1220 .machine_check = machine_check_4xx,
1221 .platform = "ppc405",
1224 .pvr_mask = 0xffff0000,
1225 .pvr_value = 0x40130000,
1226 .cpu_name = "STB03xxx",
1227 .cpu_features = CPU_FTRS_40X,
1228 .cpu_user_features = PPC_FEATURE_32 |
1229 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1230 .mmu_features = MMU_FTR_TYPE_40x,
1233 .machine_check = machine_check_4xx,
1234 .platform = "ppc405",
1237 .pvr_mask = 0xffff0000,
1238 .pvr_value = 0x41810000,
1239 .cpu_name = "STB04xxx",
1240 .cpu_features = CPU_FTRS_40X,
1241 .cpu_user_features = PPC_FEATURE_32 |
1242 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1243 .mmu_features = MMU_FTR_TYPE_40x,
1246 .machine_check = machine_check_4xx,
1247 .platform = "ppc405",
1250 .pvr_mask = 0xffff0000,
1251 .pvr_value = 0x41610000,
1252 .cpu_name = "NP405L",
1253 .cpu_features = CPU_FTRS_40X,
1254 .cpu_user_features = PPC_FEATURE_32 |
1255 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1256 .mmu_features = MMU_FTR_TYPE_40x,
1259 .machine_check = machine_check_4xx,
1260 .platform = "ppc405",
1263 .pvr_mask = 0xffff0000,
1264 .pvr_value = 0x40B10000,
1265 .cpu_name = "NP4GS3",
1266 .cpu_features = CPU_FTRS_40X,
1267 .cpu_user_features = PPC_FEATURE_32 |
1268 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1269 .mmu_features = MMU_FTR_TYPE_40x,
1272 .machine_check = machine_check_4xx,
1273 .platform = "ppc405",
1276 .pvr_mask = 0xffff0000,
1277 .pvr_value = 0x41410000,
1278 .cpu_name = "NP405H",
1279 .cpu_features = CPU_FTRS_40X,
1280 .cpu_user_features = PPC_FEATURE_32 |
1281 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1282 .mmu_features = MMU_FTR_TYPE_40x,
1285 .machine_check = machine_check_4xx,
1286 .platform = "ppc405",
1289 .pvr_mask = 0xffff0000,
1290 .pvr_value = 0x50910000,
1291 .cpu_name = "405GPr",
1292 .cpu_features = CPU_FTRS_40X,
1293 .cpu_user_features = PPC_FEATURE_32 |
1294 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1295 .mmu_features = MMU_FTR_TYPE_40x,
1298 .machine_check = machine_check_4xx,
1299 .platform = "ppc405",
1302 .pvr_mask = 0xffff0000,
1303 .pvr_value = 0x51510000,
1304 .cpu_name = "STBx25xx",
1305 .cpu_features = CPU_FTRS_40X,
1306 .cpu_user_features = PPC_FEATURE_32 |
1307 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1308 .mmu_features = MMU_FTR_TYPE_40x,
1311 .machine_check = machine_check_4xx,
1312 .platform = "ppc405",
1315 .pvr_mask = 0xffff0000,
1316 .pvr_value = 0x41F10000,
1317 .cpu_name = "405LP",
1318 .cpu_features = CPU_FTRS_40X,
1319 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
1320 .mmu_features = MMU_FTR_TYPE_40x,
1323 .machine_check = machine_check_4xx,
1324 .platform = "ppc405",
1326 { /* Xilinx Virtex-II Pro */
1327 .pvr_mask = 0xfffff000,
1328 .pvr_value = 0x20010000,
1329 .cpu_name = "Virtex-II Pro",
1330 .cpu_features = CPU_FTRS_40X,
1331 .cpu_user_features = PPC_FEATURE_32 |
1332 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1333 .mmu_features = MMU_FTR_TYPE_40x,
1336 .machine_check = machine_check_4xx,
1337 .platform = "ppc405",
1339 { /* Xilinx Virtex-4 FX */
1340 .pvr_mask = 0xfffff000,
1341 .pvr_value = 0x20011000,
1342 .cpu_name = "Virtex-4 FX",
1343 .cpu_features = CPU_FTRS_40X,
1344 .cpu_user_features = PPC_FEATURE_32 |
1345 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1346 .mmu_features = MMU_FTR_TYPE_40x,
1349 .machine_check = machine_check_4xx,
1350 .platform = "ppc405",
1353 .pvr_mask = 0xffff0000,
1354 .pvr_value = 0x51210000,
1355 .cpu_name = "405EP",
1356 .cpu_features = CPU_FTRS_40X,
1357 .cpu_user_features = PPC_FEATURE_32 |
1358 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1359 .mmu_features = MMU_FTR_TYPE_40x,
1362 .machine_check = machine_check_4xx,
1363 .platform = "ppc405",
1365 { /* 405EX Rev. A/B with Security */
1366 .pvr_mask = 0xffff000f,
1367 .pvr_value = 0x12910007,
1368 .cpu_name = "405EX Rev. A/B",
1369 .cpu_features = CPU_FTRS_40X,
1370 .cpu_user_features = PPC_FEATURE_32 |
1371 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1372 .mmu_features = MMU_FTR_TYPE_40x,
1375 .machine_check = machine_check_4xx,
1376 .platform = "ppc405",
1378 { /* 405EX Rev. C without Security */
1379 .pvr_mask = 0xffff000f,
1380 .pvr_value = 0x1291000d,
1381 .cpu_name = "405EX Rev. C",
1382 .cpu_features = CPU_FTRS_40X,
1383 .cpu_user_features = PPC_FEATURE_32 |
1384 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1385 .mmu_features = MMU_FTR_TYPE_40x,
1388 .machine_check = machine_check_4xx,
1389 .platform = "ppc405",
1391 { /* 405EX Rev. C with Security */
1392 .pvr_mask = 0xffff000f,
1393 .pvr_value = 0x1291000f,
1394 .cpu_name = "405EX Rev. C",
1395 .cpu_features = CPU_FTRS_40X,
1396 .cpu_user_features = PPC_FEATURE_32 |
1397 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1398 .mmu_features = MMU_FTR_TYPE_40x,
1401 .machine_check = machine_check_4xx,
1402 .platform = "ppc405",
1404 { /* 405EX Rev. D without Security */
1405 .pvr_mask = 0xffff000f,
1406 .pvr_value = 0x12910003,
1407 .cpu_name = "405EX Rev. D",
1408 .cpu_features = CPU_FTRS_40X,
1409 .cpu_user_features = PPC_FEATURE_32 |
1410 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1411 .mmu_features = MMU_FTR_TYPE_40x,
1414 .machine_check = machine_check_4xx,
1415 .platform = "ppc405",
1417 { /* 405EX Rev. D with Security */
1418 .pvr_mask = 0xffff000f,
1419 .pvr_value = 0x12910005,
1420 .cpu_name = "405EX Rev. D",
1421 .cpu_features = CPU_FTRS_40X,
1422 .cpu_user_features = PPC_FEATURE_32 |
1423 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1424 .mmu_features = MMU_FTR_TYPE_40x,
1427 .machine_check = machine_check_4xx,
1428 .platform = "ppc405",
1430 { /* 405EXr Rev. A/B without Security */
1431 .pvr_mask = 0xffff000f,
1432 .pvr_value = 0x12910001,
1433 .cpu_name = "405EXr Rev. A/B",
1434 .cpu_features = CPU_FTRS_40X,
1435 .cpu_user_features = PPC_FEATURE_32 |
1436 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1437 .mmu_features = MMU_FTR_TYPE_40x,
1440 .machine_check = machine_check_4xx,
1441 .platform = "ppc405",
1443 { /* 405EXr Rev. C without Security */
1444 .pvr_mask = 0xffff000f,
1445 .pvr_value = 0x12910009,
1446 .cpu_name = "405EXr Rev. C",
1447 .cpu_features = CPU_FTRS_40X,
1448 .cpu_user_features = PPC_FEATURE_32 |
1449 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1450 .mmu_features = MMU_FTR_TYPE_40x,
1453 .machine_check = machine_check_4xx,
1454 .platform = "ppc405",
1456 { /* 405EXr Rev. C with Security */
1457 .pvr_mask = 0xffff000f,
1458 .pvr_value = 0x1291000b,
1459 .cpu_name = "405EXr Rev. C",
1460 .cpu_features = CPU_FTRS_40X,
1461 .cpu_user_features = PPC_FEATURE_32 |
1462 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1463 .mmu_features = MMU_FTR_TYPE_40x,
1466 .machine_check = machine_check_4xx,
1467 .platform = "ppc405",
1469 { /* 405EXr Rev. D without Security */
1470 .pvr_mask = 0xffff000f,
1471 .pvr_value = 0x12910000,
1472 .cpu_name = "405EXr Rev. D",
1473 .cpu_features = CPU_FTRS_40X,
1474 .cpu_user_features = PPC_FEATURE_32 |
1475 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1476 .mmu_features = MMU_FTR_TYPE_40x,
1479 .machine_check = machine_check_4xx,
1480 .platform = "ppc405",
1482 { /* 405EXr Rev. D with Security */
1483 .pvr_mask = 0xffff000f,
1484 .pvr_value = 0x12910002,
1485 .cpu_name = "405EXr Rev. D",
1486 .cpu_features = CPU_FTRS_40X,
1487 .cpu_user_features = PPC_FEATURE_32 |
1488 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1489 .mmu_features = MMU_FTR_TYPE_40x,
1492 .machine_check = machine_check_4xx,
1493 .platform = "ppc405",
1497 .pvr_mask = 0xffff0000,
1498 .pvr_value = 0x41510000,
1499 .cpu_name = "405EZ",
1500 .cpu_features = CPU_FTRS_40X,
1501 .cpu_user_features = PPC_FEATURE_32 |
1502 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1503 .mmu_features = MMU_FTR_TYPE_40x,
1506 .machine_check = machine_check_4xx,
1507 .platform = "ppc405",
1509 { /* default match */
1510 .pvr_mask = 0x00000000,
1511 .pvr_value = 0x00000000,
1512 .cpu_name = "(generic 40x PPC)",
1513 .cpu_features = CPU_FTRS_40X,
1514 .cpu_user_features = PPC_FEATURE_32 |
1515 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1516 .mmu_features = MMU_FTR_TYPE_40x,
1519 .machine_check = machine_check_4xx,
1520 .platform = "ppc405",
1523 #endif /* CONFIG_40x */
1526 .pvr_mask = 0xf0000fff,
1527 .pvr_value = 0x40000850,
1528 .cpu_name = "440GR Rev. A",
1529 .cpu_features = CPU_FTRS_44X,
1530 .cpu_user_features = COMMON_USER_BOOKE,
1531 .mmu_features = MMU_FTR_TYPE_44x,
1534 .machine_check = machine_check_4xx,
1535 .platform = "ppc440",
1537 { /* Use logical PVR for 440EP (logical pvr = pvr | 0x8) */
1538 .pvr_mask = 0xf0000fff,
1539 .pvr_value = 0x40000858,
1540 .cpu_name = "440EP Rev. A",
1541 .cpu_features = CPU_FTRS_44X,
1542 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
1543 .mmu_features = MMU_FTR_TYPE_44x,
1546 .cpu_setup = __setup_cpu_440ep,
1547 .machine_check = machine_check_4xx,
1548 .platform = "ppc440",
1551 .pvr_mask = 0xf0000fff,
1552 .pvr_value = 0x400008d3,
1553 .cpu_name = "440GR Rev. B",
1554 .cpu_features = CPU_FTRS_44X,
1555 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
1556 .mmu_features = MMU_FTR_TYPE_44x,
1559 .machine_check = machine_check_4xx,
1560 .platform = "ppc440",
1562 { /* Matches both physical and logical PVR for 440EP (logical pvr = pvr | 0x8) */
1563 .pvr_mask = 0xf0000ff7,
1564 .pvr_value = 0x400008d4,
1565 .cpu_name = "440EP Rev. C",
1566 .cpu_features = CPU_FTRS_44X,
1567 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
1568 .mmu_features = MMU_FTR_TYPE_44x,
1571 .cpu_setup = __setup_cpu_440ep,
1572 .machine_check = machine_check_4xx,
1573 .platform = "ppc440",
1575 { /* Use logical PVR for 440EP (logical pvr = pvr | 0x8) */
1576 .pvr_mask = 0xf0000fff,
1577 .pvr_value = 0x400008db,
1578 .cpu_name = "440EP Rev. B",
1579 .cpu_features = CPU_FTRS_44X,
1580 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
1581 .mmu_features = MMU_FTR_TYPE_44x,
1584 .cpu_setup = __setup_cpu_440ep,
1585 .machine_check = machine_check_4xx,
1586 .platform = "ppc440",
1589 .pvr_mask = 0xf0000ffb,
1590 .pvr_value = 0x200008D0,
1591 .cpu_name = "440GRX",
1592 .cpu_features = CPU_FTRS_44X,
1593 .cpu_user_features = COMMON_USER_BOOKE,
1594 .mmu_features = MMU_FTR_TYPE_44x,
1597 .cpu_setup = __setup_cpu_440grx,
1598 .machine_check = machine_check_440A,
1599 .platform = "ppc440",
1601 { /* Use logical PVR for 440EPx (logical pvr = pvr | 0x8) */
1602 .pvr_mask = 0xf0000ffb,
1603 .pvr_value = 0x200008D8,
1604 .cpu_name = "440EPX",
1605 .cpu_features = CPU_FTRS_44X,
1606 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
1607 .mmu_features = MMU_FTR_TYPE_44x,
1610 .cpu_setup = __setup_cpu_440epx,
1611 .machine_check = machine_check_440A,
1612 .platform = "ppc440",
1614 { /* 440GP Rev. B */
1615 .pvr_mask = 0xf0000fff,
1616 .pvr_value = 0x40000440,
1617 .cpu_name = "440GP Rev. B",
1618 .cpu_features = CPU_FTRS_44X,
1619 .cpu_user_features = COMMON_USER_BOOKE,
1620 .mmu_features = MMU_FTR_TYPE_44x,
1623 .machine_check = machine_check_4xx,
1624 .platform = "ppc440gp",
1626 { /* 440GP Rev. C */
1627 .pvr_mask = 0xf0000fff,
1628 .pvr_value = 0x40000481,
1629 .cpu_name = "440GP Rev. C",
1630 .cpu_features = CPU_FTRS_44X,
1631 .cpu_user_features = COMMON_USER_BOOKE,
1632 .mmu_features = MMU_FTR_TYPE_44x,
1635 .machine_check = machine_check_4xx,
1636 .platform = "ppc440gp",
1638 { /* 440GX Rev. A */
1639 .pvr_mask = 0xf0000fff,
1640 .pvr_value = 0x50000850,
1641 .cpu_name = "440GX Rev. A",
1642 .cpu_features = CPU_FTRS_44X,
1643 .cpu_user_features = COMMON_USER_BOOKE,
1644 .mmu_features = MMU_FTR_TYPE_44x,
1647 .cpu_setup = __setup_cpu_440gx,
1648 .machine_check = machine_check_440A,
1649 .platform = "ppc440",
1651 { /* 440GX Rev. B */
1652 .pvr_mask = 0xf0000fff,
1653 .pvr_value = 0x50000851,
1654 .cpu_name = "440GX Rev. B",
1655 .cpu_features = CPU_FTRS_44X,
1656 .cpu_user_features = COMMON_USER_BOOKE,
1657 .mmu_features = MMU_FTR_TYPE_44x,
1660 .cpu_setup = __setup_cpu_440gx,
1661 .machine_check = machine_check_440A,
1662 .platform = "ppc440",
1664 { /* 440GX Rev. C */
1665 .pvr_mask = 0xf0000fff,
1666 .pvr_value = 0x50000892,
1667 .cpu_name = "440GX Rev. C",
1668 .cpu_features = CPU_FTRS_44X,
1669 .cpu_user_features = COMMON_USER_BOOKE,
1670 .mmu_features = MMU_FTR_TYPE_44x,
1673 .cpu_setup = __setup_cpu_440gx,
1674 .machine_check = machine_check_440A,
1675 .platform = "ppc440",
1677 { /* 440GX Rev. F */
1678 .pvr_mask = 0xf0000fff,
1679 .pvr_value = 0x50000894,
1680 .cpu_name = "440GX Rev. F",
1681 .cpu_features = CPU_FTRS_44X,
1682 .cpu_user_features = COMMON_USER_BOOKE,
1683 .mmu_features = MMU_FTR_TYPE_44x,
1686 .cpu_setup = __setup_cpu_440gx,
1687 .machine_check = machine_check_440A,
1688 .platform = "ppc440",
1690 { /* 440SP Rev. A */
1691 .pvr_mask = 0xfff00fff,
1692 .pvr_value = 0x53200891,
1693 .cpu_name = "440SP Rev. A",
1694 .cpu_features = CPU_FTRS_44X,
1695 .cpu_user_features = COMMON_USER_BOOKE,
1696 .mmu_features = MMU_FTR_TYPE_44x,
1699 .machine_check = machine_check_4xx,
1700 .platform = "ppc440",
1702 { /* 440SPe Rev. A */
1703 .pvr_mask = 0xfff00fff,
1704 .pvr_value = 0x53400890,
1705 .cpu_name = "440SPe Rev. A",
1706 .cpu_features = CPU_FTRS_44X,
1707 .cpu_user_features = COMMON_USER_BOOKE,
1708 .mmu_features = MMU_FTR_TYPE_44x,
1711 .cpu_setup = __setup_cpu_440spe,
1712 .machine_check = machine_check_440A,
1713 .platform = "ppc440",
1715 { /* 440SPe Rev. B */
1716 .pvr_mask = 0xfff00fff,
1717 .pvr_value = 0x53400891,
1718 .cpu_name = "440SPe Rev. B",
1719 .cpu_features = CPU_FTRS_44X,
1720 .cpu_user_features = COMMON_USER_BOOKE,
1721 .mmu_features = MMU_FTR_TYPE_44x,
1724 .cpu_setup = __setup_cpu_440spe,
1725 .machine_check = machine_check_440A,
1726 .platform = "ppc440",
1728 { /* 440 in Xilinx Virtex-5 FXT */
1729 .pvr_mask = 0xfffffff0,
1730 .pvr_value = 0x7ff21910,
1731 .cpu_name = "440 in Virtex-5 FXT",
1732 .cpu_features = CPU_FTRS_44X,
1733 .cpu_user_features = COMMON_USER_BOOKE,
1734 .mmu_features = MMU_FTR_TYPE_44x,
1737 .cpu_setup = __setup_cpu_440x5,
1738 .machine_check = machine_check_440A,
1739 .platform = "ppc440",
1742 .pvr_mask = 0xffff0006,
1743 .pvr_value = 0x13020002,
1744 .cpu_name = "460EX",
1745 .cpu_features = CPU_FTRS_440x6,
1746 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
1747 .mmu_features = MMU_FTR_TYPE_44x,
1750 .cpu_setup = __setup_cpu_460ex,
1751 .machine_check = machine_check_440A,
1752 .platform = "ppc440",
1755 .pvr_mask = 0xffff0007,
1756 .pvr_value = 0x13020004,
1757 .cpu_name = "460EX Rev. B",
1758 .cpu_features = CPU_FTRS_440x6,
1759 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
1760 .mmu_features = MMU_FTR_TYPE_44x,
1763 .cpu_setup = __setup_cpu_460ex,
1764 .machine_check = machine_check_440A,
1765 .platform = "ppc440",
1768 .pvr_mask = 0xffff0006,
1769 .pvr_value = 0x13020000,
1770 .cpu_name = "460GT",
1771 .cpu_features = CPU_FTRS_440x6,
1772 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
1773 .mmu_features = MMU_FTR_TYPE_44x,
1776 .cpu_setup = __setup_cpu_460gt,
1777 .machine_check = machine_check_440A,
1778 .platform = "ppc440",
1781 .pvr_mask = 0xffff0007,
1782 .pvr_value = 0x13020005,
1783 .cpu_name = "460GT Rev. B",
1784 .cpu_features = CPU_FTRS_440x6,
1785 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
1786 .mmu_features = MMU_FTR_TYPE_44x,
1789 .cpu_setup = __setup_cpu_460gt,
1790 .machine_check = machine_check_440A,
1791 .platform = "ppc440",
1794 .pvr_mask = 0xffffff00,
1795 .pvr_value = 0x13541800,
1796 .cpu_name = "460SX",
1797 .cpu_features = CPU_FTRS_44X,
1798 .cpu_user_features = COMMON_USER_BOOKE,
1799 .mmu_features = MMU_FTR_TYPE_44x,
1802 .cpu_setup = __setup_cpu_460sx,
1803 .machine_check = machine_check_440A,
1804 .platform = "ppc440",
1806 { /* 464 in APM821xx */
1807 .pvr_mask = 0xffffff00,
1808 .pvr_value = 0x12C41C80,
1809 .cpu_name = "APM821XX",
1810 .cpu_features = CPU_FTRS_44X,
1811 .cpu_user_features = COMMON_USER_BOOKE |
1812 PPC_FEATURE_HAS_FPU,
1813 .mmu_features = MMU_FTR_TYPE_44x,
1816 .cpu_setup = __setup_cpu_apm821xx,
1817 .machine_check = machine_check_440A,
1818 .platform = "ppc440",
1820 { /* 476 DD2 core */
1821 .pvr_mask = 0xffffffff,
1822 .pvr_value = 0x11a52080,
1824 .cpu_features = CPU_FTRS_47X | CPU_FTR_476_DD2,
1825 .cpu_user_features = COMMON_USER_BOOKE |
1826 PPC_FEATURE_HAS_FPU,
1827 .mmu_features = MMU_FTR_TYPE_47x |
1828 MMU_FTR_USE_TLBIVAX_BCAST | MMU_FTR_LOCK_BCAST_INVAL,
1830 .dcache_bsize = 128,
1831 .machine_check = machine_check_47x,
1832 .platform = "ppc470",
1835 .pvr_mask = 0xffff0000,
1836 .pvr_value = 0x00050000,
1838 .cpu_features = CPU_FTRS_47X,
1839 .cpu_user_features = COMMON_USER_BOOKE |
1840 PPC_FEATURE_HAS_FPU,
1841 .mmu_features = MMU_FTR_TYPE_47x |
1842 MMU_FTR_USE_TLBIVAX_BCAST | MMU_FTR_LOCK_BCAST_INVAL,
1844 .dcache_bsize = 128,
1845 .machine_check = machine_check_47x,
1846 .platform = "ppc470",
1849 .pvr_mask = 0xffff0000,
1850 .pvr_value = 0x11a50000,
1852 .cpu_features = CPU_FTRS_47X,
1853 .cpu_user_features = COMMON_USER_BOOKE |
1854 PPC_FEATURE_HAS_FPU,
1855 .mmu_features = MMU_FTR_TYPE_47x |
1856 MMU_FTR_USE_TLBIVAX_BCAST | MMU_FTR_LOCK_BCAST_INVAL,
1858 .dcache_bsize = 128,
1859 .machine_check = machine_check_47x,
1860 .platform = "ppc470",
1862 { /* default match */
1863 .pvr_mask = 0x00000000,
1864 .pvr_value = 0x00000000,
1865 .cpu_name = "(generic 44x PPC)",
1866 .cpu_features = CPU_FTRS_44X,
1867 .cpu_user_features = COMMON_USER_BOOKE,
1868 .mmu_features = MMU_FTR_TYPE_44x,
1871 .machine_check = machine_check_4xx,
1872 .platform = "ppc440",
1874 #endif /* CONFIG_44x */
1877 .pvr_mask = 0xfff00000,
1878 .pvr_value = 0x81000000,
1879 .cpu_name = "e200z5",
1880 /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */
1881 .cpu_features = CPU_FTRS_E200,
1882 .cpu_user_features = COMMON_USER_BOOKE |
1883 PPC_FEATURE_HAS_EFP_SINGLE |
1884 PPC_FEATURE_UNIFIED_CACHE,
1885 .mmu_features = MMU_FTR_TYPE_FSL_E,
1887 .machine_check = machine_check_e200,
1888 .platform = "ppc5554",
1891 .pvr_mask = 0xfff00000,
1892 .pvr_value = 0x81100000,
1893 .cpu_name = "e200z6",
1894 /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */
1895 .cpu_features = CPU_FTRS_E200,
1896 .cpu_user_features = COMMON_USER_BOOKE |
1897 PPC_FEATURE_HAS_SPE_COMP |
1898 PPC_FEATURE_HAS_EFP_SINGLE_COMP |
1899 PPC_FEATURE_UNIFIED_CACHE,
1900 .mmu_features = MMU_FTR_TYPE_FSL_E,
1902 .machine_check = machine_check_e200,
1903 .platform = "ppc5554",
1905 { /* default match */
1906 .pvr_mask = 0x00000000,
1907 .pvr_value = 0x00000000,
1908 .cpu_name = "(generic E200 PPC)",
1909 .cpu_features = CPU_FTRS_E200,
1910 .cpu_user_features = COMMON_USER_BOOKE |
1911 PPC_FEATURE_HAS_EFP_SINGLE |
1912 PPC_FEATURE_UNIFIED_CACHE,
1913 .mmu_features = MMU_FTR_TYPE_FSL_E,
1915 .cpu_setup = __setup_cpu_e200,
1916 .machine_check = machine_check_e200,
1917 .platform = "ppc5554",
1919 #endif /* CONFIG_E200 */
1920 #endif /* CONFIG_PPC32 */
1924 .pvr_mask = 0xffff0000,
1925 .pvr_value = 0x80200000,
1927 .cpu_features = CPU_FTRS_E500,
1928 .cpu_user_features = COMMON_USER_BOOKE |
1929 PPC_FEATURE_HAS_SPE_COMP |
1930 PPC_FEATURE_HAS_EFP_SINGLE_COMP,
1931 .mmu_features = MMU_FTR_TYPE_FSL_E,
1935 .oprofile_cpu_type = "ppc/e500",
1936 .oprofile_type = PPC_OPROFILE_FSL_EMB,
1937 .cpu_setup = __setup_cpu_e500v1,
1938 .machine_check = machine_check_e500,
1939 .platform = "ppc8540",
1942 .pvr_mask = 0xffff0000,
1943 .pvr_value = 0x80210000,
1944 .cpu_name = "e500v2",
1945 .cpu_features = CPU_FTRS_E500_2,
1946 .cpu_user_features = COMMON_USER_BOOKE |
1947 PPC_FEATURE_HAS_SPE_COMP |
1948 PPC_FEATURE_HAS_EFP_SINGLE_COMP |
1949 PPC_FEATURE_HAS_EFP_DOUBLE_COMP,
1950 .mmu_features = MMU_FTR_TYPE_FSL_E | MMU_FTR_BIG_PHYS,
1954 .oprofile_cpu_type = "ppc/e500",
1955 .oprofile_type = PPC_OPROFILE_FSL_EMB,
1956 .cpu_setup = __setup_cpu_e500v2,
1957 .machine_check = machine_check_e500,
1958 .platform = "ppc8548",
1961 .pvr_mask = 0xffff0000,
1962 .pvr_value = 0x80230000,
1963 .cpu_name = "e500mc",
1964 .cpu_features = CPU_FTRS_E500MC,
1965 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
1966 .mmu_features = MMU_FTR_TYPE_FSL_E | MMU_FTR_BIG_PHYS |
1971 .oprofile_cpu_type = "ppc/e500mc",
1972 .oprofile_type = PPC_OPROFILE_FSL_EMB,
1973 .cpu_setup = __setup_cpu_e500mc,
1974 .machine_check = machine_check_e500mc,
1975 .platform = "ppce500mc",
1977 #endif /* CONFIG_PPC32 */
1979 .pvr_mask = 0xffff0000,
1980 .pvr_value = 0x80240000,
1981 .cpu_name = "e5500",
1982 .cpu_features = CPU_FTRS_E5500,
1983 .cpu_user_features = COMMON_USER_BOOKE,
1984 .mmu_features = MMU_FTR_TYPE_FSL_E | MMU_FTR_BIG_PHYS |
1989 .oprofile_cpu_type = "ppc/e500mc",
1990 .oprofile_type = PPC_OPROFILE_FSL_EMB,
1991 .cpu_setup = __setup_cpu_e5500,
1992 .cpu_restore = __restore_cpu_e5500,
1993 .machine_check = machine_check_e500mc,
1994 .platform = "ppce5500",
1997 { /* default match */
1998 .pvr_mask = 0x00000000,
1999 .pvr_value = 0x00000000,
2000 .cpu_name = "(generic E500 PPC)",
2001 .cpu_features = CPU_FTRS_E500,
2002 .cpu_user_features = COMMON_USER_BOOKE |
2003 PPC_FEATURE_HAS_SPE_COMP |
2004 PPC_FEATURE_HAS_EFP_SINGLE_COMP,
2005 .mmu_features = MMU_FTR_TYPE_FSL_E,
2008 .machine_check = machine_check_e500,
2009 .platform = "powerpc",
2011 #endif /* CONFIG_PPC32 */
2012 #endif /* CONFIG_E500 */
2014 #ifdef CONFIG_PPC_BOOK3E_64
2015 { /* This is a default entry to get going, to be replaced by
2016 * a real one at some stage
2018 #define CPU_FTRS_BASE_BOOK3E (CPU_FTR_USE_TB | \
2019 CPU_FTR_PPCAS_ARCH_V2 | CPU_FTR_SMT | \
2020 CPU_FTR_NODSISRALIGN | CPU_FTR_NOEXECUTE)
2021 .pvr_mask = 0x00000000,
2022 .pvr_value = 0x00000000,
2023 .cpu_name = "Book3E",
2024 .cpu_features = CPU_FTRS_BASE_BOOK3E,
2025 .cpu_user_features = COMMON_USER_PPC64,
2026 .mmu_features = MMU_FTR_TYPE_3E | MMU_FTR_USE_TLBILX |
2027 MMU_FTR_USE_TLBIVAX_BCAST |
2028 MMU_FTR_LOCK_BCAST_INVAL,
2032 .machine_check = machine_check_generic,
2033 .platform = "power6",
2038 static struct cpu_spec the_cpu_spec;
2040 static void __init setup_cpu_spec(unsigned long offset, struct cpu_spec *s)
2042 struct cpu_spec *t = &the_cpu_spec;
2043 struct cpu_spec old;
2048 /* Copy everything, then do fixups */
2052 * If we are overriding a previous value derived from the real
2053 * PVR with a new value obtained using a logical PVR value,
2054 * don't modify the performance monitor fields.
2056 if (old.num_pmcs && !s->num_pmcs) {
2057 t->num_pmcs = old.num_pmcs;
2058 t->pmc_type = old.pmc_type;
2059 t->oprofile_type = old.oprofile_type;
2060 t->oprofile_mmcra_sihv = old.oprofile_mmcra_sihv;
2061 t->oprofile_mmcra_sipr = old.oprofile_mmcra_sipr;
2062 t->oprofile_mmcra_clear = old.oprofile_mmcra_clear;
2065 * If we have passed through this logic once before and
2066 * have pulled the default case because the real PVR was
2067 * not found inside cpu_specs[], then we are possibly
2068 * running in compatibility mode. In that case, let the
2069 * oprofiler know which set of compatibility counters to
2070 * pull from by making sure the oprofile_cpu_type string
2071 * is set to that of compatibility mode. If the
2072 * oprofile_cpu_type already has a value, then we are
2073 * possibly overriding a real PVR with a logical one,
2074 * and, in that case, keep the current value for
2075 * oprofile_cpu_type.
2077 if (old.oprofile_cpu_type != NULL) {
2078 t->oprofile_cpu_type = old.oprofile_cpu_type;
2079 t->oprofile_type = old.oprofile_type;
2083 *PTRRELOC(&cur_cpu_spec) = &the_cpu_spec;
2086 * Set the base platform string once; assumes
2087 * we're called with real pvr first.
2089 if (*PTRRELOC(&powerpc_base_platform) == NULL)
2090 *PTRRELOC(&powerpc_base_platform) = t->platform;
2092 #if defined(CONFIG_PPC64) || defined(CONFIG_BOOKE)
2093 /* ppc64 and booke expect identify_cpu to also call setup_cpu for
2094 * that processor. I will consolidate that at a later time, for now,
2095 * just use #ifdef. We also don't need to PTRRELOC the function
2096 * pointer on ppc64 and booke as we are running at 0 in real mode
2097 * on ppc64 and reloc_offset is always 0 on booke.
2100 t->cpu_setup(offset, t);
2102 #endif /* CONFIG_PPC64 || CONFIG_BOOKE */
2105 struct cpu_spec * __init identify_cpu(unsigned long offset, unsigned int pvr)
2107 struct cpu_spec *s = cpu_specs;
2112 for (i = 0; i < ARRAY_SIZE(cpu_specs); i++,s++) {
2113 if ((pvr & s->pvr_mask) == s->pvr_value) {
2114 setup_cpu_spec(offset, s);