Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/x68k/x68k fix pmap_changebit() to look for the bit ...



details:   https://anonhg.NetBSD.org/src/rev/da0202b1f3b0
branches:  trunk
changeset: 516138:da0202b1f3b0
user:      chs <chs%NetBSD.org@localhost>
date:      Wed Oct 17 06:28:16 2001 +0000

description:
fix pmap_changebit() to look for the bit in the page attrs
in addition to any PTEs.

diffstat:

 sys/arch/x68k/x68k/pmap.c |  9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diffs (34 lines):

diff -r 02c3637aae2a -r da0202b1f3b0 sys/arch/x68k/x68k/pmap.c
--- a/sys/arch/x68k/x68k/pmap.c Wed Oct 17 05:39:04 2001 +0000
+++ b/sys/arch/x68k/x68k/pmap.c Wed Oct 17 06:28:16 2001 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: pmap.c,v 1.67 2001/09/10 21:19:30 chris Exp $  */
+/*     $NetBSD: pmap.c,v 1.68 2001/10/17 06:28:16 chs Exp $    */
 
 /*-
  * Copyright (c) 1999 The NetBSD Foundation, Inc.
@@ -2485,11 +2485,12 @@
        struct pv_entry *pv;
        pt_entry_t *pte, npte;
        vaddr_t va;
+       char *attrp;
        int s;
 #if defined(M68K_MMU_HP) || defined(M68040) || defined(M68060)
        boolean_t firstpage = TRUE;
 #endif
-       boolean_t r = FALSE;
+       boolean_t r;
 
        PMAP_DPRINTF(PDB_BITS,
            ("pmap_changebit(%lx, %x, %x)\n", pa, set, mask));
@@ -2501,7 +2502,9 @@
         * Clear saved attributes (modify, reference)
         */
 
-       *pa_to_attribute(pa) &= mask;
+       attrp = pa_to_attribute(pa);
+       r = *attrp & ~mask;
+       *attrp &= mask;
 
        /*
         * Loop over all current mappings setting/clearing as appropos



Home | Main Index | Thread Index | Old Index