Module Name:    src
Committed By:   riastradh
Date:           Sun Oct 30 14:08:09 UTC 2022

Modified Files:
        src/sys/arch/aarch64/aarch64: pmap.c

Log Message:
aarch64/pmap: Fix criterion in previous.

Use the pte bit that says whether this is a PMAP_WIRED page, not the
bit that says whether this is a non-global page.

(Forgot to git commit --amend before exporting to CVS, sorry!)


To generate a diff of this commit:
cvs rdiff -u -r1.146 -r1.147 src/sys/arch/aarch64/aarch64/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/aarch64/aarch64/pmap.c
diff -u src/sys/arch/aarch64/aarch64/pmap.c:1.146 src/sys/arch/aarch64/aarch64/pmap.c:1.147
--- src/sys/arch/aarch64/aarch64/pmap.c:1.146	Sun Oct 30 10:26:48 2022
+++ src/sys/arch/aarch64/aarch64/pmap.c	Sun Oct 30 14:08:09 2022
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.c,v 1.146 2022/10/30 10:26:48 riastradh Exp $	*/
+/*	$NetBSD: pmap.c,v 1.147 2022/10/30 14:08:09 riastradh Exp $	*/
 
 /*
  * Copyright (c) 2017 Ryo Shimizu <r...@nerv.org>
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.146 2022/10/30 10:26:48 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.147 2022/10/30 14:08:09 riastradh Exp $");
 
 #include "opt_arm_debug.h"
 #include "opt_cpuoptions.h"
@@ -1426,7 +1426,7 @@ pmap_protect(struct pmap *pm, vaddr_t sv
 			continue;
 		}
 
-		if (pte & LX_BLKPAG_NG) {
+		if ((pte & LX_BLKPAG_OS_WIRED) == 0) {
 			const paddr_t pa = lxpde_pa(pte);
 			struct vm_page *const pg = PHYS_TO_VM_PAGE(pa);
 

Reply via email to