Module Name: src Committed By: reinoud Date: Tue Aug 23 10:41:47 UTC 2011
Modified Files: src/sys/arch/usermode/usermode: pmap.c Log Message: Cleanup pv_get() before enabling multiple-mappings To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/sys/arch/usermode/usermode/pmap.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/usermode/usermode/pmap.c diff -u src/sys/arch/usermode/usermode/pmap.c:1.13 src/sys/arch/usermode/usermode/pmap.c:1.14 --- src/sys/arch/usermode/usermode/pmap.c:1.13 Tue Aug 23 00:52:33 2011 +++ src/sys/arch/usermode/usermode/pmap.c Tue Aug 23 10:41:47 2011 @@ -1,4 +1,4 @@ -/* $NetBSD: pmap.c,v 1.13 2011/08/23 00:52:33 jmcneill Exp $ */ +/* $NetBSD: pmap.c,v 1.14 2011/08/23 10:41:47 reinoud Exp $ */ /*- * Copyright (c) 2011 Reinoud Zandijk <rein...@netbsd.org> @@ -27,7 +27,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.13 2011/08/23 00:52:33 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.14 2011/08/23 10:41:47 reinoud Exp $"); #include "opt_uvmhist.h" #include "opt_memsize.h" @@ -357,17 +357,13 @@ /* If the head entry's free use that. */ pv = &pv_table[ppn]; -printf("pmap %p, ppn %d, lpn %d, pv %p\n", pmap, ppn, lpn, pv); if (pv->pv_pmap == NULL) { UVMHIST_LOG(pmaphist, "<-- head (pv=%p)", pv, 0, 0, 0); pmap->pm_stats.resident_count++; return pv; } -printf("pmap = %p, pv->pv_pmap = %p\n", pmap, pv->pv_pmap); /* If this mapping exists already, use that. */ -printf("pv_get: mapping exists\n"); for (pv = pv; pv != NULL; pv = pv->pv_next) { -printf("pv = %p\n", pv); if (pv->pv_pmap == pmap && pv->pv_lpn == lpn) { UVMHIST_LOG(pmaphist, "<-- existing (pv=%p)", pv, 0, 0, 0); @@ -375,7 +371,7 @@ } } /* Otherwise, allocate a new entry and link it in after the head. */ - panic("pv_get: no multiple mappings yet\n"); + panic("pv_get: multiple mapped page ppn %d, lpn %d\n", ppn, lpn); #if 0 pv = pv_alloc(); if (pv == NULL)