blob: d81f826d102967a3db7ad3f3992ee00119233d55 [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001/*
Linus Torvalds1da177e2005-04-16 15:20:36 -07002 * Copyright (C) 2001 Ben. Herrenschmidt (benh@kernel.crashing.org)
3 *
Stephen Rothwell49209602005-10-12 15:55:09 +10004 * Modifications for ppc64:
5 * Copyright (C) 2003 Dave Engebretsen <engebret@us.ibm.com>
6 *
Linus Torvalds1da177e2005-04-16 15:20:36 -07007 * 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.
11 */
12
Linus Torvalds1da177e2005-04-16 15:20:36 -070013#include <linux/string.h>
14#include <linux/sched.h>
15#include <linux/threads.h>
16#include <linux/init.h>
Paul Gortmaker4b16f8e2011-07-22 18:24:23 -040017#include <linux/export.h>
Kumar Gala400d2212005-09-27 15:13:12 -050018
19#include <asm/oprofile_impl.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -070020#include <asm/cputable.h>
Benjamin Herrenschmidt42c4aaa2006-10-24 16:42:40 +100021#include <asm/prom.h> /* for PTRRELOC on ARCH=ppc */
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +000022#include <asm/mmu.h>
David Howellsae3a197e2012-03-28 18:30:02 +010023#include <asm/setup.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -070024
Kumar Gala400d2212005-09-27 15:13:12 -050025struct cpu_spec* cur_cpu_spec = NULL;
Stephen Rothwell49209602005-10-12 15:55:09 +100026EXPORT_SYMBOL(cur_cpu_spec);
Linus Torvalds1da177e2005-04-16 15:20:36 -070027
Nathan Lynch9115d132008-07-16 09:58:51 +100028/* The platform string corresponding to the real PVR */
29const char *powerpc_base_platform;
30
Stephen Rothwell49209602005-10-12 15:55:09 +100031/* NOTE:
32 * Unlike ppc32, ppc64 will only call this once for the boot CPU, it's
33 * the responsibility of the appropriate CPU save/restore functions to
34 * eventually copy these settings over. Those save/restore aren't yet
35 * part of the cputable though. That has to be fixed for both ppc32
36 * and ppc64
37 */
Geoff Levandb26f1002006-05-19 14:24:18 +100038#ifdef CONFIG_PPC32
Kumar Gala105c31d2009-01-08 08:31:20 -060039extern void __setup_cpu_e200(unsigned long offset, struct cpu_spec* spec);
40extern void __setup_cpu_e500v1(unsigned long offset, struct cpu_spec* spec);
41extern void __setup_cpu_e500v2(unsigned long offset, struct cpu_spec* spec);
42extern void __setup_cpu_e500mc(unsigned long offset, struct cpu_spec* spec);
Valentine Barshak81127532007-09-22 00:46:57 +100043extern void __setup_cpu_440ep(unsigned long offset, struct cpu_spec* spec);
44extern void __setup_cpu_440epx(unsigned long offset, struct cpu_spec* spec);
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +110045extern void __setup_cpu_440gx(unsigned long offset, struct cpu_spec* spec);
Valentine Barshak340ffd22007-09-22 00:50:09 +100046extern void __setup_cpu_440grx(unsigned long offset, struct cpu_spec* spec);
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +110047extern void __setup_cpu_440spe(unsigned long offset, struct cpu_spec* spec);
Grant Likely640d17d2008-12-04 05:39:55 +000048extern void __setup_cpu_440x5(unsigned long offset, struct cpu_spec* spec);
Stefan Roese464076a2008-02-24 08:07:41 +110049extern void __setup_cpu_460ex(unsigned long offset, struct cpu_spec* spec);
Josh Boyer939e6222008-06-11 07:52:40 -040050extern void __setup_cpu_460gt(unsigned long offset, struct cpu_spec* spec);
Madhulika Madishetty6c712092009-02-05 13:31:36 +000051extern void __setup_cpu_460sx(unsigned long offset, struct cpu_spec *spec);
Tirumala Marri6edc3232010-09-13 13:26:11 +000052extern void __setup_cpu_apm821xx(unsigned long offset, struct cpu_spec *spec);
Kumar Gala400d2212005-09-27 15:13:12 -050053extern void __setup_cpu_603(unsigned long offset, struct cpu_spec* spec);
54extern void __setup_cpu_604(unsigned long offset, struct cpu_spec* spec);
55extern void __setup_cpu_750(unsigned long offset, struct cpu_spec* spec);
56extern void __setup_cpu_750cx(unsigned long offset, struct cpu_spec* spec);
57extern void __setup_cpu_750fx(unsigned long offset, struct cpu_spec* spec);
58extern void __setup_cpu_7400(unsigned long offset, struct cpu_spec* spec);
59extern void __setup_cpu_7410(unsigned long offset, struct cpu_spec* spec);
60extern void __setup_cpu_745x(unsigned long offset, struct cpu_spec* spec);
Stephen Rothwell49209602005-10-12 15:55:09 +100061#endif /* CONFIG_PPC32 */
Olof Johanssonf39b7a52006-08-11 00:07:08 -050062#ifdef CONFIG_PPC64
Kumar Gala400d2212005-09-27 15:13:12 -050063extern void __setup_cpu_ppc970(unsigned long offset, struct cpu_spec* spec);
Olof Johansson5b43d202006-10-04 23:41:41 -050064extern void __setup_cpu_ppc970MP(unsigned long offset, struct cpu_spec* spec);
Olof Johansson11999192007-02-04 16:36:51 -060065extern void __setup_cpu_pa6t(unsigned long offset, struct cpu_spec* spec);
Stephen Rothwell40d244d2007-02-12 22:10:48 +110066extern void __restore_cpu_pa6t(void);
Olof Johanssonf39b7a52006-08-11 00:07:08 -050067extern void __restore_cpu_ppc970(void);
Michael Neulinge952e6c2008-06-18 10:47:26 +100068extern void __setup_cpu_power7(unsigned long offset, struct cpu_spec* spec);
69extern void __restore_cpu_power7(void);
Michael Neulingaec937b2012-10-30 19:34:14 +000070extern void __setup_cpu_power8(unsigned long offset, struct cpu_spec* spec);
71extern void __restore_cpu_power8(void);
Michael Neulingc3ab3002016-02-19 11:16:24 +110072extern void __setup_cpu_power9(unsigned long offset, struct cpu_spec* spec);
73extern void __restore_cpu_power9(void);
Mahesh Salgaonkar45706bb2014-12-19 08:41:05 +053074extern void __flush_tlb_power7(unsigned int action);
75extern void __flush_tlb_power8(unsigned int action);
Michael Neulingc3ab3002016-02-19 11:16:24 +110076extern void __flush_tlb_power9(unsigned int action);
Mahesh Salgaonkare22a2272013-10-30 20:05:11 +053077extern long __machine_check_early_realmode_p7(struct pt_regs *regs);
Mahesh Salgaonkarae744f32013-10-30 20:05:26 +053078extern long __machine_check_early_realmode_p8(struct pt_regs *regs);
Olof Johanssonf39b7a52006-08-11 00:07:08 -050079#endif /* CONFIG_PPC64 */
Kumar Gala4490c062010-10-08 08:32:11 -050080#if defined(CONFIG_E500)
81extern void __setup_cpu_e5500(unsigned long offset, struct cpu_spec* spec);
Kumar Galacd66cc22012-09-07 15:57:17 -050082extern void __setup_cpu_e6500(unsigned long offset, struct cpu_spec* spec);
Kumar Gala4490c062010-10-08 08:32:11 -050083extern void __restore_cpu_e5500(void);
Kumar Galacd66cc22012-09-07 15:57:17 -050084extern void __restore_cpu_e6500(void);
Kumar Gala4490c062010-10-08 08:32:11 -050085#endif /* CONFIG_E500 */
Linus Torvalds1da177e2005-04-16 15:20:36 -070086
Linus Torvalds1da177e2005-04-16 15:20:36 -070087/* This table only contains "desktop" CPUs, it need to be filled with embedded
88 * ones as well...
89 */
Stephen Rothwell49209602005-10-12 15:55:09 +100090#define COMMON_USER (PPC_FEATURE_32 | PPC_FEATURE_HAS_FPU | \
91 PPC_FEATURE_HAS_MMU)
92#define COMMON_USER_PPC64 (COMMON_USER | PPC_FEATURE_64)
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +110093#define COMMON_USER_POWER4 (COMMON_USER_PPC64 | PPC_FEATURE_POWER4)
Benjamin Herrenschmidtaa5cb0212006-03-01 15:07:07 +110094#define COMMON_USER_POWER5 (COMMON_USER_PPC64 | PPC_FEATURE_POWER5 |\
95 PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP)
96#define COMMON_USER_POWER5_PLUS (COMMON_USER_PPC64 | PPC_FEATURE_POWER5_PLUS|\
97 PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP)
Anton Blanchard03054d52006-04-29 09:51:06 +100098#define COMMON_USER_POWER6 (COMMON_USER_PPC64 | PPC_FEATURE_ARCH_2_05 |\
Paul Mackerrasfab5db92006-06-07 16:14:40 +100099 PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP | \
Nathan Lynch0f473312008-07-10 01:06:57 +1000100 PPC_FEATURE_TRUE_LE | \
101 PPC_FEATURE_PSERIES_PERFMON_COMPAT)
Michael Neulinge952e6c2008-06-18 10:47:26 +1000102#define COMMON_USER_POWER7 (COMMON_USER_PPC64 | PPC_FEATURE_ARCH_2_06 |\
103 PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP | \
Nathan Lynch0f473312008-07-10 01:06:57 +1000104 PPC_FEATURE_TRUE_LE | \
105 PPC_FEATURE_PSERIES_PERFMON_COMPAT)
Nishanth Aravamudan4a1ae4f2013-05-03 14:48:38 +0000106#define COMMON_USER2_POWER7 (PPC_FEATURE2_DSCR)
Michael Neuling71e18492012-10-30 19:34:15 +0000107#define COMMON_USER_POWER8 (COMMON_USER_PPC64 | PPC_FEATURE_ARCH_2_06 |\
108 PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP | \
109 PPC_FEATURE_TRUE_LE | \
110 PPC_FEATURE_PSERIES_PERFMON_COMPAT)
Nishanth Aravamudan748645b2013-05-03 14:49:59 +0000111#define COMMON_USER2_POWER8 (PPC_FEATURE2_ARCH_2_07 | \
Sam bobroffb4b56f92015-06-12 11:06:32 +1000112 PPC_FEATURE2_HTM_COMP | \
113 PPC_FEATURE2_HTM_NOSC_COMP | \
114 PPC_FEATURE2_DSCR | \
Benjamin Herrenschmidtdd58a092014-06-10 15:04:40 +1000115 PPC_FEATURE2_ISEL | PPC_FEATURE2_TAR | \
116 PPC_FEATURE2_VEC_CRYPTO)
Olof Johanssonb3ebd1d2006-09-06 14:35:57 -0500117#define COMMON_USER_PA6T (COMMON_USER_PPC64 | PPC_FEATURE_PA6T |\
118 PPC_FEATURE_TRUE_LE | \
119 PPC_FEATURE_HAS_ALTIVEC_COMP)
Michael Neulingc3ab3002016-02-19 11:16:24 +1100120#define COMMON_USER_POWER9 COMMON_USER_POWER8
121#define COMMON_USER2_POWER9 (COMMON_USER2_POWER8 | \
122 PPC_FEATURE2_ARCH_3_00 | \
123 PPC_FEATURE2_HAS_IEEE128)
124
Kumar Galaf45c4482009-08-18 19:08:30 +0000125#ifdef CONFIG_PPC_BOOK3E_64
126#define COMMON_USER_BOOKE (COMMON_USER_PPC64 | PPC_FEATURE_BOOKE)
127#else
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100128#define COMMON_USER_BOOKE (PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU | \
129 PPC_FEATURE_BOOKE)
Kumar Galaf45c4482009-08-18 19:08:30 +0000130#endif
Linus Torvalds1da177e2005-04-16 15:20:36 -0700131
Paul Mackerras87a72f92007-10-04 14:18:01 +1000132static struct cpu_spec __initdata cpu_specs[] = {
Benjamin Herrenschmidt2d27cfd2009-07-23 23:15:59 +0000133#ifdef CONFIG_PPC_BOOK3S_64
Stephen Rothwell49209602005-10-12 15:55:09 +1000134 { /* Power4 */
135 .pvr_mask = 0xffff0000,
136 .pvr_value = 0x00350000,
137 .cpu_name = "POWER4 (gp)",
138 .cpu_features = CPU_FTRS_POWER4,
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100139 .cpu_user_features = COMMON_USER_POWER4,
Aneesh Kumar K.Vaccfad72016-07-13 15:05:24 +0530140 .mmu_features = MMU_FTRS_POWER4 | MMU_FTR_TLBIE_CROP_VA,
Stephen Rothwell49209602005-10-12 15:55:09 +1000141 .icache_bsize = 128,
142 .dcache_bsize = 128,
143 .num_pmcs = 8,
Olof Johansson1bd2e5a2007-01-28 21:23:54 -0600144 .pmc_type = PPC_PMC_IBM,
Stephen Rothwell49209602005-10-12 15:55:09 +1000145 .oprofile_cpu_type = "ppc64/power4",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +0000146 .oprofile_type = PPC_OPROFILE_POWER4,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100147 .platform = "power4",
Stephen Rothwell49209602005-10-12 15:55:09 +1000148 },
149 { /* Power4+ */
150 .pvr_mask = 0xffff0000,
151 .pvr_value = 0x00380000,
152 .cpu_name = "POWER4+ (gq)",
153 .cpu_features = CPU_FTRS_POWER4,
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100154 .cpu_user_features = COMMON_USER_POWER4,
Aneesh Kumar K.Vaccfad72016-07-13 15:05:24 +0530155 .mmu_features = MMU_FTRS_POWER4 | MMU_FTR_TLBIE_CROP_VA,
Stephen Rothwell49209602005-10-12 15:55:09 +1000156 .icache_bsize = 128,
157 .dcache_bsize = 128,
158 .num_pmcs = 8,
Olof Johansson1bd2e5a2007-01-28 21:23:54 -0600159 .pmc_type = PPC_PMC_IBM,
Stephen Rothwell49209602005-10-12 15:55:09 +1000160 .oprofile_cpu_type = "ppc64/power4",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +0000161 .oprofile_type = PPC_OPROFILE_POWER4,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100162 .platform = "power4",
Stephen Rothwell49209602005-10-12 15:55:09 +1000163 },
164 { /* PPC970 */
165 .pvr_mask = 0xffff0000,
166 .pvr_value = 0x00390000,
167 .cpu_name = "PPC970",
168 .cpu_features = CPU_FTRS_PPC970,
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100169 .cpu_user_features = COMMON_USER_POWER4 |
Stephen Rothwell49209602005-10-12 15:55:09 +1000170 PPC_FEATURE_HAS_ALTIVEC_COMP,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000171 .mmu_features = MMU_FTRS_PPC970,
Stephen Rothwell49209602005-10-12 15:55:09 +1000172 .icache_bsize = 128,
173 .dcache_bsize = 128,
174 .num_pmcs = 8,
Olof Johansson1bd2e5a2007-01-28 21:23:54 -0600175 .pmc_type = PPC_PMC_IBM,
Stephen Rothwell49209602005-10-12 15:55:09 +1000176 .cpu_setup = __setup_cpu_ppc970,
Olof Johanssonf39b7a52006-08-11 00:07:08 -0500177 .cpu_restore = __restore_cpu_ppc970,
Stephen Rothwell49209602005-10-12 15:55:09 +1000178 .oprofile_cpu_type = "ppc64/970",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +0000179 .oprofile_type = PPC_OPROFILE_POWER4,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100180 .platform = "ppc970",
Stephen Rothwell49209602005-10-12 15:55:09 +1000181 },
Stephen Rothwell49209602005-10-12 15:55:09 +1000182 { /* PPC970FX */
183 .pvr_mask = 0xffff0000,
184 .pvr_value = 0x003c0000,
185 .cpu_name = "PPC970FX",
Stephen Rothwell49209602005-10-12 15:55:09 +1000186 .cpu_features = CPU_FTRS_PPC970,
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100187 .cpu_user_features = COMMON_USER_POWER4 |
Stephen Rothwell49209602005-10-12 15:55:09 +1000188 PPC_FEATURE_HAS_ALTIVEC_COMP,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000189 .mmu_features = MMU_FTRS_PPC970,
Stephen Rothwell49209602005-10-12 15:55:09 +1000190 .icache_bsize = 128,
191 .dcache_bsize = 128,
192 .num_pmcs = 8,
Olof Johansson1bd2e5a2007-01-28 21:23:54 -0600193 .pmc_type = PPC_PMC_IBM,
Stephen Rothwell49209602005-10-12 15:55:09 +1000194 .cpu_setup = __setup_cpu_ppc970,
Olof Johanssonf39b7a52006-08-11 00:07:08 -0500195 .cpu_restore = __restore_cpu_ppc970,
Stephen Rothwell49209602005-10-12 15:55:09 +1000196 .oprofile_cpu_type = "ppc64/970",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +0000197 .oprofile_type = PPC_OPROFILE_POWER4,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100198 .platform = "ppc970",
Stephen Rothwell49209602005-10-12 15:55:09 +1000199 },
Olof Johansson3546e812007-02-26 00:35:14 -0600200 { /* PPC970MP DD1.0 - no DEEPNAP, use regular 970 init */
201 .pvr_mask = 0xffffffff,
202 .pvr_value = 0x00440100,
203 .cpu_name = "PPC970MP",
204 .cpu_features = CPU_FTRS_PPC970,
205 .cpu_user_features = COMMON_USER_POWER4 |
206 PPC_FEATURE_HAS_ALTIVEC_COMP,
Benjamin Herrenschmidtd63ac5f2013-03-13 09:55:02 +1100207 .mmu_features = MMU_FTRS_PPC970,
Olof Johansson3546e812007-02-26 00:35:14 -0600208 .icache_bsize = 128,
209 .dcache_bsize = 128,
210 .num_pmcs = 8,
Anton Blanchard2fae4982007-05-19 15:22:41 +1000211 .pmc_type = PPC_PMC_IBM,
Olof Johansson3546e812007-02-26 00:35:14 -0600212 .cpu_setup = __setup_cpu_ppc970,
213 .cpu_restore = __restore_cpu_ppc970,
214 .oprofile_cpu_type = "ppc64/970MP",
215 .oprofile_type = PPC_OPROFILE_POWER4,
216 .platform = "ppc970",
217 },
Stephen Rothwell49209602005-10-12 15:55:09 +1000218 { /* PPC970MP */
219 .pvr_mask = 0xffff0000,
220 .pvr_value = 0x00440000,
221 .cpu_name = "PPC970MP",
222 .cpu_features = CPU_FTRS_PPC970,
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100223 .cpu_user_features = COMMON_USER_POWER4 |
Stephen Rothwell49209602005-10-12 15:55:09 +1000224 PPC_FEATURE_HAS_ALTIVEC_COMP,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000225 .mmu_features = MMU_FTRS_PPC970,
Stephen Rothwell49209602005-10-12 15:55:09 +1000226 .icache_bsize = 128,
227 .dcache_bsize = 128,
Anton Blanchard87af41b2006-05-05 05:44:26 +1000228 .num_pmcs = 8,
Anton Blanchard2fae4982007-05-19 15:22:41 +1000229 .pmc_type = PPC_PMC_IBM,
Olof Johansson5b43d202006-10-04 23:41:41 -0500230 .cpu_setup = __setup_cpu_ppc970MP,
Olof Johanssonf39b7a52006-08-11 00:07:08 -0500231 .cpu_restore = __restore_cpu_ppc970,
Mike Wolffecb3522006-11-21 14:41:54 -0600232 .oprofile_cpu_type = "ppc64/970MP",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +0000233 .oprofile_type = PPC_OPROFILE_POWER4,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100234 .platform = "ppc970",
Stephen Rothwell49209602005-10-12 15:55:09 +1000235 },
Jake Moilanen362ff7b2006-10-18 10:47:22 -0500236 { /* PPC970GX */
237 .pvr_mask = 0xffff0000,
238 .pvr_value = 0x00450000,
239 .cpu_name = "PPC970GX",
240 .cpu_features = CPU_FTRS_PPC970,
241 .cpu_user_features = COMMON_USER_POWER4 |
242 PPC_FEATURE_HAS_ALTIVEC_COMP,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000243 .mmu_features = MMU_FTRS_PPC970,
Jake Moilanen362ff7b2006-10-18 10:47:22 -0500244 .icache_bsize = 128,
245 .dcache_bsize = 128,
246 .num_pmcs = 8,
Olof Johansson1bd2e5a2007-01-28 21:23:54 -0600247 .pmc_type = PPC_PMC_IBM,
Jake Moilanen362ff7b2006-10-18 10:47:22 -0500248 .cpu_setup = __setup_cpu_ppc970,
249 .oprofile_cpu_type = "ppc64/970",
250 .oprofile_type = PPC_OPROFILE_POWER4,
251 .platform = "ppc970",
252 },
Benjamin Herrenschmidt3c726f82005-11-07 11:06:55 +1100253 { /* Power5 GR */
Stephen Rothwell49209602005-10-12 15:55:09 +1000254 .pvr_mask = 0xffff0000,
255 .pvr_value = 0x003a0000,
256 .cpu_name = "POWER5 (gr)",
257 .cpu_features = CPU_FTRS_POWER5,
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100258 .cpu_user_features = COMMON_USER_POWER5,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000259 .mmu_features = MMU_FTRS_POWER5,
Stephen Rothwell49209602005-10-12 15:55:09 +1000260 .icache_bsize = 128,
261 .dcache_bsize = 128,
262 .num_pmcs = 6,
Olof Johansson1bd2e5a2007-01-28 21:23:54 -0600263 .pmc_type = PPC_PMC_IBM,
Stephen Rothwell49209602005-10-12 15:55:09 +1000264 .oprofile_cpu_type = "ppc64/power5",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +0000265 .oprofile_type = PPC_OPROFILE_POWER4,
Michael Neulinge78dbc82006-06-08 14:42:34 +1000266 /* SIHV / SIPR bits are implemented on POWER4+ (GQ)
267 * and above but only works on POWER5 and above
268 */
269 .oprofile_mmcra_sihv = MMCRA_SIHV,
270 .oprofile_mmcra_sipr = MMCRA_SIPR,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100271 .platform = "power5",
Stephen Rothwell49209602005-10-12 15:55:09 +1000272 },
Mike Wolf31a12cec2007-07-10 13:13:47 -0500273 { /* Power5++ */
274 .pvr_mask = 0xffffff00,
275 .pvr_value = 0x003b0300,
276 .cpu_name = "POWER5+ (gs)",
277 .cpu_features = CPU_FTRS_POWER5,
278 .cpu_user_features = COMMON_USER_POWER5_PLUS,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000279 .mmu_features = MMU_FTRS_POWER5,
Mike Wolf31a12cec2007-07-10 13:13:47 -0500280 .icache_bsize = 128,
281 .dcache_bsize = 128,
282 .num_pmcs = 6,
283 .oprofile_cpu_type = "ppc64/power5++",
284 .oprofile_type = PPC_OPROFILE_POWER4,
285 .oprofile_mmcra_sihv = MMCRA_SIHV,
286 .oprofile_mmcra_sipr = MMCRA_SIPR,
287 .platform = "power5+",
288 },
Benjamin Herrenschmidt3c726f82005-11-07 11:06:55 +1100289 { /* Power5 GS */
Stephen Rothwell49209602005-10-12 15:55:09 +1000290 .pvr_mask = 0xffff0000,
291 .pvr_value = 0x003b0000,
Anton Blanchard834608f2006-01-09 15:42:30 +1100292 .cpu_name = "POWER5+ (gs)",
Stephen Rothwell49209602005-10-12 15:55:09 +1000293 .cpu_features = CPU_FTRS_POWER5,
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100294 .cpu_user_features = COMMON_USER_POWER5_PLUS,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000295 .mmu_features = MMU_FTRS_POWER5,
Stephen Rothwell49209602005-10-12 15:55:09 +1000296 .icache_bsize = 128,
297 .dcache_bsize = 128,
298 .num_pmcs = 6,
Olof Johansson1bd2e5a2007-01-28 21:23:54 -0600299 .pmc_type = PPC_PMC_IBM,
Anton Blanchard834608f2006-01-09 15:42:30 +1100300 .oprofile_cpu_type = "ppc64/power5+",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +0000301 .oprofile_type = PPC_OPROFILE_POWER4,
Michael Neulinge78dbc82006-06-08 14:42:34 +1000302 .oprofile_mmcra_sihv = MMCRA_SIHV,
303 .oprofile_mmcra_sipr = MMCRA_SIPR,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100304 .platform = "power5+",
Stephen Rothwell49209602005-10-12 15:55:09 +1000305 },
Paul Mackerras974a76f2006-11-10 20:38:53 +1100306 { /* POWER6 in P5+ mode; 2.04-compliant processor */
307 .pvr_mask = 0xffffffff,
308 .pvr_value = 0x0f000001,
309 .cpu_name = "POWER5+",
310 .cpu_features = CPU_FTRS_POWER5,
311 .cpu_user_features = COMMON_USER_POWER5_PLUS,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000312 .mmu_features = MMU_FTRS_POWER5,
Paul Mackerras974a76f2006-11-10 20:38:53 +1100313 .icache_bsize = 128,
314 .dcache_bsize = 128,
Michael Wolf79af6c42009-04-27 06:17:54 +0000315 .oprofile_cpu_type = "ppc64/ibm-compat-v1",
316 .oprofile_type = PPC_OPROFILE_POWER4,
Paul Mackerras974a76f2006-11-10 20:38:53 +1100317 .platform = "power5+",
318 },
Anton Blanchard03054d52006-04-29 09:51:06 +1000319 { /* Power6 */
320 .pvr_mask = 0xffff0000,
321 .pvr_value = 0x003e0000,
Paul Mackerras974a76f2006-11-10 20:38:53 +1100322 .cpu_name = "POWER6 (raw)",
323 .cpu_features = CPU_FTRS_POWER6,
324 .cpu_user_features = COMMON_USER_POWER6 |
325 PPC_FEATURE_POWER6_EXT,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000326 .mmu_features = MMU_FTRS_POWER6,
Paul Mackerras974a76f2006-11-10 20:38:53 +1100327 .icache_bsize = 128,
328 .dcache_bsize = 128,
329 .num_pmcs = 6,
Anton Blanchard2fae4982007-05-19 15:22:41 +1000330 .pmc_type = PPC_PMC_IBM,
Paul Mackerras974a76f2006-11-10 20:38:53 +1100331 .oprofile_cpu_type = "ppc64/power6",
332 .oprofile_type = PPC_OPROFILE_POWER4,
333 .oprofile_mmcra_sihv = POWER6_MMCRA_SIHV,
334 .oprofile_mmcra_sipr = POWER6_MMCRA_SIPR,
335 .oprofile_mmcra_clear = POWER6_MMCRA_THRM |
336 POWER6_MMCRA_OTHER,
337 .platform = "power6x",
338 },
339 { /* 2.05-compliant processor, i.e. Power6 "architected" mode */
340 .pvr_mask = 0xffffffff,
341 .pvr_value = 0x0f000002,
342 .cpu_name = "POWER6 (architected)",
Anton Blanchard03054d52006-04-29 09:51:06 +1000343 .cpu_features = CPU_FTRS_POWER6,
344 .cpu_user_features = COMMON_USER_POWER6,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000345 .mmu_features = MMU_FTRS_POWER6,
Anton Blanchard03054d52006-04-29 09:51:06 +1000346 .icache_bsize = 128,
347 .dcache_bsize = 128,
Michael Wolf79af6c42009-04-27 06:17:54 +0000348 .oprofile_cpu_type = "ppc64/ibm-compat-v1",
349 .oprofile_type = PPC_OPROFILE_POWER4,
Anton Blanchard03054d52006-04-29 09:51:06 +1000350 .platform = "power6",
351 },
Joel Schopp635f5a62008-06-19 06:18:21 +1000352 { /* 2.06-compliant processor, i.e. Power7 "architected" mode */
353 .pvr_mask = 0xffffffff,
354 .pvr_value = 0x0f000003,
355 .cpu_name = "POWER7 (architected)",
356 .cpu_features = CPU_FTRS_POWER7,
357 .cpu_user_features = COMMON_USER_POWER7,
Nishanth Aravamudan4a1ae4f2013-05-03 14:48:38 +0000358 .cpu_user_features2 = COMMON_USER2_POWER7,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000359 .mmu_features = MMU_FTRS_POWER7,
Joel Schopp635f5a62008-06-19 06:18:21 +1000360 .icache_bsize = 128,
361 .dcache_bsize = 128,
Michael Wolf79af6c42009-04-27 06:17:54 +0000362 .oprofile_type = PPC_OPROFILE_POWER4,
363 .oprofile_cpu_type = "ppc64/ibm-compat-v1",
Benjamin Herrenschmidt24cc67d2011-01-20 18:50:55 +1100364 .cpu_setup = __setup_cpu_power7,
365 .cpu_restore = __restore_cpu_power7,
Mahesh Salgaonkar04407052013-10-30 20:04:56 +0530366 .flush_tlb = __flush_tlb_power7,
Mahesh Salgaonkare22a2272013-10-30 20:05:11 +0530367 .machine_check_early = __machine_check_early_realmode_p7,
Joel Schopp635f5a62008-06-19 06:18:21 +1000368 .platform = "power7",
369 },
Michael Neulingc674e702012-11-08 20:26:42 +0000370 { /* 2.07-compliant processor, i.e. Power8 "architected" mode */
371 .pvr_mask = 0xffffffff,
372 .pvr_value = 0x0f000004,
373 .cpu_name = "POWER8 (architected)",
374 .cpu_features = CPU_FTRS_POWER8,
375 .cpu_user_features = COMMON_USER_POWER8,
Nishanth Aravamudan748645b2013-05-03 14:49:59 +0000376 .cpu_user_features2 = COMMON_USER2_POWER8,
Michael Neulingc674e702012-11-08 20:26:42 +0000377 .mmu_features = MMU_FTRS_POWER8,
378 .icache_bsize = 128,
379 .dcache_bsize = 128,
Michael Neuling6a60f9e2013-06-04 19:38:54 +0000380 .oprofile_type = PPC_OPROFILE_INVALID,
381 .oprofile_cpu_type = "ppc64/ibm-compat-v1",
Michael Neulingc674e702012-11-08 20:26:42 +0000382 .cpu_setup = __setup_cpu_power8,
383 .cpu_restore = __restore_cpu_power8,
Mahesh Salgaonkar04407052013-10-30 20:04:56 +0530384 .flush_tlb = __flush_tlb_power8,
Mahesh Salgaonkarae744f32013-10-30 20:05:26 +0530385 .machine_check_early = __machine_check_early_realmode_p8,
Michael Neulingc674e702012-11-08 20:26:42 +0000386 .platform = "power8",
387 },
Michael Neulinge952e6c2008-06-18 10:47:26 +1000388 { /* Power7 */
389 .pvr_mask = 0xffff0000,
390 .pvr_value = 0x003f0000,
Joel Schopp635f5a62008-06-19 06:18:21 +1000391 .cpu_name = "POWER7 (raw)",
Michael Neulinge952e6c2008-06-18 10:47:26 +1000392 .cpu_features = CPU_FTRS_POWER7,
393 .cpu_user_features = COMMON_USER_POWER7,
Nishanth Aravamudan4a1ae4f2013-05-03 14:48:38 +0000394 .cpu_user_features2 = COMMON_USER2_POWER7,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000395 .mmu_features = MMU_FTRS_POWER7,
Michael Neulinge952e6c2008-06-18 10:47:26 +1000396 .icache_bsize = 128,
397 .dcache_bsize = 128,
398 .num_pmcs = 6,
399 .pmc_type = PPC_PMC_IBM,
Michael Neulinge952e6c2008-06-18 10:47:26 +1000400 .oprofile_cpu_type = "ppc64/power7",
401 .oprofile_type = PPC_OPROFILE_POWER4,
Benjamin Herrenschmidt24cc67d2011-01-20 18:50:55 +1100402 .cpu_setup = __setup_cpu_power7,
403 .cpu_restore = __restore_cpu_power7,
Mahesh Salgaonkar04407052013-10-30 20:04:56 +0530404 .flush_tlb = __flush_tlb_power7,
Mahesh Salgaonkare22a2272013-10-30 20:05:11 +0530405 .machine_check_early = __machine_check_early_realmode_p7,
Michael Neulinge952e6c2008-06-18 10:47:26 +1000406 .platform = "power7",
407 },
Michael Neuling6f08cb32010-11-17 18:52:44 +0000408 { /* Power7+ */
409 .pvr_mask = 0xffff0000,
410 .pvr_value = 0x004A0000,
411 .cpu_name = "POWER7+ (raw)",
412 .cpu_features = CPU_FTRS_POWER7,
413 .cpu_user_features = COMMON_USER_POWER7,
Will Schmidtbadec112013-05-20 05:04:18 +0000414 .cpu_user_features2 = COMMON_USER2_POWER7,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000415 .mmu_features = MMU_FTRS_POWER7,
Michael Neuling6f08cb32010-11-17 18:52:44 +0000416 .icache_bsize = 128,
417 .dcache_bsize = 128,
418 .num_pmcs = 6,
419 .pmc_type = PPC_PMC_IBM,
420 .oprofile_cpu_type = "ppc64/power7",
421 .oprofile_type = PPC_OPROFILE_POWER4,
Benjamin Herrenschmidt24cc67d2011-01-20 18:50:55 +1100422 .cpu_setup = __setup_cpu_power7,
423 .cpu_restore = __restore_cpu_power7,
Mahesh Salgaonkar04407052013-10-30 20:04:56 +0530424 .flush_tlb = __flush_tlb_power7,
Mahesh Salgaonkare22a2272013-10-30 20:05:11 +0530425 .machine_check_early = __machine_check_early_realmode_p7,
Michael Neuling6f08cb32010-11-17 18:52:44 +0000426 .platform = "power7+",
427 },
Michael Neuling33959f82013-07-18 11:31:51 +1000428 { /* Power8E */
Michael Neuling71e18492012-10-30 19:34:15 +0000429 .pvr_mask = 0xffff0000,
430 .pvr_value = 0x004b0000,
Michael Neuling33959f82013-07-18 11:31:51 +1000431 .cpu_name = "POWER8E (raw)",
Michael Ellerman68f2f0d2014-03-14 16:00:28 +1100432 .cpu_features = CPU_FTRS_POWER8E,
Michael Neuling33959f82013-07-18 11:31:51 +1000433 .cpu_user_features = COMMON_USER_POWER8,
434 .cpu_user_features2 = COMMON_USER2_POWER8,
435 .mmu_features = MMU_FTRS_POWER8,
436 .icache_bsize = 128,
437 .dcache_bsize = 128,
438 .num_pmcs = 6,
439 .pmc_type = PPC_PMC_IBM,
440 .oprofile_cpu_type = "ppc64/power8",
441 .oprofile_type = PPC_OPROFILE_INVALID,
442 .cpu_setup = __setup_cpu_power8,
443 .cpu_restore = __restore_cpu_power8,
Mahesh Salgaonkar04407052013-10-30 20:04:56 +0530444 .flush_tlb = __flush_tlb_power8,
Mahesh Salgaonkarae744f32013-10-30 20:05:26 +0530445 .machine_check_early = __machine_check_early_realmode_p8,
Michael Neuling33959f82013-07-18 11:31:51 +1000446 .platform = "power8",
447 },
Benjamin Herrenschmidtddee09c2015-03-19 14:12:06 +1100448 { /* Power8NVL */
449 .pvr_mask = 0xffff0000,
450 .pvr_value = 0x004c0000,
451 .cpu_name = "POWER8NVL (raw)",
452 .cpu_features = CPU_FTRS_POWER8,
453 .cpu_user_features = COMMON_USER_POWER8,
454 .cpu_user_features2 = COMMON_USER2_POWER8,
455 .mmu_features = MMU_FTRS_POWER8,
456 .icache_bsize = 128,
457 .dcache_bsize = 128,
458 .num_pmcs = 6,
459 .pmc_type = PPC_PMC_IBM,
460 .oprofile_cpu_type = "ppc64/power8",
461 .oprofile_type = PPC_OPROFILE_INVALID,
462 .cpu_setup = __setup_cpu_power8,
463 .cpu_restore = __restore_cpu_power8,
464 .flush_tlb = __flush_tlb_power8,
465 .machine_check_early = __machine_check_early_realmode_p8,
466 .platform = "power8",
467 },
Joel Stanleybd6ba352014-07-18 11:41:37 +0930468 { /* Power8 DD1: Does not support doorbell IPIs */
469 .pvr_mask = 0xffffff00,
470 .pvr_value = 0x004d0100,
471 .cpu_name = "POWER8 (raw)",
472 .cpu_features = CPU_FTRS_POWER8_DD1,
473 .cpu_user_features = COMMON_USER_POWER8,
474 .cpu_user_features2 = COMMON_USER2_POWER8,
475 .mmu_features = MMU_FTRS_POWER8,
476 .icache_bsize = 128,
477 .dcache_bsize = 128,
478 .num_pmcs = 6,
479 .pmc_type = PPC_PMC_IBM,
480 .oprofile_cpu_type = "ppc64/power8",
481 .oprofile_type = PPC_OPROFILE_INVALID,
482 .cpu_setup = __setup_cpu_power8,
483 .cpu_restore = __restore_cpu_power8,
484 .flush_tlb = __flush_tlb_power8,
485 .machine_check_early = __machine_check_early_realmode_p8,
486 .platform = "power8",
487 },
Michael Neuling33959f82013-07-18 11:31:51 +1000488 { /* Power8 */
489 .pvr_mask = 0xffff0000,
490 .pvr_value = 0x004d0000,
Michael Neuling71e18492012-10-30 19:34:15 +0000491 .cpu_name = "POWER8 (raw)",
492 .cpu_features = CPU_FTRS_POWER8,
493 .cpu_user_features = COMMON_USER_POWER8,
Nishanth Aravamudan748645b2013-05-03 14:49:59 +0000494 .cpu_user_features2 = COMMON_USER2_POWER8,
Michael Neuling71e18492012-10-30 19:34:15 +0000495 .mmu_features = MMU_FTRS_POWER8,
496 .icache_bsize = 128,
497 .dcache_bsize = 128,
498 .num_pmcs = 6,
499 .pmc_type = PPC_PMC_IBM,
Michael Neuling6a60f9e2013-06-04 19:38:54 +0000500 .oprofile_cpu_type = "ppc64/power8",
501 .oprofile_type = PPC_OPROFILE_INVALID,
Michael Neuling71e18492012-10-30 19:34:15 +0000502 .cpu_setup = __setup_cpu_power8,
503 .cpu_restore = __restore_cpu_power8,
Mahesh Salgaonkar04407052013-10-30 20:04:56 +0530504 .flush_tlb = __flush_tlb_power8,
Mahesh Salgaonkarae744f32013-10-30 20:05:26 +0530505 .machine_check_early = __machine_check_early_realmode_p8,
Michael Neuling71e18492012-10-30 19:34:15 +0000506 .platform = "power8",
507 },
Michael Neulingc3ab3002016-02-19 11:16:24 +1100508 { /* Power9 */
509 .pvr_mask = 0xffff0000,
510 .pvr_value = 0x004e0000,
511 .cpu_name = "POWER9 (raw)",
512 .cpu_features = CPU_FTRS_POWER9,
513 .cpu_user_features = COMMON_USER_POWER9,
514 .cpu_user_features2 = COMMON_USER2_POWER9,
515 .mmu_features = MMU_FTRS_POWER9,
516 .icache_bsize = 128,
517 .dcache_bsize = 128,
518 .num_pmcs = 6,
519 .pmc_type = PPC_PMC_IBM,
520 .oprofile_cpu_type = "ppc64/power9",
521 .oprofile_type = PPC_OPROFILE_INVALID,
522 .cpu_setup = __setup_cpu_power9,
523 .cpu_restore = __restore_cpu_power9,
524 .flush_tlb = __flush_tlb_power9,
525 .platform = "power9",
526 },
Arnd Bergmannc902be72006-01-04 19:55:53 +0000527 { /* Cell Broadband Engine */
Stephen Rothwell49209602005-10-12 15:55:09 +1000528 .pvr_mask = 0xffff0000,
529 .pvr_value = 0x00700000,
530 .cpu_name = "Cell Broadband Engine",
531 .cpu_features = CPU_FTRS_CELL,
532 .cpu_user_features = COMMON_USER_PPC64 |
Benjamin Herrenschmidtaa5cb0212006-03-01 15:07:07 +1100533 PPC_FEATURE_CELL | PPC_FEATURE_HAS_ALTIVEC_COMP |
534 PPC_FEATURE_SMT,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000535 .mmu_features = MMU_FTRS_CELL,
Stephen Rothwell49209602005-10-12 15:55:09 +1000536 .icache_bsize = 128,
537 .dcache_bsize = 128,
Maynard Johnson18f21902006-11-20 18:45:16 +0100538 .num_pmcs = 4,
Olof Johansson1bd2e5a2007-01-28 21:23:54 -0600539 .pmc_type = PPC_PMC_IBM,
Maynard Johnson18f21902006-11-20 18:45:16 +0100540 .oprofile_cpu_type = "ppc64/cell-be",
541 .oprofile_type = PPC_OPROFILE_CELL,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100542 .platform = "ppc-cell-be",
Stephen Rothwell49209602005-10-12 15:55:09 +1000543 },
Olof Johanssonb3ebd1d2006-09-06 14:35:57 -0500544 { /* PA Semi PA6T */
545 .pvr_mask = 0x7fff0000,
546 .pvr_value = 0x00900000,
547 .cpu_name = "PA6T",
548 .cpu_features = CPU_FTRS_PA6T,
549 .cpu_user_features = COMMON_USER_PA6T,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000550 .mmu_features = MMU_FTRS_PA6T,
Olof Johanssonb3ebd1d2006-09-06 14:35:57 -0500551 .icache_bsize = 64,
552 .dcache_bsize = 64,
553 .num_pmcs = 6,
Olof Johansson1bd2e5a2007-01-28 21:23:54 -0600554 .pmc_type = PPC_PMC_PA6T,
Olof Johansson11999192007-02-04 16:36:51 -0600555 .cpu_setup = __setup_cpu_pa6t,
556 .cpu_restore = __restore_cpu_pa6t,
Olof Johansson25fc5302007-04-18 16:38:21 +1000557 .oprofile_cpu_type = "ppc64/pa6t",
558 .oprofile_type = PPC_OPROFILE_PA6T,
Olof Johanssonb3ebd1d2006-09-06 14:35:57 -0500559 .platform = "pa6t",
560 },
Stephen Rothwell49209602005-10-12 15:55:09 +1000561 { /* default match */
562 .pvr_mask = 0x00000000,
563 .pvr_value = 0x00000000,
564 .cpu_name = "POWER4 (compatible)",
565 .cpu_features = CPU_FTRS_COMPATIBLE,
566 .cpu_user_features = COMMON_USER_PPC64,
Matt Evans44ae3ab2011-04-06 19:48:50 +0000567 .mmu_features = MMU_FTRS_DEFAULT_HPTE_ARCH_V2,
Stephen Rothwell49209602005-10-12 15:55:09 +1000568 .icache_bsize = 128,
569 .dcache_bsize = 128,
570 .num_pmcs = 6,
Olof Johansson1bd2e5a2007-01-28 21:23:54 -0600571 .pmc_type = PPC_PMC_IBM,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100572 .platform = "power4",
Stephen Rothwell49209602005-10-12 15:55:09 +1000573 }
Benjamin Herrenschmidt2d27cfd2009-07-23 23:15:59 +0000574#endif /* CONFIG_PPC_BOOK3S_64 */
Benjamin Herrenschmidt2d27cfd2009-07-23 23:15:59 +0000575
Stephen Rothwell49209602005-10-12 15:55:09 +1000576#ifdef CONFIG_PPC32
Michael Ellerman1e07a0a2014-07-10 12:29:26 +1000577#ifdef CONFIG_PPC_BOOK3S_32
Stephen Rothwell49209602005-10-12 15:55:09 +1000578 { /* 601 */
Linus Torvalds1da177e2005-04-16 15:20:36 -0700579 .pvr_mask = 0xffff0000,
580 .pvr_value = 0x00010000,
581 .cpu_name = "601",
Kumar Gala10b35d92005-09-23 14:08:58 -0500582 .cpu_features = CPU_FTRS_PPC601,
Stephen Rothwell49209602005-10-12 15:55:09 +1000583 .cpu_user_features = COMMON_USER | PPC_FEATURE_601_INSTR |
Paul Mackerras98599012005-10-22 16:51:34 +1000584 PPC_FEATURE_UNIFIED_CACHE | PPC_FEATURE_NO_TB,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000585 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700586 .icache_bsize = 32,
587 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100588 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100589 .platform = "ppc601",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700590 },
591 { /* 603 */
592 .pvr_mask = 0xffff0000,
593 .pvr_value = 0x00030000,
594 .cpu_name = "603",
Kumar Gala10b35d92005-09-23 14:08:58 -0500595 .cpu_features = CPU_FTRS_603,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000596 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000597 .mmu_features = 0,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700598 .icache_bsize = 32,
599 .dcache_bsize = 32,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100600 .cpu_setup = __setup_cpu_603,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100601 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100602 .platform = "ppc603",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700603 },
604 { /* 603e */
605 .pvr_mask = 0xffff0000,
606 .pvr_value = 0x00060000,
607 .cpu_name = "603e",
Kumar Gala10b35d92005-09-23 14:08:58 -0500608 .cpu_features = CPU_FTRS_603,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000609 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000610 .mmu_features = 0,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700611 .icache_bsize = 32,
612 .dcache_bsize = 32,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100613 .cpu_setup = __setup_cpu_603,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100614 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100615 .platform = "ppc603",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700616 },
617 { /* 603ev */
618 .pvr_mask = 0xffff0000,
619 .pvr_value = 0x00070000,
620 .cpu_name = "603ev",
Kumar Gala10b35d92005-09-23 14:08:58 -0500621 .cpu_features = CPU_FTRS_603,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000622 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000623 .mmu_features = 0,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700624 .icache_bsize = 32,
625 .dcache_bsize = 32,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100626 .cpu_setup = __setup_cpu_603,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100627 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100628 .platform = "ppc603",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700629 },
630 { /* 604 */
631 .pvr_mask = 0xffff0000,
632 .pvr_value = 0x00040000,
633 .cpu_name = "604",
Kumar Gala10b35d92005-09-23 14:08:58 -0500634 .cpu_features = CPU_FTRS_604,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000635 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000636 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700637 .icache_bsize = 32,
638 .dcache_bsize = 32,
639 .num_pmcs = 2,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100640 .cpu_setup = __setup_cpu_604,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100641 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100642 .platform = "ppc604",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700643 },
644 { /* 604e */
645 .pvr_mask = 0xfffff000,
646 .pvr_value = 0x00090000,
647 .cpu_name = "604e",
Kumar Gala10b35d92005-09-23 14:08:58 -0500648 .cpu_features = CPU_FTRS_604,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000649 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000650 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700651 .icache_bsize = 32,
652 .dcache_bsize = 32,
653 .num_pmcs = 4,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100654 .cpu_setup = __setup_cpu_604,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100655 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100656 .platform = "ppc604",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700657 },
658 { /* 604r */
659 .pvr_mask = 0xffff0000,
660 .pvr_value = 0x00090000,
661 .cpu_name = "604r",
Kumar Gala10b35d92005-09-23 14:08:58 -0500662 .cpu_features = CPU_FTRS_604,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000663 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000664 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700665 .icache_bsize = 32,
666 .dcache_bsize = 32,
667 .num_pmcs = 4,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100668 .cpu_setup = __setup_cpu_604,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100669 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100670 .platform = "ppc604",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700671 },
672 { /* 604ev */
673 .pvr_mask = 0xffff0000,
674 .pvr_value = 0x000a0000,
675 .cpu_name = "604ev",
Kumar Gala10b35d92005-09-23 14:08:58 -0500676 .cpu_features = CPU_FTRS_604,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000677 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000678 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700679 .icache_bsize = 32,
680 .dcache_bsize = 32,
681 .num_pmcs = 4,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100682 .cpu_setup = __setup_cpu_604,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100683 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100684 .platform = "ppc604",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700685 },
686 { /* 740/750 (0x4202, don't support TAU ?) */
687 .pvr_mask = 0xffffffff,
688 .pvr_value = 0x00084202,
689 .cpu_name = "740/750",
Kumar Gala10b35d92005-09-23 14:08:58 -0500690 .cpu_features = CPU_FTRS_740_NOTAU,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000691 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000692 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700693 .icache_bsize = 32,
694 .dcache_bsize = 32,
695 .num_pmcs = 4,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100696 .cpu_setup = __setup_cpu_750,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100697 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100698 .platform = "ppc750",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700699 },
Linus Torvalds1da177e2005-04-16 15:20:36 -0700700 { /* 750CX (80100 and 8010x?) */
701 .pvr_mask = 0xfffffff0,
702 .pvr_value = 0x00080100,
703 .cpu_name = "750CX",
Kumar Gala10b35d92005-09-23 14:08:58 -0500704 .cpu_features = CPU_FTRS_750,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000705 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000706 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700707 .icache_bsize = 32,
708 .dcache_bsize = 32,
709 .num_pmcs = 4,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100710 .cpu_setup = __setup_cpu_750cx,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100711 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100712 .platform = "ppc750",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700713 },
714 { /* 750CX (82201 and 82202) */
715 .pvr_mask = 0xfffffff0,
716 .pvr_value = 0x00082200,
717 .cpu_name = "750CX",
Kumar Gala10b35d92005-09-23 14:08:58 -0500718 .cpu_features = CPU_FTRS_750,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000719 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000720 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700721 .icache_bsize = 32,
722 .dcache_bsize = 32,
723 .num_pmcs = 4,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000724 .pmc_type = PPC_PMC_IBM,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100725 .cpu_setup = __setup_cpu_750cx,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100726 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100727 .platform = "ppc750",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700728 },
729 { /* 750CXe (82214) */
730 .pvr_mask = 0xfffffff0,
731 .pvr_value = 0x00082210,
732 .cpu_name = "750CXe",
Kumar Gala10b35d92005-09-23 14:08:58 -0500733 .cpu_features = CPU_FTRS_750,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000734 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000735 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700736 .icache_bsize = 32,
737 .dcache_bsize = 32,
738 .num_pmcs = 4,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000739 .pmc_type = PPC_PMC_IBM,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100740 .cpu_setup = __setup_cpu_750cx,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100741 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100742 .platform = "ppc750",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700743 },
Arthur Othieno7c316252005-09-03 15:55:52 -0700744 { /* 750CXe "Gekko" (83214) */
745 .pvr_mask = 0xffffffff,
746 .pvr_value = 0x00083214,
747 .cpu_name = "750CXe",
Kumar Gala10b35d92005-09-23 14:08:58 -0500748 .cpu_features = CPU_FTRS_750,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000749 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000750 .mmu_features = MMU_FTR_HPTE_TABLE,
Arthur Othieno7c316252005-09-03 15:55:52 -0700751 .icache_bsize = 32,
752 .dcache_bsize = 32,
753 .num_pmcs = 4,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000754 .pmc_type = PPC_PMC_IBM,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100755 .cpu_setup = __setup_cpu_750cx,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100756 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100757 .platform = "ppc750",
Arthur Othieno7c316252005-09-03 15:55:52 -0700758 },
Albert Herranz45158dc2009-12-12 06:31:46 +0000759 { /* 750CL (and "Broadway") */
760 .pvr_mask = 0xfffff0e0,
761 .pvr_value = 0x00087000,
Jake Moilanencfbff8a2006-10-03 14:29:34 -0500762 .cpu_name = "750CL",
Josh Boyera14c4502007-04-13 04:33:25 +1000763 .cpu_features = CPU_FTRS_750CL,
Jake Moilanencfbff8a2006-10-03 14:29:34 -0500764 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000765 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
Jake Moilanencfbff8a2006-10-03 14:29:34 -0500766 .icache_bsize = 32,
767 .dcache_bsize = 32,
768 .num_pmcs = 4,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000769 .pmc_type = PPC_PMC_IBM,
Josh Boyera14c4502007-04-13 04:33:25 +1000770 .cpu_setup = __setup_cpu_750,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100771 .machine_check = machine_check_generic,
Jake Moilanencfbff8a2006-10-03 14:29:34 -0500772 .platform = "ppc750",
Dragos Tatulea04f56534772009-09-16 11:58:15 +0300773 .oprofile_cpu_type = "ppc/750",
774 .oprofile_type = PPC_OPROFILE_G4,
Jake Moilanencfbff8a2006-10-03 14:29:34 -0500775 },
Arthur Othienoac1ff042005-09-03 15:55:51 -0700776 { /* 745/755 */
777 .pvr_mask = 0xfffff000,
778 .pvr_value = 0x00083000,
779 .cpu_name = "745/755",
Kumar Gala10b35d92005-09-23 14:08:58 -0500780 .cpu_features = CPU_FTRS_750,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000781 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000782 .mmu_features = MMU_FTR_HPTE_TABLE,
Arthur Othienoac1ff042005-09-03 15:55:51 -0700783 .icache_bsize = 32,
784 .dcache_bsize = 32,
785 .num_pmcs = 4,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000786 .pmc_type = PPC_PMC_IBM,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100787 .cpu_setup = __setup_cpu_750,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100788 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100789 .platform = "ppc750",
Arthur Othienoac1ff042005-09-03 15:55:51 -0700790 },
Linus Torvalds1da177e2005-04-16 15:20:36 -0700791 { /* 750FX rev 1.x */
792 .pvr_mask = 0xffffff00,
793 .pvr_value = 0x70000100,
794 .cpu_name = "750FX",
Kumar Gala10b35d92005-09-23 14:08:58 -0500795 .cpu_features = CPU_FTRS_750FX1,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000796 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000797 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700798 .icache_bsize = 32,
799 .dcache_bsize = 32,
800 .num_pmcs = 4,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000801 .pmc_type = PPC_PMC_IBM,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100802 .cpu_setup = __setup_cpu_750,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100803 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100804 .platform = "ppc750",
Octavian Purdila7c9583a2009-03-04 02:02:42 +0000805 .oprofile_cpu_type = "ppc/750",
806 .oprofile_type = PPC_OPROFILE_G4,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700807 },
808 { /* 750FX rev 2.0 must disable HID0[DPM] */
809 .pvr_mask = 0xffffffff,
810 .pvr_value = 0x70000200,
811 .cpu_name = "750FX",
Kumar Gala10b35d92005-09-23 14:08:58 -0500812 .cpu_features = CPU_FTRS_750FX2,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000813 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000814 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700815 .icache_bsize = 32,
816 .dcache_bsize = 32,
817 .num_pmcs = 4,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000818 .pmc_type = PPC_PMC_IBM,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100819 .cpu_setup = __setup_cpu_750,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100820 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100821 .platform = "ppc750",
Octavian Purdila7c9583a2009-03-04 02:02:42 +0000822 .oprofile_cpu_type = "ppc/750",
823 .oprofile_type = PPC_OPROFILE_G4,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700824 },
825 { /* 750FX (All revs except 2.0) */
826 .pvr_mask = 0xffff0000,
827 .pvr_value = 0x70000000,
828 .cpu_name = "750FX",
Kumar Gala10b35d92005-09-23 14:08:58 -0500829 .cpu_features = CPU_FTRS_750FX,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000830 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000831 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700832 .icache_bsize = 32,
833 .dcache_bsize = 32,
834 .num_pmcs = 4,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000835 .pmc_type = PPC_PMC_IBM,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100836 .cpu_setup = __setup_cpu_750fx,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100837 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100838 .platform = "ppc750",
Octavian Purdila7c9583a2009-03-04 02:02:42 +0000839 .oprofile_cpu_type = "ppc/750",
840 .oprofile_type = PPC_OPROFILE_G4,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700841 },
842 { /* 750GX */
843 .pvr_mask = 0xffff0000,
844 .pvr_value = 0x70020000,
845 .cpu_name = "750GX",
Kumar Gala10b35d92005-09-23 14:08:58 -0500846 .cpu_features = CPU_FTRS_750GX,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000847 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000848 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700849 .icache_bsize = 32,
850 .dcache_bsize = 32,
851 .num_pmcs = 4,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000852 .pmc_type = PPC_PMC_IBM,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100853 .cpu_setup = __setup_cpu_750fx,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100854 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100855 .platform = "ppc750",
Octavian Purdila7c9583a2009-03-04 02:02:42 +0000856 .oprofile_cpu_type = "ppc/750",
857 .oprofile_type = PPC_OPROFILE_G4,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700858 },
859 { /* 740/750 (L2CR bit need fixup for 740) */
860 .pvr_mask = 0xffff0000,
861 .pvr_value = 0x00080000,
862 .cpu_name = "740/750",
Kumar Gala10b35d92005-09-23 14:08:58 -0500863 .cpu_features = CPU_FTRS_740,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000864 .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000865 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700866 .icache_bsize = 32,
867 .dcache_bsize = 32,
868 .num_pmcs = 4,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000869 .pmc_type = PPC_PMC_IBM,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100870 .cpu_setup = __setup_cpu_750,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100871 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100872 .platform = "ppc750",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700873 },
874 { /* 7400 rev 1.1 ? (no TAU) */
875 .pvr_mask = 0xffffffff,
876 .pvr_value = 0x000c1101,
877 .cpu_name = "7400 (1.1)",
Kumar Gala10b35d92005-09-23 14:08:58 -0500878 .cpu_features = CPU_FTRS_7400_NOTAU,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000879 .cpu_user_features = COMMON_USER |
880 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000881 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700882 .icache_bsize = 32,
883 .dcache_bsize = 32,
884 .num_pmcs = 4,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000885 .pmc_type = PPC_PMC_G4,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100886 .cpu_setup = __setup_cpu_7400,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100887 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100888 .platform = "ppc7400",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700889 },
890 { /* 7400 */
891 .pvr_mask = 0xffff0000,
892 .pvr_value = 0x000c0000,
893 .cpu_name = "7400",
Kumar Gala10b35d92005-09-23 14:08:58 -0500894 .cpu_features = CPU_FTRS_7400,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000895 .cpu_user_features = COMMON_USER |
896 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000897 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700898 .icache_bsize = 32,
899 .dcache_bsize = 32,
900 .num_pmcs = 4,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000901 .pmc_type = PPC_PMC_G4,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100902 .cpu_setup = __setup_cpu_7400,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100903 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100904 .platform = "ppc7400",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700905 },
906 { /* 7410 */
907 .pvr_mask = 0xffff0000,
908 .pvr_value = 0x800c0000,
909 .cpu_name = "7410",
Kumar Gala10b35d92005-09-23 14:08:58 -0500910 .cpu_features = CPU_FTRS_7400,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000911 .cpu_user_features = COMMON_USER |
912 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000913 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700914 .icache_bsize = 32,
915 .dcache_bsize = 32,
916 .num_pmcs = 4,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000917 .pmc_type = PPC_PMC_G4,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100918 .cpu_setup = __setup_cpu_7410,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100919 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100920 .platform = "ppc7400",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700921 },
922 { /* 7450 2.0 - no doze/nap */
923 .pvr_mask = 0xffffffff,
924 .pvr_value = 0x80000200,
925 .cpu_name = "7450",
Kumar Gala10b35d92005-09-23 14:08:58 -0500926 .cpu_features = CPU_FTRS_7450_20,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000927 .cpu_user_features = COMMON_USER |
928 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000929 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700930 .icache_bsize = 32,
931 .dcache_bsize = 32,
932 .num_pmcs = 6,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000933 .pmc_type = PPC_PMC_G4,
Andy Fleming555d97a2005-12-15 20:02:04 -0600934 .cpu_setup = __setup_cpu_745x,
Andy Fleming555d97a2005-12-15 20:02:04 -0600935 .oprofile_cpu_type = "ppc/7450",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +0000936 .oprofile_type = PPC_OPROFILE_G4,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100937 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100938 .platform = "ppc7450",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700939 },
940 { /* 7450 2.1 */
941 .pvr_mask = 0xffffffff,
942 .pvr_value = 0x80000201,
943 .cpu_name = "7450",
Kumar Gala10b35d92005-09-23 14:08:58 -0500944 .cpu_features = CPU_FTRS_7450_21,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000945 .cpu_user_features = COMMON_USER |
946 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000947 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700948 .icache_bsize = 32,
949 .dcache_bsize = 32,
950 .num_pmcs = 6,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000951 .pmc_type = PPC_PMC_G4,
Andy Fleming555d97a2005-12-15 20:02:04 -0600952 .cpu_setup = __setup_cpu_745x,
Andy Fleming555d97a2005-12-15 20:02:04 -0600953 .oprofile_cpu_type = "ppc/7450",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +0000954 .oprofile_type = PPC_OPROFILE_G4,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100955 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100956 .platform = "ppc7450",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700957 },
958 { /* 7450 2.3 and newer */
959 .pvr_mask = 0xffff0000,
960 .pvr_value = 0x80000000,
961 .cpu_name = "7450",
Kumar Gala10b35d92005-09-23 14:08:58 -0500962 .cpu_features = CPU_FTRS_7450_23,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000963 .cpu_user_features = COMMON_USER |
964 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000965 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700966 .icache_bsize = 32,
967 .dcache_bsize = 32,
968 .num_pmcs = 6,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000969 .pmc_type = PPC_PMC_G4,
Andy Fleming555d97a2005-12-15 20:02:04 -0600970 .cpu_setup = __setup_cpu_745x,
Andy Fleming555d97a2005-12-15 20:02:04 -0600971 .oprofile_cpu_type = "ppc/7450",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +0000972 .oprofile_type = PPC_OPROFILE_G4,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100973 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100974 .platform = "ppc7450",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700975 },
976 { /* 7455 rev 1.x */
977 .pvr_mask = 0xffffff00,
978 .pvr_value = 0x80010100,
979 .cpu_name = "7455",
Kumar Gala10b35d92005-09-23 14:08:58 -0500980 .cpu_features = CPU_FTRS_7455_1,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000981 .cpu_user_features = COMMON_USER |
982 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +0000983 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700984 .icache_bsize = 32,
985 .dcache_bsize = 32,
986 .num_pmcs = 6,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +1000987 .pmc_type = PPC_PMC_G4,
Andy Fleming555d97a2005-12-15 20:02:04 -0600988 .cpu_setup = __setup_cpu_745x,
Andy Fleming555d97a2005-12-15 20:02:04 -0600989 .oprofile_cpu_type = "ppc/7450",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +0000990 .oprofile_type = PPC_OPROFILE_G4,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +1100991 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +1100992 .platform = "ppc7450",
Linus Torvalds1da177e2005-04-16 15:20:36 -0700993 },
994 { /* 7455 rev 2.0 */
995 .pvr_mask = 0xffffffff,
996 .pvr_value = 0x80010200,
997 .cpu_name = "7455",
Kumar Gala10b35d92005-09-23 14:08:58 -0500998 .cpu_features = CPU_FTRS_7455_20,
Paul Mackerrasfab5db92006-06-07 16:14:40 +1000999 .cpu_user_features = COMMON_USER |
1000 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001001 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001002 .icache_bsize = 32,
1003 .dcache_bsize = 32,
1004 .num_pmcs = 6,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +10001005 .pmc_type = PPC_PMC_G4,
Andy Fleming555d97a2005-12-15 20:02:04 -06001006 .cpu_setup = __setup_cpu_745x,
Andy Fleming555d97a2005-12-15 20:02:04 -06001007 .oprofile_cpu_type = "ppc/7450",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +00001008 .oprofile_type = PPC_OPROFILE_G4,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001009 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001010 .platform = "ppc7450",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001011 },
1012 { /* 7455 others */
1013 .pvr_mask = 0xffff0000,
1014 .pvr_value = 0x80010000,
1015 .cpu_name = "7455",
Kumar Gala10b35d92005-09-23 14:08:58 -05001016 .cpu_features = CPU_FTRS_7455,
Paul Mackerrasfab5db92006-06-07 16:14:40 +10001017 .cpu_user_features = COMMON_USER |
1018 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001019 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001020 .icache_bsize = 32,
1021 .dcache_bsize = 32,
1022 .num_pmcs = 6,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +10001023 .pmc_type = PPC_PMC_G4,
Andy Fleming555d97a2005-12-15 20:02:04 -06001024 .cpu_setup = __setup_cpu_745x,
Andy Fleming555d97a2005-12-15 20:02:04 -06001025 .oprofile_cpu_type = "ppc/7450",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +00001026 .oprofile_type = PPC_OPROFILE_G4,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001027 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001028 .platform = "ppc7450",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001029 },
1030 { /* 7447/7457 Rev 1.0 */
1031 .pvr_mask = 0xffffffff,
1032 .pvr_value = 0x80020100,
1033 .cpu_name = "7447/7457",
Kumar Gala10b35d92005-09-23 14:08:58 -05001034 .cpu_features = CPU_FTRS_7447_10,
Paul Mackerrasfab5db92006-06-07 16:14:40 +10001035 .cpu_user_features = COMMON_USER |
1036 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001037 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001038 .icache_bsize = 32,
1039 .dcache_bsize = 32,
1040 .num_pmcs = 6,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +10001041 .pmc_type = PPC_PMC_G4,
Andy Fleming555d97a2005-12-15 20:02:04 -06001042 .cpu_setup = __setup_cpu_745x,
Andy Fleming555d97a2005-12-15 20:02:04 -06001043 .oprofile_cpu_type = "ppc/7450",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +00001044 .oprofile_type = PPC_OPROFILE_G4,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001045 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001046 .platform = "ppc7450",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001047 },
1048 { /* 7447/7457 Rev 1.1 */
1049 .pvr_mask = 0xffffffff,
1050 .pvr_value = 0x80020101,
1051 .cpu_name = "7447/7457",
Kumar Gala10b35d92005-09-23 14:08:58 -05001052 .cpu_features = CPU_FTRS_7447_10,
Paul Mackerrasfab5db92006-06-07 16:14:40 +10001053 .cpu_user_features = COMMON_USER |
1054 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001055 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001056 .icache_bsize = 32,
1057 .dcache_bsize = 32,
1058 .num_pmcs = 6,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +10001059 .pmc_type = PPC_PMC_G4,
Andy Fleming555d97a2005-12-15 20:02:04 -06001060 .cpu_setup = __setup_cpu_745x,
Andy Fleming555d97a2005-12-15 20:02:04 -06001061 .oprofile_cpu_type = "ppc/7450",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +00001062 .oprofile_type = PPC_OPROFILE_G4,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001063 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001064 .platform = "ppc7450",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001065 },
1066 { /* 7447/7457 Rev 1.2 and later */
1067 .pvr_mask = 0xffff0000,
1068 .pvr_value = 0x80020000,
1069 .cpu_name = "7447/7457",
Kumar Gala10b35d92005-09-23 14:08:58 -05001070 .cpu_features = CPU_FTRS_7447,
Paul Mackerrasfab5db92006-06-07 16:14:40 +10001071 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001072 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001073 .icache_bsize = 32,
1074 .dcache_bsize = 32,
1075 .num_pmcs = 6,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +10001076 .pmc_type = PPC_PMC_G4,
Andy Fleming555d97a2005-12-15 20:02:04 -06001077 .cpu_setup = __setup_cpu_745x,
Andy Fleming555d97a2005-12-15 20:02:04 -06001078 .oprofile_cpu_type = "ppc/7450",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +00001079 .oprofile_type = PPC_OPROFILE_G4,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001080 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001081 .platform = "ppc7450",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001082 },
1083 { /* 7447A */
1084 .pvr_mask = 0xffff0000,
1085 .pvr_value = 0x80030000,
1086 .cpu_name = "7447A",
Kumar Gala10b35d92005-09-23 14:08:58 -05001087 .cpu_features = CPU_FTRS_7447A,
Paul Mackerrasfab5db92006-06-07 16:14:40 +10001088 .cpu_user_features = COMMON_USER |
1089 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001090 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001091 .icache_bsize = 32,
1092 .dcache_bsize = 32,
1093 .num_pmcs = 6,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +10001094 .pmc_type = PPC_PMC_G4,
Andy Fleming555d97a2005-12-15 20:02:04 -06001095 .cpu_setup = __setup_cpu_745x,
Andy Fleming555d97a2005-12-15 20:02:04 -06001096 .oprofile_cpu_type = "ppc/7450",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +00001097 .oprofile_type = PPC_OPROFILE_G4,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001098 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001099 .platform = "ppc7450",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001100 },
Kumar Galabbde6302005-09-03 15:55:55 -07001101 { /* 7448 */
1102 .pvr_mask = 0xffff0000,
1103 .pvr_value = 0x80040000,
1104 .cpu_name = "7448",
James.Yang3d372542007-05-02 16:34:43 -05001105 .cpu_features = CPU_FTRS_7448,
Paul Mackerrasfab5db92006-06-07 16:14:40 +10001106 .cpu_user_features = COMMON_USER |
1107 PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001108 .mmu_features = MMU_FTR_HPTE_TABLE | MMU_FTR_USE_HIGH_BATS,
Kumar Galabbde6302005-09-03 15:55:55 -07001109 .icache_bsize = 32,
1110 .dcache_bsize = 32,
1111 .num_pmcs = 6,
Benjamin Herrenschmidtb950bdd2008-08-18 14:23:51 +10001112 .pmc_type = PPC_PMC_G4,
Andy Fleming555d97a2005-12-15 20:02:04 -06001113 .cpu_setup = __setup_cpu_745x,
Andy Fleming555d97a2005-12-15 20:02:04 -06001114 .oprofile_cpu_type = "ppc/7450",
Andy Whitcroft7a45fb12006-01-13 12:35:49 +00001115 .oprofile_type = PPC_OPROFILE_G4,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001116 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001117 .platform = "ppc7450",
Kumar Galabbde6302005-09-03 15:55:55 -07001118 },
Linus Torvalds1da177e2005-04-16 15:20:36 -07001119 { /* 82xx (8240, 8245, 8260 are all 603e cores) */
1120 .pvr_mask = 0x7fff0000,
1121 .pvr_value = 0x00810000,
1122 .cpu_name = "82xx",
Kumar Gala10b35d92005-09-23 14:08:58 -05001123 .cpu_features = CPU_FTRS_82XX,
Stephen Rothwell49209602005-10-12 15:55:09 +10001124 .cpu_user_features = COMMON_USER,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001125 .mmu_features = 0,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001126 .icache_bsize = 32,
1127 .dcache_bsize = 32,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001128 .cpu_setup = __setup_cpu_603,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001129 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001130 .platform = "ppc603",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001131 },
1132 { /* All G2_LE (603e core, plus some) have the same pvr */
1133 .pvr_mask = 0x7fff0000,
1134 .pvr_value = 0x00820000,
1135 .cpu_name = "G2_LE",
Kumar Gala10b35d92005-09-23 14:08:58 -05001136 .cpu_features = CPU_FTRS_G2_LE,
Stephen Rothwell49209602005-10-12 15:55:09 +10001137 .cpu_user_features = COMMON_USER,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001138 .mmu_features = MMU_FTR_USE_HIGH_BATS,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001139 .icache_bsize = 32,
1140 .dcache_bsize = 32,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001141 .cpu_setup = __setup_cpu_603,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001142 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001143 .platform = "ppc603",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001144 },
Kim Phillips6c4a2502006-10-02 20:10:24 -05001145 { /* e300c1 (a 603e core, plus some) on 83xx */
Linus Torvalds1da177e2005-04-16 15:20:36 -07001146 .pvr_mask = 0x7fff0000,
1147 .pvr_value = 0x00830000,
Kim Phillips6c4a2502006-10-02 20:10:24 -05001148 .cpu_name = "e300c1",
Kumar Gala10b35d92005-09-23 14:08:58 -05001149 .cpu_features = CPU_FTRS_E300,
Stephen Rothwell49209602005-10-12 15:55:09 +10001150 .cpu_user_features = COMMON_USER,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001151 .mmu_features = MMU_FTR_USE_HIGH_BATS,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001152 .icache_bsize = 32,
1153 .dcache_bsize = 32,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001154 .cpu_setup = __setup_cpu_603,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001155 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001156 .platform = "ppc603",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001157 },
Kim Phillips6c4a2502006-10-02 20:10:24 -05001158 { /* e300c2 (an e300c1 core, plus some, minus FPU) on 83xx */
1159 .pvr_mask = 0x7fff0000,
1160 .pvr_value = 0x00840000,
1161 .cpu_name = "e300c2",
Kim Phillipsaa42c692006-12-08 02:43:30 -06001162 .cpu_features = CPU_FTRS_E300C2,
Kim Phillips6c4a2502006-10-02 20:10:24 -05001163 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
Kumar Gala2319f122009-03-19 03:55:41 +00001164 .mmu_features = MMU_FTR_USE_HIGH_BATS |
1165 MMU_FTR_NEED_DTLB_SW_LRU,
Kim Phillips6c4a2502006-10-02 20:10:24 -05001166 .icache_bsize = 32,
1167 .dcache_bsize = 32,
1168 .cpu_setup = __setup_cpu_603,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001169 .machine_check = machine_check_generic,
Kim Phillips6c4a2502006-10-02 20:10:24 -05001170 .platform = "ppc603",
1171 },
Li Yanga58d5242007-10-19 19:38:42 +08001172 { /* e300c3 (e300c1, plus one IU, half cache size) on 83xx */
Scott Wood57933f82006-12-01 12:57:05 -06001173 .pvr_mask = 0x7fff0000,
1174 .pvr_value = 0x00850000,
1175 .cpu_name = "e300c3",
1176 .cpu_features = CPU_FTRS_E300,
1177 .cpu_user_features = COMMON_USER,
Kumar Gala2319f122009-03-19 03:55:41 +00001178 .mmu_features = MMU_FTR_USE_HIGH_BATS |
1179 MMU_FTR_NEED_DTLB_SW_LRU,
Scott Wood57933f82006-12-01 12:57:05 -06001180 .icache_bsize = 32,
1181 .dcache_bsize = 32,
1182 .cpu_setup = __setup_cpu_603,
Esben Haabendal974ff4e2015-01-06 12:26:59 +01001183 .machine_check = machine_check_generic,
Andy Fleming1347a2c12008-02-04 18:28:07 -06001184 .num_pmcs = 4,
1185 .oprofile_cpu_type = "ppc/e300",
1186 .oprofile_type = PPC_OPROFILE_FSL_EMB,
Scott Wood57933f82006-12-01 12:57:05 -06001187 .platform = "ppc603",
1188 },
Li Yanga58d5242007-10-19 19:38:42 +08001189 { /* e300c4 (e300c1, plus one IU) */
1190 .pvr_mask = 0x7fff0000,
1191 .pvr_value = 0x00860000,
1192 .cpu_name = "e300c4",
1193 .cpu_features = CPU_FTRS_E300,
1194 .cpu_user_features = COMMON_USER,
Kumar Gala2319f122009-03-19 03:55:41 +00001195 .mmu_features = MMU_FTR_USE_HIGH_BATS |
1196 MMU_FTR_NEED_DTLB_SW_LRU,
Li Yanga58d5242007-10-19 19:38:42 +08001197 .icache_bsize = 32,
1198 .dcache_bsize = 32,
1199 .cpu_setup = __setup_cpu_603,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001200 .machine_check = machine_check_generic,
Andy Fleming1347a2c12008-02-04 18:28:07 -06001201 .num_pmcs = 4,
1202 .oprofile_cpu_type = "ppc/e300",
1203 .oprofile_type = PPC_OPROFILE_FSL_EMB,
Li Yanga58d5242007-10-19 19:38:42 +08001204 .platform = "ppc603",
1205 },
Linus Torvalds1da177e2005-04-16 15:20:36 -07001206 { /* default match, we assume split I/D cache & TB (non-601)... */
1207 .pvr_mask = 0x00000000,
1208 .pvr_value = 0x00000000,
1209 .cpu_name = "(generic PPC)",
Kumar Gala10b35d92005-09-23 14:08:58 -05001210 .cpu_features = CPU_FTRS_CLASSIC32,
Stephen Rothwell49209602005-10-12 15:55:09 +10001211 .cpu_user_features = COMMON_USER,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001212 .mmu_features = MMU_FTR_HPTE_TABLE,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001213 .icache_bsize = 32,
1214 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001215 .machine_check = machine_check_generic,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001216 .platform = "ppc603",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001217 },
Michael Ellerman1e07a0a2014-07-10 12:29:26 +10001218#endif /* CONFIG_PPC_BOOK3S_32 */
Linus Torvalds1da177e2005-04-16 15:20:36 -07001219#ifdef CONFIG_8xx
1220 { /* 8xx */
1221 .pvr_mask = 0xffff0000,
1222 .pvr_value = 0x00500000,
1223 .cpu_name = "8xx",
1224 /* CPU_FTR_MAYBE_CAN_DOZE is possible,
1225 * if the 8xx code is there.... */
Kumar Gala10b35d92005-09-23 14:08:58 -05001226 .cpu_features = CPU_FTRS_8XX,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001227 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001228 .mmu_features = MMU_FTR_TYPE_8xx,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001229 .icache_bsize = 16,
1230 .dcache_bsize = 16,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001231 .platform = "ppc823",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001232 },
1233#endif /* CONFIG_8xx */
1234#ifdef CONFIG_40x
1235 { /* 403GC */
1236 .pvr_mask = 0xffffff00,
1237 .pvr_value = 0x00200200,
1238 .cpu_name = "403GC",
Kumar Gala10b35d92005-09-23 14:08:58 -05001239 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001240 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001241 .mmu_features = MMU_FTR_TYPE_40x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001242 .icache_bsize = 16,
1243 .dcache_bsize = 16,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001244 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001245 .platform = "ppc403",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001246 },
1247 { /* 403GCX */
1248 .pvr_mask = 0xffffff00,
1249 .pvr_value = 0x00201400,
1250 .cpu_name = "403GCX",
Kumar Gala10b35d92005-09-23 14:08:58 -05001251 .cpu_features = CPU_FTRS_40X,
Paul Mackerras98599012005-10-22 16:51:34 +10001252 .cpu_user_features = PPC_FEATURE_32 |
1253 PPC_FEATURE_HAS_MMU | PPC_FEATURE_NO_TB,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001254 .mmu_features = MMU_FTR_TYPE_40x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001255 .icache_bsize = 16,
1256 .dcache_bsize = 16,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001257 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001258 .platform = "ppc403",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001259 },
1260 { /* 403G ?? */
1261 .pvr_mask = 0xffff0000,
1262 .pvr_value = 0x00200000,
1263 .cpu_name = "403G ??",
Kumar Gala10b35d92005-09-23 14:08:58 -05001264 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001265 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001266 .mmu_features = MMU_FTR_TYPE_40x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001267 .icache_bsize = 16,
1268 .dcache_bsize = 16,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001269 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001270 .platform = "ppc403",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001271 },
1272 { /* 405GP */
1273 .pvr_mask = 0xffff0000,
1274 .pvr_value = 0x40110000,
1275 .cpu_name = "405GP",
Kumar Gala10b35d92005-09-23 14:08:58 -05001276 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001277 .cpu_user_features = PPC_FEATURE_32 |
1278 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001279 .mmu_features = MMU_FTR_TYPE_40x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001280 .icache_bsize = 32,
1281 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001282 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001283 .platform = "ppc405",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001284 },
1285 { /* STB 03xxx */
1286 .pvr_mask = 0xffff0000,
1287 .pvr_value = 0x40130000,
1288 .cpu_name = "STB03xxx",
Kumar Gala10b35d92005-09-23 14:08:58 -05001289 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001290 .cpu_user_features = PPC_FEATURE_32 |
1291 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001292 .mmu_features = MMU_FTR_TYPE_40x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001293 .icache_bsize = 32,
1294 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001295 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001296 .platform = "ppc405",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001297 },
1298 { /* STB 04xxx */
1299 .pvr_mask = 0xffff0000,
1300 .pvr_value = 0x41810000,
1301 .cpu_name = "STB04xxx",
Kumar Gala10b35d92005-09-23 14:08:58 -05001302 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001303 .cpu_user_features = PPC_FEATURE_32 |
1304 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001305 .mmu_features = MMU_FTR_TYPE_40x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001306 .icache_bsize = 32,
1307 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001308 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001309 .platform = "ppc405",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001310 },
1311 { /* NP405L */
1312 .pvr_mask = 0xffff0000,
1313 .pvr_value = 0x41610000,
1314 .cpu_name = "NP405L",
Kumar Gala10b35d92005-09-23 14:08:58 -05001315 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001316 .cpu_user_features = PPC_FEATURE_32 |
1317 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001318 .mmu_features = MMU_FTR_TYPE_40x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001319 .icache_bsize = 32,
1320 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001321 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001322 .platform = "ppc405",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001323 },
1324 { /* NP4GS3 */
1325 .pvr_mask = 0xffff0000,
1326 .pvr_value = 0x40B10000,
1327 .cpu_name = "NP4GS3",
Kumar Gala10b35d92005-09-23 14:08:58 -05001328 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001329 .cpu_user_features = PPC_FEATURE_32 |
1330 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001331 .mmu_features = MMU_FTR_TYPE_40x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001332 .icache_bsize = 32,
1333 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001334 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001335 .platform = "ppc405",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001336 },
1337 { /* NP405H */
1338 .pvr_mask = 0xffff0000,
1339 .pvr_value = 0x41410000,
1340 .cpu_name = "NP405H",
Kumar Gala10b35d92005-09-23 14:08:58 -05001341 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001342 .cpu_user_features = PPC_FEATURE_32 |
1343 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001344 .mmu_features = MMU_FTR_TYPE_40x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001345 .icache_bsize = 32,
1346 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001347 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001348 .platform = "ppc405",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001349 },
1350 { /* 405GPr */
1351 .pvr_mask = 0xffff0000,
1352 .pvr_value = 0x50910000,
1353 .cpu_name = "405GPr",
Kumar Gala10b35d92005-09-23 14:08:58 -05001354 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001355 .cpu_user_features = PPC_FEATURE_32 |
1356 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001357 .mmu_features = MMU_FTR_TYPE_40x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001358 .icache_bsize = 32,
1359 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001360 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001361 .platform = "ppc405",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001362 },
1363 { /* STBx25xx */
1364 .pvr_mask = 0xffff0000,
1365 .pvr_value = 0x51510000,
1366 .cpu_name = "STBx25xx",
Kumar Gala10b35d92005-09-23 14:08:58 -05001367 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001368 .cpu_user_features = PPC_FEATURE_32 |
1369 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001370 .mmu_features = MMU_FTR_TYPE_40x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001371 .icache_bsize = 32,
1372 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001373 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001374 .platform = "ppc405",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001375 },
1376 { /* 405LP */
1377 .pvr_mask = 0xffff0000,
1378 .pvr_value = 0x41F10000,
1379 .cpu_name = "405LP",
Kumar Gala10b35d92005-09-23 14:08:58 -05001380 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001381 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001382 .mmu_features = MMU_FTR_TYPE_40x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001383 .icache_bsize = 32,
1384 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001385 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001386 .platform = "ppc405",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001387 },
1388 { /* Xilinx Virtex-II Pro */
Grant C. Likely72646c72006-01-19 01:13:20 -07001389 .pvr_mask = 0xfffff000,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001390 .pvr_value = 0x20010000,
1391 .cpu_name = "Virtex-II Pro",
Kumar Gala10b35d92005-09-23 14:08:58 -05001392 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001393 .cpu_user_features = PPC_FEATURE_32 |
1394 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001395 .mmu_features = MMU_FTR_TYPE_40x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001396 .icache_bsize = 32,
1397 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001398 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001399 .platform = "ppc405",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001400 },
Grant C. Likely72646c72006-01-19 01:13:20 -07001401 { /* Xilinx Virtex-4 FX */
1402 .pvr_mask = 0xfffff000,
1403 .pvr_value = 0x20011000,
1404 .cpu_name = "Virtex-4 FX",
1405 .cpu_features = CPU_FTRS_40X,
1406 .cpu_user_features = PPC_FEATURE_32 |
1407 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001408 .mmu_features = MMU_FTR_TYPE_40x,
Grant C. Likely72646c72006-01-19 01:13:20 -07001409 .icache_bsize = 32,
1410 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001411 .machine_check = machine_check_4xx,
Peter Bergner838fdb42006-09-14 14:18:38 -05001412 .platform = "ppc405",
Grant C. Likely72646c72006-01-19 01:13:20 -07001413 },
Eugene Suroveginad95d602005-06-07 13:22:09 -07001414 { /* 405EP */
1415 .pvr_mask = 0xffff0000,
1416 .pvr_value = 0x51210000,
1417 .cpu_name = "405EP",
Kumar Gala10b35d92005-09-23 14:08:58 -05001418 .cpu_features = CPU_FTRS_40X,
Eugene Suroveginad95d602005-06-07 13:22:09 -07001419 .cpu_user_features = PPC_FEATURE_32 |
1420 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001421 .mmu_features = MMU_FTR_TYPE_40x,
Eugene Suroveginad95d602005-06-07 13:22:09 -07001422 .icache_bsize = 32,
1423 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001424 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001425 .platform = "ppc405",
Eugene Suroveginad95d602005-06-07 13:22:09 -07001426 },
Lee Nipperff349102010-07-09 01:17:16 +00001427 { /* 405EX Rev. A/B with Security */
1428 .pvr_mask = 0xffff000f,
1429 .pvr_value = 0x12910007,
1430 .cpu_name = "405EX Rev. A/B",
Stefan Roese5d8476c2007-10-11 22:08:14 +10001431 .cpu_features = CPU_FTRS_40X,
1432 .cpu_user_features = PPC_FEATURE_32 |
1433 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001434 .mmu_features = MMU_FTR_TYPE_40x,
Stefan Roese5d8476c2007-10-11 22:08:14 +10001435 .icache_bsize = 32,
1436 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001437 .machine_check = machine_check_4xx,
Stefan Roese5d8476c2007-10-11 22:08:14 +10001438 .platform = "ppc405",
1439 },
Lee Nipperff349102010-07-09 01:17:16 +00001440 { /* 405EX Rev. C without Security */
1441 .pvr_mask = 0xffff000f,
1442 .pvr_value = 0x1291000d,
1443 .cpu_name = "405EX Rev. C",
1444 .cpu_features = CPU_FTRS_40X,
1445 .cpu_user_features = PPC_FEATURE_32 |
1446 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1447 .mmu_features = MMU_FTR_TYPE_40x,
1448 .icache_bsize = 32,
1449 .dcache_bsize = 32,
1450 .machine_check = machine_check_4xx,
1451 .platform = "ppc405",
1452 },
1453 { /* 405EX Rev. C with Security */
1454 .pvr_mask = 0xffff000f,
1455 .pvr_value = 0x1291000f,
1456 .cpu_name = "405EX Rev. C",
1457 .cpu_features = CPU_FTRS_40X,
1458 .cpu_user_features = PPC_FEATURE_32 |
1459 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1460 .mmu_features = MMU_FTR_TYPE_40x,
1461 .icache_bsize = 32,
1462 .dcache_bsize = 32,
1463 .machine_check = machine_check_4xx,
1464 .platform = "ppc405",
1465 },
1466 { /* 405EX Rev. D without Security */
1467 .pvr_mask = 0xffff000f,
1468 .pvr_value = 0x12910003,
1469 .cpu_name = "405EX Rev. D",
1470 .cpu_features = CPU_FTRS_40X,
1471 .cpu_user_features = PPC_FEATURE_32 |
1472 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1473 .mmu_features = MMU_FTR_TYPE_40x,
1474 .icache_bsize = 32,
1475 .dcache_bsize = 32,
1476 .machine_check = machine_check_4xx,
1477 .platform = "ppc405",
1478 },
1479 { /* 405EX Rev. D with Security */
1480 .pvr_mask = 0xffff000f,
1481 .pvr_value = 0x12910005,
1482 .cpu_name = "405EX Rev. D",
1483 .cpu_features = CPU_FTRS_40X,
1484 .cpu_user_features = PPC_FEATURE_32 |
1485 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1486 .mmu_features = MMU_FTR_TYPE_40x,
1487 .icache_bsize = 32,
1488 .dcache_bsize = 32,
1489 .machine_check = machine_check_4xx,
1490 .platform = "ppc405",
1491 },
1492 { /* 405EXr Rev. A/B without Security */
1493 .pvr_mask = 0xffff000f,
1494 .pvr_value = 0x12910001,
1495 .cpu_name = "405EXr Rev. A/B",
1496 .cpu_features = CPU_FTRS_40X,
1497 .cpu_user_features = PPC_FEATURE_32 |
1498 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1499 .mmu_features = MMU_FTR_TYPE_40x,
1500 .icache_bsize = 32,
1501 .dcache_bsize = 32,
1502 .machine_check = machine_check_4xx,
1503 .platform = "ppc405",
1504 },
1505 { /* 405EXr Rev. C without Security */
1506 .pvr_mask = 0xffff000f,
1507 .pvr_value = 0x12910009,
1508 .cpu_name = "405EXr Rev. C",
1509 .cpu_features = CPU_FTRS_40X,
1510 .cpu_user_features = PPC_FEATURE_32 |
1511 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1512 .mmu_features = MMU_FTR_TYPE_40x,
1513 .icache_bsize = 32,
1514 .dcache_bsize = 32,
1515 .machine_check = machine_check_4xx,
1516 .platform = "ppc405",
1517 },
1518 { /* 405EXr Rev. C with Security */
1519 .pvr_mask = 0xffff000f,
1520 .pvr_value = 0x1291000b,
1521 .cpu_name = "405EXr Rev. C",
1522 .cpu_features = CPU_FTRS_40X,
1523 .cpu_user_features = PPC_FEATURE_32 |
1524 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1525 .mmu_features = MMU_FTR_TYPE_40x,
1526 .icache_bsize = 32,
1527 .dcache_bsize = 32,
1528 .machine_check = machine_check_4xx,
1529 .platform = "ppc405",
1530 },
1531 { /* 405EXr Rev. D without Security */
1532 .pvr_mask = 0xffff000f,
Stefan Roeseb676d842008-01-15 18:09:15 +11001533 .pvr_value = 0x12910000,
Lee Nipperff349102010-07-09 01:17:16 +00001534 .cpu_name = "405EXr Rev. D",
1535 .cpu_features = CPU_FTRS_40X,
1536 .cpu_user_features = PPC_FEATURE_32 |
1537 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1538 .mmu_features = MMU_FTR_TYPE_40x,
1539 .icache_bsize = 32,
1540 .dcache_bsize = 32,
1541 .machine_check = machine_check_4xx,
1542 .platform = "ppc405",
1543 },
1544 { /* 405EXr Rev. D with Security */
1545 .pvr_mask = 0xffff000f,
1546 .pvr_value = 0x12910002,
1547 .cpu_name = "405EXr Rev. D",
Stefan Roeseb676d842008-01-15 18:09:15 +11001548 .cpu_features = CPU_FTRS_40X,
1549 .cpu_user_features = PPC_FEATURE_32 |
1550 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001551 .mmu_features = MMU_FTR_TYPE_40x,
Stefan Roeseb676d842008-01-15 18:09:15 +11001552 .icache_bsize = 32,
1553 .dcache_bsize = 32,
1554 .machine_check = machine_check_4xx,
1555 .platform = "ppc405",
1556 },
Josh Boyerdf8f71f2008-10-09 08:56:38 -04001557 {
1558 /* 405EZ */
1559 .pvr_mask = 0xffff0000,
1560 .pvr_value = 0x41510000,
1561 .cpu_name = "405EZ",
1562 .cpu_features = CPU_FTRS_40X,
1563 .cpu_user_features = PPC_FEATURE_32 |
1564 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001565 .mmu_features = MMU_FTR_TYPE_40x,
Josh Boyerdf8f71f2008-10-09 08:56:38 -04001566 .icache_bsize = 32,
1567 .dcache_bsize = 32,
1568 .machine_check = machine_check_4xx,
1569 .platform = "ppc405",
1570 },
Tanmay Inamdard5b9ee72011-11-28 21:01:41 +00001571 { /* APM8018X */
1572 .pvr_mask = 0xffff0000,
1573 .pvr_value = 0x7ff11432,
1574 .cpu_name = "APM8018X",
1575 .cpu_features = CPU_FTRS_40X,
1576 .cpu_user_features = PPC_FEATURE_32 |
1577 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
1578 .mmu_features = MMU_FTR_TYPE_40x,
1579 .icache_bsize = 32,
1580 .dcache_bsize = 32,
1581 .machine_check = machine_check_4xx,
1582 .platform = "ppc405",
1583 },
Benjamin Herrenschmidt76bc080e2008-05-05 15:22:27 +10001584 { /* default match */
1585 .pvr_mask = 0x00000000,
1586 .pvr_value = 0x00000000,
1587 .cpu_name = "(generic 40x PPC)",
1588 .cpu_features = CPU_FTRS_40X,
1589 .cpu_user_features = PPC_FEATURE_32 |
1590 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001591 .mmu_features = MMU_FTR_TYPE_40x,
Benjamin Herrenschmidt76bc080e2008-05-05 15:22:27 +10001592 .icache_bsize = 32,
1593 .dcache_bsize = 32,
1594 .machine_check = machine_check_4xx,
1595 .platform = "ppc405",
1596 }
Linus Torvalds1da177e2005-04-16 15:20:36 -07001597
1598#endif /* CONFIG_40x */
1599#ifdef CONFIG_44x
Matt Porterc9cf73a2005-07-31 22:34:52 -07001600 {
1601 .pvr_mask = 0xf0000fff,
1602 .pvr_value = 0x40000850,
Valentine Barshakd1dfc352007-10-26 04:16:40 +10001603 .cpu_name = "440GR Rev. A",
1604 .cpu_features = CPU_FTRS_44X,
1605 .cpu_user_features = COMMON_USER_BOOKE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001606 .mmu_features = MMU_FTR_TYPE_44x,
Valentine Barshakd1dfc352007-10-26 04:16:40 +10001607 .icache_bsize = 32,
1608 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001609 .machine_check = machine_check_4xx,
Valentine Barshakd1dfc352007-10-26 04:16:40 +10001610 .platform = "ppc440",
1611 },
1612 { /* Use logical PVR for 440EP (logical pvr = pvr | 0x8) */
1613 .pvr_mask = 0xf0000fff,
1614 .pvr_value = 0x40000858,
Matt Porterc9cf73a2005-07-31 22:34:52 -07001615 .cpu_name = "440EP Rev. A",
Kumar Gala10b35d92005-09-23 14:08:58 -05001616 .cpu_features = CPU_FTRS_44X,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001617 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001618 .mmu_features = MMU_FTR_TYPE_44x,
Matt Porterc9cf73a2005-07-31 22:34:52 -07001619 .icache_bsize = 32,
1620 .dcache_bsize = 32,
Valentine Barshak81127532007-09-22 00:46:57 +10001621 .cpu_setup = __setup_cpu_440ep,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001622 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001623 .platform = "ppc440",
Matt Porterc9cf73a2005-07-31 22:34:52 -07001624 },
1625 {
1626 .pvr_mask = 0xf0000fff,
1627 .pvr_value = 0x400008d3,
Valentine Barshakd1dfc352007-10-26 04:16:40 +10001628 .cpu_name = "440GR Rev. B",
1629 .cpu_features = CPU_FTRS_44X,
1630 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001631 .mmu_features = MMU_FTR_TYPE_44x,
Valentine Barshakd1dfc352007-10-26 04:16:40 +10001632 .icache_bsize = 32,
1633 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001634 .machine_check = machine_check_4xx,
Valentine Barshakd1dfc352007-10-26 04:16:40 +10001635 .platform = "ppc440",
1636 },
Sean MacLennan3f8fc3e2008-01-10 07:25:58 +11001637 { /* Matches both physical and logical PVR for 440EP (logical pvr = pvr | 0x8) */
1638 .pvr_mask = 0xf0000ff7,
1639 .pvr_value = 0x400008d4,
1640 .cpu_name = "440EP Rev. C",
1641 .cpu_features = CPU_FTRS_44X,
1642 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001643 .mmu_features = MMU_FTR_TYPE_44x,
Sean MacLennan3f8fc3e2008-01-10 07:25:58 +11001644 .icache_bsize = 32,
1645 .dcache_bsize = 32,
1646 .cpu_setup = __setup_cpu_440ep,
1647 .machine_check = machine_check_4xx,
1648 .platform = "ppc440",
1649 },
Valentine Barshakd1dfc352007-10-26 04:16:40 +10001650 { /* Use logical PVR for 440EP (logical pvr = pvr | 0x8) */
1651 .pvr_mask = 0xf0000fff,
1652 .pvr_value = 0x400008db,
Matt Porterc9cf73a2005-07-31 22:34:52 -07001653 .cpu_name = "440EP Rev. B",
Kumar Gala10b35d92005-09-23 14:08:58 -05001654 .cpu_features = CPU_FTRS_44X,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001655 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001656 .mmu_features = MMU_FTR_TYPE_44x,
Matt Porterc9cf73a2005-07-31 22:34:52 -07001657 .icache_bsize = 32,
1658 .dcache_bsize = 32,
Valentine Barshak81127532007-09-22 00:46:57 +10001659 .cpu_setup = __setup_cpu_440ep,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001660 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001661 .platform = "ppc440",
Matt Porterc9cf73a2005-07-31 22:34:52 -07001662 },
Valentine Barshak15fc9932007-08-29 17:40:30 +04001663 { /* 440GRX */
1664 .pvr_mask = 0xf0000ffb,
Valentine Barshakd1dfc352007-10-26 04:16:40 +10001665 .pvr_value = 0x200008D0,
Valentine Barshak15fc9932007-08-29 17:40:30 +04001666 .cpu_name = "440GRX",
1667 .cpu_features = CPU_FTRS_44X,
1668 .cpu_user_features = COMMON_USER_BOOKE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001669 .mmu_features = MMU_FTR_TYPE_44x,
Valentine Barshak15fc9932007-08-29 17:40:30 +04001670 .icache_bsize = 32,
1671 .dcache_bsize = 32,
Valentine Barshak340ffd22007-09-22 00:50:09 +10001672 .cpu_setup = __setup_cpu_440grx,
Valentine Barshakb2be3b12007-12-22 03:22:23 +11001673 .machine_check = machine_check_440A,
Valentine Barshak340ffd22007-09-22 00:50:09 +10001674 .platform = "ppc440",
Valentine Barshak15fc9932007-08-29 17:40:30 +04001675 },
Valentine Barshakd1dfc352007-10-26 04:16:40 +10001676 { /* Use logical PVR for 440EPx (logical pvr = pvr | 0x8) */
1677 .pvr_mask = 0xf0000ffb,
1678 .pvr_value = 0x200008D8,
1679 .cpu_name = "440EPX",
1680 .cpu_features = CPU_FTRS_44X,
1681 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001682 .mmu_features = MMU_FTR_TYPE_44x,
Valentine Barshakd1dfc352007-10-26 04:16:40 +10001683 .icache_bsize = 32,
1684 .dcache_bsize = 32,
1685 .cpu_setup = __setup_cpu_440epx,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001686 .machine_check = machine_check_440A,
Valentine Barshakd1dfc352007-10-26 04:16:40 +10001687 .platform = "ppc440",
1688 },
Stephen Rothwell49209602005-10-12 15:55:09 +10001689 { /* 440GP Rev. B */
Linus Torvalds1da177e2005-04-16 15:20:36 -07001690 .pvr_mask = 0xf0000fff,
1691 .pvr_value = 0x40000440,
1692 .cpu_name = "440GP Rev. B",
Kumar Gala10b35d92005-09-23 14:08:58 -05001693 .cpu_features = CPU_FTRS_44X,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001694 .cpu_user_features = COMMON_USER_BOOKE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001695 .mmu_features = MMU_FTR_TYPE_44x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001696 .icache_bsize = 32,
1697 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001698 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001699 .platform = "ppc440gp",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001700 },
Stephen Rothwell49209602005-10-12 15:55:09 +10001701 { /* 440GP Rev. C */
Linus Torvalds1da177e2005-04-16 15:20:36 -07001702 .pvr_mask = 0xf0000fff,
1703 .pvr_value = 0x40000481,
1704 .cpu_name = "440GP Rev. C",
Kumar Gala10b35d92005-09-23 14:08:58 -05001705 .cpu_features = CPU_FTRS_44X,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001706 .cpu_user_features = COMMON_USER_BOOKE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001707 .mmu_features = MMU_FTR_TYPE_44x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001708 .icache_bsize = 32,
1709 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001710 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001711 .platform = "ppc440gp",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001712 },
1713 { /* 440GX Rev. A */
1714 .pvr_mask = 0xf0000fff,
1715 .pvr_value = 0x50000850,
1716 .cpu_name = "440GX Rev. A",
Kumar Gala10b35d92005-09-23 14:08:58 -05001717 .cpu_features = CPU_FTRS_44X,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001718 .cpu_user_features = COMMON_USER_BOOKE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001719 .mmu_features = MMU_FTR_TYPE_44x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001720 .icache_bsize = 32,
1721 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001722 .cpu_setup = __setup_cpu_440gx,
1723 .machine_check = machine_check_440A,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001724 .platform = "ppc440",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001725 },
1726 { /* 440GX Rev. B */
1727 .pvr_mask = 0xf0000fff,
1728 .pvr_value = 0x50000851,
1729 .cpu_name = "440GX Rev. B",
Kumar Gala10b35d92005-09-23 14:08:58 -05001730 .cpu_features = CPU_FTRS_44X,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001731 .cpu_user_features = COMMON_USER_BOOKE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001732 .mmu_features = MMU_FTR_TYPE_44x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001733 .icache_bsize = 32,
1734 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001735 .cpu_setup = __setup_cpu_440gx,
1736 .machine_check = machine_check_440A,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001737 .platform = "ppc440",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001738 },
1739 { /* 440GX Rev. C */
1740 .pvr_mask = 0xf0000fff,
1741 .pvr_value = 0x50000892,
1742 .cpu_name = "440GX Rev. C",
Kumar Gala10b35d92005-09-23 14:08:58 -05001743 .cpu_features = CPU_FTRS_44X,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001744 .cpu_user_features = COMMON_USER_BOOKE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001745 .mmu_features = MMU_FTR_TYPE_44x,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001746 .icache_bsize = 32,
1747 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001748 .cpu_setup = __setup_cpu_440gx,
1749 .machine_check = machine_check_440A,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001750 .platform = "ppc440",
Linus Torvalds1da177e2005-04-16 15:20:36 -07001751 },
Eugene Surovegin9149fb32005-09-03 15:55:40 -07001752 { /* 440GX Rev. F */
1753 .pvr_mask = 0xf0000fff,
1754 .pvr_value = 0x50000894,
1755 .cpu_name = "440GX Rev. F",
Kumar Gala10b35d92005-09-23 14:08:58 -05001756 .cpu_features = CPU_FTRS_44X,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001757 .cpu_user_features = COMMON_USER_BOOKE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001758 .mmu_features = MMU_FTR_TYPE_44x,
Eugene Surovegin9149fb32005-09-03 15:55:40 -07001759 .icache_bsize = 32,
1760 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001761 .cpu_setup = __setup_cpu_440gx,
1762 .machine_check = machine_check_440A,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001763 .platform = "ppc440",
Eugene Surovegin9149fb32005-09-03 15:55:40 -07001764 },
Matt Porter656de7e2005-09-03 15:55:42 -07001765 { /* 440SP Rev. A */
Roland Dreier333e6152007-06-16 05:36:32 +10001766 .pvr_mask = 0xfff00fff,
1767 .pvr_value = 0x53200891,
Matt Porter656de7e2005-09-03 15:55:42 -07001768 .cpu_name = "440SP Rev. A",
Kumar Gala10b35d92005-09-23 14:08:58 -05001769 .cpu_features = CPU_FTRS_44X,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001770 .cpu_user_features = COMMON_USER_BOOKE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001771 .mmu_features = MMU_FTR_TYPE_44x,
Matt Porter656de7e2005-09-03 15:55:42 -07001772 .icache_bsize = 32,
1773 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001774 .machine_check = machine_check_4xx,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001775 .platform = "ppc440",
Matt Porter656de7e2005-09-03 15:55:42 -07001776 },
Roland Dreierb0f7b8b2005-11-07 00:58:13 -08001777 { /* 440SPe Rev. A */
Roland Dreier333e6152007-06-16 05:36:32 +10001778 .pvr_mask = 0xfff00fff,
1779 .pvr_value = 0x53400890,
1780 .cpu_name = "440SPe Rev. A",
1781 .cpu_features = CPU_FTRS_44X,
1782 .cpu_user_features = COMMON_USER_BOOKE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001783 .mmu_features = MMU_FTR_TYPE_44x,
Roland Dreier333e6152007-06-16 05:36:32 +10001784 .icache_bsize = 32,
1785 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001786 .cpu_setup = __setup_cpu_440spe,
1787 .machine_check = machine_check_440A,
Roland Dreier333e6152007-06-16 05:36:32 +10001788 .platform = "ppc440",
1789 },
1790 { /* 440SPe Rev. B */
1791 .pvr_mask = 0xfff00fff,
1792 .pvr_value = 0x53400891,
1793 .cpu_name = "440SPe Rev. B",
Kumar Galaa147c582006-12-08 02:34:38 -06001794 .cpu_features = CPU_FTRS_44X,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001795 .cpu_user_features = COMMON_USER_BOOKE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001796 .mmu_features = MMU_FTR_TYPE_44x,
Roland Dreierb0f7b8b2005-11-07 00:58:13 -08001797 .icache_bsize = 32,
1798 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001799 .cpu_setup = __setup_cpu_440spe,
1800 .machine_check = machine_check_440A,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001801 .platform = "ppc440",
Roland Dreierb0f7b8b2005-11-07 00:58:13 -08001802 },
John Linn23e72372008-07-01 09:42:07 -07001803 { /* 440 in Xilinx Virtex-5 FXT */
1804 .pvr_mask = 0xfffffff0,
1805 .pvr_value = 0x7ff21910,
1806 .cpu_name = "440 in Virtex-5 FXT",
1807 .cpu_features = CPU_FTRS_44X,
1808 .cpu_user_features = COMMON_USER_BOOKE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001809 .mmu_features = MMU_FTR_TYPE_44x,
John Linn23e72372008-07-01 09:42:07 -07001810 .icache_bsize = 32,
1811 .dcache_bsize = 32,
Grant Likely640d17d2008-12-04 05:39:55 +00001812 .cpu_setup = __setup_cpu_440x5,
1813 .machine_check = machine_check_440A,
John Linn23e72372008-07-01 09:42:07 -07001814 .platform = "ppc440",
1815 },
Stefan Roese464076a2008-02-24 08:07:41 +11001816 { /* 460EX */
Stefan Roese20d70342009-07-29 07:04:46 +00001817 .pvr_mask = 0xffff0006,
Stefan Roese464076a2008-02-24 08:07:41 +11001818 .pvr_value = 0x13020002,
1819 .cpu_name = "460EX",
Benjamin Herrenschmidt6d2170b2008-12-18 19:13:22 +00001820 .cpu_features = CPU_FTRS_440x6,
Stefan Roese464076a2008-02-24 08:07:41 +11001821 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001822 .mmu_features = MMU_FTR_TYPE_44x,
Stefan Roese464076a2008-02-24 08:07:41 +11001823 .icache_bsize = 32,
1824 .dcache_bsize = 32,
1825 .cpu_setup = __setup_cpu_460ex,
1826 .machine_check = machine_check_440A,
1827 .platform = "ppc440",
1828 },
Stefan Roese20d70342009-07-29 07:04:46 +00001829 { /* 460EX Rev B */
1830 .pvr_mask = 0xffff0007,
1831 .pvr_value = 0x13020004,
1832 .cpu_name = "460EX Rev. B",
1833 .cpu_features = CPU_FTRS_440x6,
1834 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
1835 .mmu_features = MMU_FTR_TYPE_44x,
1836 .icache_bsize = 32,
1837 .dcache_bsize = 32,
1838 .cpu_setup = __setup_cpu_460ex,
1839 .machine_check = machine_check_440A,
1840 .platform = "ppc440",
1841 },
Stefan Roese464076a2008-02-24 08:07:41 +11001842 { /* 460GT */
Stefan Roese20d70342009-07-29 07:04:46 +00001843 .pvr_mask = 0xffff0006,
Stefan Roese464076a2008-02-24 08:07:41 +11001844 .pvr_value = 0x13020000,
1845 .cpu_name = "460GT",
Benjamin Herrenschmidt6d2170b2008-12-18 19:13:22 +00001846 .cpu_features = CPU_FTRS_440x6,
Josh Boyer939e6222008-06-11 07:52:40 -04001847 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001848 .mmu_features = MMU_FTR_TYPE_44x,
Stefan Roese464076a2008-02-24 08:07:41 +11001849 .icache_bsize = 32,
1850 .dcache_bsize = 32,
Josh Boyer939e6222008-06-11 07:52:40 -04001851 .cpu_setup = __setup_cpu_460gt,
Stefan Roese464076a2008-02-24 08:07:41 +11001852 .machine_check = machine_check_440A,
1853 .platform = "ppc440",
1854 },
Stefan Roese20d70342009-07-29 07:04:46 +00001855 { /* 460GT Rev B */
1856 .pvr_mask = 0xffff0007,
1857 .pvr_value = 0x13020005,
1858 .cpu_name = "460GT Rev. B",
1859 .cpu_features = CPU_FTRS_440x6,
1860 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
1861 .mmu_features = MMU_FTR_TYPE_44x,
1862 .icache_bsize = 32,
1863 .dcache_bsize = 32,
1864 .cpu_setup = __setup_cpu_460gt,
1865 .machine_check = machine_check_440A,
1866 .platform = "ppc440",
1867 },
Madhulika Madishetty6c712092009-02-05 13:31:36 +00001868 { /* 460SX */
1869 .pvr_mask = 0xffffff00,
1870 .pvr_value = 0x13541800,
1871 .cpu_name = "460SX",
1872 .cpu_features = CPU_FTRS_44X,
1873 .cpu_user_features = COMMON_USER_BOOKE,
1874 .mmu_features = MMU_FTR_TYPE_44x,
1875 .icache_bsize = 32,
1876 .dcache_bsize = 32,
1877 .cpu_setup = __setup_cpu_460sx,
1878 .machine_check = machine_check_440A,
1879 .platform = "ppc440",
1880 },
Tirumala Marri6edc3232010-09-13 13:26:11 +00001881 { /* 464 in APM821xx */
Vinh Nguyen Huu Tuong7c801162011-12-20 02:43:34 +00001882 .pvr_mask = 0xfffffff0,
Tirumala Marri6edc3232010-09-13 13:26:11 +00001883 .pvr_value = 0x12C41C80,
1884 .cpu_name = "APM821XX",
1885 .cpu_features = CPU_FTRS_44X,
1886 .cpu_user_features = COMMON_USER_BOOKE |
1887 PPC_FEATURE_HAS_FPU,
1888 .mmu_features = MMU_FTR_TYPE_44x,
1889 .icache_bsize = 32,
1890 .dcache_bsize = 32,
1891 .cpu_setup = __setup_cpu_apm821xx,
1892 .machine_check = machine_check_440A,
1893 .platform = "ppc440",
1894 },
Dave Kleikampc48d0db2011-01-26 06:17:58 +00001895 { /* 476 DD2 core */
1896 .pvr_mask = 0xffffffff,
1897 .pvr_value = 0x11a52080,
Dave Kleikampe7f75ad2010-03-05 10:43:12 +00001898 .cpu_name = "476",
Dave Kleikampc48d0db2011-01-26 06:17:58 +00001899 .cpu_features = CPU_FTRS_47X | CPU_FTR_476_DD2,
Dave Kleikampe7f75ad2010-03-05 10:43:12 +00001900 .cpu_user_features = COMMON_USER_BOOKE |
1901 PPC_FEATURE_HAS_FPU,
1902 .mmu_features = MMU_FTR_TYPE_47x |
1903 MMU_FTR_USE_TLBIVAX_BCAST | MMU_FTR_LOCK_BCAST_INVAL,
1904 .icache_bsize = 32,
1905 .dcache_bsize = 128,
Dave Kleikampfc5e7092010-03-05 03:43:18 +00001906 .machine_check = machine_check_47x,
Dave Kleikampe7f75ad2010-03-05 10:43:12 +00001907 .platform = "ppc470",
1908 },
Tony Breedsdf777bd2011-11-30 21:39:23 +00001909 { /* 476fpe */
1910 .pvr_mask = 0xffff0000,
1911 .pvr_value = 0x7ff50000,
1912 .cpu_name = "476fpe",
1913 .cpu_features = CPU_FTRS_47X | CPU_FTR_476_DD2,
1914 .cpu_user_features = COMMON_USER_BOOKE |
1915 PPC_FEATURE_HAS_FPU,
1916 .mmu_features = MMU_FTR_TYPE_47x |
1917 MMU_FTR_USE_TLBIVAX_BCAST | MMU_FTR_LOCK_BCAST_INVAL,
1918 .icache_bsize = 32,
1919 .dcache_bsize = 128,
1920 .machine_check = machine_check_47x,
1921 .platform = "ppc470",
1922 },
Torez Smithb4e8c8d2010-03-05 10:45:54 +00001923 { /* 476 iss */
1924 .pvr_mask = 0xffff0000,
1925 .pvr_value = 0x00050000,
1926 .cpu_name = "476",
1927 .cpu_features = CPU_FTRS_47X,
1928 .cpu_user_features = COMMON_USER_BOOKE |
1929 PPC_FEATURE_HAS_FPU,
Torez Smithb4e8c8d2010-03-05 10:45:54 +00001930 .mmu_features = MMU_FTR_TYPE_47x |
1931 MMU_FTR_USE_TLBIVAX_BCAST | MMU_FTR_LOCK_BCAST_INVAL,
1932 .icache_bsize = 32,
1933 .dcache_bsize = 128,
1934 .machine_check = machine_check_47x,
1935 .platform = "ppc470",
1936 },
Dave Kleikampc48d0db2011-01-26 06:17:58 +00001937 { /* 476 others */
1938 .pvr_mask = 0xffff0000,
1939 .pvr_value = 0x11a50000,
1940 .cpu_name = "476",
1941 .cpu_features = CPU_FTRS_47X,
1942 .cpu_user_features = COMMON_USER_BOOKE |
1943 PPC_FEATURE_HAS_FPU,
1944 .mmu_features = MMU_FTR_TYPE_47x |
1945 MMU_FTR_USE_TLBIVAX_BCAST | MMU_FTR_LOCK_BCAST_INVAL,
1946 .icache_bsize = 32,
1947 .dcache_bsize = 128,
1948 .machine_check = machine_check_47x,
1949 .platform = "ppc470",
1950 },
Benjamin Herrenschmidt76bc080e2008-05-05 15:22:27 +10001951 { /* default match */
1952 .pvr_mask = 0x00000000,
1953 .pvr_value = 0x00000000,
1954 .cpu_name = "(generic 44x PPC)",
1955 .cpu_features = CPU_FTRS_44X,
1956 .cpu_user_features = COMMON_USER_BOOKE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001957 .mmu_features = MMU_FTR_TYPE_44x,
Benjamin Herrenschmidt76bc080e2008-05-05 15:22:27 +10001958 .icache_bsize = 32,
1959 .dcache_bsize = 32,
1960 .machine_check = machine_check_4xx,
1961 .platform = "ppc440",
1962 }
Linus Torvalds1da177e2005-04-16 15:20:36 -07001963#endif /* CONFIG_44x */
Josh Boyere3e414b2007-12-24 08:44:47 -06001964#ifdef CONFIG_E200
Stephen Rothwell49209602005-10-12 15:55:09 +10001965 { /* e200z5 */
Kumar Gala33d9e9b2005-06-25 14:54:37 -07001966 .pvr_mask = 0xfff00000,
1967 .pvr_value = 0x81000000,
1968 .cpu_name = "e200z5",
1969 /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */
Kumar Gala10b35d92005-09-23 14:08:58 -05001970 .cpu_features = CPU_FTRS_E200,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001971 .cpu_user_features = COMMON_USER_BOOKE |
1972 PPC_FEATURE_HAS_EFP_SINGLE |
Kumar Gala33d9e9b2005-06-25 14:54:37 -07001973 PPC_FEATURE_UNIFIED_CACHE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001974 .mmu_features = MMU_FTR_TYPE_FSL_E,
Kumar Gala33d9e9b2005-06-25 14:54:37 -07001975 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001976 .machine_check = machine_check_e200,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001977 .platform = "ppc5554",
Kumar Gala33d9e9b2005-06-25 14:54:37 -07001978 },
Stephen Rothwell49209602005-10-12 15:55:09 +10001979 { /* e200z6 */
Kumar Gala33d9e9b2005-06-25 14:54:37 -07001980 .pvr_mask = 0xfff00000,
1981 .pvr_value = 0x81100000,
1982 .cpu_name = "e200z6",
1983 /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */
Kumar Gala10b35d92005-09-23 14:08:58 -05001984 .cpu_features = CPU_FTRS_E200,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001985 .cpu_user_features = COMMON_USER_BOOKE |
Kumar Gala5e14d212007-09-13 01:44:20 -05001986 PPC_FEATURE_HAS_SPE_COMP |
1987 PPC_FEATURE_HAS_EFP_SINGLE_COMP |
Kumar Gala33d9e9b2005-06-25 14:54:37 -07001988 PPC_FEATURE_UNIFIED_CACHE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00001989 .mmu_features = MMU_FTR_TYPE_FSL_E,
Kumar Gala33d9e9b2005-06-25 14:54:37 -07001990 .dcache_bsize = 32,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11001991 .machine_check = machine_check_e200,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11001992 .platform = "ppc5554",
Kumar Gala33d9e9b2005-06-25 14:54:37 -07001993 },
Benjamin Herrenschmidt76bc080e2008-05-05 15:22:27 +10001994 { /* default match */
1995 .pvr_mask = 0x00000000,
1996 .pvr_value = 0x00000000,
1997 .cpu_name = "(generic E200 PPC)",
1998 .cpu_features = CPU_FTRS_E200,
1999 .cpu_user_features = COMMON_USER_BOOKE |
2000 PPC_FEATURE_HAS_EFP_SINGLE |
2001 PPC_FEATURE_UNIFIED_CACHE,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00002002 .mmu_features = MMU_FTR_TYPE_FSL_E,
Benjamin Herrenschmidt76bc080e2008-05-05 15:22:27 +10002003 .dcache_bsize = 32,
Kumar Gala105c31d2009-01-08 08:31:20 -06002004 .cpu_setup = __setup_cpu_e200,
Benjamin Herrenschmidt76bc080e2008-05-05 15:22:27 +10002005 .machine_check = machine_check_e200,
2006 .platform = "ppc5554",
Paul Mackerras516c8be2008-05-12 14:20:35 +10002007 }
Benjamin Herrenschmidt76bc080e2008-05-05 15:22:27 +10002008#endif /* CONFIG_E200 */
Kumar Gala4490c062010-10-08 08:32:11 -05002009#endif /* CONFIG_PPC32 */
Benjamin Herrenschmidt76bc080e2008-05-05 15:22:27 +10002010#ifdef CONFIG_E500
Kumar Gala4490c062010-10-08 08:32:11 -05002011#ifdef CONFIG_PPC32
Mihai Caraman3477e712014-08-20 16:09:03 +03002012#ifndef CONFIG_PPC_E500MC
Stephen Rothwell49209602005-10-12 15:55:09 +10002013 { /* e500 */
Linus Torvalds1da177e2005-04-16 15:20:36 -07002014 .pvr_mask = 0xffff0000,
2015 .pvr_value = 0x80200000,
2016 .cpu_name = "e500",
Kumar Gala10b35d92005-09-23 14:08:58 -05002017 .cpu_features = CPU_FTRS_E500,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11002018 .cpu_user_features = COMMON_USER_BOOKE |
Kumar Gala5e14d212007-09-13 01:44:20 -05002019 PPC_FEATURE_HAS_SPE_COMP |
2020 PPC_FEATURE_HAS_EFP_SINGLE_COMP,
Nishanth Aravamudan6c1bf482013-05-04 16:01:17 +00002021 .cpu_user_features2 = PPC_FEATURE2_ISEL,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00002022 .mmu_features = MMU_FTR_TYPE_FSL_E,
Linus Torvalds1da177e2005-04-16 15:20:36 -07002023 .icache_bsize = 32,
2024 .dcache_bsize = 32,
2025 .num_pmcs = 4,
Andy Fleming555d97a2005-12-15 20:02:04 -06002026 .oprofile_cpu_type = "ppc/e500",
Andy Fleming39aef682008-02-04 18:27:55 -06002027 .oprofile_type = PPC_OPROFILE_FSL_EMB,
Kumar Gala105c31d2009-01-08 08:31:20 -06002028 .cpu_setup = __setup_cpu_e500v1,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11002029 .machine_check = machine_check_e500,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11002030 .platform = "ppc8540",
Linus Torvalds1da177e2005-04-16 15:20:36 -07002031 },
Stephen Rothwell49209602005-10-12 15:55:09 +10002032 { /* e500v2 */
Kumar Gala5b37b702005-06-21 17:15:18 -07002033 .pvr_mask = 0xffff0000,
2034 .pvr_value = 0x80210000,
2035 .cpu_name = "e500v2",
Kumar Gala10b35d92005-09-23 14:08:58 -05002036 .cpu_features = CPU_FTRS_E500_2,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11002037 .cpu_user_features = COMMON_USER_BOOKE |
Kumar Gala5e14d212007-09-13 01:44:20 -05002038 PPC_FEATURE_HAS_SPE_COMP |
2039 PPC_FEATURE_HAS_EFP_SINGLE_COMP |
2040 PPC_FEATURE_HAS_EFP_DOUBLE_COMP,
Nishanth Aravamudan6c1bf482013-05-04 16:01:17 +00002041 .cpu_user_features2 = PPC_FEATURE2_ISEL,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00002042 .mmu_features = MMU_FTR_TYPE_FSL_E | MMU_FTR_BIG_PHYS,
Kumar Gala5b37b702005-06-21 17:15:18 -07002043 .icache_bsize = 32,
2044 .dcache_bsize = 32,
2045 .num_pmcs = 4,
Andy Fleming555d97a2005-12-15 20:02:04 -06002046 .oprofile_cpu_type = "ppc/e500",
Andy Fleming39aef682008-02-04 18:27:55 -06002047 .oprofile_type = PPC_OPROFILE_FSL_EMB,
Kumar Gala105c31d2009-01-08 08:31:20 -06002048 .cpu_setup = __setup_cpu_e500v2,
Benjamin Herrenschmidt47c0bd12007-12-21 15:39:21 +11002049 .machine_check = machine_check_e500,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11002050 .platform = "ppc8548",
chenhui zhaoe7affb12015-11-20 17:13:58 +08002051 .cpu_down_flush = cpu_down_flush_e500v2,
Kumar Gala5b37b702005-06-21 17:15:18 -07002052 },
Mihai Caraman3477e712014-08-20 16:09:03 +03002053#else
Kumar Gala3dfa8772008-06-16 09:41:32 -05002054 { /* e500mc */
2055 .pvr_mask = 0xffff0000,
2056 .pvr_value = 0x80230000,
2057 .cpu_name = "e500mc",
Kumar Gala3dfa8772008-06-16 09:41:32 -05002058 .cpu_features = CPU_FTRS_E500MC,
2059 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
Nishanth Aravamudan6c1bf482013-05-04 16:01:17 +00002060 .cpu_user_features2 = PPC_FEATURE2_ISEL,
Kumar Galac3071952009-02-10 22:26:06 -06002061 .mmu_features = MMU_FTR_TYPE_FSL_E | MMU_FTR_BIG_PHYS |
Kumar Gala323d23a2009-04-23 08:51:22 -05002062 MMU_FTR_USE_TLBILX,
Kumar Gala3dfa8772008-06-16 09:41:32 -05002063 .icache_bsize = 64,
2064 .dcache_bsize = 64,
2065 .num_pmcs = 4,
Scott Wooda11106542010-02-25 18:09:45 -06002066 .oprofile_cpu_type = "ppc/e500mc",
Kumar Gala3dfa8772008-06-16 09:41:32 -05002067 .oprofile_type = PPC_OPROFILE_FSL_EMB,
Kumar Gala105c31d2009-01-08 08:31:20 -06002068 .cpu_setup = __setup_cpu_e500mc,
Scott Woodfe04b112010-04-08 00:38:22 -05002069 .machine_check = machine_check_e500mc,
Kumar Gala3dfa8772008-06-16 09:41:32 -05002070 .platform = "ppce500mc",
chenhui zhaoe7affb12015-11-20 17:13:58 +08002071 .cpu_down_flush = cpu_down_flush_e500mc,
Kumar Gala3dfa8772008-06-16 09:41:32 -05002072 },
Mihai Caraman3477e712014-08-20 16:09:03 +03002073#endif /* CONFIG_PPC_E500MC */
Kumar Gala4490c062010-10-08 08:32:11 -05002074#endif /* CONFIG_PPC32 */
Mihai Caraman3477e712014-08-20 16:09:03 +03002075#ifdef CONFIG_PPC_E500MC
Kumar Gala4490c062010-10-08 08:32:11 -05002076 { /* e5500 */
2077 .pvr_mask = 0xffff0000,
2078 .pvr_value = 0x80240000,
2079 .cpu_name = "e5500",
Kumar Gala11ed0db2011-04-06 00:11:06 -05002080 .cpu_features = CPU_FTRS_E5500,
Kumar Galafb9be232011-06-02 11:26:13 -05002081 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU,
Nishanth Aravamudan6c1bf482013-05-04 16:01:17 +00002082 .cpu_user_features2 = PPC_FEATURE2_ISEL,
Kumar Gala4490c062010-10-08 08:32:11 -05002083 .mmu_features = MMU_FTR_TYPE_FSL_E | MMU_FTR_BIG_PHYS |
2084 MMU_FTR_USE_TLBILX,
2085 .icache_bsize = 64,
2086 .dcache_bsize = 64,
2087 .num_pmcs = 4,
2088 .oprofile_cpu_type = "ppc/e500mc",
2089 .oprofile_type = PPC_OPROFILE_FSL_EMB,
2090 .cpu_setup = __setup_cpu_e5500,
Varun Sethi2c71b0c2012-07-09 18:28:21 +05302091#ifndef CONFIG_PPC32
Kumar Gala4490c062010-10-08 08:32:11 -05002092 .cpu_restore = __restore_cpu_e5500,
Varun Sethi2c71b0c2012-07-09 18:28:21 +05302093#endif
Kumar Gala4490c062010-10-08 08:32:11 -05002094 .machine_check = machine_check_e500mc,
2095 .platform = "ppce5500",
chenhui zhaoe7affb12015-11-20 17:13:58 +08002096 .cpu_down_flush = cpu_down_flush_e5500,
Kumar Gala4490c062010-10-08 08:32:11 -05002097 },
Kumar Gala10241842011-11-06 11:51:07 -06002098 { /* e6500 */
2099 .pvr_mask = 0xffff0000,
2100 .pvr_value = 0x80400000,
2101 .cpu_name = "e6500",
2102 .cpu_features = CPU_FTRS_E6500,
Kumar Galacd66cc22012-09-07 15:57:17 -05002103 .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU |
2104 PPC_FEATURE_HAS_ALTIVEC_COMP,
Nishanth Aravamudan6c1bf482013-05-04 16:01:17 +00002105 .cpu_user_features2 = PPC_FEATURE2_ISEL,
Kumar Gala10241842011-11-06 11:51:07 -06002106 .mmu_features = MMU_FTR_TYPE_FSL_E | MMU_FTR_BIG_PHYS |
2107 MMU_FTR_USE_TLBILX,
2108 .icache_bsize = 64,
2109 .dcache_bsize = 64,
Lijun Pan5815c432013-06-05 15:22:09 -05002110 .num_pmcs = 6,
Kumar Gala10241842011-11-06 11:51:07 -06002111 .oprofile_cpu_type = "ppc/e6500",
2112 .oprofile_type = PPC_OPROFILE_FSL_EMB,
Kumar Galacd66cc22012-09-07 15:57:17 -05002113 .cpu_setup = __setup_cpu_e6500,
Varun Sethi2c71b0c2012-07-09 18:28:21 +05302114#ifndef CONFIG_PPC32
Kumar Galacd66cc22012-09-07 15:57:17 -05002115 .cpu_restore = __restore_cpu_e6500,
Varun Sethi2c71b0c2012-07-09 18:28:21 +05302116#endif
Kumar Gala10241842011-11-06 11:51:07 -06002117 .machine_check = machine_check_e500mc,
2118 .platform = "ppce6500",
chenhui zhaoe7affb12015-11-20 17:13:58 +08002119 .cpu_down_flush = cpu_down_flush_e6500,
Kumar Gala10241842011-11-06 11:51:07 -06002120 },
Mihai Caraman3477e712014-08-20 16:09:03 +03002121#endif /* CONFIG_PPC_E500MC */
Kumar Gala4490c062010-10-08 08:32:11 -05002122#ifdef CONFIG_PPC32
Linus Torvalds1da177e2005-04-16 15:20:36 -07002123 { /* default match */
2124 .pvr_mask = 0x00000000,
2125 .pvr_value = 0x00000000,
Benjamin Herrenschmidt76bc080e2008-05-05 15:22:27 +10002126 .cpu_name = "(generic E500 PPC)",
2127 .cpu_features = CPU_FTRS_E500,
2128 .cpu_user_features = COMMON_USER_BOOKE |
2129 PPC_FEATURE_HAS_SPE_COMP |
2130 PPC_FEATURE_HAS_EFP_SINGLE_COMP,
Benjamin Herrenschmidt7c03d652008-12-18 19:13:32 +00002131 .mmu_features = MMU_FTR_TYPE_FSL_E,
Linus Torvalds1da177e2005-04-16 15:20:36 -07002132 .icache_bsize = 32,
2133 .dcache_bsize = 32,
Benjamin Herrenschmidt76bc080e2008-05-05 15:22:27 +10002134 .machine_check = machine_check_e500,
Paul Mackerras80f15dc2006-01-14 10:11:39 +11002135 .platform = "powerpc",
Paul Mackerras516c8be2008-05-12 14:20:35 +10002136 }
Stephen Rothwell49209602005-10-12 15:55:09 +10002137#endif /* CONFIG_PPC32 */
Kumar Gala4490c062010-10-08 08:32:11 -05002138#endif /* CONFIG_E500 */
Linus Torvalds1da177e2005-04-16 15:20:36 -07002139};
Benjamin Herrenschmidt42c4aaa2006-10-24 16:42:40 +10002140
Paul Mackerras87a72f92007-10-04 14:18:01 +10002141static struct cpu_spec the_cpu_spec;
2142
Scott Wood26ee9762011-07-25 11:04:36 +00002143static struct cpu_spec * __init setup_cpu_spec(unsigned long offset,
2144 struct cpu_spec *s)
Michael Ellerman666435b2009-02-22 16:25:43 +00002145{
2146 struct cpu_spec *t = &the_cpu_spec;
Michael Ellerman2657dd42009-02-22 16:25:45 +00002147 struct cpu_spec old;
2148
Michael Ellerman666435b2009-02-22 16:25:43 +00002149 t = PTRRELOC(t);
Michael Ellerman2657dd42009-02-22 16:25:45 +00002150 old = *t;
2151
2152 /* Copy everything, then do fixups */
2153 *t = *s;
Michael Ellerman666435b2009-02-22 16:25:43 +00002154
2155 /*
2156 * If we are overriding a previous value derived from the real
2157 * PVR with a new value obtained using a logical PVR value,
2158 * don't modify the performance monitor fields.
2159 */
Michael Ellerman2657dd42009-02-22 16:25:45 +00002160 if (old.num_pmcs && !s->num_pmcs) {
2161 t->num_pmcs = old.num_pmcs;
2162 t->pmc_type = old.pmc_type;
2163 t->oprofile_type = old.oprofile_type;
2164 t->oprofile_mmcra_sihv = old.oprofile_mmcra_sihv;
2165 t->oprofile_mmcra_sipr = old.oprofile_mmcra_sipr;
2166 t->oprofile_mmcra_clear = old.oprofile_mmcra_clear;
2167
Michael Ellerman666435b2009-02-22 16:25:43 +00002168 /*
2169 * If we have passed through this logic once before and
2170 * have pulled the default case because the real PVR was
2171 * not found inside cpu_specs[], then we are possibly
2172 * running in compatibility mode. In that case, let the
2173 * oprofiler know which set of compatibility counters to
2174 * pull from by making sure the oprofile_cpu_type string
2175 * is set to that of compatibility mode. If the
2176 * oprofile_cpu_type already has a value, then we are
2177 * possibly overriding a real PVR with a logical one,
2178 * and, in that case, keep the current value for
2179 * oprofile_cpu_type.
2180 */
Benjamin Herrenschmidtb173f032009-05-14 18:34:06 +00002181 if (old.oprofile_cpu_type != NULL) {
Benjamin Herrenschmidt0203d6e2009-04-29 19:39:38 +00002182 t->oprofile_cpu_type = old.oprofile_cpu_type;
2183 t->oprofile_type = old.oprofile_type;
Michael Wolf79af6c42009-04-27 06:17:54 +00002184 }
Michael Ellerman2657dd42009-02-22 16:25:45 +00002185 }
Michael Ellerman666435b2009-02-22 16:25:43 +00002186
2187 *PTRRELOC(&cur_cpu_spec) = &the_cpu_spec;
2188
2189 /*
2190 * Set the base platform string once; assumes
2191 * we're called with real pvr first.
2192 */
2193 if (*PTRRELOC(&powerpc_base_platform) == NULL)
2194 *PTRRELOC(&powerpc_base_platform) = t->platform;
2195
2196#if defined(CONFIG_PPC64) || defined(CONFIG_BOOKE)
2197 /* ppc64 and booke expect identify_cpu to also call setup_cpu for
2198 * that processor. I will consolidate that at a later time, for now,
2199 * just use #ifdef. We also don't need to PTRRELOC the function
2200 * pointer on ppc64 and booke as we are running at 0 in real mode
2201 * on ppc64 and reloc_offset is always 0 on booke.
2202 */
Benjamin Herrenschmidtaf9eef32011-01-20 20:36:03 +00002203 if (t->cpu_setup) {
2204 t->cpu_setup(offset, t);
Michael Ellerman666435b2009-02-22 16:25:43 +00002205 }
2206#endif /* CONFIG_PPC64 || CONFIG_BOOKE */
Scott Wood26ee9762011-07-25 11:04:36 +00002207
2208 return t;
Michael Ellerman666435b2009-02-22 16:25:43 +00002209}
2210
Paul Mackerras87a72f92007-10-04 14:18:01 +10002211struct cpu_spec * __init identify_cpu(unsigned long offset, unsigned int pvr)
Benjamin Herrenschmidt42c4aaa2006-10-24 16:42:40 +10002212{
2213 struct cpu_spec *s = cpu_specs;
Benjamin Herrenschmidt42c4aaa2006-10-24 16:42:40 +10002214 int i;
2215
2216 s = PTRRELOC(s);
Benjamin Herrenschmidt42c4aaa2006-10-24 16:42:40 +10002217
Michael Ellerman666435b2009-02-22 16:25:43 +00002218 for (i = 0; i < ARRAY_SIZE(cpu_specs); i++,s++) {
Scott Wood26ee9762011-07-25 11:04:36 +00002219 if ((pvr & s->pvr_mask) == s->pvr_value)
2220 return setup_cpu_spec(offset, s);
Michael Ellerman666435b2009-02-22 16:25:43 +00002221 }
2222
Benjamin Herrenschmidt42c4aaa2006-10-24 16:42:40 +10002223 BUG();
Michael Ellerman666435b2009-02-22 16:25:43 +00002224
Benjamin Herrenschmidt42c4aaa2006-10-24 16:42:40 +10002225 return NULL;
2226}