aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-powerpc/pgtable-ppc64.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-powerpc/pgtable-ppc64.h')
-rw-r--r--include/asm-powerpc/pgtable-ppc64.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/asm-powerpc/pgtable-ppc64.h b/include/asm-powerpc/pgtable-ppc64.h
index 2e48be841cc9..b2754d46be44 100644
--- a/include/asm-powerpc/pgtable-ppc64.h
+++ b/include/asm-powerpc/pgtable-ppc64.h
@@ -312,6 +312,15 @@ static inline void ptep_set_wrprotect(struct mm_struct *mm, unsigned long addr,
312 return; 312 return;
313 old = pte_update(mm, addr, ptep, _PAGE_RW, 0); 313 old = pte_update(mm, addr, ptep, _PAGE_RW, 0);
314} 314}
315static inline void huge_ptep_set_wrprotect(struct mm_struct *mm,
316 unsigned long addr, pte_t *ptep)
317{
318 unsigned long old;
319
320 if ((pte_val(*ptep) & _PAGE_RW) == 0)
321 return;
322 old = pte_update(mm, addr, ptep, _PAGE_RW, 1);
323}
315 324
316/* 325/*
317 * We currently remove entries from the hashtable regardless of whether 326 * We currently remove entries from the hashtable regardless of whether