aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/arm/include/asm/pgtable.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/arm/include/asm/pgtable.h b/arch/arm/include/asm/pgtable.h
index 9c82f988c0e3..c09474942f3e 100644
--- a/arch/arm/include/asm/pgtable.h
+++ b/arch/arm/include/asm/pgtable.h
@@ -240,7 +240,8 @@ static inline pte_t pte_mkspecial(pte_t pte) { return pte; }
240 240
241static inline pte_t pte_modify(pte_t pte, pgprot_t newprot) 241static inline pte_t pte_modify(pte_t pte, pgprot_t newprot)
242{ 242{
243 const pteval_t mask = L_PTE_XN | L_PTE_RDONLY | L_PTE_USER | L_PTE_NONE; 243 const pteval_t mask = L_PTE_XN | L_PTE_RDONLY | L_PTE_USER |
244 L_PTE_NONE | L_PTE_VALID;
244 pte_val(pte) = (pte_val(pte) & ~mask) | (pgprot_val(newprot) & mask); 245 pte_val(pte) = (pte_val(pte) & ~mask) | (pgprot_val(newprot) & mask);
245 return pte; 246 return pte;
246} 247}