powerpc/64s/radix: don't need to broadcast IPI for radix pmd collapse flush

The IPI broadcast is used to serialize against fast-GUP, but fast-GUP will
move to use RCU instead of disabling local interrupts in fast-GUP.  Using
an IPI is the old-styled way of serializing against fast-GUP although it
still works as expected now.

And fast-GUP now fixed the potential race with THP collapse by checking
whether PMD is changed or not.  So IPI broadcast in radix pmd collapse
flush is not necessary anymore.  But it is still needed for hash TLB.

Link: https://lkml.kernel.org/r/[email protected]
Suggested-by: Aneesh Kumar K.V <[email protected]>
Signed-off-by: Yang Shi <[email protected]>
Acked-by: David Hildenbrand <[email protected]>
Acked-by: Peter Xu <[email protected]>
Cc: Christophe Leroy <[email protected]>
Cc: Hugh Dickins <[email protected]>
Cc: Jason Gunthorpe <[email protected]>
Cc: John Hubbard <[email protected]>
Cc: "Kirill A. Shutemov" <[email protected]>
Cc: Michael Ellerman <[email protected]>
Cc: Nicholas Piggin <[email protected]>
Cc: <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
This commit is contained in:
Yang Shi
2022-09-26 12:14:33 -07:00
committed by Andrew Morton
parent 70cbc3cc78
commit bedf034169
-9
View File
@@ -937,15 +937,6 @@ pmd_t radix__pmdp_collapse_flush(struct vm_area_struct *vma, unsigned long addre
pmd = *pmdp;
pmd_clear(pmdp);
/*
* pmdp collapse_flush need to ensure that there are no parallel gup
* walk after this call. This is needed so that we can have stable
* page ref count when collapsing a page. We don't allow a collapse page
* if we have gup taken on the page. We can ensure that by sending IPI
* because gup walk happens with IRQ disabled.
*/
serialize_against_pte_lookup(vma->vm_mm);
radix__flush_tlb_collapsed_pmd(vma->vm_mm, address);
return pmd;