Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/sparc64/sparc64 remove dead code and other minor cl...
details: https://anonhg.NetBSD.org/src/rev/c82b89ab3688
branches: trunk
changeset: 571600:c82b89ab3688
user: chs <chs%NetBSD.org@localhost>
date: Fri Dec 03 01:54:14 2004 +0000
description:
remove dead code and other minor cleaning.
diffstat:
sys/arch/sparc64/sparc64/pmap.c | 39 ++++++---------------------------------
1 files changed, 6 insertions(+), 33 deletions(-)
diffs (87 lines):
diff -r c10cc017a0ea -r c82b89ab3688 sys/arch/sparc64/sparc64/pmap.c
--- a/sys/arch/sparc64/sparc64/pmap.c Thu Dec 02 21:46:52 2004 +0000
+++ b/sys/arch/sparc64/sparc64/pmap.c Fri Dec 03 01:54:14 2004 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pmap.c,v 1.158 2004/12/01 09:48:03 martin Exp $ */
+/* $NetBSD: pmap.c,v 1.159 2004/12/03 01:54:14 chs Exp $ */
/*
*
* Copyright (C) 1996-1999 Eduardo Horvath.
@@ -26,7 +26,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.158 2004/12/01 09:48:03 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.159 2004/12/03 01:54:14 chs Exp $");
#undef NO_VCACHE /* Don't forget the locked TLB in dostart */
#define HWREF
@@ -261,30 +261,7 @@
#define DPRINTF(n, f)
#endif
-#ifdef NOTDEF_DEBUG
-void pv_check __P((void));
-void
-pv_check()
-{
- int i, j, s;
-
- s = splhigh();
- for (i = 0; i < physmem; i++) {
- struct pv_entry *pv;
- for (pv = &pv_table[i]; pv; pv = pv->pv_next) {
- if (pv->pv_pmap &&
- !(pseg_get(pv->pv_pmap, pv->pv_va) & TLB_V)) {
- printf("pv_check(): unreferenced pv=%p pa=%p va=%p pm=%p\n",
- i, ptoa(first_phys_addr+i), pv->pv_va, pv->pv_pmap);
- Debugger();
- }
- }
- }
- splx(s);
-}
-#else
#define pv_check()
-#endif
/*
*
@@ -2916,7 +2893,7 @@
firstpv = pv;
- /* First remove the entire list of continuation pv's*/
+ /* First remove the entire list of continuation pv's */
for (npv = pv->pv_next; npv; npv = pv->pv_next) {
pmap = npv->pv_pmap;
va = npv->pv_va & PV_VAMASK;
@@ -2999,9 +2976,9 @@
/* dump the first pv */
if (npv) {
/* First save mod/ref bits */
+ pv->pv_pmap = npv->pv_pmap;
pv->pv_va |= npv->pv_va & PV_MASK;
pv->pv_next = npv->pv_next;
- pv->pv_pmap = npv->pv_pmap;
pool_put(&pmap_pv_pool, npv);
} else {
pv->pv_pmap = NULL;
@@ -3298,15 +3275,11 @@
pvh->pv_next = NULL;
pvh->pv_va &= (PV_REF|PV_MOD);
}
-#ifdef DEBUG
- remove_stats.pvfirst++;
-#endif
+ REMOVE_STAT(pvfirst);
} else {
for (pv = pvh, npv = pvh->pv_next; npv;
pv = npv, npv = npv->pv_next) {
-#ifdef DEBUG
- remove_stats.pvsearch++;
-#endif
+ REMOVE_STAT(pvsearch);
if (pmap == npv->pv_pmap && PV_MATCH(npv, va))
break;
}
Home |
Main Index |
Thread Index |
Old Index