[Midnightbsd-cvs] src [7797] trunk/sys/amd64/amd64/pmap.c: enable new instructions for reading and writing bases.
laffer1 at midnightbsd.org
laffer1 at midnightbsd.org
Mon Sep 5 15:22:48 EDT 2016
Revision: 7797
http://svnweb.midnightbsd.org/src/?rev=7797
Author: laffer1
Date: 2016-09-05 15:22:47 -0400 (Mon, 05 Sep 2016)
Log Message:
-----------
enable new instructions for reading and writing bases. This was already partially applied
Modified Paths:
--------------
trunk/sys/amd64/amd64/pmap.c
Modified: trunk/sys/amd64/amd64/pmap.c
===================================================================
--- trunk/sys/amd64/amd64/pmap.c 2016-09-05 17:05:41 UTC (rev 7796)
+++ trunk/sys/amd64/amd64/pmap.c 2016-09-05 19:22:47 UTC (rev 7797)
@@ -584,6 +584,8 @@
/* XXX do %cr0 as well */
load_cr4(rcr4() | CR4_PGE | CR4_PSE);
load_cr3(KPML4phys);
+ if (cpu_stdext_feature & CPUID_STDEXT_SMEP)
+ load_cr4(rcr4() | CR4_SMEP);
/*
* Initialize the kernel pmap (which is statically allocated).
More information about the Midnightbsd-cvs
mailing list