Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1 | /* |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 2 | * Copyright (C) 2001 Ben. Herrenschmidt (benh@kernel.crashing.org) |
| 3 | * |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 4 | * Modifications for ppc64: |
| 5 | * Copyright (C) 2003 Dave Engebretsen <engebret@us.ibm.com> |
| 6 | * |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 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 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 13 | #include <linux/string.h> |
| 14 | #include <linux/sched.h> |
| 15 | #include <linux/threads.h> |
| 16 | #include <linux/init.h> |
Kumar Gala | 400d221 | 2005-09-27 15:13:12 -0500 | [diff] [blame] | 17 | #include <linux/module.h> |
| 18 | |
| 19 | #include <asm/oprofile_impl.h> |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 20 | #include <asm/cputable.h> |
Benjamin Herrenschmidt | 42c4aaa | 2006-10-24 16:42:40 +1000 | [diff] [blame] | 21 | #include <asm/prom.h> /* for PTRRELOC on ARCH=ppc */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 22 | |
Kumar Gala | 400d221 | 2005-09-27 15:13:12 -0500 | [diff] [blame] | 23 | struct cpu_spec* cur_cpu_spec = NULL; |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 24 | EXPORT_SYMBOL(cur_cpu_spec); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 25 | |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 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 | */ |
Geoff Levand | b26f100 | 2006-05-19 14:24:18 +1000 | [diff] [blame] | 33 | #ifdef CONFIG_PPC32 |
Kumar Gala | 400d221 | 2005-09-27 15:13:12 -0500 | [diff] [blame] | 34 | extern void __setup_cpu_603(unsigned long offset, struct cpu_spec* spec); |
| 35 | extern void __setup_cpu_604(unsigned long offset, struct cpu_spec* spec); |
| 36 | extern void __setup_cpu_750(unsigned long offset, struct cpu_spec* spec); |
| 37 | extern void __setup_cpu_750cx(unsigned long offset, struct cpu_spec* spec); |
| 38 | extern void __setup_cpu_750fx(unsigned long offset, struct cpu_spec* spec); |
| 39 | extern void __setup_cpu_7400(unsigned long offset, struct cpu_spec* spec); |
| 40 | extern void __setup_cpu_7410(unsigned long offset, struct cpu_spec* spec); |
| 41 | extern void __setup_cpu_745x(unsigned long offset, struct cpu_spec* spec); |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 42 | #endif /* CONFIG_PPC32 */ |
Olof Johansson | f39b7a5 | 2006-08-11 00:07:08 -0500 | [diff] [blame] | 43 | #ifdef CONFIG_PPC64 |
Kumar Gala | 400d221 | 2005-09-27 15:13:12 -0500 | [diff] [blame] | 44 | extern void __setup_cpu_ppc970(unsigned long offset, struct cpu_spec* spec); |
Olof Johansson | 5b43d20 | 2006-10-04 23:41:41 -0500 | [diff] [blame] | 45 | extern void __setup_cpu_ppc970MP(unsigned long offset, struct cpu_spec* spec); |
Olof Johansson | 1199919 | 2007-02-04 16:36:51 -0600 | [diff] [blame] | 46 | extern void __setup_cpu_pa6t(unsigned long offset, struct cpu_spec* spec); |
Stephen Rothwell | 40d244d | 2007-02-12 22:10:48 +1100 | [diff] [blame] | 47 | extern void __restore_cpu_pa6t(void); |
Olof Johansson | f39b7a5 | 2006-08-11 00:07:08 -0500 | [diff] [blame] | 48 | extern void __restore_cpu_ppc970(void); |
| 49 | #endif /* CONFIG_PPC64 */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 50 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 51 | /* This table only contains "desktop" CPUs, it need to be filled with embedded |
| 52 | * ones as well... |
| 53 | */ |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 54 | #define COMMON_USER (PPC_FEATURE_32 | PPC_FEATURE_HAS_FPU | \ |
| 55 | PPC_FEATURE_HAS_MMU) |
| 56 | #define COMMON_USER_PPC64 (COMMON_USER | PPC_FEATURE_64) |
Paul Mackerras | a7ddc5e | 2005-11-10 14:29:18 +1100 | [diff] [blame] | 57 | #define COMMON_USER_POWER4 (COMMON_USER_PPC64 | PPC_FEATURE_POWER4) |
Benjamin Herrenschmidt | aa5cb02 | 2006-03-01 15:07:07 +1100 | [diff] [blame] | 58 | #define COMMON_USER_POWER5 (COMMON_USER_PPC64 | PPC_FEATURE_POWER5 |\ |
| 59 | PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP) |
| 60 | #define COMMON_USER_POWER5_PLUS (COMMON_USER_PPC64 | PPC_FEATURE_POWER5_PLUS|\ |
| 61 | PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP) |
Anton Blanchard | 03054d5 | 2006-04-29 09:51:06 +1000 | [diff] [blame] | 62 | #define COMMON_USER_POWER6 (COMMON_USER_PPC64 | PPC_FEATURE_ARCH_2_05 |\ |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 63 | PPC_FEATURE_SMT | PPC_FEATURE_ICACHE_SNOOP | \ |
| 64 | PPC_FEATURE_TRUE_LE) |
Olof Johansson | b3ebd1d | 2006-09-06 14:35:57 -0500 | [diff] [blame] | 65 | #define COMMON_USER_PA6T (COMMON_USER_PPC64 | PPC_FEATURE_PA6T |\ |
| 66 | PPC_FEATURE_TRUE_LE | \ |
| 67 | PPC_FEATURE_HAS_ALTIVEC_COMP) |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 68 | #define COMMON_USER_BOOKE (PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU | \ |
| 69 | PPC_FEATURE_BOOKE) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 70 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 71 | /* We only set the spe features if the kernel was compiled with |
| 72 | * spe support |
| 73 | */ |
| 74 | #ifdef CONFIG_SPE |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 75 | #define PPC_FEATURE_SPE_COMP PPC_FEATURE_HAS_SPE |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 76 | #else |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 77 | #define PPC_FEATURE_SPE_COMP 0 |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 78 | #endif |
| 79 | |
Benjamin Herrenschmidt | 42c4aaa | 2006-10-24 16:42:40 +1000 | [diff] [blame] | 80 | static struct cpu_spec cpu_specs[] = { |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 81 | #ifdef CONFIG_PPC64 |
| 82 | { /* Power3 */ |
| 83 | .pvr_mask = 0xffff0000, |
| 84 | .pvr_value = 0x00400000, |
| 85 | .cpu_name = "POWER3 (630)", |
| 86 | .cpu_features = CPU_FTRS_POWER3, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 87 | .cpu_user_features = COMMON_USER_PPC64|PPC_FEATURE_PPC_LE, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 88 | .icache_bsize = 128, |
| 89 | .dcache_bsize = 128, |
| 90 | .num_pmcs = 8, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 91 | .pmc_type = PPC_PMC_IBM, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 92 | .oprofile_cpu_type = "ppc64/power3", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 93 | .oprofile_type = PPC_OPROFILE_RS64, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 94 | .platform = "power3", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 95 | }, |
| 96 | { /* Power3+ */ |
| 97 | .pvr_mask = 0xffff0000, |
| 98 | .pvr_value = 0x00410000, |
| 99 | .cpu_name = "POWER3 (630+)", |
| 100 | .cpu_features = CPU_FTRS_POWER3, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 101 | .cpu_user_features = COMMON_USER_PPC64|PPC_FEATURE_PPC_LE, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 102 | .icache_bsize = 128, |
| 103 | .dcache_bsize = 128, |
| 104 | .num_pmcs = 8, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 105 | .pmc_type = PPC_PMC_IBM, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 106 | .oprofile_cpu_type = "ppc64/power3", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 107 | .oprofile_type = PPC_OPROFILE_RS64, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 108 | .platform = "power3", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 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, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 119 | .pmc_type = PPC_PMC_IBM, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 120 | .oprofile_cpu_type = "ppc64/rs64", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 121 | .oprofile_type = PPC_OPROFILE_RS64, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 122 | .platform = "rs64", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 123 | }, |
| 124 | { /* Pulsar */ |
| 125 | .pvr_mask = 0xffff0000, |
| 126 | .pvr_value = 0x00340000, |
| 127 | .cpu_name = "RS64-III (pulsar)", |
| 128 | .cpu_features = CPU_FTRS_RS64, |
| 129 | .cpu_user_features = COMMON_USER_PPC64, |
| 130 | .icache_bsize = 128, |
| 131 | .dcache_bsize = 128, |
| 132 | .num_pmcs = 8, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 133 | .pmc_type = PPC_PMC_IBM, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 134 | .oprofile_cpu_type = "ppc64/rs64", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 135 | .oprofile_type = PPC_OPROFILE_RS64, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 136 | .platform = "rs64", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 137 | }, |
| 138 | { /* I-star */ |
| 139 | .pvr_mask = 0xffff0000, |
| 140 | .pvr_value = 0x00360000, |
| 141 | .cpu_name = "RS64-III (icestar)", |
| 142 | .cpu_features = CPU_FTRS_RS64, |
| 143 | .cpu_user_features = COMMON_USER_PPC64, |
| 144 | .icache_bsize = 128, |
| 145 | .dcache_bsize = 128, |
| 146 | .num_pmcs = 8, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 147 | .pmc_type = PPC_PMC_IBM, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 148 | .oprofile_cpu_type = "ppc64/rs64", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 149 | .oprofile_type = PPC_OPROFILE_RS64, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 150 | .platform = "rs64", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 151 | }, |
| 152 | { /* S-star */ |
| 153 | .pvr_mask = 0xffff0000, |
| 154 | .pvr_value = 0x00370000, |
| 155 | .cpu_name = "RS64-IV (sstar)", |
| 156 | .cpu_features = CPU_FTRS_RS64, |
| 157 | .cpu_user_features = COMMON_USER_PPC64, |
| 158 | .icache_bsize = 128, |
| 159 | .dcache_bsize = 128, |
| 160 | .num_pmcs = 8, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 161 | .pmc_type = PPC_PMC_IBM, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 162 | .oprofile_cpu_type = "ppc64/rs64", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 163 | .oprofile_type = PPC_OPROFILE_RS64, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 164 | .platform = "rs64", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 165 | }, |
| 166 | { /* Power4 */ |
| 167 | .pvr_mask = 0xffff0000, |
| 168 | .pvr_value = 0x00350000, |
| 169 | .cpu_name = "POWER4 (gp)", |
| 170 | .cpu_features = CPU_FTRS_POWER4, |
Paul Mackerras | a7ddc5e | 2005-11-10 14:29:18 +1100 | [diff] [blame] | 171 | .cpu_user_features = COMMON_USER_POWER4, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 172 | .icache_bsize = 128, |
| 173 | .dcache_bsize = 128, |
| 174 | .num_pmcs = 8, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 175 | .pmc_type = PPC_PMC_IBM, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 176 | .oprofile_cpu_type = "ppc64/power4", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 177 | .oprofile_type = PPC_OPROFILE_POWER4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 178 | .platform = "power4", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 179 | }, |
| 180 | { /* Power4+ */ |
| 181 | .pvr_mask = 0xffff0000, |
| 182 | .pvr_value = 0x00380000, |
| 183 | .cpu_name = "POWER4+ (gq)", |
| 184 | .cpu_features = CPU_FTRS_POWER4, |
Paul Mackerras | a7ddc5e | 2005-11-10 14:29:18 +1100 | [diff] [blame] | 185 | .cpu_user_features = COMMON_USER_POWER4, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 186 | .icache_bsize = 128, |
| 187 | .dcache_bsize = 128, |
| 188 | .num_pmcs = 8, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 189 | .pmc_type = PPC_PMC_IBM, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 190 | .oprofile_cpu_type = "ppc64/power4", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 191 | .oprofile_type = PPC_OPROFILE_POWER4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 192 | .platform = "power4", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 193 | }, |
| 194 | { /* PPC970 */ |
| 195 | .pvr_mask = 0xffff0000, |
| 196 | .pvr_value = 0x00390000, |
| 197 | .cpu_name = "PPC970", |
| 198 | .cpu_features = CPU_FTRS_PPC970, |
Paul Mackerras | a7ddc5e | 2005-11-10 14:29:18 +1100 | [diff] [blame] | 199 | .cpu_user_features = COMMON_USER_POWER4 | |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 200 | PPC_FEATURE_HAS_ALTIVEC_COMP, |
| 201 | .icache_bsize = 128, |
| 202 | .dcache_bsize = 128, |
| 203 | .num_pmcs = 8, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 204 | .pmc_type = PPC_PMC_IBM, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 205 | .cpu_setup = __setup_cpu_ppc970, |
Olof Johansson | f39b7a5 | 2006-08-11 00:07:08 -0500 | [diff] [blame] | 206 | .cpu_restore = __restore_cpu_ppc970, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 207 | .oprofile_cpu_type = "ppc64/970", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 208 | .oprofile_type = PPC_OPROFILE_POWER4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 209 | .platform = "ppc970", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 210 | }, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 211 | { /* PPC970FX */ |
| 212 | .pvr_mask = 0xffff0000, |
| 213 | .pvr_value = 0x003c0000, |
| 214 | .cpu_name = "PPC970FX", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 215 | .cpu_features = CPU_FTRS_PPC970, |
Paul Mackerras | a7ddc5e | 2005-11-10 14:29:18 +1100 | [diff] [blame] | 216 | .cpu_user_features = COMMON_USER_POWER4 | |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 217 | PPC_FEATURE_HAS_ALTIVEC_COMP, |
| 218 | .icache_bsize = 128, |
| 219 | .dcache_bsize = 128, |
| 220 | .num_pmcs = 8, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 221 | .pmc_type = PPC_PMC_IBM, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 222 | .cpu_setup = __setup_cpu_ppc970, |
Olof Johansson | f39b7a5 | 2006-08-11 00:07:08 -0500 | [diff] [blame] | 223 | .cpu_restore = __restore_cpu_ppc970, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 224 | .oprofile_cpu_type = "ppc64/970", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 225 | .oprofile_type = PPC_OPROFILE_POWER4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 226 | .platform = "ppc970", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 227 | }, |
Olof Johansson | 3546e81 | 2007-02-26 00:35:14 -0600 | [diff] [blame] | 228 | { /* PPC970MP DD1.0 - no DEEPNAP, use regular 970 init */ |
| 229 | .pvr_mask = 0xffffffff, |
| 230 | .pvr_value = 0x00440100, |
| 231 | .cpu_name = "PPC970MP", |
| 232 | .cpu_features = CPU_FTRS_PPC970, |
| 233 | .cpu_user_features = COMMON_USER_POWER4 | |
| 234 | PPC_FEATURE_HAS_ALTIVEC_COMP, |
| 235 | .icache_bsize = 128, |
| 236 | .dcache_bsize = 128, |
| 237 | .num_pmcs = 8, |
| 238 | .cpu_setup = __setup_cpu_ppc970, |
| 239 | .cpu_restore = __restore_cpu_ppc970, |
| 240 | .oprofile_cpu_type = "ppc64/970MP", |
| 241 | .oprofile_type = PPC_OPROFILE_POWER4, |
| 242 | .platform = "ppc970", |
| 243 | }, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 244 | { /* PPC970MP */ |
| 245 | .pvr_mask = 0xffff0000, |
| 246 | .pvr_value = 0x00440000, |
| 247 | .cpu_name = "PPC970MP", |
| 248 | .cpu_features = CPU_FTRS_PPC970, |
Paul Mackerras | a7ddc5e | 2005-11-10 14:29:18 +1100 | [diff] [blame] | 249 | .cpu_user_features = COMMON_USER_POWER4 | |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 250 | PPC_FEATURE_HAS_ALTIVEC_COMP, |
| 251 | .icache_bsize = 128, |
| 252 | .dcache_bsize = 128, |
Anton Blanchard | 87af41b | 2006-05-05 05:44:26 +1000 | [diff] [blame] | 253 | .num_pmcs = 8, |
Olof Johansson | 5b43d20 | 2006-10-04 23:41:41 -0500 | [diff] [blame] | 254 | .cpu_setup = __setup_cpu_ppc970MP, |
Olof Johansson | f39b7a5 | 2006-08-11 00:07:08 -0500 | [diff] [blame] | 255 | .cpu_restore = __restore_cpu_ppc970, |
Mike Wolf | fecb352 | 2006-11-21 14:41:54 -0600 | [diff] [blame] | 256 | .oprofile_cpu_type = "ppc64/970MP", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 257 | .oprofile_type = PPC_OPROFILE_POWER4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 258 | .platform = "ppc970", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 259 | }, |
Jake Moilanen | 362ff7b | 2006-10-18 10:47:22 -0500 | [diff] [blame] | 260 | { /* PPC970GX */ |
| 261 | .pvr_mask = 0xffff0000, |
| 262 | .pvr_value = 0x00450000, |
| 263 | .cpu_name = "PPC970GX", |
| 264 | .cpu_features = CPU_FTRS_PPC970, |
| 265 | .cpu_user_features = COMMON_USER_POWER4 | |
| 266 | PPC_FEATURE_HAS_ALTIVEC_COMP, |
| 267 | .icache_bsize = 128, |
| 268 | .dcache_bsize = 128, |
| 269 | .num_pmcs = 8, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 270 | .pmc_type = PPC_PMC_IBM, |
Jake Moilanen | 362ff7b | 2006-10-18 10:47:22 -0500 | [diff] [blame] | 271 | .cpu_setup = __setup_cpu_ppc970, |
| 272 | .oprofile_cpu_type = "ppc64/970", |
| 273 | .oprofile_type = PPC_OPROFILE_POWER4, |
| 274 | .platform = "ppc970", |
| 275 | }, |
Benjamin Herrenschmidt | 3c726f8 | 2005-11-07 11:06:55 +1100 | [diff] [blame] | 276 | { /* Power5 GR */ |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 277 | .pvr_mask = 0xffff0000, |
| 278 | .pvr_value = 0x003a0000, |
| 279 | .cpu_name = "POWER5 (gr)", |
| 280 | .cpu_features = CPU_FTRS_POWER5, |
Paul Mackerras | a7ddc5e | 2005-11-10 14:29:18 +1100 | [diff] [blame] | 281 | .cpu_user_features = COMMON_USER_POWER5, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 282 | .icache_bsize = 128, |
| 283 | .dcache_bsize = 128, |
| 284 | .num_pmcs = 6, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 285 | .pmc_type = PPC_PMC_IBM, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 286 | .oprofile_cpu_type = "ppc64/power5", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 287 | .oprofile_type = PPC_OPROFILE_POWER4, |
Michael Neuling | e78dbc8 | 2006-06-08 14:42:34 +1000 | [diff] [blame] | 288 | /* SIHV / SIPR bits are implemented on POWER4+ (GQ) |
| 289 | * and above but only works on POWER5 and above |
| 290 | */ |
| 291 | .oprofile_mmcra_sihv = MMCRA_SIHV, |
| 292 | .oprofile_mmcra_sipr = MMCRA_SIPR, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 293 | .platform = "power5", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 294 | }, |
Benjamin Herrenschmidt | 3c726f8 | 2005-11-07 11:06:55 +1100 | [diff] [blame] | 295 | { /* Power5 GS */ |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 296 | .pvr_mask = 0xffff0000, |
| 297 | .pvr_value = 0x003b0000, |
Anton Blanchard | 834608f | 2006-01-09 15:42:30 +1100 | [diff] [blame] | 298 | .cpu_name = "POWER5+ (gs)", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 299 | .cpu_features = CPU_FTRS_POWER5, |
Paul Mackerras | a7ddc5e | 2005-11-10 14:29:18 +1100 | [diff] [blame] | 300 | .cpu_user_features = COMMON_USER_POWER5_PLUS, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 301 | .icache_bsize = 128, |
| 302 | .dcache_bsize = 128, |
| 303 | .num_pmcs = 6, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 304 | .pmc_type = PPC_PMC_IBM, |
Anton Blanchard | 834608f | 2006-01-09 15:42:30 +1100 | [diff] [blame] | 305 | .oprofile_cpu_type = "ppc64/power5+", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 306 | .oprofile_type = PPC_OPROFILE_POWER4, |
Michael Neuling | e78dbc8 | 2006-06-08 14:42:34 +1000 | [diff] [blame] | 307 | .oprofile_mmcra_sihv = MMCRA_SIHV, |
| 308 | .oprofile_mmcra_sipr = MMCRA_SIPR, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 309 | .platform = "power5+", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 310 | }, |
Paul Mackerras | 974a76f | 2006-11-10 20:38:53 +1100 | [diff] [blame] | 311 | { /* POWER6 in P5+ mode; 2.04-compliant processor */ |
| 312 | .pvr_mask = 0xffffffff, |
| 313 | .pvr_value = 0x0f000001, |
| 314 | .cpu_name = "POWER5+", |
| 315 | .cpu_features = CPU_FTRS_POWER5, |
| 316 | .cpu_user_features = COMMON_USER_POWER5_PLUS, |
| 317 | .icache_bsize = 128, |
| 318 | .dcache_bsize = 128, |
| 319 | .num_pmcs = 6, |
| 320 | .oprofile_cpu_type = "ppc64/power6", |
| 321 | .oprofile_type = PPC_OPROFILE_POWER4, |
| 322 | .oprofile_mmcra_sihv = POWER6_MMCRA_SIHV, |
| 323 | .oprofile_mmcra_sipr = POWER6_MMCRA_SIPR, |
| 324 | .oprofile_mmcra_clear = POWER6_MMCRA_THRM | |
| 325 | POWER6_MMCRA_OTHER, |
| 326 | .platform = "power5+", |
| 327 | }, |
Anton Blanchard | 03054d5 | 2006-04-29 09:51:06 +1000 | [diff] [blame] | 328 | { /* Power6 */ |
| 329 | .pvr_mask = 0xffff0000, |
| 330 | .pvr_value = 0x003e0000, |
Paul Mackerras | 974a76f | 2006-11-10 20:38:53 +1100 | [diff] [blame] | 331 | .cpu_name = "POWER6 (raw)", |
| 332 | .cpu_features = CPU_FTRS_POWER6, |
| 333 | .cpu_user_features = COMMON_USER_POWER6 | |
| 334 | PPC_FEATURE_POWER6_EXT, |
| 335 | .icache_bsize = 128, |
| 336 | .dcache_bsize = 128, |
| 337 | .num_pmcs = 6, |
| 338 | .oprofile_cpu_type = "ppc64/power6", |
| 339 | .oprofile_type = PPC_OPROFILE_POWER4, |
| 340 | .oprofile_mmcra_sihv = POWER6_MMCRA_SIHV, |
| 341 | .oprofile_mmcra_sipr = POWER6_MMCRA_SIPR, |
| 342 | .oprofile_mmcra_clear = POWER6_MMCRA_THRM | |
| 343 | POWER6_MMCRA_OTHER, |
| 344 | .platform = "power6x", |
| 345 | }, |
| 346 | { /* 2.05-compliant processor, i.e. Power6 "architected" mode */ |
| 347 | .pvr_mask = 0xffffffff, |
| 348 | .pvr_value = 0x0f000002, |
| 349 | .cpu_name = "POWER6 (architected)", |
Anton Blanchard | 03054d5 | 2006-04-29 09:51:06 +1000 | [diff] [blame] | 350 | .cpu_features = CPU_FTRS_POWER6, |
| 351 | .cpu_user_features = COMMON_USER_POWER6, |
| 352 | .icache_bsize = 128, |
| 353 | .dcache_bsize = 128, |
Anton Blanchard | 99f4861 | 2006-10-13 12:13:12 +1000 | [diff] [blame] | 354 | .num_pmcs = 6, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 355 | .pmc_type = PPC_PMC_IBM, |
Anton Blanchard | 03054d5 | 2006-04-29 09:51:06 +1000 | [diff] [blame] | 356 | .oprofile_cpu_type = "ppc64/power6", |
| 357 | .oprofile_type = PPC_OPROFILE_POWER4, |
Michael Neuling | e78dbc8 | 2006-06-08 14:42:34 +1000 | [diff] [blame] | 358 | .oprofile_mmcra_sihv = POWER6_MMCRA_SIHV, |
| 359 | .oprofile_mmcra_sipr = POWER6_MMCRA_SIPR, |
| 360 | .oprofile_mmcra_clear = POWER6_MMCRA_THRM | |
| 361 | POWER6_MMCRA_OTHER, |
Anton Blanchard | 03054d5 | 2006-04-29 09:51:06 +1000 | [diff] [blame] | 362 | .platform = "power6", |
| 363 | }, |
Arnd Bergmann | c902be7 | 2006-01-04 19:55:53 +0000 | [diff] [blame] | 364 | { /* Cell Broadband Engine */ |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 365 | .pvr_mask = 0xffff0000, |
| 366 | .pvr_value = 0x00700000, |
| 367 | .cpu_name = "Cell Broadband Engine", |
| 368 | .cpu_features = CPU_FTRS_CELL, |
| 369 | .cpu_user_features = COMMON_USER_PPC64 | |
Benjamin Herrenschmidt | aa5cb02 | 2006-03-01 15:07:07 +1100 | [diff] [blame] | 370 | PPC_FEATURE_CELL | PPC_FEATURE_HAS_ALTIVEC_COMP | |
| 371 | PPC_FEATURE_SMT, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 372 | .icache_bsize = 128, |
| 373 | .dcache_bsize = 128, |
Maynard Johnson | 18f2190 | 2006-11-20 18:45:16 +0100 | [diff] [blame] | 374 | .num_pmcs = 4, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 375 | .pmc_type = PPC_PMC_IBM, |
Maynard Johnson | 18f2190 | 2006-11-20 18:45:16 +0100 | [diff] [blame] | 376 | .oprofile_cpu_type = "ppc64/cell-be", |
| 377 | .oprofile_type = PPC_OPROFILE_CELL, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 378 | .platform = "ppc-cell-be", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 379 | }, |
Olof Johansson | b3ebd1d | 2006-09-06 14:35:57 -0500 | [diff] [blame] | 380 | { /* PA Semi PA6T */ |
| 381 | .pvr_mask = 0x7fff0000, |
| 382 | .pvr_value = 0x00900000, |
| 383 | .cpu_name = "PA6T", |
| 384 | .cpu_features = CPU_FTRS_PA6T, |
| 385 | .cpu_user_features = COMMON_USER_PA6T, |
| 386 | .icache_bsize = 64, |
| 387 | .dcache_bsize = 64, |
| 388 | .num_pmcs = 6, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 389 | .pmc_type = PPC_PMC_PA6T, |
Olof Johansson | 1199919 | 2007-02-04 16:36:51 -0600 | [diff] [blame] | 390 | .cpu_setup = __setup_cpu_pa6t, |
| 391 | .cpu_restore = __restore_cpu_pa6t, |
Olof Johansson | b3ebd1d | 2006-09-06 14:35:57 -0500 | [diff] [blame] | 392 | .platform = "pa6t", |
| 393 | }, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 394 | { /* default match */ |
| 395 | .pvr_mask = 0x00000000, |
| 396 | .pvr_value = 0x00000000, |
| 397 | .cpu_name = "POWER4 (compatible)", |
| 398 | .cpu_features = CPU_FTRS_COMPATIBLE, |
| 399 | .cpu_user_features = COMMON_USER_PPC64, |
| 400 | .icache_bsize = 128, |
| 401 | .dcache_bsize = 128, |
| 402 | .num_pmcs = 6, |
Olof Johansson | 1bd2e5a | 2007-01-28 21:23:54 -0600 | [diff] [blame] | 403 | .pmc_type = PPC_PMC_IBM, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 404 | .platform = "power4", |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 405 | } |
| 406 | #endif /* CONFIG_PPC64 */ |
| 407 | #ifdef CONFIG_PPC32 |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 408 | #if CLASSIC_PPC |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 409 | { /* 601 */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 410 | .pvr_mask = 0xffff0000, |
| 411 | .pvr_value = 0x00010000, |
| 412 | .cpu_name = "601", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 413 | .cpu_features = CPU_FTRS_PPC601, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 414 | .cpu_user_features = COMMON_USER | PPC_FEATURE_601_INSTR | |
Paul Mackerras | 9859901 | 2005-10-22 16:51:34 +1000 | [diff] [blame] | 415 | PPC_FEATURE_UNIFIED_CACHE | PPC_FEATURE_NO_TB, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 416 | .icache_bsize = 32, |
| 417 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 418 | .platform = "ppc601", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 419 | }, |
| 420 | { /* 603 */ |
| 421 | .pvr_mask = 0xffff0000, |
| 422 | .pvr_value = 0x00030000, |
| 423 | .cpu_name = "603", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 424 | .cpu_features = CPU_FTRS_603, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 425 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 426 | .icache_bsize = 32, |
| 427 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 428 | .cpu_setup = __setup_cpu_603, |
| 429 | .platform = "ppc603", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 430 | }, |
| 431 | { /* 603e */ |
| 432 | .pvr_mask = 0xffff0000, |
| 433 | .pvr_value = 0x00060000, |
| 434 | .cpu_name = "603e", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 435 | .cpu_features = CPU_FTRS_603, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 436 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 437 | .icache_bsize = 32, |
| 438 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 439 | .cpu_setup = __setup_cpu_603, |
| 440 | .platform = "ppc603", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 441 | }, |
| 442 | { /* 603ev */ |
| 443 | .pvr_mask = 0xffff0000, |
| 444 | .pvr_value = 0x00070000, |
| 445 | .cpu_name = "603ev", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 446 | .cpu_features = CPU_FTRS_603, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 447 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 448 | .icache_bsize = 32, |
| 449 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 450 | .cpu_setup = __setup_cpu_603, |
| 451 | .platform = "ppc603", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 452 | }, |
| 453 | { /* 604 */ |
| 454 | .pvr_mask = 0xffff0000, |
| 455 | .pvr_value = 0x00040000, |
| 456 | .cpu_name = "604", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 457 | .cpu_features = CPU_FTRS_604, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 458 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 459 | .icache_bsize = 32, |
| 460 | .dcache_bsize = 32, |
| 461 | .num_pmcs = 2, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 462 | .cpu_setup = __setup_cpu_604, |
| 463 | .platform = "ppc604", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 464 | }, |
| 465 | { /* 604e */ |
| 466 | .pvr_mask = 0xfffff000, |
| 467 | .pvr_value = 0x00090000, |
| 468 | .cpu_name = "604e", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 469 | .cpu_features = CPU_FTRS_604, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 470 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 471 | .icache_bsize = 32, |
| 472 | .dcache_bsize = 32, |
| 473 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 474 | .cpu_setup = __setup_cpu_604, |
| 475 | .platform = "ppc604", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 476 | }, |
| 477 | { /* 604r */ |
| 478 | .pvr_mask = 0xffff0000, |
| 479 | .pvr_value = 0x00090000, |
| 480 | .cpu_name = "604r", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 481 | .cpu_features = CPU_FTRS_604, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 482 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 483 | .icache_bsize = 32, |
| 484 | .dcache_bsize = 32, |
| 485 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 486 | .cpu_setup = __setup_cpu_604, |
| 487 | .platform = "ppc604", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 488 | }, |
| 489 | { /* 604ev */ |
| 490 | .pvr_mask = 0xffff0000, |
| 491 | .pvr_value = 0x000a0000, |
| 492 | .cpu_name = "604ev", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 493 | .cpu_features = CPU_FTRS_604, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 494 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 495 | .icache_bsize = 32, |
| 496 | .dcache_bsize = 32, |
| 497 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 498 | .cpu_setup = __setup_cpu_604, |
| 499 | .platform = "ppc604", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 500 | }, |
| 501 | { /* 740/750 (0x4202, don't support TAU ?) */ |
| 502 | .pvr_mask = 0xffffffff, |
| 503 | .pvr_value = 0x00084202, |
| 504 | .cpu_name = "740/750", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 505 | .cpu_features = CPU_FTRS_740_NOTAU, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 506 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 507 | .icache_bsize = 32, |
| 508 | .dcache_bsize = 32, |
| 509 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 510 | .cpu_setup = __setup_cpu_750, |
| 511 | .platform = "ppc750", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 512 | }, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 513 | { /* 750CX (80100 and 8010x?) */ |
| 514 | .pvr_mask = 0xfffffff0, |
| 515 | .pvr_value = 0x00080100, |
| 516 | .cpu_name = "750CX", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 517 | .cpu_features = CPU_FTRS_750, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 518 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 519 | .icache_bsize = 32, |
| 520 | .dcache_bsize = 32, |
| 521 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 522 | .cpu_setup = __setup_cpu_750cx, |
| 523 | .platform = "ppc750", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 524 | }, |
| 525 | { /* 750CX (82201 and 82202) */ |
| 526 | .pvr_mask = 0xfffffff0, |
| 527 | .pvr_value = 0x00082200, |
| 528 | .cpu_name = "750CX", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 529 | .cpu_features = CPU_FTRS_750, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 530 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 531 | .icache_bsize = 32, |
| 532 | .dcache_bsize = 32, |
| 533 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 534 | .cpu_setup = __setup_cpu_750cx, |
| 535 | .platform = "ppc750", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 536 | }, |
| 537 | { /* 750CXe (82214) */ |
| 538 | .pvr_mask = 0xfffffff0, |
| 539 | .pvr_value = 0x00082210, |
| 540 | .cpu_name = "750CXe", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 541 | .cpu_features = CPU_FTRS_750, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 542 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 543 | .icache_bsize = 32, |
| 544 | .dcache_bsize = 32, |
| 545 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 546 | .cpu_setup = __setup_cpu_750cx, |
| 547 | .platform = "ppc750", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 548 | }, |
Arthur Othieno | 7c31625 | 2005-09-03 15:55:52 -0700 | [diff] [blame] | 549 | { /* 750CXe "Gekko" (83214) */ |
| 550 | .pvr_mask = 0xffffffff, |
| 551 | .pvr_value = 0x00083214, |
| 552 | .cpu_name = "750CXe", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 553 | .cpu_features = CPU_FTRS_750, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 554 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Arthur Othieno | 7c31625 | 2005-09-03 15:55:52 -0700 | [diff] [blame] | 555 | .icache_bsize = 32, |
| 556 | .dcache_bsize = 32, |
| 557 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 558 | .cpu_setup = __setup_cpu_750cx, |
| 559 | .platform = "ppc750", |
Arthur Othieno | 7c31625 | 2005-09-03 15:55:52 -0700 | [diff] [blame] | 560 | }, |
Jake Moilanen | cfbff8a | 2006-10-03 14:29:34 -0500 | [diff] [blame^] | 561 | { /* 750CL */ |
| 562 | .pvr_mask = 0xfffff0f0, |
| 563 | .pvr_value = 0x00087010, |
| 564 | .cpu_name = "750CL", |
| 565 | .cpu_features = CPU_FTRS_750, |
| 566 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
| 567 | .icache_bsize = 32, |
| 568 | .dcache_bsize = 32, |
| 569 | .num_pmcs = 4, |
| 570 | .cpu_setup = __setup_cpu_750cx, |
| 571 | .platform = "ppc750", |
| 572 | }, |
Arthur Othieno | ac1ff04 | 2005-09-03 15:55:51 -0700 | [diff] [blame] | 573 | { /* 745/755 */ |
| 574 | .pvr_mask = 0xfffff000, |
| 575 | .pvr_value = 0x00083000, |
| 576 | .cpu_name = "745/755", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 577 | .cpu_features = CPU_FTRS_750, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 578 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Arthur Othieno | ac1ff04 | 2005-09-03 15:55:51 -0700 | [diff] [blame] | 579 | .icache_bsize = 32, |
| 580 | .dcache_bsize = 32, |
| 581 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 582 | .cpu_setup = __setup_cpu_750, |
| 583 | .platform = "ppc750", |
Arthur Othieno | ac1ff04 | 2005-09-03 15:55:51 -0700 | [diff] [blame] | 584 | }, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 585 | { /* 750FX rev 1.x */ |
| 586 | .pvr_mask = 0xffffff00, |
| 587 | .pvr_value = 0x70000100, |
| 588 | .cpu_name = "750FX", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 589 | .cpu_features = CPU_FTRS_750FX1, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 590 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 591 | .icache_bsize = 32, |
| 592 | .dcache_bsize = 32, |
| 593 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 594 | .cpu_setup = __setup_cpu_750, |
| 595 | .platform = "ppc750", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 596 | }, |
| 597 | { /* 750FX rev 2.0 must disable HID0[DPM] */ |
| 598 | .pvr_mask = 0xffffffff, |
| 599 | .pvr_value = 0x70000200, |
| 600 | .cpu_name = "750FX", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 601 | .cpu_features = CPU_FTRS_750FX2, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 602 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 603 | .icache_bsize = 32, |
| 604 | .dcache_bsize = 32, |
| 605 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 606 | .cpu_setup = __setup_cpu_750, |
| 607 | .platform = "ppc750", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 608 | }, |
| 609 | { /* 750FX (All revs except 2.0) */ |
| 610 | .pvr_mask = 0xffff0000, |
| 611 | .pvr_value = 0x70000000, |
| 612 | .cpu_name = "750FX", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 613 | .cpu_features = CPU_FTRS_750FX, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 614 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 615 | .icache_bsize = 32, |
| 616 | .dcache_bsize = 32, |
| 617 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 618 | .cpu_setup = __setup_cpu_750fx, |
| 619 | .platform = "ppc750", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 620 | }, |
| 621 | { /* 750GX */ |
| 622 | .pvr_mask = 0xffff0000, |
| 623 | .pvr_value = 0x70020000, |
| 624 | .cpu_name = "750GX", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 625 | .cpu_features = CPU_FTRS_750GX, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 626 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 627 | .icache_bsize = 32, |
| 628 | .dcache_bsize = 32, |
| 629 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 630 | .cpu_setup = __setup_cpu_750fx, |
| 631 | .platform = "ppc750", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 632 | }, |
| 633 | { /* 740/750 (L2CR bit need fixup for 740) */ |
| 634 | .pvr_mask = 0xffff0000, |
| 635 | .pvr_value = 0x00080000, |
| 636 | .cpu_name = "740/750", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 637 | .cpu_features = CPU_FTRS_740, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 638 | .cpu_user_features = COMMON_USER | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 639 | .icache_bsize = 32, |
| 640 | .dcache_bsize = 32, |
| 641 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 642 | .cpu_setup = __setup_cpu_750, |
| 643 | .platform = "ppc750", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 644 | }, |
| 645 | { /* 7400 rev 1.1 ? (no TAU) */ |
| 646 | .pvr_mask = 0xffffffff, |
| 647 | .pvr_value = 0x000c1101, |
| 648 | .cpu_name = "7400 (1.1)", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 649 | .cpu_features = CPU_FTRS_7400_NOTAU, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 650 | .cpu_user_features = COMMON_USER | |
| 651 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 652 | .icache_bsize = 32, |
| 653 | .dcache_bsize = 32, |
| 654 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 655 | .cpu_setup = __setup_cpu_7400, |
| 656 | .platform = "ppc7400", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 657 | }, |
| 658 | { /* 7400 */ |
| 659 | .pvr_mask = 0xffff0000, |
| 660 | .pvr_value = 0x000c0000, |
| 661 | .cpu_name = "7400", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 662 | .cpu_features = CPU_FTRS_7400, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 663 | .cpu_user_features = COMMON_USER | |
| 664 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 665 | .icache_bsize = 32, |
| 666 | .dcache_bsize = 32, |
| 667 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 668 | .cpu_setup = __setup_cpu_7400, |
| 669 | .platform = "ppc7400", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 670 | }, |
| 671 | { /* 7410 */ |
| 672 | .pvr_mask = 0xffff0000, |
| 673 | .pvr_value = 0x800c0000, |
| 674 | .cpu_name = "7410", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 675 | .cpu_features = CPU_FTRS_7400, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 676 | .cpu_user_features = COMMON_USER | |
| 677 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 678 | .icache_bsize = 32, |
| 679 | .dcache_bsize = 32, |
| 680 | .num_pmcs = 4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 681 | .cpu_setup = __setup_cpu_7410, |
| 682 | .platform = "ppc7400", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 683 | }, |
| 684 | { /* 7450 2.0 - no doze/nap */ |
| 685 | .pvr_mask = 0xffffffff, |
| 686 | .pvr_value = 0x80000200, |
| 687 | .cpu_name = "7450", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 688 | .cpu_features = CPU_FTRS_7450_20, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 689 | .cpu_user_features = COMMON_USER | |
| 690 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 691 | .icache_bsize = 32, |
| 692 | .dcache_bsize = 32, |
| 693 | .num_pmcs = 6, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 694 | .cpu_setup = __setup_cpu_745x, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 695 | .oprofile_cpu_type = "ppc/7450", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 696 | .oprofile_type = PPC_OPROFILE_G4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 697 | .platform = "ppc7450", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 698 | }, |
| 699 | { /* 7450 2.1 */ |
| 700 | .pvr_mask = 0xffffffff, |
| 701 | .pvr_value = 0x80000201, |
| 702 | .cpu_name = "7450", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 703 | .cpu_features = CPU_FTRS_7450_21, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 704 | .cpu_user_features = COMMON_USER | |
| 705 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 706 | .icache_bsize = 32, |
| 707 | .dcache_bsize = 32, |
| 708 | .num_pmcs = 6, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 709 | .cpu_setup = __setup_cpu_745x, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 710 | .oprofile_cpu_type = "ppc/7450", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 711 | .oprofile_type = PPC_OPROFILE_G4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 712 | .platform = "ppc7450", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 713 | }, |
| 714 | { /* 7450 2.3 and newer */ |
| 715 | .pvr_mask = 0xffff0000, |
| 716 | .pvr_value = 0x80000000, |
| 717 | .cpu_name = "7450", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 718 | .cpu_features = CPU_FTRS_7450_23, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 719 | .cpu_user_features = COMMON_USER | |
| 720 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 721 | .icache_bsize = 32, |
| 722 | .dcache_bsize = 32, |
| 723 | .num_pmcs = 6, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 724 | .cpu_setup = __setup_cpu_745x, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 725 | .oprofile_cpu_type = "ppc/7450", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 726 | .oprofile_type = PPC_OPROFILE_G4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 727 | .platform = "ppc7450", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 728 | }, |
| 729 | { /* 7455 rev 1.x */ |
| 730 | .pvr_mask = 0xffffff00, |
| 731 | .pvr_value = 0x80010100, |
| 732 | .cpu_name = "7455", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 733 | .cpu_features = CPU_FTRS_7455_1, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 734 | .cpu_user_features = COMMON_USER | |
| 735 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 736 | .icache_bsize = 32, |
| 737 | .dcache_bsize = 32, |
| 738 | .num_pmcs = 6, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 739 | .cpu_setup = __setup_cpu_745x, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 740 | .oprofile_cpu_type = "ppc/7450", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 741 | .oprofile_type = PPC_OPROFILE_G4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 742 | .platform = "ppc7450", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 743 | }, |
| 744 | { /* 7455 rev 2.0 */ |
| 745 | .pvr_mask = 0xffffffff, |
| 746 | .pvr_value = 0x80010200, |
| 747 | .cpu_name = "7455", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 748 | .cpu_features = CPU_FTRS_7455_20, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 749 | .cpu_user_features = COMMON_USER | |
| 750 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 751 | .icache_bsize = 32, |
| 752 | .dcache_bsize = 32, |
| 753 | .num_pmcs = 6, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 754 | .cpu_setup = __setup_cpu_745x, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 755 | .oprofile_cpu_type = "ppc/7450", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 756 | .oprofile_type = PPC_OPROFILE_G4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 757 | .platform = "ppc7450", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 758 | }, |
| 759 | { /* 7455 others */ |
| 760 | .pvr_mask = 0xffff0000, |
| 761 | .pvr_value = 0x80010000, |
| 762 | .cpu_name = "7455", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 763 | .cpu_features = CPU_FTRS_7455, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 764 | .cpu_user_features = COMMON_USER | |
| 765 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 766 | .icache_bsize = 32, |
| 767 | .dcache_bsize = 32, |
| 768 | .num_pmcs = 6, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 769 | .cpu_setup = __setup_cpu_745x, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 770 | .oprofile_cpu_type = "ppc/7450", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 771 | .oprofile_type = PPC_OPROFILE_G4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 772 | .platform = "ppc7450", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 773 | }, |
| 774 | { /* 7447/7457 Rev 1.0 */ |
| 775 | .pvr_mask = 0xffffffff, |
| 776 | .pvr_value = 0x80020100, |
| 777 | .cpu_name = "7447/7457", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 778 | .cpu_features = CPU_FTRS_7447_10, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 779 | .cpu_user_features = COMMON_USER | |
| 780 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 781 | .icache_bsize = 32, |
| 782 | .dcache_bsize = 32, |
| 783 | .num_pmcs = 6, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 784 | .cpu_setup = __setup_cpu_745x, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 785 | .oprofile_cpu_type = "ppc/7450", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 786 | .oprofile_type = PPC_OPROFILE_G4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 787 | .platform = "ppc7450", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 788 | }, |
| 789 | { /* 7447/7457 Rev 1.1 */ |
| 790 | .pvr_mask = 0xffffffff, |
| 791 | .pvr_value = 0x80020101, |
| 792 | .cpu_name = "7447/7457", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 793 | .cpu_features = CPU_FTRS_7447_10, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 794 | .cpu_user_features = COMMON_USER | |
| 795 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 796 | .icache_bsize = 32, |
| 797 | .dcache_bsize = 32, |
| 798 | .num_pmcs = 6, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 799 | .cpu_setup = __setup_cpu_745x, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 800 | .oprofile_cpu_type = "ppc/7450", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 801 | .oprofile_type = PPC_OPROFILE_G4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 802 | .platform = "ppc7450", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 803 | }, |
| 804 | { /* 7447/7457 Rev 1.2 and later */ |
| 805 | .pvr_mask = 0xffff0000, |
| 806 | .pvr_value = 0x80020000, |
| 807 | .cpu_name = "7447/7457", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 808 | .cpu_features = CPU_FTRS_7447, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 809 | .cpu_user_features = COMMON_USER | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 810 | .icache_bsize = 32, |
| 811 | .dcache_bsize = 32, |
| 812 | .num_pmcs = 6, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 813 | .cpu_setup = __setup_cpu_745x, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 814 | .oprofile_cpu_type = "ppc/7450", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 815 | .oprofile_type = PPC_OPROFILE_G4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 816 | .platform = "ppc7450", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 817 | }, |
| 818 | { /* 7447A */ |
| 819 | .pvr_mask = 0xffff0000, |
| 820 | .pvr_value = 0x80030000, |
| 821 | .cpu_name = "7447A", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 822 | .cpu_features = CPU_FTRS_7447A, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 823 | .cpu_user_features = COMMON_USER | |
| 824 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 825 | .icache_bsize = 32, |
| 826 | .dcache_bsize = 32, |
| 827 | .num_pmcs = 6, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 828 | .cpu_setup = __setup_cpu_745x, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 829 | .oprofile_cpu_type = "ppc/7450", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 830 | .oprofile_type = PPC_OPROFILE_G4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 831 | .platform = "ppc7450", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 832 | }, |
Kumar Gala | bbde630 | 2005-09-03 15:55:55 -0700 | [diff] [blame] | 833 | { /* 7448 */ |
| 834 | .pvr_mask = 0xffff0000, |
| 835 | .pvr_value = 0x80040000, |
| 836 | .cpu_name = "7448", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 837 | .cpu_features = CPU_FTRS_7447A, |
Paul Mackerras | fab5db9 | 2006-06-07 16:14:40 +1000 | [diff] [blame] | 838 | .cpu_user_features = COMMON_USER | |
| 839 | PPC_FEATURE_HAS_ALTIVEC_COMP | PPC_FEATURE_PPC_LE, |
Kumar Gala | bbde630 | 2005-09-03 15:55:55 -0700 | [diff] [blame] | 840 | .icache_bsize = 32, |
| 841 | .dcache_bsize = 32, |
| 842 | .num_pmcs = 6, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 843 | .cpu_setup = __setup_cpu_745x, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 844 | .oprofile_cpu_type = "ppc/7450", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 845 | .oprofile_type = PPC_OPROFILE_G4, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 846 | .platform = "ppc7450", |
Kumar Gala | bbde630 | 2005-09-03 15:55:55 -0700 | [diff] [blame] | 847 | }, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 848 | { /* 82xx (8240, 8245, 8260 are all 603e cores) */ |
| 849 | .pvr_mask = 0x7fff0000, |
| 850 | .pvr_value = 0x00810000, |
| 851 | .cpu_name = "82xx", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 852 | .cpu_features = CPU_FTRS_82XX, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 853 | .cpu_user_features = COMMON_USER, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 854 | .icache_bsize = 32, |
| 855 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 856 | .cpu_setup = __setup_cpu_603, |
| 857 | .platform = "ppc603", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 858 | }, |
| 859 | { /* All G2_LE (603e core, plus some) have the same pvr */ |
| 860 | .pvr_mask = 0x7fff0000, |
| 861 | .pvr_value = 0x00820000, |
| 862 | .cpu_name = "G2_LE", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 863 | .cpu_features = CPU_FTRS_G2_LE, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 864 | .cpu_user_features = COMMON_USER, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 865 | .icache_bsize = 32, |
| 866 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 867 | .cpu_setup = __setup_cpu_603, |
| 868 | .platform = "ppc603", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 869 | }, |
Kim Phillips | 6c4a250 | 2006-10-02 20:10:24 -0500 | [diff] [blame] | 870 | { /* e300c1 (a 603e core, plus some) on 83xx */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 871 | .pvr_mask = 0x7fff0000, |
| 872 | .pvr_value = 0x00830000, |
Kim Phillips | 6c4a250 | 2006-10-02 20:10:24 -0500 | [diff] [blame] | 873 | .cpu_name = "e300c1", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 874 | .cpu_features = CPU_FTRS_E300, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 875 | .cpu_user_features = COMMON_USER, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 876 | .icache_bsize = 32, |
| 877 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 878 | .cpu_setup = __setup_cpu_603, |
| 879 | .platform = "ppc603", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 880 | }, |
Kim Phillips | 6c4a250 | 2006-10-02 20:10:24 -0500 | [diff] [blame] | 881 | { /* e300c2 (an e300c1 core, plus some, minus FPU) on 83xx */ |
| 882 | .pvr_mask = 0x7fff0000, |
| 883 | .pvr_value = 0x00840000, |
| 884 | .cpu_name = "e300c2", |
Kim Phillips | aa42c69 | 2006-12-08 02:43:30 -0600 | [diff] [blame] | 885 | .cpu_features = CPU_FTRS_E300C2, |
Kim Phillips | 6c4a250 | 2006-10-02 20:10:24 -0500 | [diff] [blame] | 886 | .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU, |
| 887 | .icache_bsize = 32, |
| 888 | .dcache_bsize = 32, |
| 889 | .cpu_setup = __setup_cpu_603, |
| 890 | .platform = "ppc603", |
| 891 | }, |
Scott Wood | 57933f8 | 2006-12-01 12:57:05 -0600 | [diff] [blame] | 892 | { /* e300c3 on 83xx */ |
| 893 | .pvr_mask = 0x7fff0000, |
| 894 | .pvr_value = 0x00850000, |
| 895 | .cpu_name = "e300c3", |
| 896 | .cpu_features = CPU_FTRS_E300, |
| 897 | .cpu_user_features = COMMON_USER, |
| 898 | .icache_bsize = 32, |
| 899 | .dcache_bsize = 32, |
| 900 | .cpu_setup = __setup_cpu_603, |
| 901 | .platform = "ppc603", |
| 902 | }, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 903 | { /* default match, we assume split I/D cache & TB (non-601)... */ |
| 904 | .pvr_mask = 0x00000000, |
| 905 | .pvr_value = 0x00000000, |
| 906 | .cpu_name = "(generic PPC)", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 907 | .cpu_features = CPU_FTRS_CLASSIC32, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 908 | .cpu_user_features = COMMON_USER, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 909 | .icache_bsize = 32, |
| 910 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 911 | .platform = "ppc603", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 912 | }, |
| 913 | #endif /* CLASSIC_PPC */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 914 | #ifdef CONFIG_8xx |
| 915 | { /* 8xx */ |
| 916 | .pvr_mask = 0xffff0000, |
| 917 | .pvr_value = 0x00500000, |
| 918 | .cpu_name = "8xx", |
| 919 | /* CPU_FTR_MAYBE_CAN_DOZE is possible, |
| 920 | * if the 8xx code is there.... */ |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 921 | .cpu_features = CPU_FTRS_8XX, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 922 | .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU, |
| 923 | .icache_bsize = 16, |
| 924 | .dcache_bsize = 16, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 925 | .platform = "ppc823", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 926 | }, |
| 927 | #endif /* CONFIG_8xx */ |
| 928 | #ifdef CONFIG_40x |
| 929 | { /* 403GC */ |
| 930 | .pvr_mask = 0xffffff00, |
| 931 | .pvr_value = 0x00200200, |
| 932 | .cpu_name = "403GC", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 933 | .cpu_features = CPU_FTRS_40X, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 934 | .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU, |
| 935 | .icache_bsize = 16, |
| 936 | .dcache_bsize = 16, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 937 | .platform = "ppc403", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 938 | }, |
| 939 | { /* 403GCX */ |
| 940 | .pvr_mask = 0xffffff00, |
| 941 | .pvr_value = 0x00201400, |
| 942 | .cpu_name = "403GCX", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 943 | .cpu_features = CPU_FTRS_40X, |
Paul Mackerras | 9859901 | 2005-10-22 16:51:34 +1000 | [diff] [blame] | 944 | .cpu_user_features = PPC_FEATURE_32 | |
| 945 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_NO_TB, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 946 | .icache_bsize = 16, |
| 947 | .dcache_bsize = 16, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 948 | .platform = "ppc403", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 949 | }, |
| 950 | { /* 403G ?? */ |
| 951 | .pvr_mask = 0xffff0000, |
| 952 | .pvr_value = 0x00200000, |
| 953 | .cpu_name = "403G ??", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 954 | .cpu_features = CPU_FTRS_40X, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 955 | .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU, |
| 956 | .icache_bsize = 16, |
| 957 | .dcache_bsize = 16, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 958 | .platform = "ppc403", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 959 | }, |
| 960 | { /* 405GP */ |
| 961 | .pvr_mask = 0xffff0000, |
| 962 | .pvr_value = 0x40110000, |
| 963 | .cpu_name = "405GP", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 964 | .cpu_features = CPU_FTRS_40X, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 965 | .cpu_user_features = PPC_FEATURE_32 | |
| 966 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, |
| 967 | .icache_bsize = 32, |
| 968 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 969 | .platform = "ppc405", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 970 | }, |
| 971 | { /* STB 03xxx */ |
| 972 | .pvr_mask = 0xffff0000, |
| 973 | .pvr_value = 0x40130000, |
| 974 | .cpu_name = "STB03xxx", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 975 | .cpu_features = CPU_FTRS_40X, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 976 | .cpu_user_features = PPC_FEATURE_32 | |
| 977 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, |
| 978 | .icache_bsize = 32, |
| 979 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 980 | .platform = "ppc405", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 981 | }, |
| 982 | { /* STB 04xxx */ |
| 983 | .pvr_mask = 0xffff0000, |
| 984 | .pvr_value = 0x41810000, |
| 985 | .cpu_name = "STB04xxx", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 986 | .cpu_features = CPU_FTRS_40X, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 987 | .cpu_user_features = PPC_FEATURE_32 | |
| 988 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, |
| 989 | .icache_bsize = 32, |
| 990 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 991 | .platform = "ppc405", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 992 | }, |
| 993 | { /* NP405L */ |
| 994 | .pvr_mask = 0xffff0000, |
| 995 | .pvr_value = 0x41610000, |
| 996 | .cpu_name = "NP405L", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 997 | .cpu_features = CPU_FTRS_40X, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 998 | .cpu_user_features = PPC_FEATURE_32 | |
| 999 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, |
| 1000 | .icache_bsize = 32, |
| 1001 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1002 | .platform = "ppc405", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1003 | }, |
| 1004 | { /* NP4GS3 */ |
| 1005 | .pvr_mask = 0xffff0000, |
| 1006 | .pvr_value = 0x40B10000, |
| 1007 | .cpu_name = "NP4GS3", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1008 | .cpu_features = CPU_FTRS_40X, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1009 | .cpu_user_features = PPC_FEATURE_32 | |
| 1010 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, |
| 1011 | .icache_bsize = 32, |
| 1012 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1013 | .platform = "ppc405", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1014 | }, |
| 1015 | { /* NP405H */ |
| 1016 | .pvr_mask = 0xffff0000, |
| 1017 | .pvr_value = 0x41410000, |
| 1018 | .cpu_name = "NP405H", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1019 | .cpu_features = CPU_FTRS_40X, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1020 | .cpu_user_features = PPC_FEATURE_32 | |
| 1021 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, |
| 1022 | .icache_bsize = 32, |
| 1023 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1024 | .platform = "ppc405", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1025 | }, |
| 1026 | { /* 405GPr */ |
| 1027 | .pvr_mask = 0xffff0000, |
| 1028 | .pvr_value = 0x50910000, |
| 1029 | .cpu_name = "405GPr", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1030 | .cpu_features = CPU_FTRS_40X, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1031 | .cpu_user_features = PPC_FEATURE_32 | |
| 1032 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, |
| 1033 | .icache_bsize = 32, |
| 1034 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1035 | .platform = "ppc405", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1036 | }, |
| 1037 | { /* STBx25xx */ |
| 1038 | .pvr_mask = 0xffff0000, |
| 1039 | .pvr_value = 0x51510000, |
| 1040 | .cpu_name = "STBx25xx", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1041 | .cpu_features = CPU_FTRS_40X, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1042 | .cpu_user_features = PPC_FEATURE_32 | |
| 1043 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, |
| 1044 | .icache_bsize = 32, |
| 1045 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1046 | .platform = "ppc405", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1047 | }, |
| 1048 | { /* 405LP */ |
| 1049 | .pvr_mask = 0xffff0000, |
| 1050 | .pvr_value = 0x41F10000, |
| 1051 | .cpu_name = "405LP", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1052 | .cpu_features = CPU_FTRS_40X, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1053 | .cpu_user_features = PPC_FEATURE_32 | PPC_FEATURE_HAS_MMU, |
| 1054 | .icache_bsize = 32, |
| 1055 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1056 | .platform = "ppc405", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1057 | }, |
| 1058 | { /* Xilinx Virtex-II Pro */ |
Grant C. Likely | 72646c7 | 2006-01-19 01:13:20 -0700 | [diff] [blame] | 1059 | .pvr_mask = 0xfffff000, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1060 | .pvr_value = 0x20010000, |
| 1061 | .cpu_name = "Virtex-II Pro", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1062 | .cpu_features = CPU_FTRS_40X, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1063 | .cpu_user_features = PPC_FEATURE_32 | |
| 1064 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, |
| 1065 | .icache_bsize = 32, |
| 1066 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1067 | .platform = "ppc405", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1068 | }, |
Grant C. Likely | 72646c7 | 2006-01-19 01:13:20 -0700 | [diff] [blame] | 1069 | { /* Xilinx Virtex-4 FX */ |
| 1070 | .pvr_mask = 0xfffff000, |
| 1071 | .pvr_value = 0x20011000, |
| 1072 | .cpu_name = "Virtex-4 FX", |
| 1073 | .cpu_features = CPU_FTRS_40X, |
| 1074 | .cpu_user_features = PPC_FEATURE_32 | |
| 1075 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, |
| 1076 | .icache_bsize = 32, |
| 1077 | .dcache_bsize = 32, |
Peter Bergner | 838fdb4 | 2006-09-14 14:18:38 -0500 | [diff] [blame] | 1078 | .platform = "ppc405", |
Grant C. Likely | 72646c7 | 2006-01-19 01:13:20 -0700 | [diff] [blame] | 1079 | }, |
Eugene Surovegin | ad95d60 | 2005-06-07 13:22:09 -0700 | [diff] [blame] | 1080 | { /* 405EP */ |
| 1081 | .pvr_mask = 0xffff0000, |
| 1082 | .pvr_value = 0x51210000, |
| 1083 | .cpu_name = "405EP", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1084 | .cpu_features = CPU_FTRS_40X, |
Eugene Surovegin | ad95d60 | 2005-06-07 13:22:09 -0700 | [diff] [blame] | 1085 | .cpu_user_features = PPC_FEATURE_32 | |
| 1086 | PPC_FEATURE_HAS_MMU | PPC_FEATURE_HAS_4xxMAC, |
| 1087 | .icache_bsize = 32, |
| 1088 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1089 | .platform = "ppc405", |
Eugene Surovegin | ad95d60 | 2005-06-07 13:22:09 -0700 | [diff] [blame] | 1090 | }, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1091 | |
| 1092 | #endif /* CONFIG_40x */ |
| 1093 | #ifdef CONFIG_44x |
Matt Porter | c9cf73a | 2005-07-31 22:34:52 -0700 | [diff] [blame] | 1094 | { |
| 1095 | .pvr_mask = 0xf0000fff, |
| 1096 | .pvr_value = 0x40000850, |
| 1097 | .cpu_name = "440EP Rev. A", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1098 | .cpu_features = CPU_FTRS_44X, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1099 | .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU, |
Matt Porter | c9cf73a | 2005-07-31 22:34:52 -0700 | [diff] [blame] | 1100 | .icache_bsize = 32, |
| 1101 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1102 | .platform = "ppc440", |
Matt Porter | c9cf73a | 2005-07-31 22:34:52 -0700 | [diff] [blame] | 1103 | }, |
| 1104 | { |
| 1105 | .pvr_mask = 0xf0000fff, |
| 1106 | .pvr_value = 0x400008d3, |
| 1107 | .cpu_name = "440EP Rev. B", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1108 | .cpu_features = CPU_FTRS_44X, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1109 | .cpu_user_features = COMMON_USER_BOOKE | PPC_FEATURE_HAS_FPU, |
Matt Porter | c9cf73a | 2005-07-31 22:34:52 -0700 | [diff] [blame] | 1110 | .icache_bsize = 32, |
| 1111 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1112 | .platform = "ppc440", |
Matt Porter | c9cf73a | 2005-07-31 22:34:52 -0700 | [diff] [blame] | 1113 | }, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 1114 | { /* 440GP Rev. B */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1115 | .pvr_mask = 0xf0000fff, |
| 1116 | .pvr_value = 0x40000440, |
| 1117 | .cpu_name = "440GP Rev. B", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1118 | .cpu_features = CPU_FTRS_44X, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1119 | .cpu_user_features = COMMON_USER_BOOKE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1120 | .icache_bsize = 32, |
| 1121 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1122 | .platform = "ppc440gp", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1123 | }, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 1124 | { /* 440GP Rev. C */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1125 | .pvr_mask = 0xf0000fff, |
| 1126 | .pvr_value = 0x40000481, |
| 1127 | .cpu_name = "440GP Rev. C", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1128 | .cpu_features = CPU_FTRS_44X, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1129 | .cpu_user_features = COMMON_USER_BOOKE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1130 | .icache_bsize = 32, |
| 1131 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1132 | .platform = "ppc440gp", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1133 | }, |
| 1134 | { /* 440GX Rev. A */ |
| 1135 | .pvr_mask = 0xf0000fff, |
| 1136 | .pvr_value = 0x50000850, |
| 1137 | .cpu_name = "440GX Rev. A", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1138 | .cpu_features = CPU_FTRS_44X, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1139 | .cpu_user_features = COMMON_USER_BOOKE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1140 | .icache_bsize = 32, |
| 1141 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1142 | .platform = "ppc440", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1143 | }, |
| 1144 | { /* 440GX Rev. B */ |
| 1145 | .pvr_mask = 0xf0000fff, |
| 1146 | .pvr_value = 0x50000851, |
| 1147 | .cpu_name = "440GX Rev. B", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1148 | .cpu_features = CPU_FTRS_44X, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1149 | .cpu_user_features = COMMON_USER_BOOKE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1150 | .icache_bsize = 32, |
| 1151 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1152 | .platform = "ppc440", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1153 | }, |
| 1154 | { /* 440GX Rev. C */ |
| 1155 | .pvr_mask = 0xf0000fff, |
| 1156 | .pvr_value = 0x50000892, |
| 1157 | .cpu_name = "440GX Rev. C", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1158 | .cpu_features = CPU_FTRS_44X, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1159 | .cpu_user_features = COMMON_USER_BOOKE, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1160 | .icache_bsize = 32, |
| 1161 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1162 | .platform = "ppc440", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1163 | }, |
Eugene Surovegin | 9149fb3 | 2005-09-03 15:55:40 -0700 | [diff] [blame] | 1164 | { /* 440GX Rev. F */ |
| 1165 | .pvr_mask = 0xf0000fff, |
| 1166 | .pvr_value = 0x50000894, |
| 1167 | .cpu_name = "440GX Rev. F", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1168 | .cpu_features = CPU_FTRS_44X, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1169 | .cpu_user_features = COMMON_USER_BOOKE, |
Eugene Surovegin | 9149fb3 | 2005-09-03 15:55:40 -0700 | [diff] [blame] | 1170 | .icache_bsize = 32, |
| 1171 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1172 | .platform = "ppc440", |
Eugene Surovegin | 9149fb3 | 2005-09-03 15:55:40 -0700 | [diff] [blame] | 1173 | }, |
Matt Porter | 656de7e | 2005-09-03 15:55:42 -0700 | [diff] [blame] | 1174 | { /* 440SP Rev. A */ |
| 1175 | .pvr_mask = 0xff000fff, |
| 1176 | .pvr_value = 0x53000891, |
| 1177 | .cpu_name = "440SP Rev. A", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1178 | .cpu_features = CPU_FTRS_44X, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1179 | .cpu_user_features = COMMON_USER_BOOKE, |
Matt Porter | 656de7e | 2005-09-03 15:55:42 -0700 | [diff] [blame] | 1180 | .icache_bsize = 32, |
| 1181 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1182 | .platform = "ppc440", |
Matt Porter | 656de7e | 2005-09-03 15:55:42 -0700 | [diff] [blame] | 1183 | }, |
Roland Dreier | b0f7b8b | 2005-11-07 00:58:13 -0800 | [diff] [blame] | 1184 | { /* 440SPe Rev. A */ |
| 1185 | .pvr_mask = 0xff000fff, |
| 1186 | .pvr_value = 0x53000890, |
| 1187 | .cpu_name = "440SPe Rev. A", |
Kumar Gala | a147c58 | 2006-12-08 02:34:38 -0600 | [diff] [blame] | 1188 | .cpu_features = CPU_FTRS_44X, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1189 | .cpu_user_features = COMMON_USER_BOOKE, |
Roland Dreier | b0f7b8b | 2005-11-07 00:58:13 -0800 | [diff] [blame] | 1190 | .icache_bsize = 32, |
| 1191 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1192 | .platform = "ppc440", |
Roland Dreier | b0f7b8b | 2005-11-07 00:58:13 -0800 | [diff] [blame] | 1193 | }, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1194 | #endif /* CONFIG_44x */ |
Kumar Gala | 33d9e9b | 2005-06-25 14:54:37 -0700 | [diff] [blame] | 1195 | #ifdef CONFIG_FSL_BOOKE |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 1196 | { /* e200z5 */ |
Kumar Gala | 33d9e9b | 2005-06-25 14:54:37 -0700 | [diff] [blame] | 1197 | .pvr_mask = 0xfff00000, |
| 1198 | .pvr_value = 0x81000000, |
| 1199 | .cpu_name = "e200z5", |
| 1200 | /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */ |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1201 | .cpu_features = CPU_FTRS_E200, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1202 | .cpu_user_features = COMMON_USER_BOOKE | |
| 1203 | PPC_FEATURE_HAS_EFP_SINGLE | |
Kumar Gala | 33d9e9b | 2005-06-25 14:54:37 -0700 | [diff] [blame] | 1204 | PPC_FEATURE_UNIFIED_CACHE, |
| 1205 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1206 | .platform = "ppc5554", |
Kumar Gala | 33d9e9b | 2005-06-25 14:54:37 -0700 | [diff] [blame] | 1207 | }, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 1208 | { /* e200z6 */ |
Kumar Gala | 33d9e9b | 2005-06-25 14:54:37 -0700 | [diff] [blame] | 1209 | .pvr_mask = 0xfff00000, |
| 1210 | .pvr_value = 0x81100000, |
| 1211 | .cpu_name = "e200z6", |
| 1212 | /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */ |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1213 | .cpu_features = CPU_FTRS_E200, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1214 | .cpu_user_features = COMMON_USER_BOOKE | |
| 1215 | PPC_FEATURE_SPE_COMP | |
Kumar Gala | 33d9e9b | 2005-06-25 14:54:37 -0700 | [diff] [blame] | 1216 | PPC_FEATURE_HAS_EFP_SINGLE | |
| 1217 | PPC_FEATURE_UNIFIED_CACHE, |
| 1218 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1219 | .platform = "ppc5554", |
Kumar Gala | 33d9e9b | 2005-06-25 14:54:37 -0700 | [diff] [blame] | 1220 | }, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 1221 | { /* e500 */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1222 | .pvr_mask = 0xffff0000, |
| 1223 | .pvr_value = 0x80200000, |
| 1224 | .cpu_name = "e500", |
| 1225 | /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */ |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1226 | .cpu_features = CPU_FTRS_E500, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1227 | .cpu_user_features = COMMON_USER_BOOKE | |
| 1228 | PPC_FEATURE_SPE_COMP | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1229 | PPC_FEATURE_HAS_EFP_SINGLE, |
| 1230 | .icache_bsize = 32, |
| 1231 | .dcache_bsize = 32, |
| 1232 | .num_pmcs = 4, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 1233 | .oprofile_cpu_type = "ppc/e500", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 1234 | .oprofile_type = PPC_OPROFILE_BOOKE, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1235 | .platform = "ppc8540", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1236 | }, |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 1237 | { /* e500v2 */ |
Kumar Gala | 5b37b70 | 2005-06-21 17:15:18 -0700 | [diff] [blame] | 1238 | .pvr_mask = 0xffff0000, |
| 1239 | .pvr_value = 0x80210000, |
| 1240 | .cpu_name = "e500v2", |
| 1241 | /* xxx - galak: add CPU_FTR_MAYBE_CAN_DOZE */ |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1242 | .cpu_features = CPU_FTRS_E500_2, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1243 | .cpu_user_features = COMMON_USER_BOOKE | |
| 1244 | PPC_FEATURE_SPE_COMP | |
| 1245 | PPC_FEATURE_HAS_EFP_SINGLE | |
| 1246 | PPC_FEATURE_HAS_EFP_DOUBLE, |
Kumar Gala | 5b37b70 | 2005-06-21 17:15:18 -0700 | [diff] [blame] | 1247 | .icache_bsize = 32, |
| 1248 | .dcache_bsize = 32, |
| 1249 | .num_pmcs = 4, |
Andy Fleming | 555d97a | 2005-12-15 20:02:04 -0600 | [diff] [blame] | 1250 | .oprofile_cpu_type = "ppc/e500", |
Andy Whitcroft | 7a45fb1 | 2006-01-13 12:35:49 +0000 | [diff] [blame] | 1251 | .oprofile_type = PPC_OPROFILE_BOOKE, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1252 | .platform = "ppc8548", |
Kumar Gala | 5b37b70 | 2005-06-21 17:15:18 -0700 | [diff] [blame] | 1253 | }, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1254 | #endif |
| 1255 | #if !CLASSIC_PPC |
| 1256 | { /* default match */ |
| 1257 | .pvr_mask = 0x00000000, |
| 1258 | .pvr_value = 0x00000000, |
| 1259 | .cpu_name = "(generic PPC)", |
Kumar Gala | 10b35d9 | 2005-09-23 14:08:58 -0500 | [diff] [blame] | 1260 | .cpu_features = CPU_FTRS_GENERIC_32, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1261 | .cpu_user_features = PPC_FEATURE_32, |
| 1262 | .icache_bsize = 32, |
| 1263 | .dcache_bsize = 32, |
Paul Mackerras | 80f15dc | 2006-01-14 10:11:39 +1100 | [diff] [blame] | 1264 | .platform = "powerpc", |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1265 | } |
| 1266 | #endif /* !CLASSIC_PPC */ |
Stephen Rothwell | 4920960 | 2005-10-12 15:55:09 +1000 | [diff] [blame] | 1267 | #endif /* CONFIG_PPC32 */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1268 | }; |
Benjamin Herrenschmidt | 42c4aaa | 2006-10-24 16:42:40 +1000 | [diff] [blame] | 1269 | |
Paul Mackerras | 974a76f | 2006-11-10 20:38:53 +1100 | [diff] [blame] | 1270 | struct cpu_spec *identify_cpu(unsigned long offset, unsigned int pvr) |
Benjamin Herrenschmidt | 42c4aaa | 2006-10-24 16:42:40 +1000 | [diff] [blame] | 1271 | { |
| 1272 | struct cpu_spec *s = cpu_specs; |
| 1273 | struct cpu_spec **cur = &cur_cpu_spec; |
Benjamin Herrenschmidt | 42c4aaa | 2006-10-24 16:42:40 +1000 | [diff] [blame] | 1274 | int i; |
| 1275 | |
| 1276 | s = PTRRELOC(s); |
| 1277 | cur = PTRRELOC(cur); |
| 1278 | |
Benjamin Herrenschmidt | 42c4aaa | 2006-10-24 16:42:40 +1000 | [diff] [blame] | 1279 | for (i = 0; i < ARRAY_SIZE(cpu_specs); i++,s++) |
| 1280 | if ((pvr & s->pvr_mask) == s->pvr_value) { |
| 1281 | *cur = cpu_specs + i; |
| 1282 | #ifdef CONFIG_PPC64 |
| 1283 | /* ppc64 expects identify_cpu to also call setup_cpu |
| 1284 | * for that processor. I will consolidate that at a |
| 1285 | * later time, for now, just use our friend #ifdef. |
| 1286 | * we also don't need to PTRRELOC the function pointer |
| 1287 | * on ppc64 as we are running at 0 in real mode. |
| 1288 | */ |
| 1289 | if (s->cpu_setup) { |
| 1290 | s->cpu_setup(offset, s); |
| 1291 | } |
| 1292 | #endif /* CONFIG_PPC64 */ |
| 1293 | return s; |
| 1294 | } |
| 1295 | BUG(); |
| 1296 | return NULL; |
| 1297 | } |
| 1298 | |
Benjamin Herrenschmidt | 0909c8c | 2006-10-20 11:47:18 +1000 | [diff] [blame] | 1299 | void do_feature_fixups(unsigned long value, void *fixup_start, void *fixup_end) |
Benjamin Herrenschmidt | 42c4aaa | 2006-10-24 16:42:40 +1000 | [diff] [blame] | 1300 | { |
| 1301 | struct fixup_entry { |
| 1302 | unsigned long mask; |
| 1303 | unsigned long value; |
Benjamin Herrenschmidt | 0909c8c | 2006-10-20 11:47:18 +1000 | [diff] [blame] | 1304 | long start_off; |
| 1305 | long end_off; |
Benjamin Herrenschmidt | 42c4aaa | 2006-10-24 16:42:40 +1000 | [diff] [blame] | 1306 | } *fcur, *fend; |
| 1307 | |
| 1308 | fcur = fixup_start; |
| 1309 | fend = fixup_end; |
| 1310 | |
| 1311 | for (; fcur < fend; fcur++) { |
| 1312 | unsigned int *pstart, *pend, *p; |
| 1313 | |
| 1314 | if ((value & fcur->mask) == fcur->value) |
| 1315 | continue; |
| 1316 | |
| 1317 | /* These PTRRELOCs will disappear once the new scheme for |
| 1318 | * modules and vdso is implemented |
| 1319 | */ |
Benjamin Herrenschmidt | 0909c8c | 2006-10-20 11:47:18 +1000 | [diff] [blame] | 1320 | pstart = ((unsigned int *)fcur) + (fcur->start_off / 4); |
| 1321 | pend = ((unsigned int *)fcur) + (fcur->end_off / 4); |
Benjamin Herrenschmidt | 42c4aaa | 2006-10-24 16:42:40 +1000 | [diff] [blame] | 1322 | |
| 1323 | for (p = pstart; p < pend; p++) { |
| 1324 | *p = 0x60000000u; |
| 1325 | asm volatile ("dcbst 0, %0" : : "r" (p)); |
| 1326 | } |
| 1327 | asm volatile ("sync" : : : "memory"); |
| 1328 | for (p = pstart; p < pend; p++) |
| 1329 | asm volatile ("icbi 0,%0" : : "r" (p)); |
| 1330 | asm volatile ("sync; isync" : : : "memory"); |
| 1331 | } |
| 1332 | } |