Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/usermode/usermode Make pmap.c not so chatty unless ...
details: https://anonhg.NetBSD.org/src/rev/41d46bfbea3a
branches: trunk
changeset: 769419:41d46bfbea3a
user: reinoud <reinoud%NetBSD.org@localhost>
date: Fri Sep 09 12:41:12 2011 +0000
description:
Make pmap.c not so chatty unless we've enabled debug and verbose
diffstat:
sys/arch/usermode/usermode/pmap.c | 19 +++++++++++--------
1 files changed, 11 insertions(+), 8 deletions(-)
diffs (47 lines):
diff -r a3f7eb3b9beb -r 41d46bfbea3a sys/arch/usermode/usermode/pmap.c
--- a/sys/arch/usermode/usermode/pmap.c Fri Sep 09 12:28:05 2011 +0000
+++ b/sys/arch/usermode/usermode/pmap.c Fri Sep 09 12:41:12 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pmap.c,v 1.58 2011/09/09 12:28:05 reinoud Exp $ */
+/* $NetBSD: pmap.c,v 1.59 2011/09/09 12:41:12 reinoud Exp $ */
/*-
* Copyright (c) 2011 Reinoud Zandijk <reinoud%NetBSD.org@localhost>
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.58 2011/09/09 12:28:05 reinoud Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.59 2011/09/09 12:41:12 reinoud Exp $");
#include "opt_memsize.h"
#include "opt_kmempages.h"
@@ -452,10 +452,13 @@
}
}
/* Otherwise, allocate a new entry and link it in after the head. */
- printf("pv_get: multiple mapped page ppn %"PRIdPTR", lpn %"PRIdPTR"\n",
- ppn, lpn);
-assert(ppn < phys_npages);
-assert(ppn >= 0);
+ aprint_debug("pv_get: multiple mapped page ppn %"PRIdPTR", "
+ "lpn %"PRIdPTR"\n", ppn, lpn);
+
+ /* extra sanity */
+ assert(ppn < phys_npages);
+ assert(ppn >= 0);
+
pv = pv_alloc();
if (pv == NULL)
return NULL;
@@ -507,8 +510,8 @@
/* if its not mapped in, we have a TBL fault */
if ((pv->pv_vflags & PV_MAPPEDIN) == 0) {
if (pv->pv_mmap_ppl != THUNK_PROT_NONE) {
- printf("%s: tlb fault page lpn %"PRIiPTR"\n", __func__,
- pv->pv_lpn);
+ aprint_debug("%s: tlb fault page lpn %"PRIiPTR"\n",
+ __func__, pv->pv_lpn);
pmap_page_activate(pv);
return true;
}
Home |
Main Index |
Thread Index |
Old Index