Module Name: src
Committed By: maxv
Date: Sat Jan 20 08:45:28 UTC 2018
Modified Files:
src/sys/arch/x86/x86: pmap.c
Log Message:
Mmh, restore PG_G on the direct map, we still want that in the non-SVS
case.
To generate a diff of this commit:
cvs rdiff -u -r1.278 -r1.279 src/sys/arch/x86/x86/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/x86/x86/pmap.c
diff -u src/sys/arch/x86/x86/pmap.c:1.278 src/sys/arch/x86/x86/pmap.c:1.279
--- src/sys/arch/x86/x86/pmap.c:1.278 Sun Jan 7 16:10:16 2018
+++ src/sys/arch/x86/x86/pmap.c Sat Jan 20 08:45:28 2018
@@ -1,4 +1,4 @@
-/* $NetBSD: pmap.c,v 1.278 2018/01/07 16:10:16 maxv Exp $ */
+/* $NetBSD: pmap.c,v 1.279 2018/01/20 08:45:28 maxv Exp $ */
/*
* Copyright (c) 2008, 2010, 2016, 2017 The NetBSD Foundation, Inc.
@@ -170,7 +170,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.278 2018/01/07 16:10:16 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.279 2018/01/20 08:45:28 maxv Exp $");
#include "opt_user_ldt.h"
#include "opt_lockdebug.h"
@@ -1635,9 +1635,11 @@ pmap_init_directmap(struct pmap *kpm)
pa = (paddr_t)(i * NBPD_L2);
if (spahole <= pa && pa < epahole) {
- L2_BASE[L2e_idx+i] = pa | holepteflags | PG_U | PG_PS;
+ L2_BASE[L2e_idx+i] = pa | holepteflags | PG_U |
+ PG_PS | pmap_pg_g;
} else {
- L2_BASE[L2e_idx+i] = pa | pteflags | PG_U | PG_PS;
+ L2_BASE[L2e_idx+i] = pa | pteflags | PG_U |
+ PG_PS | pmap_pg_g;
}
}