Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/xen/x86 Map the PTE space as non-executable on PAE....
details: https://anonhg.NetBSD.org/src/rev/e997e426f596
branches: trunk
changeset: 348652:e997e426f596
user: maxv <maxv%NetBSD.org@localhost>
date: Tue Nov 01 12:16:10 2016 +0000
description:
Map the PTE space as non-executable on PAE. The same is already done on
amd64.
diffstat:
sys/arch/xen/x86/x86_xpmap.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diffs (28 lines):
diff -r 1385c841a30a -r e997e426f596 sys/arch/xen/x86/x86_xpmap.c
--- a/sys/arch/xen/x86/x86_xpmap.c Tue Nov 01 12:00:21 2016 +0000
+++ b/sys/arch/xen/x86/x86_xpmap.c Tue Nov 01 12:16:10 2016 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: x86_xpmap.c,v 1.62 2016/11/01 12:00:21 maxv Exp $ */
+/* $NetBSD: x86_xpmap.c,v 1.63 2016/11/01 12:16:10 maxv Exp $ */
/*
* Copyright (c) 2006 Mathieu Ropert <mro%adviseo.fr@localhost>
@@ -69,7 +69,7 @@
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: x86_xpmap.c,v 1.62 2016/11/01 12:00:21 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: x86_xpmap.c,v 1.63 2016/11/01 12:16:10 maxv Exp $");
#include "opt_xen.h"
#include "opt_ddb.h"
@@ -994,7 +994,8 @@
*/
addr = (u_long)pde - KERNBASE;
for (i = 0; i < 3; i++, addr += PAGE_SIZE) {
- pde[PDIR_SLOT_PTE + i] = xpmap_ptom_masked(addr) | PG_k | PG_V;
+ pde[PDIR_SLOT_PTE + i] = xpmap_ptom_masked(addr) | PG_k | PG_V |
+ pg_nx;
__PRINTK(("pde[%d] va %#" PRIxVADDR " pa %#" PRIxPADDR
" entry %#" PRIxPADDR "\n",
(int)(PDIR_SLOT_PTE + i), pde + PAGE_SIZE * i,
Home |
Main Index |
Thread Index |
Old Index