diff options
-rw-r--r-- | arch/x86/mm/pageattr.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/arch/x86/mm/pageattr.c b/arch/x86/mm/pageattr.c index d18c41d752f3..cbe8e9223bee 100644 --- a/arch/x86/mm/pageattr.c +++ b/arch/x86/mm/pageattr.c | |||
@@ -130,8 +130,13 @@ static int split_large_page(pte_t *kpte, unsigned long address) | |||
130 | set_pte(&pbase[i], pfn_pte(addr >> PAGE_SHIFT, ref_prot)); | 130 | set_pte(&pbase[i], pfn_pte(addr >> PAGE_SHIFT, ref_prot)); |
131 | 131 | ||
132 | /* | 132 | /* |
133 | * Install the new, split up pagetable: | 133 | * Install the new, split up pagetable. Important detail here: |
134 | * | ||
135 | * On Intel the NX bit of all levels must be cleared to make a | ||
136 | * page executable. See section 4.13.2 of Intel 64 and IA-32 | ||
137 | * Architectures Software Developer's Manual). | ||
134 | */ | 138 | */ |
139 | ref_prot = pte_pgprot(pte_mkexec(pte_clrhuge(*kpte))); | ||
135 | __set_pmd_pte(kpte, address, mk_pte(base, ref_prot)); | 140 | __set_pmd_pte(kpte, address, mk_pte(base, ref_prot)); |
136 | base = NULL; | 141 | base = NULL; |
137 | 142 | ||