Commit | Line | Data |
---|---|---|
1da177e4 | 1 | /* |
1da177e4 LT |
2 | * Copyright (C) 2001 Ben. Herrenschmidt (benh@kernel.crashing.org) |
3 | * | |
4920960f SR |
4 | * Modifications for ppc64: |
5 | * Copyright (C) 2003 Dave Engebretsen <engebret@us.ibm.com> | |
6 | * | |
1da177e4 LT |
7 | * This program is free software; you can redistribute it and/or |
8 | * modify it under the terms of the GNU General Public License | |
9 | * as published by the Free Software Foundation; either version | |
10 | * 2 of the License, or (at your option) any later version. | |
11 | */ | |
12 | ||
1da177e4 LT |
13 | #include <linux/string.h> |
14 | #include <linux/sched.h> | |
15 | #include <linux/threads.h> | |
16 | #include <linux/init.h> | |
400d2212 KG |
17 | #include <linux/module.h> |
18 | ||
19 | #include <asm/oprofile_impl.h> | |
1da177e4 | 20 | #include <asm/cputable.h> |
42c4aaad | 21 | #include <asm/prom.h> /* for PTRRELOC on ARCH=ppc */ |
1da177e4 | 22 | |
400d2212 | 23 | struct cpu_spec* cur_cpu_spec = NULL; |
4920960f | 24 | EXPORT_SYMBOL(cur_cpu_spec); |
1da177e4 | 25 | |
4920960f SR |
26 | /* NOTE: |
27 | * Unlike ppc32, ppc64 will only call this once for the boot CPU, it's | |
28 | * the responsibility of the appropriate CPU save/restore functions to | |
29 | * eventually copy these settings over. Those save/restore aren't yet | |
30 | * part of the cputable though. That has to be fixed for both ppc32 | |
31 | * and ppc64 | |
32 | */ | |
b26f100d | 33 | #ifdef CONFIG_PPC32 |
8112753b VB |
34 | extern void __setup_cpu_440ep(unsigned long offset, struct cpu_spec* spec); |
35 | extern void __setup_cpu_440epx(unsigned long offset, struct cpu_spec* spec); | |
47c0bd1a | 36 | extern void __setup_cpu_440gx(unsigned long offset, struct cpu_spec* spec); |
340ffd26 | 37 | extern void __setup_cpu_440grx(unsigned long offset, struct cpu_spec* spec); |
47c0bd1a | 38 | extern void __setup_cpu_440spe(unsigned long offset, struct cpu_spec* spec); |
464076a4 SR |
39 | extern void __setup_cpu_460ex(unsigned long offset, struct cpu_spec* spec); |
40 | extern void __setup_cpu_460gt(unsigned long offset, struct cpu_spec* spec); | |
400d2212 KG |
41 | extern void __setup_cpu_603(unsigned long offset, struct cpu_spec* spec); |
42 | extern void __setup_cpu_604(unsigned long offset, struct cpu_spec* spec); | |
43 | extern void __setup_cpu_750(unsigned long offset, struct cpu_spec* spec); | |
44 | extern void __setup_cpu_750cx(unsigned long offset, struct cpu_spec* spec); | |
45 | extern void __setup_cpu_750fx(unsigned long offset, struct cpu_spec* spec); | |
46 | extern void __setup_cpu_7400(unsigned long offset, struct cpu_spec* spec); | |
47 | extern void __setup_cpu_7410(unsigned long offset, struct cpu_spec* spec); | |
48 | extern void __setup_cpu_745x(unsigned long offset, struct cpu_spec* spec); | |
4920960f | 49 | #endif /* CONFIG_PPC32 */ |
f39b7a55 | 50 | #ifdef CONFIG_PPC64 |
400d2212 | 51 | extern void __setup_cpu_ppc970(unsigned long offset, struct cpu_spec* spec); |
5b43d20a | 52 | extern void __setup_cpu_ppc970MP(unsigned long offset, struct cpu_spec* spec); |
1199919b | 53 | extern void __setup_cpu_pa6t(unsigned long offset, struct cpu_spec* spec); |
40d244d6 | 54 | extern void __restore_cpu_pa6t(void); |
f39b7a55 OJ |
55 | extern void __restore_cpu_ppc970(void); |
56 | #endif /* CONFIG_PPC64 */ | |
1da177e4 | 57 | |
1da177e4 LT |
58 | /* This table only contains "desktop" CPUs, it need to be filled with embedded |
59 | * ones as well... | |
60 | */ | |
4920960f SR |
61 | #define COMMON_USER (PPC_FEATURE_32 | PPC_FEATURE_HAS_FPU | \ |
62 | PPC_FEATURE_HAS_MMU) | |
63 | #define COMMON_USER_PPC64 (COMMON_USER | PPC_FEATURE_64) | |
a7ddc5e8 | 64 | #define COMMON_USER_POWER4 (COMMON_USER_PPC64 | PPC_FEATURE_POWER4) |
aa5cb021 BH |
65 | #define COMMON_USER_POWER5 (COMMON_USER_PPC64 | PPC_FEATURE_POWER5 |\ |
66 | PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP) | |
67 | #define COMMON_USER_POWER5_PLUS (COMMON_USER_PPC64 | PPC_FEATURE_POWER5_PLUS|\ | |
68 | PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP) | |
03054d51 | 69 | #define COMMON_USER_POWER6 (COMMON_USER_PPC64 | PPC_FEATURE_ARCH_2_05 |\ |
fab5db97 PM |
70 | PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP | \ |
71 | PPC_FEATURE_TRUE_LE) | |
b3ebd1d8 OJ |
72 | #define COMMON_USER_PA6T (COMMON_USER_PPC64 | PPC_FEATURE_PA6T |\ |
73 | PPC_FEATURE_TRUE_LE | \ | |
74 | PPC_FEATURE_HAS_ALTIVEC_COMP) | |
80f15dc7 PM |
75 | #define COMMON_USER_BOOKE (PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU | \ |
76 | PPC_FEATURE_BOOKE) | |
1da177e4 | 77 | |
87a72f9e | 78 | static struct cpu_spec __initdata cpu_specs[] = { |
4920960f SR |
79 | #ifdef CONFIG_PPC64 |
80 | { /* Power3 */ | |
81 | .pvr_mask = 0xffff0000, | |
82 | .pvr_value = 0x00400000, | |
83 | .cpu_name = "POWER3 (630)", | |
84 | .cpu_features = CPU_FTRS_POWER3, | |
fab5db97 | 85 | .cpu_user_features = COMMON_USER_PPC64|PPC_FEATURE_PPC_LE, |
4920960f SR |
86 | .icache_bsize = 128, |
87 | .dcache_bsize = 128, | |
88 | .num_pmcs = 8, | |
1bd2e5ae | 89 | .pmc_type = PPC_PMC_IBM, |
4920960f | 90 | .oprofile_cpu_type = "ppc64/power3", |
7a45fb19 | 91 | .oprofile_type = PPC_OPROFILE_RS64, |
47c0bd1a | 92 | .machine_check = machine_check_generic, |
80f15dc7 | 93 | .platform = "power3", |
4920960f SR |
94 | }, |
95 | { /* Power3+ */ | |
96 | .pvr_mask = 0xffff0000, | |
97 | .pvr_value = 0x00410000, | |
98 | .cpu_name = "POWER3 (630+)", | |
99 | .cpu_features = CPU_FTRS_POWER3, | |
fab5db97 | 100 | .cpu_user_features = COMMON_USER_PPC64|PPC_FEATURE_PPC_LE, |
4920960f SR |
101 | .icache_bsize = 128, |
102 | .dcache_bsize = 128, | |
103 | .num_pmcs = 8, | |
1bd2e5ae | 104 | .pmc_type = PPC_PMC_IBM, |
4920960f | 105 | .oprofile_cpu_type = "ppc64/power3", |
7a45fb19 | 106 | .oprofile_type = PPC_OPROFILE_RS64, |
47c0bd1a | 107 | .machine_check = machine_check_generic, |
80f15dc7 | 108 | .platform = "power3", |
4920960f SR |
109 | }, |
110 | { /* Northstar */ | |
111 | .pvr_mask = 0xffff0000, | |
112 | .pvr_value = 0x00330000, | |
113 | .cpu_name = "RS64-II (northstar)", | |
114 | .cpu_features = CPU_FTRS_RS64, | |
115 | .cpu_user_features = COMMON_USER_PPC64, | |
116 | .icache_bsize = 128, | |
117 | .dcache_bsize = 128, | |
118 | .num_pmcs = 8, | |
1bd2e5ae | 119 | .pmc_type = PPC_PMC_IBM, |
4920960f | 120 | .oprofile_cpu_type = "ppc64/rs64", |
7a45fb19 | 121 | .oprofile_type = PPC_OPROFILE_RS64, |
47c0bd1a | 122 | .machine_check = machine_check_generic, |
80f15dc7 | 123 | .platform = "rs64", |
4920960f SR |
124 | }, |
125 | { /* Pulsar */ | |
126 | .pvr_mask = 0xffff0000, | |
127 | .pvr_value = 0x00340000, | |
128 | .cpu_name = "RS64-III (pulsar)", | |
129 | .cpu_features = CPU_FTRS_RS64, | |
130 | .cpu_user_features = COMMON_USER_PPC64, | |
131 | .icache_bsize = 128, | |
132 | .dcache_bsize = 128, | |
133 | .num_pmcs = 8, | |
1bd2e5ae | 134 | .pmc_type = PPC_PMC_IBM, |
4920960f | 135 | .oprofile_cpu_type = "ppc64/rs64", |
7a45fb19 | 136 | .oprofile_type = PPC_OPROFILE_RS64, |
47c0bd1a | 137 | .machine_check = machine_check_generic, |
80f15dc7 | 138 | .platform = "rs64", |
4920960f SR |
139 | }, |
140 | { /* I-star */ | |
141 | .pvr_mask = 0xffff0000, | |
142 | .pvr_value = 0x00360000, | |
143 | .cpu_name = "RS64-III (icestar)", | |
144 | .cpu_features = CPU_FTRS_RS64, | |
145 | .cpu_user_features = COMMON_USER_PPC64, | |
146 | .icache_bsize = 128, | |
147 | .dcache_bsize = 128, | |
148 | .num_pmcs = 8, | |
1bd2e5ae | 149 | .pmc_type = PPC_PMC_IBM, |
4920960f | 150 | .oprofile_cpu_type = "ppc64/rs64", |
7a45fb19 | 151 | .oprofile_type = PPC_OPROFILE_RS64, |
47c0bd1a | 152 | .machine_check = machine_check_generic, |
80f15dc7 | 153 | .platform = "rs64", |
4920960f SR |
154 | }, |
155 | { /* S-star */ | |
156 | .pvr_mask = 0xffff0000, | |
157 | .pvr_value = 0x00370000, | |
158 | .cpu_name = "RS64-IV (sstar)", | |
159 | .cpu_features = CPU_FTRS_RS64, | |
160 | .cpu_user_features = COMMON_USER_PPC64, | |
161 | .icache_bsize = 128, | |
162 | .dcache_bsize = 128, | |
163 | .num_pmcs = 8, | |
1bd2e5ae | 164 | .pmc_type = PPC_PMC_IBM, |
4920960f | 165 | .oprofile_cpu_type = "ppc64/rs64", |
7a45fb19 | 166 | .oprofile_type = PPC_OPROFILE_RS64, |
47c0bd1a | 167 | .machine_check = machine_check_generic, |
80f15dc7 | 168 | .platform = "rs64", |
4920960f SR |
169 | }, |
170 | { /* Power4 */ | |
171 | .pvr_mask = 0xffff0000, | |
172 | .pvr_value = 0x00350000, | |
173 | .cpu_name = "POWER4 (gp)", | |
174 | .cpu_features = CPU_FTRS_POWER4, | |
a7ddc5e8 | 175 | .cpu_user_features = COMMON_USER_POWER4, |
4920960f SR |
176 | .icache_bsize = 128, |
177 | .dcache_bsize = 128, | |
178 | .num_pmcs = 8, | |
1bd2e5ae | 179 | .pmc_type = PPC_PMC_IBM, |
4920960f | 180 | .oprofile_cpu_type = "ppc64/power4", |
7a45fb19 | 181 | .oprofile_type = PPC_OPROFILE_POWER4, |
47c0bd1a | 182 | .machine_check = machine_check_generic, |
80f15dc7 | 183 | .platform = "power4", |
4920960f SR |
184 | }, |
185 | { /* Power4+ */ | |
186 | .pvr_mask = 0xffff0000, | |
187 | .pvr_value = 0x00380000, | |
188 | .cpu_name = "POWER4+ (gq)", | |
189 | .cpu_features = CPU_FTRS_POWER4, | |
a7ddc5e8 | 190 | .cpu_user_features = COMMON_USER_POWER4, |
4920960f SR |
191 | .icache_bsize = 128, |
192 | .dcache_bsize = 128, | |
193 | .num_pmcs = 8, | |
1bd2e5ae | 194 | .pmc_type = PPC_PMC_IBM, |
4920960f | 195 | .oprofile_cpu_type = "ppc64/power4", |
7a45fb19 | 196 | .oprofile_type = PPC_OPROFILE_POWER4, |
47c0bd1a | 197 | .machine_check = machine_check_generic, |
80f15dc7 | 198 | .platform = "power4", |
4920960f SR |
199 | }, |
200 | { /* PPC970 */ | |
201 | .pvr_mask = 0xffff0000, | |
202 | .pvr_value = 0x00390000, | |
203 | .cpu_name = "PPC970", | |
204 | .cpu_features = CPU_FTRS_PPC970, | |
a7ddc5e8 | 205 | .cpu_user_features = COMMON_USER_POWER4 | |
4920960f SR |
206 | PPC_FEATURE_HAS_ALTIVEC_COMP, |
207 | .icache_bsize = 128, | |
208 | .dcache_bsize = 128, | |
209 | .num_pmcs = 8, | |
1bd2e5ae | 210 | .pmc_type = PPC_PMC_IBM, |
4920960f | 211 | .cpu_setup = __setup_cpu_ppc970, |
f39b7a55 | 212 | .cpu_restore = __restore_cpu_ppc970, |
4920960f | 213 | .oprofile_cpu_type = "ppc64/970", |
7a45fb19 | 214 | .oprofile_type = PPC_OPROFILE_POWER4, |
47c0bd1a | 215 | .machine_check = machine_check_generic, |
80f15dc7 | 216 | .platform = "ppc970", |
4920960f | 217 | }, |
4920960f SR |
218 | { /* PPC970FX */ |
219 | .pvr_mask = 0xffff0000, | |
220 | .pvr_value = 0x003c0000, | |
221 | .cpu_name = "PPC970FX", | |
4920960f | 222 | .cpu_features = CPU_FTRS_PPC970, |
a7ddc5e8 | 223 | .cpu_user_features = COMMON_USER_POWER4 | |
4920960f SR |
224 | PPC_FEATURE_HAS_ALTIVEC_COMP, |
225 | .icache_bsize = 128, | |
226 | .dcache_bsize = 128, | |
227 | .num_pmcs = 8, | |
1bd2e5ae | 228 | .pmc_type = PPC_PMC_IBM, |
4920960f | 229 | .cpu_setup = __setup_cpu_ppc970, |
f39b7a55 | 230 | .cpu_restore = __restore_cpu_ppc970, |
4920960f | 231 | .oprofile_cpu_type = "ppc64/970", |
7a45fb19 | 232 | .oprofile_type = PPC_OPROFILE_POWER4, |
47c0bd1a | 233 | .machine_check = machine_check_generic, |
80f15dc7 | 234 | .platform = "ppc970", |
3546e811 OJ |
235 | }, |
236 | { /* PPC970MP DD1.0 - no DEEPNAP, use regular 970 init */ | |
237 | .pvr_mask = 0xffffffff, | |
238 | .pvr_value = 0x00440100, | |
239 | .cpu_name = "PPC970MP", | |
240 | .cpu_features = CPU_FTRS_PPC970, | |
241 | .cpu_user_features = COMMON_USER_POWER4 | | |
242 | PPC_FEATURE_HAS_ALTIVEC_COMP, | |
243 | .icache_bsize = 128, | |
244 | .dcache_bsize = 128, | |
245 | .num_pmcs = 8, | |
2fae4985 | 246 | .pmc_type = PPC_PMC_IBM, |
3546e811 OJ |
247 | .cpu_setup = __setup_cpu_ppc970, |
248 | .cpu_restore = __restore_cpu_ppc970, | |
249 | .oprofile_cpu_type = "ppc64/970MP", | |
250 | .oprofile_type = PPC_OPROFILE_POWER4, | |
47c0bd1a | 251 | .machine_check = machine_check_generic, |
3546e811 | 252 | .platform = "ppc970", |
4920960f | 253 | }, |
4920960f SR |
254 | { /* PPC970MP */ |
255 | .pvr_mask = 0xffff0000, | |
256 | .pvr_value = 0x00440000, | |
257 | .cpu_name = "PPC970MP", | |
258 | .cpu_features = CPU_FTRS_PPC970, | |
a7ddc5e8 | 259 | .cpu_user_features = COMMON_USER_POWER4 | |
4920960f SR |
260 | PPC_FEATURE_HAS_ALTIVEC_COMP, |
261 | .icache_bsize = 128, | |
262 | .dcache_bsize = 128, | |
87af41be | 263 | .num_pmcs = 8, |
2fae4985 | 264 | .pmc_type = PPC_PMC_IBM, |
5b43d20a | 265 | .cpu_setup = __setup_cpu_ppc970MP, |
f39b7a55 | 266 | .cpu_restore = __restore_cpu_ppc970, |
fecb352f | 267 | .oprofile_cpu_type = "ppc64/970MP", |
7a45fb19 | 268 | .oprofile_type = PPC_OPROFILE_POWER4, |
47c0bd1a | 269 | .machine_check = machine_check_generic, |
80f15dc7 | 270 | .platform = "ppc970", |
4920960f | 271 | }, |
362ff7b2 JM |
272 | { /* PPC970GX */ |
273 | .pvr_mask = 0xffff0000, | |
274 | .pvr_value = 0x00450000, | |
275 | .cpu_name = "PPC970GX", | |
276 | .cpu_features = CPU_FTRS_PPC970, | |
277 | .cpu_user_features = COMMON_USER_POWER4 | | |
278 | PPC_FEATURE_HAS_ALTIVEC_COMP, | |
279 | .icache_bsize = 128, | |
280 | .dcache_bsize = 128, | |
281 | .num_pmcs = 8, | |
1bd2e5ae | 282 | .pmc_type = PPC_PMC_IBM, |
362ff7b2 JM |
283 | .cpu_setup = __setup_cpu_ppc970, |
284 | .oprofile_cpu_type = "ppc64/970", | |
285 | .oprofile_type = PPC_OPROFILE_POWER4, | |
47c0bd1a | 286 | .machine_check = machine_check_generic, |
362ff7b2 JM |
287 | .platform = "ppc970", |
288 | }, | |
3c726f8d | 289 | { /* Power5 GR */ |
4920960f SR |
290 | .pvr_mask = 0xffff0000, |
291 | .pvr_value = 0x003a0000, | |
292 | .cpu_name = "POWER5 (gr)", | |
293 | .cpu_features = CPU_FTRS_POWER5, | |
a7ddc5e8 | 294 | .cpu_user_features = COMMON_USER_POWER5, |
4920960f SR |
295 | .icache_bsize = 128, |
296 | .dcache_bsize = 128, | |
297 | .num_pmcs = 6, | |
1bd2e5ae | 298 | .pmc_type = PPC_PMC_IBM, |
4920960f | 299 | .oprofile_cpu_type = "ppc64/power5", |
7a45fb19 | 300 | .oprofile_type = PPC_OPROFILE_POWER4, |
e78dbc80 MN |
301 | /* SIHV / SIPR bits are implemented on POWER4+ (GQ) |
302 | * and above but only works on POWER5 and above | |
303 | */ | |
304 | .oprofile_mmcra_sihv = MMCRA_SIHV, | |
305 | .oprofile_mmcra_sipr = MMCRA_SIPR, | |
47c0bd1a | 306 | .machine_check = machine_check_generic, |
80f15dc7 | 307 | .platform = "power5", |
4920960f | 308 | }, |
31a12cec MW |
309 | { /* Power5++ */ |
310 | .pvr_mask = 0xffffff00, | |
311 | .pvr_value = 0x003b0300, | |
312 | .cpu_name = "POWER5+ (gs)", | |
313 | .cpu_features = CPU_FTRS_POWER5, | |
314 | .cpu_user_features = COMMON_USER_POWER5_PLUS, | |
315 | .icache_bsize = 128, | |
316 | .dcache_bsize = 128, | |
317 | .num_pmcs = 6, | |
318 | .oprofile_cpu_type = "ppc64/power5++", | |
319 | .oprofile_type = PPC_OPROFILE_POWER4, | |
320 | .oprofile_mmcra_sihv = MMCRA_SIHV, | |
321 | .oprofile_mmcra_sipr = MMCRA_SIPR, | |
47c0bd1a | 322 | .machine_check = machine_check_generic, |
31a12cec MW |
323 | .platform = "power5+", |
324 | }, | |
3c726f8d | 325 | { /* Power5 GS */ |
4920960f SR |
326 | .pvr_mask = 0xffff0000, |
327 | .pvr_value = 0x003b0000, | |
834608f7 | 328 | .cpu_name = "POWER5+ (gs)", |
4920960f | 329 | .cpu_features = CPU_FTRS_POWER5, |
a7ddc5e8 | 330 | .cpu_user_features = COMMON_USER_POWER5_PLUS, |
4920960f SR |
331 | .icache_bsize = 128, |
332 | .dcache_bsize = 128, | |
333 | .num_pmcs = 6, | |
1bd2e5ae | 334 | .pmc_type = PPC_PMC_IBM, |
834608f7 | 335 | .oprofile_cpu_type = "ppc64/power5+", |
7a45fb19 | 336 | .oprofile_type = PPC_OPROFILE_POWER4, |
e78dbc80 MN |
337 | .oprofile_mmcra_sihv = MMCRA_SIHV, |
338 | .oprofile_mmcra_sipr = MMCRA_SIPR, | |
47c0bd1a | 339 | .machine_check = machine_check_generic, |
80f15dc7 | 340 | .platform = "power5+", |
4920960f | 341 | }, |
974a76f5 PM |
342 | { /* POWER6 in P5+ mode; 2.04-compliant processor */ |
343 | .pvr_mask = 0xffffffff, | |
344 | .pvr_value = 0x0f000001, | |
345 | .cpu_name = "POWER5+", | |
346 | .cpu_features = CPU_FTRS_POWER5, | |
347 | .cpu_user_features = COMMON_USER_POWER5_PLUS, | |
348 | .icache_bsize = 128, | |
349 | .dcache_bsize = 128, | |
47c0bd1a | 350 | .machine_check = machine_check_generic, |
974a76f5 PM |
351 | .platform = "power5+", |
352 | }, | |
03054d51 AB |
353 | { /* Power6 */ |
354 | .pvr_mask = 0xffff0000, | |
355 | .pvr_value = 0x003e0000, | |
974a76f5 PM |
356 | .cpu_name = "POWER6 (raw)", |
357 | .cpu_features = CPU_FTRS_POWER6, | |
358 | .cpu_user_features = COMMON_USER_POWER6 | | |
359 | PPC_FEATURE_POWER6_EXT, | |
360 | .icache_bsize = 128, | |
361 | .dcache_bsize = 128, | |
362 | .num_pmcs = 6, | |
2fae4985 | 363 | .pmc_type = PPC_PMC_IBM, |
974a76f5 PM |
364 | .oprofile_cpu_type = "ppc64/power6", |
365 | .oprofile_type = PPC_OPROFILE_POWER4, | |
366 | .oprofile_mmcra_sihv = POWER6_MMCRA_SIHV, | |
367 | .oprofile_mmcra_sipr = POWER6_MMCRA_SIPR, | |
368 | .oprofile_mmcra_clear = POWER6_MMCRA_THRM | | |
369 | POWER6_MMCRA_OTHER, | |
47c0bd1a | 370 | .machine_check = machine_check_generic, |
974a76f5 PM |
371 | .platform = "power6x", |
372 | }, | |
373 | { /* 2.05-compliant processor, i.e. Power6 "architected" mode */ | |
374 | .pvr_mask = 0xffffffff, | |
375 | .pvr_value = 0x0f000002, | |
376 | .cpu_name = "POWER6 (architected)", | |
03054d51 AB |
377 | .cpu_features = CPU_FTRS_POWER6, |
378 | .cpu_user_features = COMMON_USER_POWER6, | |
379 | .icache_bsize = 128, | |
380 | .dcache_bsize = 128, | |
47c0bd1a | 381 | .machine_check = machine_check_generic, |
03054d51 AB |
382 | .platform = "power6", |
383 | }, | |
c902be71 | 384 | { /* Cell Broadband Engine */ |
4920960f SR |
385 | .pvr_mask = 0xffff0000, |
386 | .pvr_value = 0x00700000, | |
387 | .cpu_name = "Cell Broadband Engine", | |
388 | .cpu_features = CPU_FTRS_CELL, | |
389 | .cpu_user_features = COMMON_USER_PPC64 | | |
aa5cb021 BH |
390 | PPC_FEATURE_CELL | PPC_FEATURE_HAS_ALTIVEC_COMP | |
391 | PPC_FEATURE_SMT, | |
4920960f SR |
392 | .icache_bsize = 128, |
393 | .dcache_bsize = 128, | |
18f2190d | 394 | .num_pmcs = 4, |
1bd2e5ae | 395 | .pmc_type = PPC_PMC_IBM, |
18f2190d MJ |
396 | .oprofile_cpu_type = "ppc64/cell-be", |
397 | .oprofile_type = PPC_OPROFILE_CELL, | |
47c0bd1a | 398 | .machine_check = machine_check_generic, |
80f15dc7 | 399 | .platform = "ppc-cell-be", |
4920960f | 400 | }, |
b3ebd1d8 OJ |
401 | { /* PA Semi PA6T */ |
402 | .pvr_mask = 0x7fff0000, | |
403 | .pvr_value = 0x00900000, | |
404 | .cpu_name = "PA6T", | |
405 | .cpu_features = CPU_FTRS_PA6T, | |
406 | .cpu_user_features = COMMON_USER_PA6T, | |
407 | .icache_bsize = 64, | |
408 | .dcache_bsize = 64, | |
409 | .num_pmcs = 6, | |
1bd2e5ae | 410 | .pmc_type = PPC_PMC_PA6T, |
1199919b OJ |
411 | .cpu_setup = __setup_cpu_pa6t, |
412 | .cpu_restore = __restore_cpu_pa6t, | |
25fc530e OJ |
413 | .oprofile_cpu_type = "ppc64/pa6t", |
414 | .oprofile_type = PPC_OPROFILE_PA6T, | |
47c0bd1a | 415 | .machine_check = machine_check_generic, |
b3ebd1d8 OJ |
416 | .platform = "pa6t", |
417 | }, | |
4920960f SR |
418 | { /* default match */ |
419 | .pvr_mask = 0x00000000, | |
420 | .pvr_value = 0x00000000, | |
421 | .cpu_name = "POWER4 (compatible)", | |
422 | .cpu_features = CPU_FTRS_COMPATIBLE, | |
423 | .cpu_user_features = COMMON_USER_PPC64, | |
424 | .icache_bsize = 128, | |
425 | .dcache_bsize = 128, | |
426 | .num_pmcs = 6, | |
1bd2e5ae | 427 | .pmc_type = PPC_PMC_IBM, |
47c0bd1a | 428 | .machine_check = machine_check_generic, |
80f15dc7 | 429 | .platform = "power4", |
4920960f SR |
430 | } |
431 | #endif /* CONFIG_PPC64 */ | |
432 | #ifdef CONFIG_PPC32 | |
1da177e4 | 433 | #if CLASSIC_PPC |
4920960f | 434 | { /* 601 */ |
1da177e4 LT |
435 | .pvr_mask = 0xffff0000, |
436 | .pvr_value = 0x00010000, | |
437 | .cpu_name = "601", | |
10b35d99 | 438 | .cpu_features = CPU_FTRS_PPC601, |
4920960f | 439 | .cpu_user_features = COMMON_USER | PPC_FEATURE_601_INSTR | |
d8e998c5 | 440 | PPC_FEATURE_UNIFIED_CACHE | PPC_FEATURE_NO_TB, |
1da177e4 LT |
441 | .icache_bsize = 32, |
442 | .dcache_bsize = 32, | |
47c0bd1a | 443 | .machine_check = machine_check_generic, |
80f15dc7 | 444 | .platform = "ppc601", |
1da177e4 LT |
445 | }, |
446 | { /* 603 */ | |
447 | .pvr_mask = 0xffff0000, | |
448 | .pvr_value = 0x00030000, | |
449 | .cpu_name = "603", | |
10b35d99 | 450 | .cpu_features = CPU_FTRS_603, |
fab5db97 | 451 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
452 | .icache_bsize = 32, |
453 | .dcache_bsize = 32, | |
80f15dc7 | 454 | .cpu_setup = __setup_cpu_603, |
47c0bd1a | 455 | .machine_check = machine_check_generic, |
80f15dc7 | 456 | .platform = "ppc603", |
1da177e4 LT |
457 | }, |
458 | { /* 603e */ | |
459 | .pvr_mask = 0xffff0000, | |
460 | .pvr_value = 0x00060000, | |
461 | .cpu_name = "603e", | |
10b35d99 | 462 | .cpu_features = CPU_FTRS_603, |
fab5db97 | 463 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
464 | .icache_bsize = 32, |
465 | .dcache_bsize = 32, | |
80f15dc7 | 466 | .cpu_setup = __setup_cpu_603, |
47c0bd1a | 467 | .machine_check = machine_check_generic, |
80f15dc7 | 468 | .platform = "ppc603", |
1da177e4 LT |
469 | }, |
470 | { /* 603ev */ | |
471 | .pvr_mask = 0xffff0000, | |
472 | .pvr_value = 0x00070000, | |
473 | .cpu_name = "603ev", | |
10b35d99 | 474 | .cpu_features = CPU_FTRS_603, |
fab5db97 | 475 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
476 | .icache_bsize = 32, |
477 | .dcache_bsize = 32, | |
80f15dc7 | 478 | .cpu_setup = __setup_cpu_603, |
47c0bd1a | 479 | .machine_check = machine_check_generic, |
80f15dc7 | 480 | .platform = "ppc603", |
1da177e4 LT |
481 | }, |
482 | { /* 604 */ | |
483 | .pvr_mask = 0xffff0000, | |
484 | .pvr_value = 0x00040000, | |
485 | .cpu_name = "604", | |
10b35d99 | 486 | .cpu_features = CPU_FTRS_604, |
fab5db97 | 487 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
488 | .icache_bsize = 32, |
489 | .dcache_bsize = 32, | |
490 | .num_pmcs = 2, | |
80f15dc7 | 491 | .cpu_setup = __setup_cpu_604, |
47c0bd1a | 492 | .machine_check = machine_check_generic, |
80f15dc7 | 493 | .platform = "ppc604", |
1da177e4 LT |
494 | }, |
495 | { /* 604e */ | |
496 | .pvr_mask = 0xfffff000, | |
497 | .pvr_value = 0x00090000, | |
498 | .cpu_name = "604e", | |
10b35d99 | 499 | .cpu_features = CPU_FTRS_604, |
fab5db97 | 500 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
501 | .icache_bsize = 32, |
502 | .dcache_bsize = 32, | |
503 | .num_pmcs = 4, | |
80f15dc7 | 504 | .cpu_setup = __setup_cpu_604, |
47c0bd1a | 505 | .machine_check = machine_check_generic, |
80f15dc7 | 506 | .platform = "ppc604", |
1da177e4 LT |
507 | }, |
508 | { /* 604r */ | |
509 | .pvr_mask = 0xffff0000, | |
510 | .pvr_value = 0x00090000, | |
511 | .cpu_name = "604r", | |
10b35d99 | 512 | .cpu_features = CPU_FTRS_604, |
fab5db97 | 513 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
514 | .icache_bsize = 32, |
515 | .dcache_bsize = 32, | |
516 | .num_pmcs = 4, | |
80f15dc7 | 517 | .cpu_setup = __setup_cpu_604, |
47c0bd1a | 518 | .machine_check = machine_check_generic, |
80f15dc7 | 519 | .platform = "ppc604", |
1da177e4 LT |
520 | }, |
521 | { /* 604ev */ | |
522 | .pvr_mask = 0xffff0000, | |
523 | .pvr_value = 0x000a0000, | |
524 | .cpu_name = "604ev", | |
10b35d99 | 525 | .cpu_features = CPU_FTRS_604, |
fab5db97 | 526 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
527 | .icache_bsize = 32, |
528 | .dcache_bsize = 32, | |
529 | .num_pmcs = 4, | |
80f15dc7 | 530 | .cpu_setup = __setup_cpu_604, |
47c0bd1a | 531 | .machine_check = machine_check_generic, |
80f15dc7 | 532 | .platform = "ppc604", |
1da177e4 LT |
533 | }, |
534 | { /* 740/750 (0x4202, don't support TAU ?) */ | |
535 | .pvr_mask = 0xffffffff, | |
536 | .pvr_value = 0x00084202, | |
537 | .cpu_name = "740/750", | |
10b35d99 | 538 | .cpu_features = CPU_FTRS_740_NOTAU, |
fab5db97 | 539 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
540 | .icache_bsize = 32, |
541 | .dcache_bsize = 32, | |
542 | .num_pmcs = 4, | |
80f15dc7 | 543 | .cpu_setup = __setup_cpu_750, |
47c0bd1a | 544 | .machine_check = machine_check_generic, |
80f15dc7 | 545 | .platform = "ppc750", |
1da177e4 | 546 | }, |
1da177e4 LT |
547 | { /* 750CX (80100 and 8010x?) */ |
548 | .pvr_mask = 0xfffffff0, | |
549 | .pvr_value = 0x00080100, | |
550 | .cpu_name = "750CX", | |
10b35d99 | 551 | .cpu_features = CPU_FTRS_750, |
fab5db97 | 552 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
553 | .icache_bsize = 32, |
554 | .dcache_bsize = 32, | |
555 | .num_pmcs = 4, | |
80f15dc7 | 556 | .cpu_setup = __setup_cpu_750cx, |
47c0bd1a | 557 | .machine_check = machine_check_generic, |
80f15dc7 | 558 | .platform = "ppc750", |
1da177e4 LT |
559 | }, |
560 | { /* 750CX (82201 and 82202) */ | |
561 | .pvr_mask = 0xfffffff0, | |
562 | .pvr_value = 0x00082200, | |
563 | .cpu_name = "750CX", | |
10b35d99 | 564 | .cpu_features = CPU_FTRS_750, |
fab5db97 | 565 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
566 | .icache_bsize = 32, |
567 | .dcache_bsize = 32, | |
568 | .num_pmcs = 4, | |
80f15dc7 | 569 | .cpu_setup = __setup_cpu_750cx, |
47c0bd1a | 570 | .machine_check = machine_check_generic, |
80f15dc7 | 571 | .platform = "ppc750", |
1da177e4 LT |
572 | }, |
573 | { /* 750CXe (82214) */ | |
574 | .pvr_mask = 0xfffffff0, | |
575 | .pvr_value = 0x00082210, | |
576 | .cpu_name = "750CXe", | |
10b35d99 | 577 | .cpu_features = CPU_FTRS_750, |
fab5db97 | 578 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
579 | .icache_bsize = 32, |
580 | .dcache_bsize = 32, | |
581 | .num_pmcs = 4, | |
80f15dc7 | 582 | .cpu_setup = __setup_cpu_750cx, |
47c0bd1a | 583 | .machine_check = machine_check_generic, |
80f15dc7 | 584 | .platform = "ppc750", |
1da177e4 | 585 | }, |
7c31625a AO |
586 | { /* 750CXe "Gekko" (83214) */ |
587 | .pvr_mask = 0xffffffff, | |
588 | .pvr_value = 0x00083214, | |
589 | .cpu_name = "750CXe", | |
10b35d99 | 590 | .cpu_features = CPU_FTRS_750, |
fab5db97 | 591 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
7c31625a AO |
592 | .icache_bsize = 32, |
593 | .dcache_bsize = 32, | |
594 | .num_pmcs = 4, | |
80f15dc7 | 595 | .cpu_setup = __setup_cpu_750cx, |
47c0bd1a | 596 | .machine_check = machine_check_generic, |
80f15dc7 | 597 | .platform = "ppc750", |
7c31625a | 598 | }, |
cfbff8a3 JM |
599 | { /* 750CL */ |
600 | .pvr_mask = 0xfffff0f0, | |
601 | .pvr_value = 0x00087010, | |
602 | .cpu_name = "750CL", | |
a14c4508 | 603 | .cpu_features = CPU_FTRS_750CL, |
cfbff8a3 JM |
604 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
605 | .icache_bsize = 32, | |
606 | .dcache_bsize = 32, | |
607 | .num_pmcs = 4, | |
a14c4508 | 608 | .cpu_setup = __setup_cpu_750, |
47c0bd1a | 609 | .machine_check = machine_check_generic, |
cfbff8a3 JM |
610 | .platform = "ppc750", |
611 | }, | |
ac1ff047 AO |
612 | { /* 745/755 */ |
613 | .pvr_mask = 0xfffff000, | |
614 | .pvr_value = 0x00083000, | |
615 | .cpu_name = "745/755", | |
10b35d99 | 616 | .cpu_features = CPU_FTRS_750, |
fab5db97 | 617 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
ac1ff047 AO |
618 | .icache_bsize = 32, |
619 | .dcache_bsize = 32, | |
620 | .num_pmcs = 4, | |
80f15dc7 | 621 | .cpu_setup = __setup_cpu_750, |
47c0bd1a | 622 | .machine_check = machine_check_generic, |
80f15dc7 | 623 | .platform = "ppc750", |
ac1ff047 | 624 | }, |
1da177e4 LT |
625 | { /* 750FX rev 1.x */ |
626 | .pvr_mask = 0xffffff00, | |
627 | .pvr_value = 0x70000100, | |
628 | .cpu_name = "750FX", | |
10b35d99 | 629 | .cpu_features = CPU_FTRS_750FX1, |
fab5db97 | 630 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
631 | .icache_bsize = 32, |
632 | .dcache_bsize = 32, | |
633 | .num_pmcs = 4, | |
80f15dc7 | 634 | .cpu_setup = __setup_cpu_750, |
47c0bd1a | 635 | .machine_check = machine_check_generic, |
80f15dc7 | 636 | .platform = "ppc750", |
1da177e4 LT |
637 | }, |
638 | { /* 750FX rev 2.0 must disable HID0[DPM] */ | |
639 | .pvr_mask = 0xffffffff, | |
640 | .pvr_value = 0x70000200, | |
641 | .cpu_name = "750FX", | |
10b35d99 | 642 | .cpu_features = CPU_FTRS_750FX2, |
fab5db97 | 643 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
644 | .icache_bsize = 32, |
645 | .dcache_bsize = 32, | |
646 | .num_pmcs = 4, | |
80f15dc7 | 647 | .cpu_setup = __setup_cpu_750, |
47c0bd1a | 648 | .machine_check = machine_check_generic, |
80f15dc7 | 649 | .platform = "ppc750", |
1da177e4 LT |
650 | }, |
651 | { /* 750FX (All revs except 2.0) */ | |
652 | .pvr_mask = 0xffff0000, | |
653 | .pvr_value = 0x70000000, | |
654 | .cpu_name = "750FX", | |
10b35d99 | 655 | .cpu_features = CPU_FTRS_750FX, |
fab5db97 | 656 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
657 | .icache_bsize = 32, |
658 | .dcache_bsize = 32, | |
659 | .num_pmcs = 4, | |
80f15dc7 | 660 | .cpu_setup = __setup_cpu_750fx, |
47c0bd1a | 661 | .machine_check = machine_check_generic, |
80f15dc7 | 662 | .platform = "ppc750", |
1da177e4 LT |
663 | }, |
664 | { /* 750GX */ | |
665 | .pvr_mask = 0xffff0000, | |
666 | .pvr_value = 0x70020000, | |
667 | .cpu_name = "750GX", | |
10b35d99 | 668 | .cpu_features = CPU_FTRS_750GX, |
fab5db97 | 669 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
670 | .icache_bsize = 32, |
671 | .dcache_bsize = 32, | |
672 | .num_pmcs = 4, | |
80f15dc7 | 673 | .cpu_setup = __setup_cpu_750fx, |
47c0bd1a | 674 | .machine_check = machine_check_generic, |
80f15dc7 | 675 | .platform = "ppc750", |
1da177e4 LT |
676 | }, |
677 | { /* 740/750 (L2CR bit need fixup for 740) */ | |
678 | .pvr_mask = 0xffff0000, | |
679 | .pvr_value = 0x00080000, | |
680 | .cpu_name = "740/750", | |
10b35d99 | 681 | .cpu_features = CPU_FTRS_740, |
fab5db97 | 682 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
683 | .icache_bsize = 32, |
684 | .dcache_bsize = 32, | |
685 | .num_pmcs = 4, | |
80f15dc7 | 686 | .cpu_setup = __setup_cpu_750, |
47c0bd1a | 687 | .machine_check = machine_check_generic, |
80f15dc7 | 688 | .platform = "ppc750", |
1da177e4 LT |
689 | }, |
690 | { /* 7400 rev 1.1 ? (no TAU) */ | |
691 | .pvr_mask = 0xffffffff, | |
692 | .pvr_value = 0x000c1101, | |
693 | .cpu_name = "7400 (1.1)", | |
10b35d99 | 694 | .cpu_features = CPU_FTRS_7400_NOTAU, |
fab5db97 PM |
695 | .cpu_user_features = COMMON_USER | |
696 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, | |
1da177e4 LT |
697 | .icache_bsize = 32, |
698 | .dcache_bsize = 32, | |
699 | .num_pmcs = 4, | |
80f15dc7 | 700 | .cpu_setup = __setup_cpu_7400, |
47c0bd1a | 701 | .machine_check = machine_check_generic, |
80f15dc7 | 702 | .platform = "ppc7400", |
1da177e4 LT |
703 | }, |
704 | { /* 7400 */ | |
705 | .pvr_mask = 0xffff0000, | |
706 | .pvr_value = 0x000c0000, | |
707 | .cpu_name = "7400", | |
10b35d99 | 708 | .cpu_features = CPU_FTRS_7400, |
fab5db97 PM |
709 | .cpu_user_features = COMMON_USER | |
710 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, | |
1da177e4 LT |
711 | .icache_bsize = 32, |
712 | .dcache_bsize = 32, | |
713 | .num_pmcs = 4, | |
80f15dc7 | 714 | .cpu_setup = __setup_cpu_7400, |
47c0bd1a | 715 | .machine_check = machine_check_generic, |
80f15dc7 | 716 | .platform = "ppc7400", |
1da177e4 LT |
717 | }, |
718 | { /* 7410 */ | |
719 | .pvr_mask = 0xffff0000, | |
720 | .pvr_value = 0x800c0000, | |
721 | .cpu_name = "7410", | |
10b35d99 | 722 | .cpu_features = CPU_FTRS_7400, |
fab5db97 PM |
723 | .cpu_user_features = COMMON_USER | |
724 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, | |
1da177e4 LT |
725 | .icache_bsize = 32, |
726 | .dcache_bsize = 32, | |
727 | .num_pmcs = 4, | |
80f15dc7 | 728 | .cpu_setup = __setup_cpu_7410, |
47c0bd1a | 729 | .machine_check = machine_check_generic, |
80f15dc7 | 730 | .platform = "ppc7400", |
1da177e4 LT |
731 | }, |
732 | { /* 7450 2.0 - no doze/nap */ | |
733 | .pvr_mask = 0xffffffff, | |
734 | .pvr_value = 0x80000200, | |
735 | .cpu_name = "7450", | |
10b35d99 | 736 | .cpu_features = CPU_FTRS_7450_20, |
fab5db97 PM |
737 | .cpu_user_features = COMMON_USER | |
738 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, | |
1da177e4 LT |
739 | .icache_bsize = 32, |
740 | .dcache_bsize = 32, | |
741 | .num_pmcs = 6, | |
555d97ac | 742 | .cpu_setup = __setup_cpu_745x, |
555d97ac | 743 | .oprofile_cpu_type = "ppc/7450", |
7a45fb19 | 744 | .oprofile_type = PPC_OPROFILE_G4, |
47c0bd1a | 745 | .machine_check = machine_check_generic, |
80f15dc7 | 746 | .platform = "ppc7450", |
1da177e4 LT |
747 | }, |
748 | { /* 7450 2.1 */ | |
749 | .pvr_mask = 0xffffffff, | |
750 | .pvr_value = 0x80000201, | |
751 | .cpu_name = "7450", | |
10b35d99 | 752 | .cpu_features = CPU_FTRS_7450_21, |
fab5db97 PM |
753 | .cpu_user_features = COMMON_USER | |
754 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, | |
1da177e4 LT |
755 | .icache_bsize = 32, |
756 | .dcache_bsize = 32, | |
757 | .num_pmcs = 6, | |
555d97ac | 758 | .cpu_setup = __setup_cpu_745x, |
555d97ac | 759 | .oprofile_cpu_type = "ppc/7450", |
7a45fb19 | 760 | .oprofile_type = PPC_OPROFILE_G4, |
47c0bd1a | 761 | .machine_check = machine_check_generic, |
80f15dc7 | 762 | .platform = "ppc7450", |
1da177e4 LT |
763 | }, |
764 | { /* 7450 2.3 and newer */ | |
765 | .pvr_mask = 0xffff0000, | |
766 | .pvr_value = 0x80000000, | |
767 | .cpu_name = "7450", | |
10b35d99 | 768 | .cpu_features = CPU_FTRS_7450_23, |
fab5db97 PM |
769 | .cpu_user_features = COMMON_USER | |
770 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, | |
1da177e4 LT |
771 | .icache_bsize = 32, |
772 | .dcache_bsize = 32, | |
773 | .num_pmcs = 6, | |
555d97ac | 774 | .cpu_setup = __setup_cpu_745x, |
555d97ac | 775 | .oprofile_cpu_type = "ppc/7450", |
7a45fb19 | 776 | .oprofile_type = PPC_OPROFILE_G4, |
47c0bd1a | 777 | .machine_check = machine_check_generic, |
80f15dc7 | 778 | .platform = "ppc7450", |
1da177e4 LT |
779 | }, |
780 | { /* 7455 rev 1.x */ | |
781 | .pvr_mask = 0xffffff00, | |
782 | .pvr_value = 0x80010100, | |
783 | .cpu_name = "7455", | |
10b35d99 | 784 | .cpu_features = CPU_FTRS_7455_1, |
fab5db97 PM |
785 | .cpu_user_features = COMMON_USER | |
786 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, | |
1da177e4 LT |
787 | .icache_bsize = 32, |
788 | .dcache_bsize = 32, | |
789 | .num_pmcs = 6, | |
555d97ac | 790 | .cpu_setup = __setup_cpu_745x, |
555d97ac | 791 | .oprofile_cpu_type = "ppc/7450", |
7a45fb19 | 792 | .oprofile_type = PPC_OPROFILE_G4, |
47c0bd1a | 793 | .machine_check = machine_check_generic, |
80f15dc7 | 794 | .platform = "ppc7450", |
1da177e4 LT |
795 | }, |
796 | { /* 7455 rev 2.0 */ | |
797 | .pvr_mask = 0xffffffff, | |
798 | .pvr_value = 0x80010200, | |
799 | .cpu_name = "7455", | |
10b35d99 | 800 | .cpu_features = CPU_FTRS_7455_20, |
fab5db97 PM |
801 | .cpu_user_features = COMMON_USER | |
802 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, | |
1da177e4 LT |
803 | .icache_bsize = 32, |
804 | .dcache_bsize = 32, | |
805 | .num_pmcs = 6, | |
555d97ac | 806 | .cpu_setup = __setup_cpu_745x, |
555d97ac | 807 | .oprofile_cpu_type = "ppc/7450", |
7a45fb19 | 808 | .oprofile_type = PPC_OPROFILE_G4, |
47c0bd1a | 809 | .machine_check = machine_check_generic, |
80f15dc7 | 810 | .platform = "ppc7450", |
1da177e4 LT |
811 | }, |
812 | { /* 7455 others */ | |
813 | .pvr_mask = 0xffff0000, | |
814 | .pvr_value = 0x80010000, | |
815 | .cpu_name = "7455", | |
10b35d99 | 816 | .cpu_features = CPU_FTRS_7455, |
fab5db97 PM |
817 | .cpu_user_features = COMMON_USER | |
818 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, | |
1da177e4 LT |
819 | .icache_bsize = 32, |
820 | .dcache_bsize = 32, | |
821 | .num_pmcs = 6, | |
555d97ac | 822 | .cpu_setup = __setup_cpu_745x, |
555d97ac | 823 | .oprofile_cpu_type = "ppc/7450", |
7a45fb19 | 824 | .oprofile_type = PPC_OPROFILE_G4, |
47c0bd1a | 825 | .machine_check = machine_check_generic, |
80f15dc7 | 826 | .platform = "ppc7450", |
1da177e4 LT |
827 | }, |
828 | { /* 7447/7457 Rev 1.0 */ | |
829 | .pvr_mask = 0xffffffff, | |
830 | .pvr_value = 0x80020100, | |
831 | .cpu_name = "7447/7457", | |
10b35d99 | 832 | .cpu_features = CPU_FTRS_7447_10, |
fab5db97 PM |
833 | .cpu_user_features = COMMON_USER | |
834 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, | |
1da177e4 LT |
835 | .icache_bsize = 32, |
836 | .dcache_bsize = 32, | |
837 | .num_pmcs = 6, | |
555d97ac | 838 | .cpu_setup = __setup_cpu_745x, |
555d97ac | 839 | .oprofile_cpu_type = "ppc/7450", |
7a45fb19 | 840 | .oprofile_type = PPC_OPROFILE_G4, |
47c0bd1a | 841 | .machine_check = machine_check_generic, |
80f15dc7 | 842 | .platform = "ppc7450", |
1da177e4 LT |
843 | }, |
844 | { /* 7447/7457 Rev 1.1 */ | |
845 | .pvr_mask = 0xffffffff, | |
846 | .pvr_value = 0x80020101, | |
847 | .cpu_name = "7447/7457", | |
10b35d99 | 848 | .cpu_features = CPU_FTRS_7447_10, |
fab5db97 PM |
849 | .cpu_user_features = COMMON_USER | |
850 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, | |
1da177e4 LT |
851 | .icache_bsize = 32, |
852 | .dcache_bsize = 32, | |
853 | .num_pmcs = 6, | |
555d97ac | 854 | .cpu_setup = __setup_cpu_745x, |
555d97ac | 855 | .oprofile_cpu_type = "ppc/7450", |
7a45fb19 | 856 | .oprofile_type = PPC_OPROFILE_G4, |
47c0bd1a | 857 | .machine_check = machine_check_generic, |
80f15dc7 | 858 | .platform = "ppc7450", |
1da177e4 LT |
859 | }, |
860 | { /* 7447/7457 Rev 1.2 and later */ | |
861 | .pvr_mask = 0xffff0000, | |
862 | .pvr_value = 0x80020000, | |
863 | .cpu_name = "7447/7457", | |
10b35d99 | 864 | .cpu_features = CPU_FTRS_7447, |
fab5db97 | 865 | .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
1da177e4 LT |
866 | .icache_bsize = 32, |
867 | .dcache_bsize = 32, | |
868 | .num_pmcs = 6, | |
555d97ac | 869 | .cpu_setup = __setup_cpu_745x, |
555d97ac | 870 | .oprofile_cpu_type = "ppc/7450", |
7a45fb19 | 871 | .oprofile_type = PPC_OPROFILE_G4, |
47c0bd1a | 872 | .machine_check = machine_check_generic, |
80f15dc7 | 873 | .platform = "ppc7450", |
1da177e4 LT |
874 | }, |
875 | { /* 7447A */ | |
876 | .pvr_mask = 0xffff0000, | |
877 | .pvr_value = 0x80030000, | |
878 | .cpu_name = "7447A", | |
10b35d99 | 879 | .cpu_features = CPU_FTRS_7447A, |
fab5db97 PM |
880 | .cpu_user_features = COMMON_USER | |
881 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, | |
bbde630b KG |
882 | .icache_bsize = 32, |
883 | .dcache_bsize = 32, | |
884 | .num_pmcs = 6, | |
555d97ac | 885 | .cpu_setup = __setup_cpu_745x, |
555d97ac | 886 | .oprofile_cpu_type = "ppc/7450", |
7a45fb19 | 887 | .oprofile_type = PPC_OPROFILE_G4, |
47c0bd1a | 888 | .machine_check = machine_check_generic, |
80f15dc7 | 889 | .platform = "ppc7450", |
bbde630b KG |
890 | }, |
891 | { /* 7448 */ | |
892 | .pvr_mask = 0xffff0000, | |
893 | .pvr_value = 0x80040000, | |
894 | .cpu_name = "7448", | |
3d372548 | 895 | .cpu_features = CPU_FTRS_7448, |
fab5db97 PM |
896 | .cpu_user_features = COMMON_USER | |
897 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, | |
1da177e4 LT |
898 | .icache_bsize = 32, |
899 | .dcache_bsize = 32, | |
900 | .num_pmcs = 6, | |
555d97ac | 901 | .cpu_setup = __setup_cpu_745x, |
555d97ac | 902 | .oprofile_cpu_type = "ppc/7450", |
7a45fb19 | 903 | .oprofile_type = PPC_OPROFILE_G4, |
47c0bd1a | 904 | .machine_check = machine_check_generic, |
80f15dc7 | 905 | .platform = "ppc7450", |
1da177e4 LT |
906 | }, |
907 | { /* 82xx (8240, 8245, 8260 are all 603e cores) */ | |
908 | .pvr_mask = 0x7fff0000, | |
909 | .pvr_value = 0x00810000, | |
910 | .cpu_name = "82xx", | |
10b35d99 | 911 | .cpu_features = CPU_FTRS_82XX, |
4920960f | 912 | .cpu_user_features = COMMON_USER, |
1da177e4 LT |
913 | .icache_bsize = 32, |
914 | .dcache_bsize = 32, | |
80f15dc7 | 915 | .cpu_setup = __setup_cpu_603, |
47c0bd1a | 916 | .machine_check = machine_check_generic, |
80f15dc7 | 917 | .platform = "ppc603", |
1da177e4 LT |
918 | }, |
919 | { /* All G2_LE (603e core, plus some) have the same pvr */ | |
920 | .pvr_mask = 0x7fff0000, | |
921 | .pvr_value = 0x00820000, | |
922 | .cpu_name = "G2_LE", | |
10b35d99 | 923 | .cpu_features = CPU_FTRS_G2_LE, |
4920960f | 924 | .cpu_user_features = COMMON_USER, |
1da177e4 LT |
925 | .icache_bsize = 32, |
926 | .dcache_bsize = 32, | |
80f15dc7 | 927 | .cpu_setup = __setup_cpu_603, |
47c0bd1a | 928 | .machine_check = machine_check_generic, |
80f15dc7 | 929 | .platform = "ppc603", |
1da177e4 | 930 | }, |
6c4a2501 | 931 | { /* e300c1 (a 603e core, plus some) on 83xx */ |
1da177e4 LT |
932 | .pvr_mask = 0x7fff0000, |
933 | .pvr_value = 0x00830000, | |
6c4a2501 | 934 | .cpu_name = "e300c1", |
10b35d99 | 935 | .cpu_features = CPU_FTRS_E300, |
4920960f | 936 | .cpu_user_features = COMMON_USER, |
1da177e4 LT |
937 | .icache_bsize = 32, |
938 | .dcache_bsize = 32, | |
80f15dc7 | 939 | .cpu_setup = __setup_cpu_603, |
47c0bd1a | 940 | .machine_check = machine_check_generic, |
80f15dc7 | 941 | .platform = "ppc603", |
1da177e4 | 942 | }, |
6c4a2501 KP |
943 | { /* e300c2 (an e300c1 core, plus some, minus FPU) on 83xx */ |
944 | .pvr_mask = 0x7fff0000, | |
945 | .pvr_value = 0x00840000, | |
946 | .cpu_name = "e300c2", | |
aa42c69c | 947 | .cpu_features = CPU_FTRS_E300C2, |
6c4a2501 KP |
948 | .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU, |
949 | .icache_bsize = 32, | |
950 | .dcache_bsize = 32, | |
951 | .cpu_setup = __setup_cpu_603, | |
47c0bd1a | 952 | .machine_check = machine_check_generic, |
6c4a2501 KP |
953 | .platform = "ppc603", |
954 | }, | |
a58d5244 | 955 | { /* e300c3 (e300c1, plus one IU, half cache size) on 83xx */ |
57933f8f SW |
956 | .pvr_mask = 0x7fff0000, |
957 | .pvr_value = 0x00850000, | |
958 | .cpu_name = "e300c3", | |
959 | .cpu_features = CPU_FTRS_E300, | |
960 | .cpu_user_features = COMMON_USER, | |
961 | .icache_bsize = 32, | |
962 | .dcache_bsize = 32, | |
963 | .cpu_setup = __setup_cpu_603, | |
1347a2c1 AF |
964 | .num_pmcs = 4, |
965 | .oprofile_cpu_type = "ppc/e300", | |
966 | .oprofile_type = PPC_OPROFILE_FSL_EMB, | |
57933f8f SW |
967 | .platform = "ppc603", |
968 | }, | |
a58d5244 LY |
969 | { /* e300c4 (e300c1, plus one IU) */ |
970 | .pvr_mask = 0x7fff0000, | |
971 | .pvr_value = 0x00860000, | |
972 | .cpu_name = "e300c4", | |
973 | .cpu_features = CPU_FTRS_E300, | |
974 | .cpu_user_features = COMMON_USER, | |
975 | .icache_bsize = 32, | |
976 | .dcache_bsize = 32, | |
977 | .cpu_setup = __setup_cpu_603, | |
47c0bd1a | 978 | .machine_check = machine_check_generic, |
1347a2c1 AF |
979 | .num_pmcs = 4, |
980 | .oprofile_cpu_type = "ppc/e300", | |
981 | .oprofile_type = PPC_OPROFILE_FSL_EMB, | |
a58d5244 LY |
982 | .platform = "ppc603", |
983 | }, | |
1da177e4 LT |
984 | { /* default match, we assume split I/D cache & TB (non-601)... */ |
985 | .pvr_mask = 0x00000000, | |
986 | .pvr_value = 0x00000000, | |
987 | .cpu_name = "(generic PPC)", | |
10b35d99 | 988 | .cpu_features = CPU_FTRS_CLASSIC32, |
4920960f | 989 | .cpu_user_features = COMMON_USER, |
1da177e4 LT |
990 | .icache_bsize = 32, |
991 | .dcache_bsize = 32, | |
47c0bd1a | 992 | .machine_check = machine_check_generic, |
80f15dc7 | 993 | .platform = "ppc603", |
1da177e4 LT |
994 | }, |
995 | #endif /* CLASSIC_PPC */ | |
1da177e4 LT |
996 | #ifdef CONFIG_8xx |
997 | { /* 8xx */ | |
998 | .pvr_mask = 0xffff0000, | |
999 | .pvr_value = 0x00500000, | |
1000 | .cpu_name = "8xx", | |
1001 | /* CPU_FTR_MAYBE_CAN_DOZE is possible, | |
1002 | * if the 8xx code is there.... */ | |
10b35d99 | 1003 | .cpu_features = CPU_FTRS_8XX, |
1da177e4 LT |
1004 | .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU, |
1005 | .icache_bsize = 16, | |
1006 | .dcache_bsize = 16, | |
80f15dc7 | 1007 | .platform = "ppc823", |
1da177e4 LT |
1008 | }, |
1009 | #endif /* CONFIG_8xx */ | |
1010 | #ifdef CONFIG_40x | |
1011 | { /* 403GC */ | |
1012 | .pvr_mask = 0xffffff00, | |
1013 | .pvr_value = 0x00200200, | |
1014 | .cpu_name = "403GC", | |
10b35d99 | 1015 | .cpu_features = CPU_FTRS_40X, |
1da177e4 LT |
1016 | .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU, |
1017 | .icache_bsize = 16, | |
1018 | .dcache_bsize = 16, | |
47c0bd1a | 1019 | .machine_check = machine_check_4xx, |
80f15dc7 | 1020 | .platform = "ppc403", |
1da177e4 LT |
1021 | }, |
1022 | { /* 403GCX */ | |
1023 | .pvr_mask = 0xffffff00, | |
1024 | .pvr_value = 0x00201400, | |
1025 | .cpu_name = "403GCX", | |
10b35d99 | 1026 | .cpu_features = CPU_FTRS_40X, |
d8e998c5 BH |
1027 | .cpu_user_features = PPC_FEATURE_32 | |
1028 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_NO_TB, | |
1da177e4 LT |
1029 | .icache_bsize = 16, |
1030 | .dcache_bsize = 16, | |
47c0bd1a | 1031 | .machine_check = machine_check_4xx, |
80f15dc7 | 1032 | .platform = "ppc403", |
1da177e4 LT |
1033 | }, |
1034 | { /* 403G ?? */ | |
1035 | .pvr_mask = 0xffff0000, | |
1036 | .pvr_value = 0x00200000, | |
1037 | .cpu_name = "403G ??", | |
10b35d99 | 1038 | .cpu_features = CPU_FTRS_40X, |
1da177e4 LT |
1039 | .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU, |
1040 | .icache_bsize = 16, | |
1041 | .dcache_bsize = 16, | |
47c0bd1a | 1042 | .machine_check = machine_check_4xx, |
80f15dc7 | 1043 | .platform = "ppc403", |
1da177e4 LT |
1044 | }, |
1045 | { /* 405GP */ | |
1046 | .pvr_mask = 0xffff0000, | |
1047 | .pvr_value = 0x40110000, | |
1048 | .cpu_name = "405GP", | |
10b35d99 | 1049 | .cpu_features = CPU_FTRS_40X, |
1da177e4 LT |
1050 | .cpu_user_features = PPC_FEATURE_32 | |
1051 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, | |
1052 | .icache_bsize = 32, | |
1053 | .dcache_bsize = 32, | |
47c0bd1a | 1054 | .machine_check = machine_check_4xx, |
80f15dc7 | 1055 | .platform = "ppc405", |
1da177e4 LT |
1056 | }, |
1057 | { /* STB 03xxx */ | |
1058 | .pvr_mask = 0xffff0000, | |
1059 | .pvr_value = 0x40130000, | |
1060 | .cpu_name = "STB03xxx", | |
10b35d99 | 1061 | .cpu_features = CPU_FTRS_40X, |
1da177e4 LT |
1062 | .cpu_user_features = PPC_FEATURE_32 | |
1063 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, | |
1064 | .icache_bsize = 32, | |
1065 | .dcache_bsize = 32, | |
47c0bd1a | 1066 | .machine_check = machine_check_4xx, |
80f15dc7 | 1067 | .platform = "ppc405", |
1da177e4 LT |
1068 | }, |
1069 | { /* STB 04xxx */ | |
1070 | .pvr_mask = 0xffff0000, | |
1071 | .pvr_value = 0x41810000, | |
1072 | .cpu_name = "STB04xxx", | |
10b35d99 | 1073 | .cpu_features = CPU_FTRS_40X, |
1da177e4 LT |
1074 | .cpu_user_features = PPC_FEATURE_32 | |
1075 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, | |
1076 | .icache_bsize = 32, | |
1077 | .dcache_bsize = 32, | |
47c0bd1a | 1078 | .machine_check = machine_check_4xx, |
80f15dc7 | 1079 | .platform = "ppc405", |
1da177e4 LT |
1080 | }, |
1081 | { /* NP405L */ | |
1082 | .pvr_mask = 0xffff0000, | |
1083 | .pvr_value = 0x41610000, | |
1084 | .cpu_name = "NP405L", | |
10b35d99 | 1085 | .cpu_features = CPU_FTRS_40X, |
1da177e4 LT |
1086 | .cpu_user_features = PPC_FEATURE_32 | |
1087 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, | |
1088 | .icache_bsize = 32, | |
1089 | .dcache_bsize = 32, | |
47c0bd1a | 1090 | .machine_check = machine_check_4xx, |
80f15dc7 | 1091 | .platform = "ppc405", |
1da177e4 LT |
1092 | }, |
1093 | { /* NP4GS3 */ | |
1094 | .pvr_mask = 0xffff0000, | |
1095 | .pvr_value = 0x40B10000, | |
1096 | .cpu_name = "NP4GS3", | |
10b35d99 | 1097 | .cpu_features = CPU_FTRS_40X, |
1da177e4 LT |
1098 | .cpu_user_features = PPC_FEATURE_32 | |
1099 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, | |
1100 | .icache_bsize = 32, | |
1101 | .dcache_bsize = 32, | |
47c0bd1a | 1102 | .machine_check = machine_check_4xx, |
80f15dc7 | 1103 | .platform = "ppc405", |
1da177e4 LT |
1104 | }, |
1105 | { /* NP405H */ | |
1106 | .pvr_mask = 0xffff0000, | |
1107 | .pvr_value = 0x41410000, | |
1108 | .cpu_name = "NP405H", | |
10b35d99 | 1109 | .cpu_features = CPU_FTRS_40X, |
1da177e4 LT |
1110 | .cpu_user_features = PPC_FEATURE_32 | |
1111 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, | |
1112 | .icache_bsize = 32, | |
1113 | .dcache_bsize = 32, | |
47c0bd1a | 1114 | .machine_check = machine_check_4xx, |
80f15dc7 | 1115 | .platform = "ppc405", |
1da177e4 LT |
1116 | }, |
1117 | { /* 405GPr */ | |
1118 | .pvr_mask = 0xffff0000, | |
1119 | .pvr_value = 0x50910000, | |
1120 | .cpu_name = "405GPr", | |
10b35d99 | 1121 | .cpu_features = CPU_FTRS_40X, |
1da177e4 LT |
1122 | .cpu_user_features = PPC_FEATURE_32 | |
1123 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, | |
1124 | .icache_bsize = 32, | |
1125 | .dcache_bsize = 32, | |
47c0bd1a | 1126 | .machine_check = machine_check_4xx, |
80f15dc7 | 1127 | .platform = "ppc405", |
1da177e4 LT |
1128 | }, |
1129 | { /* STBx25xx */ | |
1130 | .pvr_mask = 0xffff0000, | |
1131 | .pvr_value = 0x51510000, | |
1132 | .cpu_name = "STBx25xx", | |
10b35d99 | 1133 | .cpu_features = CPU_FTRS_40X, |
1da177e4 LT |
1134 | .cpu_user_features = PPC_FEATURE_32 | |
1135 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, | |
1136 | .icache_bsize = 32, | |
1137 | .dcache_bsize = 32, | |
47c0bd1a | 1138 | .machine_check = machine_check_4xx, |
80f15dc7 | 1139 | .platform = "ppc405", |
1da177e4 LT |
1140 | }, |
1141 | { /* 405LP */ | |
1142 | .pvr_mask = 0xffff0000, | |
1143 | .pvr_value = 0x41F10000, | |
1144 | .cpu_name = "405LP", | |
10b35d99 | 1145 | .cpu_features = CPU_FTRS_40X, |
1da177e4 LT |
1146 | .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU, |
1147 | .icache_bsize = 32, | |
1148 | .dcache_bsize = 32, | |
47c0bd1a | 1149 | .machine_check = machine_check_4xx, |
80f15dc7 | 1150 | .platform = "ppc405", |
1da177e4 LT |
1151 | }, |
1152 | { /* Xilinx Virtex-II Pro */ | |
72646c7f | 1153 | .pvr_mask = 0xfffff000, |
1da177e4 LT |
1154 | .pvr_value = 0x20010000, |
1155 | .cpu_name = "Virtex-II Pro", | |
10b35d99 | 1156 | .cpu_features = CPU_FTRS_40X, |
1da177e4 LT |
1157 | .cpu_user_features = PPC_FEATURE_32 | |
1158 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, | |
1159 | .icache_bsize = 32, | |
1160 | .dcache_bsize = 32, | |
47c0bd1a | 1161 | .machine_check = machine_check_4xx, |
80f15dc7 | 1162 | .platform = "ppc405", |
1da177e4 | 1163 | }, |
72646c7f GL |
1164 | { /* Xilinx Virtex-4 FX */ |
1165 | .pvr_mask = 0xfffff000, | |
1166 | .pvr_value = 0x20011000, | |
1167 | .cpu_name = "Virtex-4 FX", | |
1168 | .cpu_features = CPU_FTRS_40X, | |
1169 | .cpu_user_features = PPC_FEATURE_32 | | |
1170 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, | |
1171 | .icache_bsize = 32, | |
1172 | .dcache_bsize = 32, | |
47c0bd1a | 1173 | .machine_check = machine_check_4xx, |
838fdb4d | 1174 | .platform = "ppc405", |
72646c7f | 1175 | }, |
ad95d609 ES |
1176 | { /* 405EP */ |
1177 | .pvr_mask = 0xffff0000, | |
1178 | .pvr_value = 0x51210000, | |
1179 | .cpu_name = "405EP", | |
10b35d99 | 1180 | .cpu_features = CPU_FTRS_40X, |
5d8476c8 SR |
1181 | .cpu_user_features = PPC_FEATURE_32 | |
1182 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, | |
1183 | .icache_bsize = 32, | |
1184 | .dcache_bsize = 32, | |
47c0bd1a | 1185 | .machine_check = machine_check_4xx, |
5d8476c8 SR |
1186 | .platform = "ppc405", |
1187 | }, | |
1188 | { /* 405EX */ | |
b676d84e SR |
1189 | .pvr_mask = 0xffff0004, |
1190 | .pvr_value = 0x12910004, | |
5d8476c8 SR |
1191 | .cpu_name = "405EX", |
1192 | .cpu_features = CPU_FTRS_40X, | |
ad95d609 ES |
1193 | .cpu_user_features = PPC_FEATURE_32 | |
1194 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, | |
1195 | .icache_bsize = 32, | |
1196 | .dcache_bsize = 32, | |
47c0bd1a | 1197 | .machine_check = machine_check_4xx, |
80f15dc7 | 1198 | .platform = "ppc405", |
ad95d609 | 1199 | }, |
b676d84e SR |
1200 | { /* 405EXr */ |
1201 | .pvr_mask = 0xffff0004, | |
1202 | .pvr_value = 0x12910000, | |
1203 | .cpu_name = "405EXr", | |
1204 | .cpu_features = CPU_FTRS_40X, | |
1205 | .cpu_user_features = PPC_FEATURE_32 | | |
1206 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, | |
1207 | .icache_bsize = 32, | |
1208 | .dcache_bsize = 32, | |
1209 | .machine_check = machine_check_4xx, | |
1210 | .platform = "ppc405", | |
1211 | }, | |
1da177e4 LT |
1212 | |
1213 | #endif /* CONFIG_40x */ | |
1214 | #ifdef CONFIG_44x | |
c9cf73ae MP |
1215 | { |
1216 | .pvr_mask = 0xf0000fff, | |
1217 | .pvr_value = 0x40000850, | |
d1dfc35d VB |
1218 | .cpu_name = "440GR Rev. A", |
1219 | .cpu_features = CPU_FTRS_44X, | |
1220 | .cpu_user_features = COMMON_USER_BOOKE, | |
1221 | .icache_bsize = 32, | |
1222 | .dcache_bsize = 32, | |
47c0bd1a | 1223 | .machine_check = machine_check_4xx, |
d1dfc35d VB |
1224 | .platform = "ppc440", |
1225 | }, | |
1226 | { /* Use logical PVR for 440EP (logical pvr = pvr | 0x8) */ | |
1227 | .pvr_mask = 0xf0000fff, | |
1228 | .pvr_value = 0x40000858, | |
c9cf73ae | 1229 | .cpu_name = "440EP Rev. A", |
10b35d99 | 1230 | .cpu_features = CPU_FTRS_44X, |
80f15dc7 | 1231 | .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU, |
c9cf73ae MP |
1232 | .icache_bsize = 32, |
1233 | .dcache_bsize = 32, | |
8112753b | 1234 | .cpu_setup = __setup_cpu_440ep, |
47c0bd1a | 1235 | .machine_check = machine_check_4xx, |
80f15dc7 | 1236 | .platform = "ppc440", |
c9cf73ae MP |
1237 | }, |
1238 | { | |
1239 | .pvr_mask = 0xf0000fff, | |
1240 | .pvr_value = 0x400008d3, | |
d1dfc35d | 1241 | .cpu_name = "440GR Rev. B", |
10b35d99 | 1242 | .cpu_features = CPU_FTRS_44X, |
80f15dc7 | 1243 | .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU, |
c9cf73ae MP |
1244 | .icache_bsize = 32, |
1245 | .dcache_bsize = 32, | |
47c0bd1a | 1246 | .machine_check = machine_check_4xx, |
80f15dc7 | 1247 | .platform = "ppc440", |
c9cf73ae | 1248 | }, |
3f8fc3e0 SM |
1249 | { /* Matches both physical and logical PVR for 440EP (logical pvr = pvr | 0x8) */ |
1250 | .pvr_mask = 0xf0000ff7, | |
1251 | .pvr_value = 0x400008d4, | |
1252 | .cpu_name = "440EP Rev. C", | |
1253 | .cpu_features = CPU_FTRS_44X, | |
1254 | .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU, | |
1255 | .icache_bsize = 32, | |
1256 | .dcache_bsize = 32, | |
1257 | .cpu_setup = __setup_cpu_440ep, | |
1258 | .machine_check = machine_check_4xx, | |
1259 | .platform = "ppc440", | |
1260 | }, | |
d1dfc35d VB |
1261 | { /* Use logical PVR for 440EP (logical pvr = pvr | 0x8) */ |
1262 | .pvr_mask = 0xf0000fff, | |
1263 | .pvr_value = 0x400008db, | |
1264 | .cpu_name = "440EP Rev. B", | |
15fc993e VB |
1265 | .cpu_features = CPU_FTRS_44X, |
1266 | .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU, | |
1267 | .icache_bsize = 32, | |
1268 | .dcache_bsize = 32, | |
d1dfc35d | 1269 | .cpu_setup = __setup_cpu_440ep, |
47c0bd1a | 1270 | .machine_check = machine_check_4xx, |
8112753b | 1271 | .platform = "ppc440", |
15fc993e VB |
1272 | }, |
1273 | { /* 440GRX */ | |
1274 | .pvr_mask = 0xf0000ffb, | |
d1dfc35d | 1275 | .pvr_value = 0x200008D0, |
15fc993e VB |
1276 | .cpu_name = "440GRX", |
1277 | .cpu_features = CPU_FTRS_44X, | |
1278 | .cpu_user_features = COMMON_USER_BOOKE, | |
1279 | .icache_bsize = 32, | |
1280 | .dcache_bsize = 32, | |
340ffd26 | 1281 | .cpu_setup = __setup_cpu_440grx, |
b2be3b15 | 1282 | .machine_check = machine_check_440A, |
340ffd26 | 1283 | .platform = "ppc440", |
15fc993e | 1284 | }, |
d1dfc35d VB |
1285 | { /* Use logical PVR for 440EPx (logical pvr = pvr | 0x8) */ |
1286 | .pvr_mask = 0xf0000ffb, | |
1287 | .pvr_value = 0x200008D8, | |
1288 | .cpu_name = "440EPX", | |
1289 | .cpu_features = CPU_FTRS_44X, | |
1290 | .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU, | |
1291 | .icache_bsize = 32, | |
1292 | .dcache_bsize = 32, | |
1293 | .cpu_setup = __setup_cpu_440epx, | |
47c0bd1a | 1294 | .machine_check = machine_check_440A, |
d1dfc35d VB |
1295 | .platform = "ppc440", |
1296 | }, | |
4920960f | 1297 | { /* 440GP Rev. B */ |
1da177e4 LT |
1298 | .pvr_mask = 0xf0000fff, |
1299 | .pvr_value = 0x40000440, | |
1300 | .cpu_name = "440GP Rev. B", | |
10b35d99 | 1301 | .cpu_features = CPU_FTRS_44X, |
80f15dc7 | 1302 | .cpu_user_features = COMMON_USER_BOOKE, |
1da177e4 LT |
1303 | .icache_bsize = 32, |
1304 | .dcache_bsize = 32, | |
47c0bd1a | 1305 | .machine_check = machine_check_4xx, |
80f15dc7 | 1306 | .platform = "ppc440gp", |
1da177e4 | 1307 | }, |
4920960f | 1308 | { /* 440GP Rev. C */ |
1da177e4 LT |
1309 | .pvr_mask = 0xf0000fff, |
1310 | .pvr_value = 0x40000481, | |
1311 | .cpu_name = "440GP Rev. C", | |
10b35d99 | 1312 | .cpu_features = CPU_FTRS_44X, |
80f15dc7 | 1313 | .cpu_user_features = COMMON_USER_BOOKE, |
1da177e4 LT |
1314 | .icache_bsize = 32, |
1315 | .dcache_bsize = 32, | |
47c0bd1a | 1316 | .machine_check = machine_check_4xx, |
80f15dc7 | 1317 | .platform = "ppc440gp", |
1da177e4 LT |
1318 | }, |
1319 | { /* 440GX Rev. A */ | |
1320 | .pvr_mask = 0xf0000fff, | |
1321 | .pvr_value = 0x50000850, | |
1322 | .cpu_name = "440GX Rev. A", | |
10b35d99 | 1323 | .cpu_features = CPU_FTRS_44X, |
80f15dc7 | 1324 | .cpu_user_features = COMMON_USER_BOOKE, |
1da177e4 LT |
1325 | .icache_bsize = 32, |
1326 | .dcache_bsize = 32, | |
47c0bd1a BH |
1327 | .cpu_setup = __setup_cpu_440gx, |
1328 | .machine_check = machine_check_440A, | |
80f15dc7 | 1329 | .platform = "ppc440", |
1da177e4 LT |
1330 | }, |
1331 | { /* 440GX Rev. B */ | |
1332 | .pvr_mask = 0xf0000fff, | |
1333 | .pvr_value = 0x50000851, | |
1334 | .cpu_name = "440GX Rev. B", | |
10b35d99 | 1335 | .cpu_features = CPU_FTRS_44X, |
80f15dc7 | 1336 | .cpu_user_features = COMMON_USER_BOOKE, |
1da177e4 LT |
1337 | .icache_bsize = 32, |
1338 | .dcache_bsize = 32, | |
47c0bd1a BH |
1339 | .cpu_setup = __setup_cpu_440gx, |
1340 | .machine_check = machine_check_440A, | |
80f15dc7 | 1341 | .platform = "ppc440", |
1da177e4 LT |
1342 | }, |
1343 | { /* 440GX Rev. C */ | |
1344 | .pvr_mask = 0xf0000fff, | |
1345 | .pvr_value = 0x50000892, | |
1346 | .cpu_name = "440GX Rev. C", | |
10b35d99 | 1347 | .cpu_features = CPU_FTRS_44X, |
80f15dc7 | 1348 | .cpu_user_features = COMMON_USER_BOOKE, |
1da177e4 LT |
1349 | .icache_bsize = 32, |
1350 | .dcache_bsize = 32, | |
47c0bd1a BH |
1351 | .cpu_setup = __setup_cpu_440gx, |
1352 | .machine_check = machine_check_440A, | |
80f15dc7 | 1353 | .platform = "ppc440", |
1da177e4 | 1354 | }, |
9149fb3b ES |
1355 | { /* 440GX Rev. F */ |
1356 | .pvr_mask = 0xf0000fff, | |
1357 | .pvr_value = 0x50000894, | |
1358 | .cpu_name = "440GX Rev. F", | |
10b35d99 | 1359 | .cpu_features = CPU_FTRS_44X, |
80f15dc7 | 1360 | .cpu_user_features = COMMON_USER_BOOKE, |
9149fb3b ES |
1361 | .icache_bsize = 32, |
1362 | .dcache_bsize = 32, | |
47c0bd1a BH |
1363 | .cpu_setup = __setup_cpu_440gx, |
1364 | .machine_check = machine_check_440A, | |
80f15dc7 | 1365 | .platform = "ppc440", |
9149fb3b | 1366 | }, |
656de7e4 | 1367 | { /* 440SP Rev. A */ |
333e6154 RD |
1368 | .pvr_mask = 0xfff00fff, |
1369 | .pvr_value = 0x53200891, | |
656de7e4 | 1370 | .cpu_name = "440SP Rev. A", |
10b35d99 | 1371 | .cpu_features = CPU_FTRS_44X, |
80f15dc7 | 1372 | .cpu_user_features = COMMON_USER_BOOKE, |
656de7e4 MP |
1373 | .icache_bsize = 32, |
1374 | .dcache_bsize = 32, | |
47c0bd1a | 1375 | .machine_check = machine_check_4xx, |
80f15dc7 | 1376 | .platform = "ppc440", |
656de7e4 | 1377 | }, |
b0f7b8bc | 1378 | { /* 440SPe Rev. A */ |
333e6154 RD |
1379 | .pvr_mask = 0xfff00fff, |
1380 | .pvr_value = 0x53400890, | |
1381 | .cpu_name = "440SPe Rev. A", | |
1382 | .cpu_features = CPU_FTRS_44X, | |
1383 | .cpu_user_features = COMMON_USER_BOOKE, | |
1384 | .icache_bsize = 32, | |
1385 | .dcache_bsize = 32, | |
47c0bd1a BH |
1386 | .cpu_setup = __setup_cpu_440spe, |
1387 | .machine_check = machine_check_440A, | |
333e6154 RD |
1388 | .platform = "ppc440", |
1389 | }, | |
1390 | { /* 440SPe Rev. B */ | |
1391 | .pvr_mask = 0xfff00fff, | |
1392 | .pvr_value = 0x53400891, | |
1393 | .cpu_name = "440SPe Rev. B", | |
a147c585 | 1394 | .cpu_features = CPU_FTRS_44X, |
80f15dc7 | 1395 | .cpu_user_features = COMMON_USER_BOOKE, |
b0f7b8bc RD |
1396 | .icache_bsize = 32, |
1397 | .dcache_bsize = 32, | |
47c0bd1a BH |
1398 | .cpu_setup = __setup_cpu_440spe, |
1399 | .machine_check = machine_check_440A, | |
80f15dc7 | 1400 | .platform = "ppc440", |
b0f7b8bc | 1401 | }, |
464076a4 SR |
1402 | { /* 460EX */ |
1403 | .pvr_mask = 0xffff0002, | |
1404 | .pvr_value = 0x13020002, | |
1405 | .cpu_name = "460EX", | |
1406 | .cpu_features = CPU_FTRS_44X, | |
1407 | .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU, | |
1408 | .icache_bsize = 32, | |
1409 | .dcache_bsize = 32, | |
1410 | .cpu_setup = __setup_cpu_460ex, | |
1411 | .machine_check = machine_check_440A, | |
1412 | .platform = "ppc440", | |
1413 | }, | |
1414 | { /* 460GT */ | |
1415 | .pvr_mask = 0xffff0002, | |
1416 | .pvr_value = 0x13020000, | |
1417 | .cpu_name = "460GT", | |
1418 | .cpu_features = CPU_FTRS_44X, | |
1419 | .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU, | |
1420 | .icache_bsize = 32, | |
1421 | .dcache_bsize = 32, | |
1422 | .cpu_setup = __setup_cpu_460gt, | |
1423 | .machine_check = machine_check_440A, | |
1424 | .platform = "ppc440", | |
1425 | }, | |
1da177e4 | 1426 | #endif /* CONFIG_44x */ |
33d9e9b5 | 1427 | #ifdef CONFIG_FSL_BOOKE |
e3e414bc | 1428 | #ifdef CONFIG_E200 |
4920960f | 1429 | { /* e200z5 */ |
33d9e9b5 KG |
1430 | .pvr_mask = 0xfff00000, |
1431 | .pvr_value = 0x81000000, | |
1432 | .cpu_name = "e200z5", | |
1433 | /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */ | |
10b35d99 | 1434 | .cpu_features = CPU_FTRS_E200, |
80f15dc7 PM |
1435 | .cpu_user_features = COMMON_USER_BOOKE | |
1436 | PPC_FEATURE_HAS_EFP_SINGLE | | |
33d9e9b5 KG |
1437 | PPC_FEATURE_UNIFIED_CACHE, |
1438 | .dcache_bsize = 32, | |
47c0bd1a | 1439 | .machine_check = machine_check_e200, |
80f15dc7 | 1440 | .platform = "ppc5554", |
33d9e9b5 | 1441 | }, |
4920960f | 1442 | { /* e200z6 */ |
33d9e9b5 KG |
1443 | .pvr_mask = 0xfff00000, |
1444 | .pvr_value = 0x81100000, | |
1445 | .cpu_name = "e200z6", | |
1446 | /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */ | |
10b35d99 | 1447 | .cpu_features = CPU_FTRS_E200, |
80f15dc7 | 1448 | .cpu_user_features = COMMON_USER_BOOKE | |
5e14d21e KG |
1449 | PPC_FEATURE_HAS_SPE_COMP | |
1450 | PPC_FEATURE_HAS_EFP_SINGLE_COMP | | |
33d9e9b5 KG |
1451 | PPC_FEATURE_UNIFIED_CACHE, |
1452 | .dcache_bsize = 32, | |
47c0bd1a | 1453 | .machine_check = machine_check_e200, |
80f15dc7 | 1454 | .platform = "ppc5554", |
33d9e9b5 | 1455 | }, |
e3e414bc | 1456 | #elif defined(CONFIG_E500) |
4920960f | 1457 | { /* e500 */ |
1da177e4 LT |
1458 | .pvr_mask = 0xffff0000, |
1459 | .pvr_value = 0x80200000, | |
1460 | .cpu_name = "e500", | |
1461 | /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */ | |
10b35d99 | 1462 | .cpu_features = CPU_FTRS_E500, |
80f15dc7 | 1463 | .cpu_user_features = COMMON_USER_BOOKE | |
5e14d21e KG |
1464 | PPC_FEATURE_HAS_SPE_COMP | |
1465 | PPC_FEATURE_HAS_EFP_SINGLE_COMP, | |
1da177e4 LT |
1466 | .icache_bsize = 32, |
1467 | .dcache_bsize = 32, | |
1468 | .num_pmcs = 4, | |
555d97ac | 1469 | .oprofile_cpu_type = "ppc/e500", |
39aef685 | 1470 | .oprofile_type = PPC_OPROFILE_FSL_EMB, |
47c0bd1a | 1471 | .machine_check = machine_check_e500, |
80f15dc7 | 1472 | .platform = "ppc8540", |
1da177e4 | 1473 | }, |
4920960f | 1474 | { /* e500v2 */ |
5b37b700 KG |
1475 | .pvr_mask = 0xffff0000, |
1476 | .pvr_value = 0x80210000, | |
1477 | .cpu_name = "e500v2", | |
1478 | /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */ | |
10b35d99 | 1479 | .cpu_features = CPU_FTRS_E500_2, |
80f15dc7 | 1480 | .cpu_user_features = COMMON_USER_BOOKE | |
5e14d21e KG |
1481 | PPC_FEATURE_HAS_SPE_COMP | |
1482 | PPC_FEATURE_HAS_EFP_SINGLE_COMP | | |
1483 | PPC_FEATURE_HAS_EFP_DOUBLE_COMP, | |
5b37b700 KG |
1484 | .icache_bsize = 32, |
1485 | .dcache_bsize = 32, | |
1486 | .num_pmcs = 4, | |
555d97ac | 1487 | .oprofile_cpu_type = "ppc/e500", |
39aef685 | 1488 | .oprofile_type = PPC_OPROFILE_FSL_EMB, |
47c0bd1a | 1489 | .machine_check = machine_check_e500, |
80f15dc7 | 1490 | .platform = "ppc8548", |
5b37b700 | 1491 | }, |
1da177e4 | 1492 | #endif |
e3e414bc | 1493 | #endif |
1da177e4 LT |
1494 | #if !CLASSIC_PPC |
1495 | { /* default match */ | |
1496 | .pvr_mask = 0x00000000, | |
1497 | .pvr_value = 0x00000000, | |
1498 | .cpu_name = "(generic PPC)", | |
10b35d99 | 1499 | .cpu_features = CPU_FTRS_GENERIC_32, |
1da177e4 LT |
1500 | .cpu_user_features = PPC_FEATURE_32, |
1501 | .icache_bsize = 32, | |
1502 | .dcache_bsize = 32, | |
80f15dc7 | 1503 | .platform = "powerpc", |
1da177e4 LT |
1504 | } |
1505 | #endif /* !CLASSIC_PPC */ | |
4920960f | 1506 | #endif /* CONFIG_PPC32 */ |
1da177e4 | 1507 | }; |
42c4aaad | 1508 | |
87a72f9e PM |
1509 | static struct cpu_spec the_cpu_spec; |
1510 | ||
1511 | struct cpu_spec * __init identify_cpu(unsigned long offset, unsigned int pvr) | |
42c4aaad BH |
1512 | { |
1513 | struct cpu_spec *s = cpu_specs; | |
87a72f9e | 1514 | struct cpu_spec *t = &the_cpu_spec; |
42c4aaad BH |
1515 | int i; |
1516 | ||
1517 | s = PTRRELOC(s); | |
87a72f9e | 1518 | t = PTRRELOC(t); |
42c4aaad | 1519 | |
42c4aaad BH |
1520 | for (i = 0; i < ARRAY_SIZE(cpu_specs); i++,s++) |
1521 | if ((pvr & s->pvr_mask) == s->pvr_value) { | |
87a72f9e PM |
1522 | /* |
1523 | * If we are overriding a previous value derived | |
1524 | * from the real PVR with a new value obtained | |
1525 | * using a logical PVR value, don't modify the | |
1526 | * performance monitor fields. | |
1527 | */ | |
1528 | if (t->num_pmcs && !s->num_pmcs) { | |
1529 | t->cpu_name = s->cpu_name; | |
1530 | t->cpu_features = s->cpu_features; | |
1531 | t->cpu_user_features = s->cpu_user_features; | |
1532 | t->icache_bsize = s->icache_bsize; | |
1533 | t->dcache_bsize = s->dcache_bsize; | |
1534 | t->cpu_setup = s->cpu_setup; | |
1535 | t->cpu_restore = s->cpu_restore; | |
1536 | t->platform = s->platform; | |
1537 | } else | |
1538 | *t = *s; | |
1539 | *PTRRELOC(&cur_cpu_spec) = &the_cpu_spec; | |
84e3ad5b | 1540 | #if defined(CONFIG_PPC64) || defined(CONFIG_BOOKE) |
464076a4 | 1541 | /* ppc64 and booke expect identify_cpu to also call |
84e3ad5b VB |
1542 | * setup_cpu for that processor. I will consolidate |
1543 | * that at a later time, for now, just use #ifdef. | |
42c4aaad | 1544 | * we also don't need to PTRRELOC the function pointer |
84e3ad5b VB |
1545 | * on ppc64 and booke as we are running at 0 in real |
1546 | * mode on ppc64 and reloc_offset is always 0 on booke. | |
42c4aaad BH |
1547 | */ |
1548 | if (s->cpu_setup) { | |
1549 | s->cpu_setup(offset, s); | |
1550 | } | |
84e3ad5b | 1551 | #endif /* CONFIG_PPC64 || CONFIG_BOOKE */ |
42c4aaad BH |
1552 | return s; |
1553 | } | |
1554 | BUG(); | |
1555 | return NULL; | |
1556 | } | |
1557 | ||
0909c8c2 | 1558 | void do_feature_fixups(unsigned long value, void *fixup_start, void *fixup_end) |
42c4aaad BH |
1559 | { |
1560 | struct fixup_entry { | |
1561 | unsigned long mask; | |
1562 | unsigned long value; | |
0909c8c2 BH |
1563 | long start_off; |
1564 | long end_off; | |
42c4aaad BH |
1565 | } *fcur, *fend; |
1566 | ||
1567 | fcur = fixup_start; | |
1568 | fend = fixup_end; | |
1569 | ||
1570 | for (; fcur < fend; fcur++) { | |
1571 | unsigned int *pstart, *pend, *p; | |
1572 | ||
1573 | if ((value & fcur->mask) == fcur->value) | |
1574 | continue; | |
1575 | ||
1576 | /* These PTRRELOCs will disappear once the new scheme for | |
1577 | * modules and vdso is implemented | |
1578 | */ | |
0909c8c2 BH |
1579 | pstart = ((unsigned int *)fcur) + (fcur->start_off / 4); |
1580 | pend = ((unsigned int *)fcur) + (fcur->end_off / 4); | |
42c4aaad BH |
1581 | |
1582 | for (p = pstart; p < pend; p++) { | |
1583 | *p = 0x60000000u; | |
1584 | asm volatile ("dcbst 0, %0" : : "r" (p)); | |
1585 | } | |
1586 | asm volatile ("sync" : : : "memory"); | |
1587 | for (p = pstart; p < pend; p++) | |
1588 | asm volatile ("icbi 0,%0" : : "r" (p)); | |
1589 | asm volatile ("sync; isync" : : : "memory"); | |
1590 | } | |
1591 | } |