Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/mips/mips - Make sure ASID PARANOIADIAG work with M...



details:   https://anonhg.NetBSD.org/src/rev/44a629fe4d74
branches:  trunk
changeset: 473134:44a629fe4d74
user:      nisimura <nisimura%NetBSD.org@localhost>
date:      Fri May 21 06:19:55 1999 +0000

description:
- Make sure ASID PARANOIADIAG work with MIPS3.

diffstat:

 sys/arch/mips/mips/pmap.c |  10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diffs (45 lines):

diff -r e230f526a82e -r 44a629fe4d74 sys/arch/mips/mips/pmap.c
--- a/sys/arch/mips/mips/pmap.c Fri May 21 06:01:14 1999 +0000
+++ b/sys/arch/mips/mips/pmap.c Fri May 21 06:19:55 1999 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: pmap.c,v 1.63 1999/05/21 05:28:31 nisimura Exp $       */
+/*     $NetBSD: pmap.c,v 1.64 1999/05/21 06:19:55 nisimura Exp $       */
 
 /*-
  * Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -78,7 +78,7 @@
 
 #include <sys/cdefs.h>
 
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.63 1999/05/21 05:28:31 nisimura Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.64 1999/05/21 06:19:55 nisimura Exp $");
 
 /*
  *     Manages physical address maps.
@@ -749,7 +749,7 @@
                unsigned asid;
 
                __asm __volatile("mfc0 %0,$10; nop" : "=r"(asid));
-               asid = (asid & 0xfc0) >> 6;
+               asid = (CPUISMIPS3) ? (asid & 0xff) : (asid & 0xfc0) >> 6;
                if (asid != pmap->pm_asid) {
                        panic("inconsistency for active TLB flush: %d <-> %d",
                                asid, pmap->pm_asid);
@@ -931,7 +931,7 @@
                unsigned asid;
 
                __asm __volatile("mfc0 %0,$10; nop" : "=r"(asid));
-               asid = (asid & 0xfc0) >> 6;
+               asid = (CPUISMIPS3) ? (asid & 0xff) : (asid & 0xfc0) >> 6;
                if (asid != pmap->pm_asid) {
                        panic("inconsistency for active TLB update: %d <-> %d",
                                asid, pmap->pm_asid);
@@ -1296,7 +1296,7 @@
                unsigned asid;
 
                __asm __volatile("mfc0 %0,$10; nop" : "=r"(asid));
-               asid = (asid & 0xfc0) >> 6;
+               asid = (CPUISMIPS3) ? (asid & 0xff) : (asid & 0xfc0) >> 6;
                if (asid != pmap->pm_asid) {
                        panic("inconsistency for active TLB update: %d <-> %d",
                                asid, pmap->pm_asid);



Home | Main Index | Thread Index | Old Index