summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2001-12-16 23:06:05 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2001-12-16 23:06:05 +0000
commit5bf95247910fc5b8f121c4362e91ebdc89cbbedc (patch)
tree6536d2864f7eff4803c0de3f701988c2baa0718b /sys
parent99eab7317349164dbef35bb0724dc60d6d33396c (diff)
Delay a cache invalidation in a 68060-only loop.
Also, better tests for validity bits in STEs.
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/m68k/m68k/pmap_motorola.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/sys/arch/m68k/m68k/pmap_motorola.c b/sys/arch/m68k/m68k/pmap_motorola.c
index a30e82688f5..06058c3d402 100644
--- a/sys/arch/m68k/m68k/pmap_motorola.c
+++ b/sys/arch/m68k/m68k/pmap_motorola.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pmap_motorola.c,v 1.12 2001/12/16 21:48:48 miod Exp $ */
+/* $OpenBSD: pmap_motorola.c,v 1.13 2001/12/16 23:06:04 miod Exp $ */
/*
* Copyright (c) 1999 The NetBSD Foundation, Inc.
@@ -529,10 +529,13 @@ pmap_init()
pte = pmap_pte(pmap_kernel(), addr2);
*pte = (*pte | PG_CI) & ~PG_CCB;
TBIS(addr2);
- DCIS();
}
#endif
} while (addr != addr2);
+#ifdef M68060
+ if (mmutype == MMU_68060)
+ DCIS();
+#endif
PMAP_DPRINTF(PDB_INIT, ("pmap_init: KPT: %ld pages from %lx to %lx\n",
atop(s), addr, addr + s));
@@ -1881,11 +1884,11 @@ ok:
if (pmapdebug & (PDB_PTPAGE|PDB_COLLECT))
pmapdebug = opmapdebug;
- if (*ste != SG_NV)
+ if (!(*ste & SG_V))
printf("collect: kernel STE at %p still valid (%x)\n",
ste, *ste);
ste = &Sysptmap[ste - pmap_ste(pmap_kernel(), 0)];
- if (*ste != SG_NV)
+ if (!(*ste & SG_V))
printf("collect: kernel PTmap at %p still valid (%x)\n",
ste, *ste);
#endif
@@ -2152,7 +2155,7 @@ pmap_mapmulti(pmap, va)
#endif
bste = pmap_ste(pmap, HPMMBASEADDR(va));
ste = pmap_ste(pmap, va);
- if (*ste == SG_NV && (*bste & SG_V)) {
+ if (!(*ste & SG_V) && (*bste & SG_V)) {
*ste = *bste;
TBIAU();
return (0);