OSDN Git Service

powerpc/mm: Add missing global TLB invalidate if cxl is active
authorFrederic Barrat <fbarrat@linux.vnet.ibm.com>
Wed, 29 Mar 2017 17:19:42 +0000 (19:19 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 12 Apr 2017 10:38:34 +0000 (12:38 +0200)
commita67004a3896eacd109a0138b5526957381fe4337
tree4104475f88535fbadec2ecb568a95d05cfc695f0
parent435cc436a88652046b9ca89fb56acf3a4b1a44b8
powerpc/mm: Add missing global TLB invalidate if cxl is active

commit 88b1bf7268f56887ca88eb09c6fb0f4fc970121a upstream.

Commit 4c6d9acce1f4 ("powerpc/mm: Add hooks for cxl") converted local
TLB invalidates to global if the cxl driver is active. This is necessary
because the CAPP snoops invalidations to forward them to the PSL on the
cxl adapter. However one path was forgotten. native_flush_hash_range()
still does local TLB invalidates, as found out the hard way recently.

This patch fixes it by following the same logic as previously: if the
cxl driver is active, the local TLB invalidates are 'upgraded' to
global.

Fixes: 4c6d9acce1f4 ("powerpc/mm: Add hooks for cxl")
Signed-off-by: Frederic Barrat <fbarrat@linux.vnet.ibm.com>
Reviewed-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/powerpc/mm/hash_native_64.c