Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. =================================================================== RCS file: /ftp/cvs/cvsroot/src/sys/arch/sun3/sun3/pmap.c,v rcsdiff: /ftp/cvs/cvsroot/src/sys/arch/sun3/sun3/pmap.c,v: warning: Unknown phrases like `commitid ...;' are present. retrieving revision 1.155 retrieving revision 1.155.20.2 diff -u -p -r1.155 -r1.155.20.2 --- src/sys/arch/sun3/sun3/pmap.c 2007/10/17 19:57:46 1.155 +++ src/sys/arch/sun3/sun3/pmap.c 2009/05/04 08:12:01 1.155.20.2 @@ -1,4 +1,4 @@ -/* $NetBSD: pmap.c,v 1.155 2007/10/17 19:57:46 garbled Exp $ */ +/* $NetBSD: pmap.c,v 1.155.20.2 2009/05/04 08:12:01 yamt Exp $ */ /*- * Copyright (c) 1996 The NetBSD Foundation, Inc. @@ -15,13 +15,6 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - * must display the following acknowledgement: - * This product includes software developed by the NetBSD - * Foundation, Inc. and its contributors. - * 4. Neither the name of The NetBSD Foundation nor the names of its - * contributors may be used to endorse or promote products derived - * from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED @@ -87,7 +80,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.155 2007/10/17 19:57:46 garbled Exp $"); +__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.155.20.2 2009/05/04 08:12:01 yamt Exp $"); #include "opt_ddb.h" #include "opt_pmap_debug.h" @@ -233,8 +226,9 @@ vaddr_t tmp_vpages[2] = { int tmp_vpages_inuse; static int pmap_version = 1; -struct pmap kernel_pmap_store; -#define kernel_pmap (&kernel_pmap_store) +static struct pmap kernel_pmap_store; +struct pmap *const kernel_pmap_ptr = &kernel_pmap_store; +#define kernel_pmap (kernel_pmap_ptr) static u_char kernel_segmap[NSEGMAP]; /* memory pool for pmap structures */ @@ -416,7 +410,7 @@ void _pmap_switch(pmap_t); #ifdef PMAP_DEBUG void pmap_print(pmap_t); -void pv_print(struct vm_page *); +void pv_print(paddr_t); void pmeg_print(pmeg_t); static void pmeg_verify_empty(vaddr_t); #endif /* PMAP_DEBUG */ @@ -1974,7 +1968,7 @@ pmap_reference(pmap_t pmap) * insert this page into the given map NOW. */ int -pmap_enter(pmap_t pmap, vaddr_t va, paddr_t pa, vm_prot_t prot, int flags) +pmap_enter(pmap_t pmap, vaddr_t va, paddr_t pa, vm_prot_t prot, u_int flags) { int new_pte, s; bool wired = (flags & PMAP_WIRED) != 0; @@ -2438,8 +2432,8 @@ pmap_kenter_pa(vaddr_t va, paddr_t pa, v } #ifdef PMAP_DEBUG if ((pmap_debug & PMD_SETPTE) || (va == pmap_db_watchva)) { - printf("pmap: set_pte pmap=%p va=0x%lx old=0x%x new=0x%x " - "(ek)\n", pmap, va, old_pte, new_pte); + printf("pmap: set_pte pmap=%p va=0x%lx new=0x%x " + "(ek)\n", pmap, va, new_pte); } #endif /* cache flush done above */ @@ -2929,7 +2923,7 @@ pmap_page_protect(struct vm_page *pg, vm s = splvm(); #ifdef PMAP_DEBUG if (pmap_debug & PMD_PROTECT) - printf("pmap_page_protect(0x%lx, 0x%lx)\n", pa, prot); + printf("pmap_page_protect(0x%lx, 0x%x)\n", pa, prot); #endif switch (prot) { case VM_PROT_ALL: @@ -3801,7 +3795,7 @@ pmeg_print(pmeg_t pmegp) { db_printf("link_next=%p link_prev=%p\n", TAILQ_NEXT(pmegp, pmeg_link), - TAILQ_PREV(pmegp, pmeg_link)); + TAILQ_PREV(pmegp, pmeg_tailq, pmeg_link)); db_printf("index=0x%x owner=%p own_vers=0x%x\n", pmegp->pmeg_index, pmegp->pmeg_owner, pmegp->pmeg_version); db_printf("va=0x%lx wired=0x%x reserved=0x%x vpgs=0x%x qstate=0x%x\n",