blob: 2f82a2091440f7d765661248b627959b69e09145 [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
13#include <linux/config.h>
14#include <linux/string.h>
15#include <linux/sched.h>
16#include <linux/threads.h>
17#include <linux/init.h>
Kumar Gala400d2212005-09-27 15:13:12 -050018#include <linux/module.h>
19
20#include <asm/oprofile_impl.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -070021#include <asm/cputable.h>
22
Kumar Gala400d2212005-09-27 15:13:12 -050023struct cpu_spec* cur_cpu_spec = NULL;
Stephen Rothwell49209602005-10-12 15:55:09 +100024EXPORT_SYMBOL(cur_cpu_spec);
Linus Torvalds1da177e2005-04-16 15:20:36 -070025
Stephen Rothwell49209602005-10-12 15:55:09 +100026/* 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 */
33#ifdef CONFIG_PPC64
34extern void __setup_cpu_power3(unsigned long offset, struct cpu_spec* spec);
35extern void __setup_cpu_power4(unsigned long offset, struct cpu_spec* spec);
36extern void __setup_cpu_be(unsigned long offset, struct cpu_spec* spec);
37#else
Kumar Gala400d2212005-09-27 15:13:12 -050038extern void __setup_cpu_603(unsigned long offset, struct cpu_spec* spec);
39extern void __setup_cpu_604(unsigned long offset, struct cpu_spec* spec);
40extern void __setup_cpu_750(unsigned long offset, struct cpu_spec* spec);
41extern void __setup_cpu_750cx(unsigned long offset, struct cpu_spec* spec);
42extern void __setup_cpu_750fx(unsigned long offset, struct cpu_spec* spec);
43extern void __setup_cpu_7400(unsigned long offset, struct cpu_spec* spec);
44extern void __setup_cpu_7410(unsigned long offset, struct cpu_spec* spec);
45extern void __setup_cpu_745x(unsigned long offset, struct cpu_spec* spec);
Stephen Rothwell49209602005-10-12 15:55:09 +100046#endif /* CONFIG_PPC32 */
Kumar Gala400d2212005-09-27 15:13:12 -050047extern void __setup_cpu_ppc970(unsigned long offset, struct cpu_spec* spec);
Linus Torvalds1da177e2005-04-16 15:20:36 -070048
Linus Torvalds1da177e2005-04-16 15:20:36 -070049/* This table only contains "desktop" CPUs, it need to be filled with embedded
50 * ones as well...
51 */
Stephen Rothwell49209602005-10-12 15:55:09 +100052#define COMMON_USER (PPC_FEATURE_32 | PPC_FEATURE_HAS_FPU | \
53 PPC_FEATURE_HAS_MMU)
54#define COMMON_USER_PPC64 (COMMON_USER | PPC_FEATURE_64)
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +110055#define COMMON_USER_POWER4 (COMMON_USER_PPC64 | PPC_FEATURE_POWER4)
56#define COMMON_USER_POWER5 (COMMON_USER_PPC64 | PPC_FEATURE_POWER5)
57#define COMMON_USER_POWER5_PLUS (COMMON_USER_PPC64 | PPC_FEATURE_POWER5_PLUS)
Stephen Rothwell49209602005-10-12 15:55:09 +100058
Linus Torvalds1da177e2005-04-16 15:20:36 -070059
Linus Torvalds1da177e2005-04-16 15:20:36 -070060/* We only set the spe features if the kernel was compiled with
61 * spe support
62 */
63#ifdef CONFIG_SPE
Stephen Rothwell49209602005-10-12 15:55:09 +100064#define PPC_FEATURE_SPE_COMP PPC_FEATURE_HAS_SPE
Linus Torvalds1da177e2005-04-16 15:20:36 -070065#else
Stephen Rothwell49209602005-10-12 15:55:09 +100066#define PPC_FEATURE_SPE_COMP 0
Linus Torvalds1da177e2005-04-16 15:20:36 -070067#endif
68
Linus Torvalds1da177e2005-04-16 15:20:36 -070069struct cpu_spec cpu_specs[] = {
Stephen Rothwell49209602005-10-12 15:55:09 +100070#ifdef CONFIG_PPC64
71 { /* Power3 */
72 .pvr_mask = 0xffff0000,
73 .pvr_value = 0x00400000,
74 .cpu_name = "POWER3 (630)",
75 .cpu_features = CPU_FTRS_POWER3,
76 .cpu_user_features = COMMON_USER_PPC64,
77 .icache_bsize = 128,
78 .dcache_bsize = 128,
79 .num_pmcs = 8,
80 .cpu_setup = __setup_cpu_power3,
81#ifdef CONFIG_OPROFILE
82 .oprofile_cpu_type = "ppc64/power3",
83 .oprofile_model = &op_model_rs64,
84#endif
85 },
86 { /* Power3+ */
87 .pvr_mask = 0xffff0000,
88 .pvr_value = 0x00410000,
89 .cpu_name = "POWER3 (630+)",
90 .cpu_features = CPU_FTRS_POWER3,
91 .cpu_user_features = COMMON_USER_PPC64,
92 .icache_bsize = 128,
93 .dcache_bsize = 128,
94 .num_pmcs = 8,
95 .cpu_setup = __setup_cpu_power3,
96#ifdef CONFIG_OPROFILE
97 .oprofile_cpu_type = "ppc64/power3",
98 .oprofile_model = &op_model_rs64,
99#endif
100 },
101 { /* Northstar */
102 .pvr_mask = 0xffff0000,
103 .pvr_value = 0x00330000,
104 .cpu_name = "RS64-II (northstar)",
105 .cpu_features = CPU_FTRS_RS64,
106 .cpu_user_features = COMMON_USER_PPC64,
107 .icache_bsize = 128,
108 .dcache_bsize = 128,
109 .num_pmcs = 8,
110 .cpu_setup = __setup_cpu_power3,
111#ifdef CONFIG_OPROFILE
112 .oprofile_cpu_type = "ppc64/rs64",
113 .oprofile_model = &op_model_rs64,
114#endif
115 },
116 { /* Pulsar */
117 .pvr_mask = 0xffff0000,
118 .pvr_value = 0x00340000,
119 .cpu_name = "RS64-III (pulsar)",
120 .cpu_features = CPU_FTRS_RS64,
121 .cpu_user_features = COMMON_USER_PPC64,
122 .icache_bsize = 128,
123 .dcache_bsize = 128,
124 .num_pmcs = 8,
125 .cpu_setup = __setup_cpu_power3,
126#ifdef CONFIG_OPROFILE
127 .oprofile_cpu_type = "ppc64/rs64",
128 .oprofile_model = &op_model_rs64,
129#endif
130 },
131 { /* I-star */
132 .pvr_mask = 0xffff0000,
133 .pvr_value = 0x00360000,
134 .cpu_name = "RS64-III (icestar)",
135 .cpu_features = CPU_FTRS_RS64,
136 .cpu_user_features = COMMON_USER_PPC64,
137 .icache_bsize = 128,
138 .dcache_bsize = 128,
139 .num_pmcs = 8,
140 .cpu_setup = __setup_cpu_power3,
141#ifdef CONFIG_OPROFILE
142 .oprofile_cpu_type = "ppc64/rs64",
143 .oprofile_model = &op_model_rs64,
144#endif
145 },
146 { /* S-star */
147 .pvr_mask = 0xffff0000,
148 .pvr_value = 0x00370000,
149 .cpu_name = "RS64-IV (sstar)",
150 .cpu_features = CPU_FTRS_RS64,
151 .cpu_user_features = COMMON_USER_PPC64,
152 .icache_bsize = 128,
153 .dcache_bsize = 128,
154 .num_pmcs = 8,
155 .cpu_setup = __setup_cpu_power3,
156#ifdef CONFIG_OPROFILE
157 .oprofile_cpu_type = "ppc64/rs64",
158 .oprofile_model = &op_model_rs64,
159#endif
160 },
161 { /* Power4 */
162 .pvr_mask = 0xffff0000,
163 .pvr_value = 0x00350000,
164 .cpu_name = "POWER4 (gp)",
165 .cpu_features = CPU_FTRS_POWER4,
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100166 .cpu_user_features = COMMON_USER_POWER4,
Stephen Rothwell49209602005-10-12 15:55:09 +1000167 .icache_bsize = 128,
168 .dcache_bsize = 128,
169 .num_pmcs = 8,
170 .cpu_setup = __setup_cpu_power4,
171#ifdef CONFIG_OPROFILE
172 .oprofile_cpu_type = "ppc64/power4",
173 .oprofile_model = &op_model_rs64,
174#endif
175 },
176 { /* Power4+ */
177 .pvr_mask = 0xffff0000,
178 .pvr_value = 0x00380000,
179 .cpu_name = "POWER4+ (gq)",
180 .cpu_features = CPU_FTRS_POWER4,
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100181 .cpu_user_features = COMMON_USER_POWER4,
Stephen Rothwell49209602005-10-12 15:55:09 +1000182 .icache_bsize = 128,
183 .dcache_bsize = 128,
184 .num_pmcs = 8,
185 .cpu_setup = __setup_cpu_power4,
186#ifdef CONFIG_OPROFILE
187 .oprofile_cpu_type = "ppc64/power4",
188 .oprofile_model = &op_model_power4,
189#endif
190 },
191 { /* PPC970 */
192 .pvr_mask = 0xffff0000,
193 .pvr_value = 0x00390000,
194 .cpu_name = "PPC970",
195 .cpu_features = CPU_FTRS_PPC970,
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100196 .cpu_user_features = COMMON_USER_POWER4 |
Stephen Rothwell49209602005-10-12 15:55:09 +1000197 PPC_FEATURE_HAS_ALTIVEC_COMP,
198 .icache_bsize = 128,
199 .dcache_bsize = 128,
200 .num_pmcs = 8,
201 .cpu_setup = __setup_cpu_ppc970,
202#ifdef CONFIG_OPROFILE
203 .oprofile_cpu_type = "ppc64/970",
204 .oprofile_model = &op_model_power4,
205#endif
206 },
207#endif /* CONFIG_PPC64 */
208#if defined(CONFIG_PPC64) || defined(CONFIG_POWER4)
209 { /* PPC970FX */
210 .pvr_mask = 0xffff0000,
211 .pvr_value = 0x003c0000,
212 .cpu_name = "PPC970FX",
213#ifdef CONFIG_PPC32
214 .cpu_features = CPU_FTRS_970_32,
215#else
216 .cpu_features = CPU_FTRS_PPC970,
217#endif
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100218 .cpu_user_features = COMMON_USER_POWER4 |
Stephen Rothwell49209602005-10-12 15:55:09 +1000219 PPC_FEATURE_HAS_ALTIVEC_COMP,
220 .icache_bsize = 128,
221 .dcache_bsize = 128,
222 .num_pmcs = 8,
223 .cpu_setup = __setup_cpu_ppc970,
224#ifdef CONFIG_OPROFILE
225 .oprofile_cpu_type = "ppc64/970",
226 .oprofile_model = &op_model_power4,
227#endif
228 },
229#endif /* defined(CONFIG_PPC64) || defined(CONFIG_POWER4) */
230#ifdef CONFIG_PPC64
231 { /* PPC970MP */
232 .pvr_mask = 0xffff0000,
233 .pvr_value = 0x00440000,
234 .cpu_name = "PPC970MP",
235 .cpu_features = CPU_FTRS_PPC970,
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100236 .cpu_user_features = COMMON_USER_POWER4 |
Stephen Rothwell49209602005-10-12 15:55:09 +1000237 PPC_FEATURE_HAS_ALTIVEC_COMP,
238 .icache_bsize = 128,
239 .dcache_bsize = 128,
240 .cpu_setup = __setup_cpu_ppc970,
241#ifdef CONFIG_OPROFILE
242 .oprofile_cpu_type = "ppc64/970",
243 .oprofile_model = &op_model_power4,
244#endif
245 },
Benjamin Herrenschmidt3c726f82005-11-07 11:06:55 +1100246 { /* Power5 GR */
Stephen Rothwell49209602005-10-12 15:55:09 +1000247 .pvr_mask = 0xffff0000,
248 .pvr_value = 0x003a0000,
249 .cpu_name = "POWER5 (gr)",
250 .cpu_features = CPU_FTRS_POWER5,
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100251 .cpu_user_features = COMMON_USER_POWER5,
Stephen Rothwell49209602005-10-12 15:55:09 +1000252 .icache_bsize = 128,
253 .dcache_bsize = 128,
254 .num_pmcs = 6,
255 .cpu_setup = __setup_cpu_power4,
256#ifdef CONFIG_OPROFILE
257 .oprofile_cpu_type = "ppc64/power5",
258 .oprofile_model = &op_model_power4,
259#endif
260 },
Benjamin Herrenschmidt3c726f82005-11-07 11:06:55 +1100261 { /* Power5 GS */
Stephen Rothwell49209602005-10-12 15:55:09 +1000262 .pvr_mask = 0xffff0000,
263 .pvr_value = 0x003b0000,
264 .cpu_name = "POWER5 (gs)",
265 .cpu_features = CPU_FTRS_POWER5,
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100266 .cpu_user_features = COMMON_USER_POWER5_PLUS,
Stephen Rothwell49209602005-10-12 15:55:09 +1000267 .icache_bsize = 128,
268 .dcache_bsize = 128,
269 .num_pmcs = 6,
270 .cpu_setup = __setup_cpu_power4,
271#ifdef CONFIG_OPROFILE
272 .oprofile_cpu_type = "ppc64/power5",
273 .oprofile_model = &op_model_power4,
274#endif
275 },
Arnd Bergmannc902be72006-01-04 19:55:53 +0000276 { /* Cell Broadband Engine */
Stephen Rothwell49209602005-10-12 15:55:09 +1000277 .pvr_mask = 0xffff0000,
278 .pvr_value = 0x00700000,
279 .cpu_name = "Cell Broadband Engine",
280 .cpu_features = CPU_FTRS_CELL,
281 .cpu_user_features = COMMON_USER_PPC64 |
Paul Mackerrasa7ddc5e2005-11-10 14:29:18 +1100282 PPC_FEATURE_CELL | PPC_FEATURE_HAS_ALTIVEC_COMP,
Stephen Rothwell49209602005-10-12 15:55:09 +1000283 .icache_bsize = 128,
284 .dcache_bsize = 128,
285 .cpu_setup = __setup_cpu_be,
286 },
287 { /* default match */
288 .pvr_mask = 0x00000000,
289 .pvr_value = 0x00000000,
290 .cpu_name = "POWER4 (compatible)",
291 .cpu_features = CPU_FTRS_COMPATIBLE,
292 .cpu_user_features = COMMON_USER_PPC64,
293 .icache_bsize = 128,
294 .dcache_bsize = 128,
295 .num_pmcs = 6,
296 .cpu_setup = __setup_cpu_power4,
297 }
298#endif /* CONFIG_PPC64 */
299#ifdef CONFIG_PPC32
Linus Torvalds1da177e2005-04-16 15:20:36 -0700300#if CLASSIC_PPC
Stephen Rothwell49209602005-10-12 15:55:09 +1000301 { /* 601 */
Linus Torvalds1da177e2005-04-16 15:20:36 -0700302 .pvr_mask = 0xffff0000,
303 .pvr_value = 0x00010000,
304 .cpu_name = "601",
Kumar Gala10b35d92005-09-23 14:08:58 -0500305 .cpu_features = CPU_FTRS_PPC601,
Stephen Rothwell49209602005-10-12 15:55:09 +1000306 .cpu_user_features = COMMON_USER | PPC_FEATURE_601_INSTR |
Paul Mackerras98599012005-10-22 16:51:34 +1000307 PPC_FEATURE_UNIFIED_CACHE | PPC_FEATURE_NO_TB,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700308 .icache_bsize = 32,
309 .dcache_bsize = 32,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700310 },
311 { /* 603 */
312 .pvr_mask = 0xffff0000,
313 .pvr_value = 0x00030000,
314 .cpu_name = "603",
Kumar Gala10b35d92005-09-23 14:08:58 -0500315 .cpu_features = CPU_FTRS_603,
Stephen Rothwell49209602005-10-12 15:55:09 +1000316 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700317 .icache_bsize = 32,
318 .dcache_bsize = 32,
319 .cpu_setup = __setup_cpu_603
320 },
321 { /* 603e */
322 .pvr_mask = 0xffff0000,
323 .pvr_value = 0x00060000,
324 .cpu_name = "603e",
Kumar Gala10b35d92005-09-23 14:08:58 -0500325 .cpu_features = CPU_FTRS_603,
Stephen Rothwell49209602005-10-12 15:55:09 +1000326 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700327 .icache_bsize = 32,
328 .dcache_bsize = 32,
329 .cpu_setup = __setup_cpu_603
330 },
331 { /* 603ev */
332 .pvr_mask = 0xffff0000,
333 .pvr_value = 0x00070000,
334 .cpu_name = "603ev",
Kumar Gala10b35d92005-09-23 14:08:58 -0500335 .cpu_features = CPU_FTRS_603,
Stephen Rothwell49209602005-10-12 15:55:09 +1000336 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700337 .icache_bsize = 32,
338 .dcache_bsize = 32,
339 .cpu_setup = __setup_cpu_603
340 },
341 { /* 604 */
342 .pvr_mask = 0xffff0000,
343 .pvr_value = 0x00040000,
344 .cpu_name = "604",
Kumar Gala10b35d92005-09-23 14:08:58 -0500345 .cpu_features = CPU_FTRS_604,
Stephen Rothwell49209602005-10-12 15:55:09 +1000346 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700347 .icache_bsize = 32,
348 .dcache_bsize = 32,
349 .num_pmcs = 2,
350 .cpu_setup = __setup_cpu_604
351 },
352 { /* 604e */
353 .pvr_mask = 0xfffff000,
354 .pvr_value = 0x00090000,
355 .cpu_name = "604e",
Kumar Gala10b35d92005-09-23 14:08:58 -0500356 .cpu_features = CPU_FTRS_604,
Stephen Rothwell49209602005-10-12 15:55:09 +1000357 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700358 .icache_bsize = 32,
359 .dcache_bsize = 32,
360 .num_pmcs = 4,
361 .cpu_setup = __setup_cpu_604
362 },
363 { /* 604r */
364 .pvr_mask = 0xffff0000,
365 .pvr_value = 0x00090000,
366 .cpu_name = "604r",
Kumar Gala10b35d92005-09-23 14:08:58 -0500367 .cpu_features = CPU_FTRS_604,
Stephen Rothwell49209602005-10-12 15:55:09 +1000368 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700369 .icache_bsize = 32,
370 .dcache_bsize = 32,
371 .num_pmcs = 4,
372 .cpu_setup = __setup_cpu_604
373 },
374 { /* 604ev */
375 .pvr_mask = 0xffff0000,
376 .pvr_value = 0x000a0000,
377 .cpu_name = "604ev",
Kumar Gala10b35d92005-09-23 14:08:58 -0500378 .cpu_features = CPU_FTRS_604,
Stephen Rothwell49209602005-10-12 15:55:09 +1000379 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700380 .icache_bsize = 32,
381 .dcache_bsize = 32,
382 .num_pmcs = 4,
383 .cpu_setup = __setup_cpu_604
384 },
385 { /* 740/750 (0x4202, don't support TAU ?) */
386 .pvr_mask = 0xffffffff,
387 .pvr_value = 0x00084202,
388 .cpu_name = "740/750",
Kumar Gala10b35d92005-09-23 14:08:58 -0500389 .cpu_features = CPU_FTRS_740_NOTAU,
Stephen Rothwell49209602005-10-12 15:55:09 +1000390 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700391 .icache_bsize = 32,
392 .dcache_bsize = 32,
393 .num_pmcs = 4,
394 .cpu_setup = __setup_cpu_750
395 },
Linus Torvalds1da177e2005-04-16 15:20:36 -0700396 { /* 750CX (80100 and 8010x?) */
397 .pvr_mask = 0xfffffff0,
398 .pvr_value = 0x00080100,
399 .cpu_name = "750CX",
Kumar Gala10b35d92005-09-23 14:08:58 -0500400 .cpu_features = CPU_FTRS_750,
Stephen Rothwell49209602005-10-12 15:55:09 +1000401 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700402 .icache_bsize = 32,
403 .dcache_bsize = 32,
404 .num_pmcs = 4,
405 .cpu_setup = __setup_cpu_750cx
406 },
407 { /* 750CX (82201 and 82202) */
408 .pvr_mask = 0xfffffff0,
409 .pvr_value = 0x00082200,
410 .cpu_name = "750CX",
Kumar Gala10b35d92005-09-23 14:08:58 -0500411 .cpu_features = CPU_FTRS_750,
Stephen Rothwell49209602005-10-12 15:55:09 +1000412 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700413 .icache_bsize = 32,
414 .dcache_bsize = 32,
415 .num_pmcs = 4,
416 .cpu_setup = __setup_cpu_750cx
417 },
418 { /* 750CXe (82214) */
419 .pvr_mask = 0xfffffff0,
420 .pvr_value = 0x00082210,
421 .cpu_name = "750CXe",
Kumar Gala10b35d92005-09-23 14:08:58 -0500422 .cpu_features = CPU_FTRS_750,
Stephen Rothwell49209602005-10-12 15:55:09 +1000423 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700424 .icache_bsize = 32,
425 .dcache_bsize = 32,
426 .num_pmcs = 4,
427 .cpu_setup = __setup_cpu_750cx
428 },
Arthur Othieno7c316252005-09-03 15:55:52 -0700429 { /* 750CXe "Gekko" (83214) */
430 .pvr_mask = 0xffffffff,
431 .pvr_value = 0x00083214,
432 .cpu_name = "750CXe",
Kumar Gala10b35d92005-09-23 14:08:58 -0500433 .cpu_features = CPU_FTRS_750,
Stephen Rothwell49209602005-10-12 15:55:09 +1000434 .cpu_user_features = COMMON_USER,
Arthur Othieno7c316252005-09-03 15:55:52 -0700435 .icache_bsize = 32,
436 .dcache_bsize = 32,
437 .num_pmcs = 4,
438 .cpu_setup = __setup_cpu_750cx
439 },
Arthur Othienoac1ff042005-09-03 15:55:51 -0700440 { /* 745/755 */
441 .pvr_mask = 0xfffff000,
442 .pvr_value = 0x00083000,
443 .cpu_name = "745/755",
Kumar Gala10b35d92005-09-23 14:08:58 -0500444 .cpu_features = CPU_FTRS_750,
Stephen Rothwell49209602005-10-12 15:55:09 +1000445 .cpu_user_features = COMMON_USER,
Arthur Othienoac1ff042005-09-03 15:55:51 -0700446 .icache_bsize = 32,
447 .dcache_bsize = 32,
448 .num_pmcs = 4,
449 .cpu_setup = __setup_cpu_750
450 },
Linus Torvalds1da177e2005-04-16 15:20:36 -0700451 { /* 750FX rev 1.x */
452 .pvr_mask = 0xffffff00,
453 .pvr_value = 0x70000100,
454 .cpu_name = "750FX",
Kumar Gala10b35d92005-09-23 14:08:58 -0500455 .cpu_features = CPU_FTRS_750FX1,
Stephen Rothwell49209602005-10-12 15:55:09 +1000456 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700457 .icache_bsize = 32,
458 .dcache_bsize = 32,
459 .num_pmcs = 4,
460 .cpu_setup = __setup_cpu_750
461 },
462 { /* 750FX rev 2.0 must disable HID0[DPM] */
463 .pvr_mask = 0xffffffff,
464 .pvr_value = 0x70000200,
465 .cpu_name = "750FX",
Kumar Gala10b35d92005-09-23 14:08:58 -0500466 .cpu_features = CPU_FTRS_750FX2,
Stephen Rothwell49209602005-10-12 15:55:09 +1000467 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700468 .icache_bsize = 32,
469 .dcache_bsize = 32,
470 .num_pmcs = 4,
471 .cpu_setup = __setup_cpu_750
472 },
473 { /* 750FX (All revs except 2.0) */
474 .pvr_mask = 0xffff0000,
475 .pvr_value = 0x70000000,
476 .cpu_name = "750FX",
Kumar Gala10b35d92005-09-23 14:08:58 -0500477 .cpu_features = CPU_FTRS_750FX,
Stephen Rothwell49209602005-10-12 15:55:09 +1000478 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700479 .icache_bsize = 32,
480 .dcache_bsize = 32,
481 .num_pmcs = 4,
482 .cpu_setup = __setup_cpu_750fx
483 },
484 { /* 750GX */
485 .pvr_mask = 0xffff0000,
486 .pvr_value = 0x70020000,
487 .cpu_name = "750GX",
Kumar Gala10b35d92005-09-23 14:08:58 -0500488 .cpu_features = CPU_FTRS_750GX,
Stephen Rothwell49209602005-10-12 15:55:09 +1000489 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700490 .icache_bsize = 32,
491 .dcache_bsize = 32,
492 .num_pmcs = 4,
493 .cpu_setup = __setup_cpu_750fx
494 },
495 { /* 740/750 (L2CR bit need fixup for 740) */
496 .pvr_mask = 0xffff0000,
497 .pvr_value = 0x00080000,
498 .cpu_name = "740/750",
Kumar Gala10b35d92005-09-23 14:08:58 -0500499 .cpu_features = CPU_FTRS_740,
Stephen Rothwell49209602005-10-12 15:55:09 +1000500 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700501 .icache_bsize = 32,
502 .dcache_bsize = 32,
503 .num_pmcs = 4,
504 .cpu_setup = __setup_cpu_750
505 },
506 { /* 7400 rev 1.1 ? (no TAU) */
507 .pvr_mask = 0xffffffff,
508 .pvr_value = 0x000c1101,
509 .cpu_name = "7400 (1.1)",
Kumar Gala10b35d92005-09-23 14:08:58 -0500510 .cpu_features = CPU_FTRS_7400_NOTAU,
Stephen Rothwell49209602005-10-12 15:55:09 +1000511 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700512 .icache_bsize = 32,
513 .dcache_bsize = 32,
514 .num_pmcs = 4,
515 .cpu_setup = __setup_cpu_7400
516 },
517 { /* 7400 */
518 .pvr_mask = 0xffff0000,
519 .pvr_value = 0x000c0000,
520 .cpu_name = "7400",
Kumar Gala10b35d92005-09-23 14:08:58 -0500521 .cpu_features = CPU_FTRS_7400,
Stephen Rothwell49209602005-10-12 15:55:09 +1000522 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700523 .icache_bsize = 32,
524 .dcache_bsize = 32,
525 .num_pmcs = 4,
526 .cpu_setup = __setup_cpu_7400
527 },
528 { /* 7410 */
529 .pvr_mask = 0xffff0000,
530 .pvr_value = 0x800c0000,
531 .cpu_name = "7410",
Kumar Gala10b35d92005-09-23 14:08:58 -0500532 .cpu_features = CPU_FTRS_7400,
Stephen Rothwell49209602005-10-12 15:55:09 +1000533 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700534 .icache_bsize = 32,
535 .dcache_bsize = 32,
536 .num_pmcs = 4,
537 .cpu_setup = __setup_cpu_7410
538 },
539 { /* 7450 2.0 - no doze/nap */
540 .pvr_mask = 0xffffffff,
541 .pvr_value = 0x80000200,
542 .cpu_name = "7450",
Kumar Gala10b35d92005-09-23 14:08:58 -0500543 .cpu_features = CPU_FTRS_7450_20,
Stephen Rothwell49209602005-10-12 15:55:09 +1000544 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700545 .icache_bsize = 32,
546 .dcache_bsize = 32,
547 .num_pmcs = 6,
Andy Fleming555d97a2005-12-15 20:02:04 -0600548 .cpu_setup = __setup_cpu_745x,
549#ifdef CONFIG_OPROFILE
550 .oprofile_cpu_type = "ppc/7450",
551 .oprofile_model = &op_model_7450,
552#endif
Linus Torvalds1da177e2005-04-16 15:20:36 -0700553 },
554 { /* 7450 2.1 */
555 .pvr_mask = 0xffffffff,
556 .pvr_value = 0x80000201,
557 .cpu_name = "7450",
Kumar Gala10b35d92005-09-23 14:08:58 -0500558 .cpu_features = CPU_FTRS_7450_21,
Stephen Rothwell49209602005-10-12 15:55:09 +1000559 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700560 .icache_bsize = 32,
561 .dcache_bsize = 32,
562 .num_pmcs = 6,
Andy Fleming555d97a2005-12-15 20:02:04 -0600563 .cpu_setup = __setup_cpu_745x,
564#ifdef CONFIG_OPROFILE
565 .oprofile_cpu_type = "ppc/7450",
566 .oprofile_model = &op_model_7450,
567#endif
Linus Torvalds1da177e2005-04-16 15:20:36 -0700568 },
569 { /* 7450 2.3 and newer */
570 .pvr_mask = 0xffff0000,
571 .pvr_value = 0x80000000,
572 .cpu_name = "7450",
Kumar Gala10b35d92005-09-23 14:08:58 -0500573 .cpu_features = CPU_FTRS_7450_23,
Stephen Rothwell49209602005-10-12 15:55:09 +1000574 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700575 .icache_bsize = 32,
576 .dcache_bsize = 32,
577 .num_pmcs = 6,
Andy Fleming555d97a2005-12-15 20:02:04 -0600578 .cpu_setup = __setup_cpu_745x,
579#ifdef CONFIG_OPROFILE
580 .oprofile_cpu_type = "ppc/7450",
581 .oprofile_model = &op_model_7450,
582#endif
Linus Torvalds1da177e2005-04-16 15:20:36 -0700583 },
584 { /* 7455 rev 1.x */
585 .pvr_mask = 0xffffff00,
586 .pvr_value = 0x80010100,
587 .cpu_name = "7455",
Kumar Gala10b35d92005-09-23 14:08:58 -0500588 .cpu_features = CPU_FTRS_7455_1,
Stephen Rothwell49209602005-10-12 15:55:09 +1000589 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700590 .icache_bsize = 32,
591 .dcache_bsize = 32,
592 .num_pmcs = 6,
Andy Fleming555d97a2005-12-15 20:02:04 -0600593 .cpu_setup = __setup_cpu_745x,
594#ifdef CONFIG_OPROFILE
595 .oprofile_cpu_type = "ppc/7450",
596 .oprofile_model = &op_model_7450,
597#endif
Linus Torvalds1da177e2005-04-16 15:20:36 -0700598 },
599 { /* 7455 rev 2.0 */
600 .pvr_mask = 0xffffffff,
601 .pvr_value = 0x80010200,
602 .cpu_name = "7455",
Kumar Gala10b35d92005-09-23 14:08:58 -0500603 .cpu_features = CPU_FTRS_7455_20,
Stephen Rothwell49209602005-10-12 15:55:09 +1000604 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700605 .icache_bsize = 32,
606 .dcache_bsize = 32,
607 .num_pmcs = 6,
Andy Fleming555d97a2005-12-15 20:02:04 -0600608 .cpu_setup = __setup_cpu_745x,
609#ifdef CONFIG_OPROFILE
610 .oprofile_cpu_type = "ppc/7450",
611 .oprofile_model = &op_model_7450,
612#endif
Linus Torvalds1da177e2005-04-16 15:20:36 -0700613 },
614 { /* 7455 others */
615 .pvr_mask = 0xffff0000,
616 .pvr_value = 0x80010000,
617 .cpu_name = "7455",
Kumar Gala10b35d92005-09-23 14:08:58 -0500618 .cpu_features = CPU_FTRS_7455,
Stephen Rothwell49209602005-10-12 15:55:09 +1000619 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700620 .icache_bsize = 32,
621 .dcache_bsize = 32,
622 .num_pmcs = 6,
Andy Fleming555d97a2005-12-15 20:02:04 -0600623 .cpu_setup = __setup_cpu_745x,
624#ifdef CONFIG_OPROFILE
625 .oprofile_cpu_type = "ppc/7450",
626 .oprofile_model = &op_model_7450,
627#endif
Linus Torvalds1da177e2005-04-16 15:20:36 -0700628 },
629 { /* 7447/7457 Rev 1.0 */
630 .pvr_mask = 0xffffffff,
631 .pvr_value = 0x80020100,
632 .cpu_name = "7447/7457",
Kumar Gala10b35d92005-09-23 14:08:58 -0500633 .cpu_features = CPU_FTRS_7447_10,
Stephen Rothwell49209602005-10-12 15:55:09 +1000634 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700635 .icache_bsize = 32,
636 .dcache_bsize = 32,
637 .num_pmcs = 6,
Andy Fleming555d97a2005-12-15 20:02:04 -0600638 .cpu_setup = __setup_cpu_745x,
639#ifdef CONFIG_OPROFILE
640 .oprofile_cpu_type = "ppc/7450",
641 .oprofile_model = &op_model_7450,
642#endif
Linus Torvalds1da177e2005-04-16 15:20:36 -0700643 },
644 { /* 7447/7457 Rev 1.1 */
645 .pvr_mask = 0xffffffff,
646 .pvr_value = 0x80020101,
647 .cpu_name = "7447/7457",
Kumar Gala10b35d92005-09-23 14:08:58 -0500648 .cpu_features = CPU_FTRS_7447_10,
Stephen Rothwell49209602005-10-12 15:55:09 +1000649 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700650 .icache_bsize = 32,
651 .dcache_bsize = 32,
652 .num_pmcs = 6,
Andy Fleming555d97a2005-12-15 20:02:04 -0600653 .cpu_setup = __setup_cpu_745x,
654#ifdef CONFIG_OPROFILE
655 .oprofile_cpu_type = "ppc/7450",
656 .oprofile_model = &op_model_7450,
657#endif
Linus Torvalds1da177e2005-04-16 15:20:36 -0700658 },
659 { /* 7447/7457 Rev 1.2 and later */
660 .pvr_mask = 0xffff0000,
661 .pvr_value = 0x80020000,
662 .cpu_name = "7447/7457",
Kumar Gala10b35d92005-09-23 14:08:58 -0500663 .cpu_features = CPU_FTRS_7447,
Stephen Rothwell49209602005-10-12 15:55:09 +1000664 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700665 .icache_bsize = 32,
666 .dcache_bsize = 32,
667 .num_pmcs = 6,
Andy Fleming555d97a2005-12-15 20:02:04 -0600668 .cpu_setup = __setup_cpu_745x,
669#ifdef CONFIG_OPROFILE
670 .oprofile_cpu_type = "ppc/7450",
671 .oprofile_model = &op_model_7450,
672#endif
Linus Torvalds1da177e2005-04-16 15:20:36 -0700673 },
674 { /* 7447A */
675 .pvr_mask = 0xffff0000,
676 .pvr_value = 0x80030000,
677 .cpu_name = "7447A",
Kumar Gala10b35d92005-09-23 14:08:58 -0500678 .cpu_features = CPU_FTRS_7447A,
Stephen Rothwell49209602005-10-12 15:55:09 +1000679 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700680 .icache_bsize = 32,
681 .dcache_bsize = 32,
682 .num_pmcs = 6,
Andy Fleming555d97a2005-12-15 20:02:04 -0600683 .cpu_setup = __setup_cpu_745x,
684#ifdef CONFIG_OPROFILE
685 .oprofile_cpu_type = "ppc/7450",
686 .oprofile_model = &op_model_7450,
687#endif
Linus Torvalds1da177e2005-04-16 15:20:36 -0700688 },
Kumar Galabbde6302005-09-03 15:55:55 -0700689 { /* 7448 */
690 .pvr_mask = 0xffff0000,
691 .pvr_value = 0x80040000,
692 .cpu_name = "7448",
Kumar Gala10b35d92005-09-23 14:08:58 -0500693 .cpu_features = CPU_FTRS_7447A,
Stephen Rothwell49209602005-10-12 15:55:09 +1000694 .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP,
Kumar Galabbde6302005-09-03 15:55:55 -0700695 .icache_bsize = 32,
696 .dcache_bsize = 32,
697 .num_pmcs = 6,
Andy Fleming555d97a2005-12-15 20:02:04 -0600698 .cpu_setup = __setup_cpu_745x,
699#ifdef CONFIG_OPROFILE
700 .oprofile_cpu_type = "ppc/7450",
701 .oprofile_model = &op_model_7450,
702#endif
Kumar Galabbde6302005-09-03 15:55:55 -0700703 },
Linus Torvalds1da177e2005-04-16 15:20:36 -0700704 { /* 82xx (8240, 8245, 8260 are all 603e cores) */
705 .pvr_mask = 0x7fff0000,
706 .pvr_value = 0x00810000,
707 .cpu_name = "82xx",
Kumar Gala10b35d92005-09-23 14:08:58 -0500708 .cpu_features = CPU_FTRS_82XX,
Stephen Rothwell49209602005-10-12 15:55:09 +1000709 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700710 .icache_bsize = 32,
711 .dcache_bsize = 32,
712 .cpu_setup = __setup_cpu_603
713 },
714 { /* All G2_LE (603e core, plus some) have the same pvr */
715 .pvr_mask = 0x7fff0000,
716 .pvr_value = 0x00820000,
717 .cpu_name = "G2_LE",
Kumar Gala10b35d92005-09-23 14:08:58 -0500718 .cpu_features = CPU_FTRS_G2_LE,
Stephen Rothwell49209602005-10-12 15:55:09 +1000719 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700720 .icache_bsize = 32,
721 .dcache_bsize = 32,
722 .cpu_setup = __setup_cpu_603
723 },
724 { /* e300 (a 603e core, plus some) on 83xx */
725 .pvr_mask = 0x7fff0000,
726 .pvr_value = 0x00830000,
727 .cpu_name = "e300",
Kumar Gala10b35d92005-09-23 14:08:58 -0500728 .cpu_features = CPU_FTRS_E300,
Stephen Rothwell49209602005-10-12 15:55:09 +1000729 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700730 .icache_bsize = 32,
731 .dcache_bsize = 32,
732 .cpu_setup = __setup_cpu_603
733 },
734 { /* default match, we assume split I/D cache & TB (non-601)... */
735 .pvr_mask = 0x00000000,
736 .pvr_value = 0x00000000,
737 .cpu_name = "(generic PPC)",
Kumar Gala10b35d92005-09-23 14:08:58 -0500738 .cpu_features = CPU_FTRS_CLASSIC32,
Stephen Rothwell49209602005-10-12 15:55:09 +1000739 .cpu_user_features = COMMON_USER,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700740 .icache_bsize = 32,
741 .dcache_bsize = 32,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700742 },
743#endif /* CLASSIC_PPC */
Linus Torvalds1da177e2005-04-16 15:20:36 -0700744#ifdef CONFIG_8xx
745 { /* 8xx */
746 .pvr_mask = 0xffff0000,
747 .pvr_value = 0x00500000,
748 .cpu_name = "8xx",
749 /* CPU_FTR_MAYBE_CAN_DOZE is possible,
750 * if the 8xx code is there.... */
Kumar Gala10b35d92005-09-23 14:08:58 -0500751 .cpu_features = CPU_FTRS_8XX,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700752 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
753 .icache_bsize = 16,
754 .dcache_bsize = 16,
755 },
756#endif /* CONFIG_8xx */
757#ifdef CONFIG_40x
758 { /* 403GC */
759 .pvr_mask = 0xffffff00,
760 .pvr_value = 0x00200200,
761 .cpu_name = "403GC",
Kumar Gala10b35d92005-09-23 14:08:58 -0500762 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700763 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
764 .icache_bsize = 16,
765 .dcache_bsize = 16,
766 },
767 { /* 403GCX */
768 .pvr_mask = 0xffffff00,
769 .pvr_value = 0x00201400,
770 .cpu_name = "403GCX",
Kumar Gala10b35d92005-09-23 14:08:58 -0500771 .cpu_features = CPU_FTRS_40X,
Paul Mackerras98599012005-10-22 16:51:34 +1000772 .cpu_user_features = PPC_FEATURE_32 |
773 PPC_FEATURE_HAS_MMU | PPC_FEATURE_NO_TB,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700774 .icache_bsize = 16,
775 .dcache_bsize = 16,
776 },
777 { /* 403G ?? */
778 .pvr_mask = 0xffff0000,
779 .pvr_value = 0x00200000,
780 .cpu_name = "403G ??",
Kumar Gala10b35d92005-09-23 14:08:58 -0500781 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700782 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
783 .icache_bsize = 16,
784 .dcache_bsize = 16,
785 },
786 { /* 405GP */
787 .pvr_mask = 0xffff0000,
788 .pvr_value = 0x40110000,
789 .cpu_name = "405GP",
Kumar Gala10b35d92005-09-23 14:08:58 -0500790 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700791 .cpu_user_features = PPC_FEATURE_32 |
792 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
793 .icache_bsize = 32,
794 .dcache_bsize = 32,
795 },
796 { /* STB 03xxx */
797 .pvr_mask = 0xffff0000,
798 .pvr_value = 0x40130000,
799 .cpu_name = "STB03xxx",
Kumar Gala10b35d92005-09-23 14:08:58 -0500800 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700801 .cpu_user_features = PPC_FEATURE_32 |
802 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
803 .icache_bsize = 32,
804 .dcache_bsize = 32,
805 },
806 { /* STB 04xxx */
807 .pvr_mask = 0xffff0000,
808 .pvr_value = 0x41810000,
809 .cpu_name = "STB04xxx",
Kumar Gala10b35d92005-09-23 14:08:58 -0500810 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700811 .cpu_user_features = PPC_FEATURE_32 |
812 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
813 .icache_bsize = 32,
814 .dcache_bsize = 32,
815 },
816 { /* NP405L */
817 .pvr_mask = 0xffff0000,
818 .pvr_value = 0x41610000,
819 .cpu_name = "NP405L",
Kumar Gala10b35d92005-09-23 14:08:58 -0500820 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700821 .cpu_user_features = PPC_FEATURE_32 |
822 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
823 .icache_bsize = 32,
824 .dcache_bsize = 32,
825 },
826 { /* NP4GS3 */
827 .pvr_mask = 0xffff0000,
828 .pvr_value = 0x40B10000,
829 .cpu_name = "NP4GS3",
Kumar Gala10b35d92005-09-23 14:08:58 -0500830 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700831 .cpu_user_features = PPC_FEATURE_32 |
832 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
833 .icache_bsize = 32,
834 .dcache_bsize = 32,
835 },
836 { /* NP405H */
837 .pvr_mask = 0xffff0000,
838 .pvr_value = 0x41410000,
839 .cpu_name = "NP405H",
Kumar Gala10b35d92005-09-23 14:08:58 -0500840 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700841 .cpu_user_features = PPC_FEATURE_32 |
842 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
843 .icache_bsize = 32,
844 .dcache_bsize = 32,
845 },
846 { /* 405GPr */
847 .pvr_mask = 0xffff0000,
848 .pvr_value = 0x50910000,
849 .cpu_name = "405GPr",
Kumar Gala10b35d92005-09-23 14:08:58 -0500850 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700851 .cpu_user_features = PPC_FEATURE_32 |
852 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
853 .icache_bsize = 32,
854 .dcache_bsize = 32,
855 },
856 { /* STBx25xx */
857 .pvr_mask = 0xffff0000,
858 .pvr_value = 0x51510000,
859 .cpu_name = "STBx25xx",
Kumar Gala10b35d92005-09-23 14:08:58 -0500860 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700861 .cpu_user_features = PPC_FEATURE_32 |
862 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
863 .icache_bsize = 32,
864 .dcache_bsize = 32,
865 },
866 { /* 405LP */
867 .pvr_mask = 0xffff0000,
868 .pvr_value = 0x41F10000,
869 .cpu_name = "405LP",
Kumar Gala10b35d92005-09-23 14:08:58 -0500870 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700871 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
872 .icache_bsize = 32,
873 .dcache_bsize = 32,
874 },
875 { /* Xilinx Virtex-II Pro */
876 .pvr_mask = 0xffff0000,
877 .pvr_value = 0x20010000,
878 .cpu_name = "Virtex-II Pro",
Kumar Gala10b35d92005-09-23 14:08:58 -0500879 .cpu_features = CPU_FTRS_40X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700880 .cpu_user_features = PPC_FEATURE_32 |
881 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
882 .icache_bsize = 32,
883 .dcache_bsize = 32,
884 },
Eugene Suroveginad95d602005-06-07 13:22:09 -0700885 { /* 405EP */
886 .pvr_mask = 0xffff0000,
887 .pvr_value = 0x51210000,
888 .cpu_name = "405EP",
Kumar Gala10b35d92005-09-23 14:08:58 -0500889 .cpu_features = CPU_FTRS_40X,
Eugene Suroveginad95d602005-06-07 13:22:09 -0700890 .cpu_user_features = PPC_FEATURE_32 |
891 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC,
892 .icache_bsize = 32,
893 .dcache_bsize = 32,
894 },
Linus Torvalds1da177e2005-04-16 15:20:36 -0700895
896#endif /* CONFIG_40x */
897#ifdef CONFIG_44x
Matt Porterc9cf73a2005-07-31 22:34:52 -0700898 {
899 .pvr_mask = 0xf0000fff,
900 .pvr_value = 0x40000850,
901 .cpu_name = "440EP Rev. A",
Kumar Gala10b35d92005-09-23 14:08:58 -0500902 .cpu_features = CPU_FTRS_44X,
Stephen Rothwell49209602005-10-12 15:55:09 +1000903 .cpu_user_features = COMMON_USER, /* 440EP has an FPU */
Matt Porterc9cf73a2005-07-31 22:34:52 -0700904 .icache_bsize = 32,
905 .dcache_bsize = 32,
906 },
907 {
908 .pvr_mask = 0xf0000fff,
909 .pvr_value = 0x400008d3,
910 .cpu_name = "440EP Rev. B",
Kumar Gala10b35d92005-09-23 14:08:58 -0500911 .cpu_features = CPU_FTRS_44X,
Stephen Rothwell49209602005-10-12 15:55:09 +1000912 .cpu_user_features = COMMON_USER, /* 440EP has an FPU */
Matt Porterc9cf73a2005-07-31 22:34:52 -0700913 .icache_bsize = 32,
914 .dcache_bsize = 32,
915 },
Stephen Rothwell49209602005-10-12 15:55:09 +1000916 { /* 440GP Rev. B */
Linus Torvalds1da177e2005-04-16 15:20:36 -0700917 .pvr_mask = 0xf0000fff,
918 .pvr_value = 0x40000440,
919 .cpu_name = "440GP Rev. B",
Kumar Gala10b35d92005-09-23 14:08:58 -0500920 .cpu_features = CPU_FTRS_44X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700921 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
922 .icache_bsize = 32,
923 .dcache_bsize = 32,
924 },
Stephen Rothwell49209602005-10-12 15:55:09 +1000925 { /* 440GP Rev. C */
Linus Torvalds1da177e2005-04-16 15:20:36 -0700926 .pvr_mask = 0xf0000fff,
927 .pvr_value = 0x40000481,
928 .cpu_name = "440GP Rev. C",
Kumar Gala10b35d92005-09-23 14:08:58 -0500929 .cpu_features = CPU_FTRS_44X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700930 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
931 .icache_bsize = 32,
932 .dcache_bsize = 32,
933 },
934 { /* 440GX Rev. A */
935 .pvr_mask = 0xf0000fff,
936 .pvr_value = 0x50000850,
937 .cpu_name = "440GX Rev. A",
Kumar Gala10b35d92005-09-23 14:08:58 -0500938 .cpu_features = CPU_FTRS_44X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700939 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
940 .icache_bsize = 32,
941 .dcache_bsize = 32,
942 },
943 { /* 440GX Rev. B */
944 .pvr_mask = 0xf0000fff,
945 .pvr_value = 0x50000851,
946 .cpu_name = "440GX Rev. B",
Kumar Gala10b35d92005-09-23 14:08:58 -0500947 .cpu_features = CPU_FTRS_44X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700948 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
949 .icache_bsize = 32,
950 .dcache_bsize = 32,
951 },
952 { /* 440GX Rev. C */
953 .pvr_mask = 0xf0000fff,
954 .pvr_value = 0x50000892,
955 .cpu_name = "440GX Rev. C",
Kumar Gala10b35d92005-09-23 14:08:58 -0500956 .cpu_features = CPU_FTRS_44X,
Linus Torvalds1da177e2005-04-16 15:20:36 -0700957 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
958 .icache_bsize = 32,
959 .dcache_bsize = 32,
960 },
Eugene Surovegin9149fb32005-09-03 15:55:40 -0700961 { /* 440GX Rev. F */
962 .pvr_mask = 0xf0000fff,
963 .pvr_value = 0x50000894,
964 .cpu_name = "440GX Rev. F",
Kumar Gala10b35d92005-09-23 14:08:58 -0500965 .cpu_features = CPU_FTRS_44X,
Eugene Surovegin9149fb32005-09-03 15:55:40 -0700966 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
967 .icache_bsize = 32,
968 .dcache_bsize = 32,
969 },
Matt Porter656de7e2005-09-03 15:55:42 -0700970 { /* 440SP Rev. A */
971 .pvr_mask = 0xff000fff,
972 .pvr_value = 0x53000891,
973 .cpu_name = "440SP Rev. A",
Kumar Gala10b35d92005-09-23 14:08:58 -0500974 .cpu_features = CPU_FTRS_44X,
Matt Porter656de7e2005-09-03 15:55:42 -0700975 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
976 .icache_bsize = 32,
977 .dcache_bsize = 32,
978 },
Roland Dreierb0f7b8b2005-11-07 00:58:13 -0800979 { /* 440SPe Rev. A */
980 .pvr_mask = 0xff000fff,
981 .pvr_value = 0x53000890,
982 .cpu_name = "440SPe Rev. A",
983 .cpu_features = CPU_FTR_SPLIT_ID_CACHE |
984 CPU_FTR_USE_TB,
985 .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU,
986 .icache_bsize = 32,
987 .dcache_bsize = 32,
988 },
Linus Torvalds1da177e2005-04-16 15:20:36 -0700989#endif /* CONFIG_44x */
Kumar Gala33d9e9b2005-06-25 14:54:37 -0700990#ifdef CONFIG_FSL_BOOKE
Stephen Rothwell49209602005-10-12 15:55:09 +1000991 { /* e200z5 */
Kumar Gala33d9e9b2005-06-25 14:54:37 -0700992 .pvr_mask = 0xfff00000,
993 .pvr_value = 0x81000000,
994 .cpu_name = "e200z5",
995 /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */
Kumar Gala10b35d92005-09-23 14:08:58 -0500996 .cpu_features = CPU_FTRS_E200,
Kumar Gala33d9e9b2005-06-25 14:54:37 -0700997 .cpu_user_features = PPC_FEATURE_32 |
998 PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_EFP_SINGLE |
999 PPC_FEATURE_UNIFIED_CACHE,
1000 .dcache_bsize = 32,
1001 },
Stephen Rothwell49209602005-10-12 15:55:09 +10001002 { /* e200z6 */
Kumar Gala33d9e9b2005-06-25 14:54:37 -07001003 .pvr_mask = 0xfff00000,
1004 .pvr_value = 0x81100000,
1005 .cpu_name = "e200z6",
1006 /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */
Kumar Gala10b35d92005-09-23 14:08:58 -05001007 .cpu_features = CPU_FTRS_E200,
Kumar Gala33d9e9b2005-06-25 14:54:37 -07001008 .cpu_user_features = PPC_FEATURE_32 |
1009 PPC_FEATURE_HAS_MMU | PPC_FEATURE_SPE_COMP |
1010 PPC_FEATURE_HAS_EFP_SINGLE |
1011 PPC_FEATURE_UNIFIED_CACHE,
1012 .dcache_bsize = 32,
1013 },
Stephen Rothwell49209602005-10-12 15:55:09 +10001014 { /* e500 */
Linus Torvalds1da177e2005-04-16 15:20:36 -07001015 .pvr_mask = 0xffff0000,
1016 .pvr_value = 0x80200000,
1017 .cpu_name = "e500",
1018 /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */
Kumar Gala10b35d92005-09-23 14:08:58 -05001019 .cpu_features = CPU_FTRS_E500,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001020 .cpu_user_features = PPC_FEATURE_32 |
1021 PPC_FEATURE_HAS_MMU | PPC_FEATURE_SPE_COMP |
1022 PPC_FEATURE_HAS_EFP_SINGLE,
1023 .icache_bsize = 32,
1024 .dcache_bsize = 32,
1025 .num_pmcs = 4,
Andy Fleming555d97a2005-12-15 20:02:04 -06001026#ifdef CONFIG_OPROFILE
1027 .oprofile_cpu_type = "ppc/e500",
1028 .oprofile_model = &op_model_fsl_booke,
1029#endif
Linus Torvalds1da177e2005-04-16 15:20:36 -07001030 },
Stephen Rothwell49209602005-10-12 15:55:09 +10001031 { /* e500v2 */
Kumar Gala5b37b702005-06-21 17:15:18 -07001032 .pvr_mask = 0xffff0000,
1033 .pvr_value = 0x80210000,
1034 .cpu_name = "e500v2",
1035 /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */
Kumar Gala10b35d92005-09-23 14:08:58 -05001036 .cpu_features = CPU_FTRS_E500_2,
Kumar Gala5b37b702005-06-21 17:15:18 -07001037 .cpu_user_features = PPC_FEATURE_32 |
1038 PPC_FEATURE_HAS_MMU | PPC_FEATURE_SPE_COMP |
1039 PPC_FEATURE_HAS_EFP_SINGLE | PPC_FEATURE_HAS_EFP_DOUBLE,
1040 .icache_bsize = 32,
1041 .dcache_bsize = 32,
1042 .num_pmcs = 4,
Andy Fleming555d97a2005-12-15 20:02:04 -06001043#ifdef CONFIG_OPROFILE
1044 .oprofile_cpu_type = "ppc/e500",
1045 .oprofile_model = &op_model_fsl_booke,
1046#endif
Kumar Gala5b37b702005-06-21 17:15:18 -07001047 },
Linus Torvalds1da177e2005-04-16 15:20:36 -07001048#endif
1049#if !CLASSIC_PPC
1050 { /* default match */
1051 .pvr_mask = 0x00000000,
1052 .pvr_value = 0x00000000,
1053 .cpu_name = "(generic PPC)",
Kumar Gala10b35d92005-09-23 14:08:58 -05001054 .cpu_features = CPU_FTRS_GENERIC_32,
Linus Torvalds1da177e2005-04-16 15:20:36 -07001055 .cpu_user_features = PPC_FEATURE_32,
1056 .icache_bsize = 32,
1057 .dcache_bsize = 32,
1058 }
1059#endif /* !CLASSIC_PPC */
Stephen Rothwell49209602005-10-12 15:55:09 +10001060#endif /* CONFIG_PPC32 */
Linus Torvalds1da177e2005-04-16 15:20:36 -07001061};