summaryrefslogtreecommitdiff
path: root/sys/arch
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2003-09-29 20:29:05 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2003-09-29 20:29:05 +0000
commit6ee928535e07c49458ffced6c4a9be137341c901 (patch)
treec5339db7bde1503fd1864d1fecee03e1eb91fe41 /sys/arch
parent9da92a8685db6d6599496a78b38f8134c4b360b3 (diff)
Disable cache on page tables unconditionnaly, not only for MVME188: magically
solves the last 187 issues... Although the slowdown is surprisingly small, this is only a temporary measure, there is room for improvement...
Diffstat (limited to 'sys/arch')
-rw-r--r--sys/arch/mvme88k/mvme88k/pmap.c43
1 files changed, 11 insertions, 32 deletions
diff --git a/sys/arch/mvme88k/mvme88k/pmap.c b/sys/arch/mvme88k/mvme88k/pmap.c
index 489e76010f3..b6e710028e8 100644
--- a/sys/arch/mvme88k/mvme88k/pmap.c
+++ b/sys/arch/mvme88k/mvme88k/pmap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pmap.c,v 1.79 2003/09/29 13:05:56 miod Exp $ */
+/* $OpenBSD: pmap.c,v 1.80 2003/09/29 20:29:04 miod Exp $ */
/*
* Copyright (c) 2001, 2002, 2003 Miodrag Vallat
* Copyright (c) 1998-2001 Steve Murphree, Jr.
@@ -615,12 +615,10 @@ pmap_cache_ctrl(pmap_t pmap, vaddr_t s, vaddr_t e, u_int mode)
if ((pmap_con_dbg & (CD_CACHE | CD_NORM)) == (CD_CACHE | CD_NORM)) {
printf("(pmap_cache_ctrl: %x) pmap %x, va %x, mode %x\n", curproc, pmap, s, mode);
}
-#endif /* DEBUG */
-#ifdef DIAGNOSTIC
if (pmap == PMAP_NULL)
panic("pmap_cache_ctrl: pmap is NULL");
-#endif
+#endif /* DEBUG */
PMAP_LOCK(pmap, spl);
@@ -695,8 +693,8 @@ pmap_cache_ctrl(pmap_t pmap, vaddr_t s, vaddr_t e, u_int mode)
* reflect this allocation. This space is mapped in virtual memory
* immediately following the kernel code/data map.
*
- * A pair of virtual pages are reserved for debugging and IO
- * purposes. They are arbitrarily mapped when needed. They are used,
+ * A pair of virtual pages per cpu are reserved for debugging and
+ * IO purposes. They are arbitrarily mapped when needed. They are used,
* for example, by pmap_copy_page and pmap_zero_page.
*
* For m88k, we have to map BUG memory also. This is a read only
@@ -1069,15 +1067,6 @@ pmap_bootstrap(vaddr_t load_start, paddr_t *phys_start, paddr_t *phys_end,
* Initialize the pmap module. It is called by vm_init, to initialize
* any structures that the pmap system needs to map virtual memory.
*
- * Parameters:
- * phys_start physical address of first available page
- * (was last set by pmap_bootstrap)
- * phys_end physical address of last available page
- *
- * Extern/Globals
- * pmap_phys_start
- * pmap_phys_end
- *
* Calls:
* pool_init
*
@@ -1202,15 +1191,10 @@ pmap_create(void)
}
#endif
-#ifdef MVME188
- if (brdtyp == BRD_188) {
- /*
- * memory for page tables should be CACHE DISABLED on MVME188
- */
- pmap_cache_ctrl(kernel_pmap,
- (vaddr_t)segdt, (vaddr_t)segdt + s, CACHE_INH);
- }
-#endif
+ /* memory for page tables should be CACHE DISABLED */
+ pmap_cache_ctrl(kernel_pmap,
+ (vaddr_t)segdt, (vaddr_t)segdt + s, CACHE_INH);
+
/*
* Initialize SDT_ENTRIES.
*/
@@ -1857,14 +1841,9 @@ pmap_expand(pmap_t pmap, vaddr_t v)
if (pmap_extract(kernel_pmap, pdt_vaddr, &pdt_paddr) == FALSE)
panic("pmap_expand: pmap_extract failed");
-#ifdef MVME188
- if (brdtyp == BRD_188) {
- /*
- * the pages for page tables should be CACHE DISABLED on MVME188
- */
- pmap_cache_ctrl(kernel_pmap, pdt_vaddr, pdt_vaddr+PAGE_SIZE, CACHE_INH);
- }
-#endif
+ /* memory for page tables should be CACHE DISABLED */
+ pmap_cache_ctrl(kernel_pmap,
+ pdt_vaddr, pdt_vaddr + PAGE_SIZE, CACHE_INH);
PMAP_LOCK(pmap, spl);