Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 15 Jul 2014 17:16:06 +0000 (UTC)
From:      Alan Cox <alc@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r268693 - head/sys/arm/arm
Message-ID:  <201407151716.s6FHG6um090152@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: alc
Date: Tue Jul 15 17:16:06 2014
New Revision: 268693
URL: http://svnweb.freebsd.org/changeset/base/268693

Log:
  Actually set the "no execute" bit on 1 MB page mappings in pmap_protect().
  Previously, the "no execute" bit was being set directly in the PTE, instead
  of the local variable in which the new PTE value is being constructed.  So,
  when the local variable was finally assigned to the PTE, the "no execute"
  bit setting was lost.

Modified:
  head/sys/arm/arm/pmap-v6.c

Modified: head/sys/arm/arm/pmap-v6.c
==============================================================================
--- head/sys/arm/arm/pmap-v6.c	Tue Jul 15 17:14:53 2014	(r268692)
+++ head/sys/arm/arm/pmap-v6.c	Tue Jul 15 17:16:06 2014	(r268693)
@@ -2846,7 +2846,7 @@ pmap_protect(pmap_t pmap, vm_offset_t sv
 			    eva >= next_bucket) {
 				l1pd &= ~(L1_S_PROT_MASK | L1_S_XN);
 				if (!(prot & VM_PROT_EXECUTE))
-					*pl1pd |= L1_S_XN;
+					l1pd |= L1_S_XN;
 				/*
 				 * At this point we are always setting
 				 * write-protect bit.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201407151716.s6FHG6um090152>