@@ -142,7 +142,6 @@ static inline unsigned long radix__pte_update(struct mm_struct *mm,
unsigned long new_pte;
old_pte = __radix_pte_update(ptep, ~0, 0);
- asm volatile("ptesync" : : : "memory");
/*
* new value of pte
*/
@@ -153,6 +152,7 @@ static inline unsigned long radix__pte_update(struct mm_struct *mm,
* tlb flush batching is done by mmu gather code
*/
if (new_pte) {
+ asm volatile("ptesync" : : : "memory");
psize = radix_get_mmu_psize(pg_sz);
radix__flush_tlb_page_psize(mm, addr, psize);
__radix_pte_update(ptep, 0, new_pte);