powerpc/tlb: Add local flush for page given mm_struct and psize
authorBenjamin Gray <bgray@linux.ibm.com>
Wed, 9 Nov 2022 04:51:10 +0000 (15:51 +1100)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 30 Nov 2022 10:46:49 +0000 (21:46 +1100)
commit274d842fa1efd9449e62222c8896e0be11621f1f
treee561c879fbb8aec516100c49d8a3127bfae68a26
parentd34471c9bd5d47ab148dd68817631a4238f755c4
powerpc/tlb: Add local flush for page given mm_struct and psize

Adds a local TLB flush operation that works given an mm_struct, VA to
flush, and page size representation. Most implementations mirror the
surrounding code. The book3s/32/tlbflush.h implementation is left as
a BUILD_BUG because it is more complicated and not required for
anything as yet.

This removes the need to create a vm_area_struct, which the temporary
patching mm work does not need.

Signed-off-by: Benjamin Gray <bgray@linux.ibm.com>
Reviewed-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20221109045112.187069-8-bgray@linux.ibm.com
arch/powerpc/include/asm/book3s/32/tlbflush.h
arch/powerpc/include/asm/book3s/64/tlbflush.h
arch/powerpc/include/asm/nohash/tlbflush.h
arch/powerpc/mm/nohash/tlb.c