summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Langer <martin-langer@gmx.de>2008-09-07 17:51:32 +1000
committerPaul Mackerras <paulus@samba.org>2008-09-15 11:08:48 -0700
commita501d8f30e4fcca563e4ee462be00f96e51181d5 (patch)
tree5cb283736191251b3fd984a000b27a18884550ef
parent0b26425ce101a7c1b1ad4ec353d4e860223d9fc4 (diff)
downloadop-kernel-dev-a501d8f30e4fcca563e4ee462be00f96e51181d5.zip
op-kernel-dev-a501d8f30e4fcca563e4ee462be00f96e51181d5.tar.gz
powerpc: Fix major revision number for Freescale cores
Some 74xx cores by Freescale are using the configuration field instead of the major revision field for their revision number. This corrects the wrong behaviour for those ppc cores including my one. There is a reference document at Freecale. It describes the PVR register. This is based on that pdf. You can find the document at: http://www.freescale.com/files/archives/doc/support_info/PPCPVR.pdf Signed-off-by: Martin Langer <martin-langer@gmx.de> Signed-off-by: Paul Mackerras <paulus@samba.org>
-rw-r--r--arch/powerpc/kernel/setup-common.c17
1 files changed, 15 insertions, 2 deletions
diff --git a/arch/powerpc/kernel/setup-common.c b/arch/powerpc/kernel/setup-common.c
index 9cc5a52..5ec56ff 100644
--- a/arch/powerpc/kernel/setup-common.c
+++ b/arch/powerpc/kernel/setup-common.c
@@ -254,8 +254,21 @@ static int show_cpuinfo(struct seq_file *m, void *v)
/* If we are a Freescale core do a simple check so
* we dont have to keep adding cases in the future */
if (PVR_VER(pvr) & 0x8000) {
- maj = PVR_MAJ(pvr);
- min = PVR_MIN(pvr);
+ switch (PVR_VER(pvr)) {
+ case 0x8000: /* 7441/7450/7451, Voyager */
+ case 0x8001: /* 7445/7455, Apollo 6 */
+ case 0x8002: /* 7447/7457, Apollo 7 */
+ case 0x8003: /* 7447A, Apollo 7 PM */
+ case 0x8004: /* 7448, Apollo 8 */
+ case 0x800c: /* 7410, Nitro */
+ maj = ((pvr >> 8) & 0xF);
+ min = PVR_MIN(pvr);
+ break;
+ default: /* e500/book-e */
+ maj = PVR_MAJ(pvr);
+ min = PVR_MIN(pvr);
+ break;
+ }
} else {
switch (PVR_VER(pvr)) {
case 0x0020: /* 403 family */
OpenPOWER on IntegriCloud