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 Fix LOCKDEBUG spin lock held panic on MIP...
details: https://anonhg.NetBSD.org/src/rev/0fe7fd0ffb9a
branches: trunk
changeset: 762692:0fe7fd0ffb9a
user: tsutsui <tsutsui%NetBSD.org@localhost>
date: Fri Feb 25 19:32:51 2011 +0000
description:
Fix LOCKDEBUG spin lock held panic on MIPS_CACHE_VIRTUAL_ALIAS CPUs.
Now cobalt boots multiuser, but many programs complains
"clntudp_create: RPC: Program not registered"
as well as R5000 sgimips O2. Smells virtual cache alias issue around pool...
diffstat:
sys/arch/mips/mips/pmap.c | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
diffs (49 lines):
diff -r c6f9e2ef1932 -r 0fe7fd0ffb9a sys/arch/mips/mips/pmap.c
--- a/sys/arch/mips/mips/pmap.c Fri Feb 25 19:27:05 2011 +0000
+++ b/sys/arch/mips/mips/pmap.c Fri Feb 25 19:32:51 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pmap.c,v 1.195 2011/02/20 07:45:48 matt Exp $ */
+/* $NetBSD: pmap.c,v 1.196 2011/02/25 19:32:51 tsutsui Exp $ */
/*-
* Copyright (c) 1998, 2001 The NetBSD Foundation, Inc.
@@ -67,7 +67,7 @@
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.195 2011/02/20 07:45:48 matt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.196 2011/02/25 19:32:51 tsutsui Exp $");
/*
* Manages physical address maps.
@@ -2234,7 +2234,7 @@
pmap, va);
#endif
if (__predict_true(apv == NULL)) {
-#ifdef MULTIPROCESSOR
+#if defined(MULTIPROCESSOR) || !defined(_LP64) || defined(PMAP_POOLPAGE_DEBUG)
/*
* To allocate a PV, we have to release the PVLIST lock
* so get the page generation. We allocate the PV, and
@@ -2245,6 +2245,7 @@
apv = (pv_entry_t)pmap_pv_alloc();
if (apv == NULL)
panic("pmap_enter_pv: pmap_pv_alloc() failed");
+#if defined(MULTIPROCESSOR) || !defined(_LP64) || defined(PMAP_POOLPAGE_DEBUG)
#ifdef MULTIPROCESSOR
/*
* If the generation has changed, then someone else
@@ -2252,10 +2253,13 @@
* start over.
*/
uint16_t oldgen = gen;
+#endif
gen = PG_MD_PVLIST_LOCK(md, true);
+#ifdef MULTIPROCESSOR
if (gen != oldgen)
goto again;
#endif
+#endif
}
npv = apv;
apv = NULL;
Home |
Main Index |
Thread Index |
Old Index