]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/commit
powerpc/mm/radix: Flush page walk cache when freeing page table
authorAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Wed, 8 Jun 2016 14:25:51 +0000 (19:55 +0530)
committerMichael Ellerman <mpe@ellerman.id.au>
Fri, 10 Jun 2016 06:14:52 +0000 (16:14 +1000)
commita145abf12c9f7d30d8c330c9d8a97428cbf0589b
treefd6299b45426739853fc7b4da91fd62d7fdf3a74
parent36194812a4063dd2a72070aec3ee7890d135a587
powerpc/mm/radix: Flush page walk cache when freeing page table

Even though a tlb_flush() does a flush with invalidate all cache,
we can end up doing an RCU page table free before calling tlb_flush().
That means we can have page walk cache entries even after we free the
page table pages. This can result in us doing wrong page table walk.

Avoid this by doing pwc flush on every page table free. We can't batch
the pwc flush, because the rcu call back function where we free the
page table pages doesn't have information of the mmu gather. Thus we
have to do a pwc on every page table page freed.

Note: I also removed the dummy tlb_flush_pgtable call functions for
hash 32.

Fixes: 1a472c9dba6b ("powerpc/mm/radix: Add tlbflush routines")
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/include/asm/book3s/32/pgalloc.h
arch/powerpc/include/asm/book3s/64/pgalloc.h
arch/powerpc/include/asm/book3s/64/tlbflush-radix.h
arch/powerpc/include/asm/book3s/64/tlbflush.h
arch/powerpc/include/asm/book3s/pgalloc.h
arch/powerpc/mm/tlb-radix.c