aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-ia64/pgtable.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-ia64/pgtable.h')
-rw-r--r--include/asm-ia64/pgtable.h25
1 files changed, 16 insertions, 9 deletions
diff --git a/include/asm-ia64/pgtable.h b/include/asm-ia64/pgtable.h
index 670b706411b8..6580f31b3135 100644
--- a/include/asm-ia64/pgtable.h
+++ b/include/asm-ia64/pgtable.h
@@ -533,16 +533,23 @@ extern void lazy_mmu_prot_update (pte_t pte);
533 * daccess_bit in ivt.S). 533 * daccess_bit in ivt.S).
534 */ 534 */
535#ifdef CONFIG_SMP 535#ifdef CONFIG_SMP
536# define ptep_set_access_flags(__vma, __addr, __ptep, __entry, __safely_writable) \ 536# define ptep_set_access_flags(__vma, __addr, __ptep, __entry, __safely_writable) \
537do { \ 537({ \
538 if (__safely_writable) { \ 538 int __changed = !pte_same(*(__ptep), __entry); \
539 set_pte(__ptep, __entry); \ 539 if (__changed && __safely_writable) { \
540 flush_tlb_page(__vma, __addr); \ 540 set_pte(__ptep, __entry); \
541 } \ 541 flush_tlb_page(__vma, __addr); \
542} while (0) 542 } \
543 __changed; \
544})
543#else 545#else
544# define ptep_set_access_flags(__vma, __addr, __ptep, __entry, __safely_writable) \ 546# define ptep_set_access_flags(__vma, __addr, __ptep, __entry, __safely_writable) \
545 ptep_establish(__vma, __addr, __ptep, __entry) 547({ \
548 int __changed = !pte_same(*(__ptep), __entry); \
549 if (__changed) \
550 ptep_establish(__vma, __addr, __ptep, __entry); \
551 __changed; \
552})
546#endif 553#endif
547 554
548# ifdef CONFIG_VIRTUAL_MEM_MAP 555# ifdef CONFIG_VIRTUAL_MEM_MAP