summaryrefslogtreecommitdiff
path: root/sys/arch/m88k
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2007-11-24 11:13:57 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2007-11-24 11:13:57 +0000
commit3d988f7694a760da57147f55faa77d3ef494fe18 (patch)
tree6360cbf1faeedc9e7552d4b8d6f0eae42a9545e6 /sys/arch/m88k
parentfc8f5d963cbfbce1bd21dcd873cad6b8ddb17815 (diff)
Do not mark any page as global on monoprocessor kernels if running on a
88110, to avoid snooping notification bus cycles, as recommended by the manual.
Diffstat (limited to 'sys/arch/m88k')
-rw-r--r--sys/arch/m88k/m88k/pmap.c10
-rw-r--r--sys/arch/m88k/m88k/vm_machdep.c10
2 files changed, 17 insertions, 3 deletions
diff --git a/sys/arch/m88k/m88k/pmap.c b/sys/arch/m88k/m88k/pmap.c
index 4630714243c..9b2fd26d6f2 100644
--- a/sys/arch/m88k/m88k/pmap.c
+++ b/sys/arch/m88k/m88k/pmap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pmap.c,v 1.39 2007/11/22 05:47:46 miod Exp $ */
+/* $OpenBSD: pmap.c,v 1.40 2007/11/24 11:13:56 miod Exp $ */
/*
* Copyright (c) 2001-2004, Miodrag Vallat
* Copyright (c) 1998-2001 Steve Murphree, Jr.
@@ -714,6 +714,10 @@ pmap_bootstrap(vaddr_t load_start)
kernel_pmap->pm_apr = (atop((paddr_t)kmap) << PG_SHIFT) |
CACHE_GLOBAL | CACHE_WT | APR_V;
+#if !defined(MULTIPROCESSOR) && defined(M88110)
+ if (CPU_IS88110)
+ kernel_pmap->pm_apr &= ~CACHE_GLOBAL;
+#endif
pmap_bootstrap_cpu(cpu_number());
}
@@ -854,6 +858,10 @@ pmap_create(void)
(paddr_t *)&stpa) == FALSE)
panic("pmap_create: pmap_extract failed!");
pmap->pm_apr = (atop(stpa) << PG_SHIFT) | CACHE_GLOBAL | APR_V;
+#if !defined(MULTIPROCESSOR) && defined(M88110)
+ if (CPU_IS88110)
+ pmap->pm_apr &= ~CACHE_GLOBAL;
+#endif
#ifdef PMAPDEBUG
if (pmap_debug & CD_CREAT)
diff --git a/sys/arch/m88k/m88k/vm_machdep.c b/sys/arch/m88k/m88k/vm_machdep.c
index 189067e730e..27f24bebf32 100644
--- a/sys/arch/m88k/m88k/vm_machdep.c
+++ b/sys/arch/m88k/m88k/vm_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: vm_machdep.c,v 1.19 2007/11/22 05:46:38 miod Exp $ */
+/* $OpenBSD: vm_machdep.c,v 1.20 2007/11/24 11:13:56 miod Exp $ */
/*
* Copyright (c) 1998 Steve Murphree, Jr.
@@ -211,8 +211,14 @@ vmapbuf(bp, len)
addr += PAGE_SIZE;
kva += PAGE_SIZE;
}
+
/* make sure snooping will be possible... */
- pmap_cache_ctrl(pmap_kernel(), ova, ova + len, CACHE_GLOBAL);
+#if !defined(MULTIPROCESSOR) && defined(M88110)
+ if (CPU_IS88110)
+ pmap_cache_ctrl(pmap_kernel(), ova, ova + len, 0);
+ else
+#endif
+ pmap_cache_ctrl(pmap_kernel(), ova, ova + len, CACHE_GLOBAL);
pmap_update(pmap_kernel());
}