1 /* SPDX-License-Identifier: GPL-2.0-or-later */
3 * Copyright (C) 2001 Ben. Herrenschmidt (benh@kernel.crashing.org)
6 #define COMMON_USER (PPC_FEATURE_32 | PPC_FEATURE_HAS_FPU | \
9 static struct cpu_spec cpu_specs
[] __initdata
= {
10 #ifdef CONFIG_PPC_BOOK3S_603
12 .pvr_mask
= 0xffff0000,
13 .pvr_value
= 0x00030000,
15 .cpu_features
= CPU_FTRS_603
,
16 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
20 .cpu_setup
= __setup_cpu_603
,
21 .machine_check
= machine_check_generic
,
25 .pvr_mask
= 0xffff0000,
26 .pvr_value
= 0x00060000,
28 .cpu_features
= CPU_FTRS_603
,
29 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
33 .cpu_setup
= __setup_cpu_603
,
34 .machine_check
= machine_check_generic
,
38 .pvr_mask
= 0xffff0000,
39 .pvr_value
= 0x00070000,
41 .cpu_features
= CPU_FTRS_603
,
42 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
46 .cpu_setup
= __setup_cpu_603
,
47 .machine_check
= machine_check_generic
,
50 { /* 82xx (8240, 8245, 8260 are all 603e cores) */
51 .pvr_mask
= 0x7fff0000,
52 .pvr_value
= 0x00810000,
54 .cpu_features
= CPU_FTRS_82XX
,
55 .cpu_user_features
= COMMON_USER
,
59 .cpu_setup
= __setup_cpu_603
,
60 .machine_check
= machine_check_generic
,
63 { /* All G2_LE (603e core, plus some) have the same pvr */
64 .pvr_mask
= 0x7fff0000,
65 .pvr_value
= 0x00820000,
67 .cpu_features
= CPU_FTRS_G2_LE
,
68 .cpu_user_features
= COMMON_USER
,
69 .mmu_features
= MMU_FTR_USE_HIGH_BATS
,
72 .cpu_setup
= __setup_cpu_603
,
73 .machine_check
= machine_check_generic
,
76 #ifdef CONFIG_PPC_83xx
77 { /* e300c1 (a 603e core, plus some) on 83xx */
78 .pvr_mask
= 0x7fff0000,
79 .pvr_value
= 0x00830000,
81 .cpu_features
= CPU_FTRS_E300
,
82 .cpu_user_features
= COMMON_USER
,
83 .mmu_features
= MMU_FTR_USE_HIGH_BATS
,
86 .cpu_setup
= __setup_cpu_603
,
87 .machine_check
= machine_check_83xx
,
90 { /* e300c2 (an e300c1 core, plus some, minus FPU) on 83xx */
91 .pvr_mask
= 0x7fff0000,
92 .pvr_value
= 0x00840000,
94 .cpu_features
= CPU_FTRS_E300C2
,
95 .cpu_user_features
= PPC_FEATURE_32
| PPC_FEATURE_HAS_MMU
,
96 .mmu_features
= MMU_FTR_USE_HIGH_BATS
| MMU_FTR_NEED_DTLB_SW_LRU
,
99 .cpu_setup
= __setup_cpu_603
,
100 .machine_check
= machine_check_83xx
,
101 .platform
= "ppc603",
103 { /* e300c3 (e300c1, plus one IU, half cache size) on 83xx */
104 .pvr_mask
= 0x7fff0000,
105 .pvr_value
= 0x00850000,
106 .cpu_name
= "e300c3",
107 .cpu_features
= CPU_FTRS_E300
,
108 .cpu_user_features
= COMMON_USER
,
109 .mmu_features
= MMU_FTR_USE_HIGH_BATS
| MMU_FTR_NEED_DTLB_SW_LRU
,
112 .cpu_setup
= __setup_cpu_603
,
113 .machine_check
= machine_check_83xx
,
115 .platform
= "ppc603",
117 { /* e300c4 (e300c1, plus one IU) */
118 .pvr_mask
= 0x7fff0000,
119 .pvr_value
= 0x00860000,
120 .cpu_name
= "e300c4",
121 .cpu_features
= CPU_FTRS_E300
,
122 .cpu_user_features
= COMMON_USER
,
123 .mmu_features
= MMU_FTR_USE_HIGH_BATS
| MMU_FTR_NEED_DTLB_SW_LRU
,
126 .cpu_setup
= __setup_cpu_603
,
127 .machine_check
= machine_check_83xx
,
129 .platform
= "ppc603",
132 #endif /* CONFIG_PPC_BOOK3S_603 */
133 #ifdef CONFIG_PPC_BOOK3S_604
135 .pvr_mask
= 0xffff0000,
136 .pvr_value
= 0x00040000,
138 .cpu_features
= CPU_FTRS_604
,
139 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
140 .mmu_features
= MMU_FTR_HPTE_TABLE
,
144 .cpu_setup
= __setup_cpu_604
,
145 .machine_check
= machine_check_generic
,
146 .platform
= "ppc604",
149 .pvr_mask
= 0xfffff000,
150 .pvr_value
= 0x00090000,
152 .cpu_features
= CPU_FTRS_604
,
153 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
154 .mmu_features
= MMU_FTR_HPTE_TABLE
,
158 .cpu_setup
= __setup_cpu_604
,
159 .machine_check
= machine_check_generic
,
160 .platform
= "ppc604",
163 .pvr_mask
= 0xffff0000,
164 .pvr_value
= 0x00090000,
166 .cpu_features
= CPU_FTRS_604
,
167 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
168 .mmu_features
= MMU_FTR_HPTE_TABLE
,
172 .cpu_setup
= __setup_cpu_604
,
173 .machine_check
= machine_check_generic
,
174 .platform
= "ppc604",
177 .pvr_mask
= 0xffff0000,
178 .pvr_value
= 0x000a0000,
180 .cpu_features
= CPU_FTRS_604
,
181 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
182 .mmu_features
= MMU_FTR_HPTE_TABLE
,
186 .cpu_setup
= __setup_cpu_604
,
187 .machine_check
= machine_check_generic
,
188 .platform
= "ppc604",
190 { /* 740/750 (0x4202, don't support TAU ?) */
191 .pvr_mask
= 0xffffffff,
192 .pvr_value
= 0x00084202,
193 .cpu_name
= "740/750",
194 .cpu_features
= CPU_FTRS_740_NOTAU
,
195 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
196 .mmu_features
= MMU_FTR_HPTE_TABLE
,
200 .cpu_setup
= __setup_cpu_750
,
201 .machine_check
= machine_check_generic
,
202 .platform
= "ppc750",
204 { /* 750CX (80100 and 8010x?) */
205 .pvr_mask
= 0xfffffff0,
206 .pvr_value
= 0x00080100,
208 .cpu_features
= CPU_FTRS_750
,
209 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
210 .mmu_features
= MMU_FTR_HPTE_TABLE
,
214 .cpu_setup
= __setup_cpu_750cx
,
215 .machine_check
= machine_check_generic
,
216 .platform
= "ppc750",
218 { /* 750CX (82201 and 82202) */
219 .pvr_mask
= 0xfffffff0,
220 .pvr_value
= 0x00082200,
222 .cpu_features
= CPU_FTRS_750
,
223 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
224 .mmu_features
= MMU_FTR_HPTE_TABLE
,
228 .pmc_type
= PPC_PMC_IBM
,
229 .cpu_setup
= __setup_cpu_750cx
,
230 .machine_check
= machine_check_generic
,
231 .platform
= "ppc750",
233 { /* 750CXe (82214) */
234 .pvr_mask
= 0xfffffff0,
235 .pvr_value
= 0x00082210,
236 .cpu_name
= "750CXe",
237 .cpu_features
= CPU_FTRS_750
,
238 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
239 .mmu_features
= MMU_FTR_HPTE_TABLE
,
243 .pmc_type
= PPC_PMC_IBM
,
244 .cpu_setup
= __setup_cpu_750cx
,
245 .machine_check
= machine_check_generic
,
246 .platform
= "ppc750",
248 { /* 750CXe "Gekko" (83214) */
249 .pvr_mask
= 0xffffffff,
250 .pvr_value
= 0x00083214,
251 .cpu_name
= "750CXe",
252 .cpu_features
= CPU_FTRS_750
,
253 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
254 .mmu_features
= MMU_FTR_HPTE_TABLE
,
258 .pmc_type
= PPC_PMC_IBM
,
259 .cpu_setup
= __setup_cpu_750cx
,
260 .machine_check
= machine_check_generic
,
261 .platform
= "ppc750",
263 { /* 750CL (and "Broadway") */
264 .pvr_mask
= 0xfffff0e0,
265 .pvr_value
= 0x00087000,
267 .cpu_features
= CPU_FTRS_750CL
,
268 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
269 .mmu_features
= MMU_FTR_HPTE_TABLE
| MMU_FTR_USE_HIGH_BATS
,
273 .pmc_type
= PPC_PMC_IBM
,
274 .cpu_setup
= __setup_cpu_750
,
275 .machine_check
= machine_check_generic
,
276 .platform
= "ppc750",
279 .pvr_mask
= 0xfffff000,
280 .pvr_value
= 0x00083000,
281 .cpu_name
= "745/755",
282 .cpu_features
= CPU_FTRS_750
,
283 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
284 .mmu_features
= MMU_FTR_HPTE_TABLE
,
288 .pmc_type
= PPC_PMC_IBM
,
289 .cpu_setup
= __setup_cpu_750
,
290 .machine_check
= machine_check_generic
,
291 .platform
= "ppc750",
293 { /* 750FX rev 1.x */
294 .pvr_mask
= 0xffffff00,
295 .pvr_value
= 0x70000100,
297 .cpu_features
= CPU_FTRS_750FX1
,
298 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
299 .mmu_features
= MMU_FTR_HPTE_TABLE
,
303 .pmc_type
= PPC_PMC_IBM
,
304 .cpu_setup
= __setup_cpu_750
,
305 .machine_check
= machine_check_generic
,
306 .platform
= "ppc750",
308 { /* 750FX rev 2.0 must disable HID0[DPM] */
309 .pvr_mask
= 0xffffffff,
310 .pvr_value
= 0x70000200,
312 .cpu_features
= CPU_FTRS_750FX2
,
313 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
314 .mmu_features
= MMU_FTR_HPTE_TABLE
,
318 .pmc_type
= PPC_PMC_IBM
,
319 .cpu_setup
= __setup_cpu_750
,
320 .machine_check
= machine_check_generic
,
321 .platform
= "ppc750",
323 { /* 750FX (All revs except 2.0) */
324 .pvr_mask
= 0xffff0000,
325 .pvr_value
= 0x70000000,
327 .cpu_features
= CPU_FTRS_750FX
,
328 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
329 .mmu_features
= MMU_FTR_HPTE_TABLE
| MMU_FTR_USE_HIGH_BATS
,
333 .pmc_type
= PPC_PMC_IBM
,
334 .cpu_setup
= __setup_cpu_750fx
,
335 .machine_check
= machine_check_generic
,
336 .platform
= "ppc750",
339 .pvr_mask
= 0xffff0000,
340 .pvr_value
= 0x70020000,
342 .cpu_features
= CPU_FTRS_750GX
,
343 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
344 .mmu_features
= MMU_FTR_HPTE_TABLE
| MMU_FTR_USE_HIGH_BATS
,
348 .pmc_type
= PPC_PMC_IBM
,
349 .cpu_setup
= __setup_cpu_750fx
,
350 .machine_check
= machine_check_generic
,
351 .platform
= "ppc750",
353 { /* 740/750 (L2CR bit need fixup for 740) */
354 .pvr_mask
= 0xffff0000,
355 .pvr_value
= 0x00080000,
356 .cpu_name
= "740/750",
357 .cpu_features
= CPU_FTRS_740
,
358 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_PPC_LE
,
359 .mmu_features
= MMU_FTR_HPTE_TABLE
,
363 .pmc_type
= PPC_PMC_IBM
,
364 .cpu_setup
= __setup_cpu_750
,
365 .machine_check
= machine_check_generic
,
366 .platform
= "ppc750",
368 { /* 7400 rev 1.1 ? (no TAU) */
369 .pvr_mask
= 0xffffffff,
370 .pvr_value
= 0x000c1101,
371 .cpu_name
= "7400 (1.1)",
372 .cpu_features
= CPU_FTRS_7400_NOTAU
,
373 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
375 .mmu_features
= MMU_FTR_HPTE_TABLE
,
379 .pmc_type
= PPC_PMC_G4
,
380 .cpu_setup
= __setup_cpu_7400
,
381 .machine_check
= machine_check_generic
,
382 .platform
= "ppc7400",
385 .pvr_mask
= 0xffff0000,
386 .pvr_value
= 0x000c0000,
388 .cpu_features
= CPU_FTRS_7400
,
389 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
391 .mmu_features
= MMU_FTR_HPTE_TABLE
,
395 .pmc_type
= PPC_PMC_G4
,
396 .cpu_setup
= __setup_cpu_7400
,
397 .machine_check
= machine_check_generic
,
398 .platform
= "ppc7400",
401 .pvr_mask
= 0xffff0000,
402 .pvr_value
= 0x800c0000,
404 .cpu_features
= CPU_FTRS_7400
,
405 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
407 .mmu_features
= MMU_FTR_HPTE_TABLE
,
411 .pmc_type
= PPC_PMC_G4
,
412 .cpu_setup
= __setup_cpu_7410
,
413 .machine_check
= machine_check_generic
,
414 .platform
= "ppc7400",
416 { /* 7450 2.0 - no doze/nap */
417 .pvr_mask
= 0xffffffff,
418 .pvr_value
= 0x80000200,
420 .cpu_features
= CPU_FTRS_7450_20
,
421 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
423 .mmu_features
= MMU_FTR_HPTE_TABLE
,
427 .pmc_type
= PPC_PMC_G4
,
428 .cpu_setup
= __setup_cpu_745x
,
429 .machine_check
= machine_check_generic
,
430 .platform
= "ppc7450",
433 .pvr_mask
= 0xffffffff,
434 .pvr_value
= 0x80000201,
436 .cpu_features
= CPU_FTRS_7450_21
,
437 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
439 .mmu_features
= MMU_FTR_HPTE_TABLE
,
443 .pmc_type
= PPC_PMC_G4
,
444 .cpu_setup
= __setup_cpu_745x
,
445 .machine_check
= machine_check_generic
,
446 .platform
= "ppc7450",
448 { /* 7450 2.3 and newer */
449 .pvr_mask
= 0xffff0000,
450 .pvr_value
= 0x80000000,
452 .cpu_features
= CPU_FTRS_7450_23
,
453 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
455 .mmu_features
= MMU_FTR_HPTE_TABLE
,
459 .pmc_type
= PPC_PMC_G4
,
460 .cpu_setup
= __setup_cpu_745x
,
461 .machine_check
= machine_check_generic
,
462 .platform
= "ppc7450",
465 .pvr_mask
= 0xffffff00,
466 .pvr_value
= 0x80010100,
468 .cpu_features
= CPU_FTRS_7455_1
,
469 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
471 .mmu_features
= MMU_FTR_HPTE_TABLE
| MMU_FTR_USE_HIGH_BATS
,
475 .pmc_type
= PPC_PMC_G4
,
476 .cpu_setup
= __setup_cpu_745x
,
477 .machine_check
= machine_check_generic
,
478 .platform
= "ppc7450",
481 .pvr_mask
= 0xffffffff,
482 .pvr_value
= 0x80010200,
484 .cpu_features
= CPU_FTRS_7455_20
,
485 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
487 .mmu_features
= MMU_FTR_HPTE_TABLE
| MMU_FTR_USE_HIGH_BATS
,
491 .pmc_type
= PPC_PMC_G4
,
492 .cpu_setup
= __setup_cpu_745x
,
493 .machine_check
= machine_check_generic
,
494 .platform
= "ppc7450",
497 .pvr_mask
= 0xffff0000,
498 .pvr_value
= 0x80010000,
500 .cpu_features
= CPU_FTRS_7455
,
501 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
503 .mmu_features
= MMU_FTR_HPTE_TABLE
| MMU_FTR_USE_HIGH_BATS
,
507 .pmc_type
= PPC_PMC_G4
,
508 .cpu_setup
= __setup_cpu_745x
,
509 .machine_check
= machine_check_generic
,
510 .platform
= "ppc7450",
512 { /* 7447/7457 Rev 1.0 */
513 .pvr_mask
= 0xffffffff,
514 .pvr_value
= 0x80020100,
515 .cpu_name
= "7447/7457",
516 .cpu_features
= CPU_FTRS_7447_10
,
517 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
519 .mmu_features
= MMU_FTR_HPTE_TABLE
| MMU_FTR_USE_HIGH_BATS
,
523 .pmc_type
= PPC_PMC_G4
,
524 .cpu_setup
= __setup_cpu_745x
,
525 .machine_check
= machine_check_generic
,
526 .platform
= "ppc7450",
528 { /* 7447/7457 Rev 1.1 */
529 .pvr_mask
= 0xffffffff,
530 .pvr_value
= 0x80020101,
531 .cpu_name
= "7447/7457",
532 .cpu_features
= CPU_FTRS_7447_10
,
533 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
535 .mmu_features
= MMU_FTR_HPTE_TABLE
| MMU_FTR_USE_HIGH_BATS
,
539 .pmc_type
= PPC_PMC_G4
,
540 .cpu_setup
= __setup_cpu_745x
,
541 .machine_check
= machine_check_generic
,
542 .platform
= "ppc7450",
544 { /* 7447/7457 Rev 1.2 and later */
545 .pvr_mask
= 0xffff0000,
546 .pvr_value
= 0x80020000,
547 .cpu_name
= "7447/7457",
548 .cpu_features
= CPU_FTRS_7447
,
549 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
551 .mmu_features
= MMU_FTR_HPTE_TABLE
| MMU_FTR_USE_HIGH_BATS
,
555 .pmc_type
= PPC_PMC_G4
,
556 .cpu_setup
= __setup_cpu_745x
,
557 .machine_check
= machine_check_generic
,
558 .platform
= "ppc7450",
561 .pvr_mask
= 0xffff0000,
562 .pvr_value
= 0x80030000,
564 .cpu_features
= CPU_FTRS_7447A
,
565 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
567 .mmu_features
= MMU_FTR_HPTE_TABLE
| MMU_FTR_USE_HIGH_BATS
,
571 .pmc_type
= PPC_PMC_G4
,
572 .cpu_setup
= __setup_cpu_745x
,
573 .machine_check
= machine_check_generic
,
574 .platform
= "ppc7450",
577 .pvr_mask
= 0xffff0000,
578 .pvr_value
= 0x80040000,
580 .cpu_features
= CPU_FTRS_7448
,
581 .cpu_user_features
= COMMON_USER
| PPC_FEATURE_HAS_ALTIVEC_COMP
|
583 .mmu_features
= MMU_FTR_HPTE_TABLE
| MMU_FTR_USE_HIGH_BATS
,
587 .pmc_type
= PPC_PMC_G4
,
588 .cpu_setup
= __setup_cpu_745x
,
589 .machine_check
= machine_check_generic
,
590 .platform
= "ppc7450",
592 { /* default match, we assume split I/D cache & TB (non-601)... */
593 .pvr_mask
= 0x00000000,
594 .pvr_value
= 0x00000000,
595 .cpu_name
= "(generic PPC)",
596 .cpu_features
= CPU_FTRS_CLASSIC32
,
597 .cpu_user_features
= COMMON_USER
,
598 .mmu_features
= MMU_FTR_HPTE_TABLE
,
601 .machine_check
= machine_check_generic
,
602 .platform
= "ppc603",
604 #endif /* CONFIG_PPC_BOOK3S_604 */