diff options
Diffstat (limited to 'include/asm-sparc64/pgtable.h')
-rw-r--r-- | include/asm-sparc64/pgtable.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/include/asm-sparc64/pgtable.h b/include/asm-sparc64/pgtable.h index 72f9a524dc67..4e218814bb3c 100644 --- a/include/asm-sparc64/pgtable.h +++ b/include/asm-sparc64/pgtable.h | |||
@@ -688,6 +688,23 @@ static inline void set_pte_at(struct mm_struct *mm, unsigned long addr, pte_t *p | |||
688 | #define pte_clear(mm,addr,ptep) \ | 688 | #define pte_clear(mm,addr,ptep) \ |
689 | set_pte_at((mm), (addr), (ptep), __pte(0UL)) | 689 | set_pte_at((mm), (addr), (ptep), __pte(0UL)) |
690 | 690 | ||
691 | #ifdef DCACHE_ALIASING_POSSIBLE | ||
692 | #define __HAVE_ARCH_MOVE_PTE | ||
693 | #define move_pte(pte, prot, old_addr, new_addr) \ | ||
694 | ({ \ | ||
695 | pte_t newpte = (pte); \ | ||
696 | if (tlb_type != hypervisor && pte_present(pte)) { \ | ||
697 | unsigned long this_pfn = pte_pfn(pte); \ | ||
698 | \ | ||
699 | if (pfn_valid(this_pfn) && \ | ||
700 | (((old_addr) ^ (new_addr)) & (1 << 13))) \ | ||
701 | flush_dcache_page_all(current->mm, \ | ||
702 | pfn_to_page(this_pfn)); \ | ||
703 | } \ | ||
704 | newpte; \ | ||
705 | }) | ||
706 | #endif | ||
707 | |||
691 | extern pgd_t swapper_pg_dir[2048]; | 708 | extern pgd_t swapper_pg_dir[2048]; |
692 | extern pmd_t swapper_low_pmd_dir[2048]; | 709 | extern pmd_t swapper_low_pmd_dir[2048]; |
693 | 710 | ||