Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/alpha/common fix SGMAP_DEBUG on alpha
details: https://anonhg.NetBSD.org/src/rev/555b124a3e05
branches: trunk
changeset: 757967:555b124a3e05
user: hans <hans%NetBSD.org@localhost>
date: Thu Oct 07 19:39:30 2010 +0000
description:
fix SGMAP_DEBUG on alpha
diffstat:
sys/arch/alpha/common/sgmap_typedep.c | 25 +++++++++++--------------
1 files changed, 11 insertions(+), 14 deletions(-)
diffs (67 lines):
diff -r f4cc96d4badd -r 555b124a3e05 sys/arch/alpha/common/sgmap_typedep.c
--- a/sys/arch/alpha/common/sgmap_typedep.c Thu Oct 07 16:26:37 2010 +0000
+++ b/sys/arch/alpha/common/sgmap_typedep.c Thu Oct 07 19:39:30 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: sgmap_typedep.c,v 1.35 2008/04/28 20:23:11 martin Exp $ */
+/* $NetBSD: sgmap_typedep.c,v 1.36 2010/10/07 19:39:30 hans Exp $ */
/*-
* Copyright (c) 1997, 1998, 2001 The NetBSD Foundation, Inc.
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(1, "$NetBSD: sgmap_typedep.c,v 1.35 2008/04/28 20:23:11 martin Exp $");
+__KERNEL_RCSID(1, "$NetBSD: sgmap_typedep.c,v 1.36 2010/10/07 19:39:30 hans Exp $");
#include "opt_ddb.h"
@@ -121,9 +121,12 @@
}
}
-#if 0
- printf("len 0x%lx -> 0x%lx, boundary 0x%lx -> 0x%lx -> ",
- (endva - va), sgvalen, map->_dm_boundary, boundary);
+#ifdef SGMAP_DEBUG
+ if (__C(SGMAP_TYPE,_debug)) {
+ printf("sgmap_load: va:endva = 0x%lx:0x%lx\n", va, endva);
+ printf("sgmap_load: sgvalen = 0x%lx, boundary = 0x%lx\n",
+ sgvalen, boundary);
+ }
#endif
s = splvm();
@@ -133,10 +136,6 @@
if (error)
return (error);
-#if 0
- printf("error %d sgva 0x%lx\n", error, sgva);
-#endif
-
pteidx = sgva >> SGMAP_ADDR_PTEIDX_SHIFT;
pte = &page_table[pteidx * SGMAP_PTE_SPACING];
@@ -153,8 +152,8 @@
#ifdef SGMAP_DEBUG
if (__C(SGMAP_TYPE,_debug))
- printf("sgmap_load: wbase = 0x%lx, vpage = 0x%x, "
- "DMA addr = 0x%lx\n", sgmap->aps_wbase, sgva,
+ printf("sgmap_load: wbase = 0x%lx, vpage = 0x%lx, "
+ "DMA addr = 0x%lx\n", sgmap->aps_wbase, (uint64_t)sgva,
map->dm_segs[seg].ds_addr);
#endif
@@ -181,9 +180,7 @@
#ifdef SGMAP_DEBUG
if (__C(SGMAP_TYPE,_debug)) {
printf("sgmap_load: spill page, pte = %p, "
- "*pte = 0x%lx\n", pte, *pte);
- printf("sgmap_load: pte count = %d\n",
- map->_dm_ptecnt);
+ "*pte = 0x%lx\n", pte, (uint64_t)*pte);
}
#endif
}
Home |
Main Index |
Thread Index |
Old Index