linux_dsm_epyc7002/include
Peter Zijlstra 0758cd8304 asm-generic/tlb: avoid potential double flush
Aneesh reported that:

	tlb_flush_mmu()
	  tlb_flush_mmu_tlbonly()
	    tlb_flush()			<-- #1
	  tlb_flush_mmu_free()
	    tlb_table_flush()
	      tlb_table_invalidate()
		tlb_flush_mmu_tlbonly()
		  tlb_flush()		<-- #2

does two TLBIs when tlb->fullmm, because __tlb_reset_range() will not
clear tlb->end in that case.

Observe that any caller to __tlb_adjust_range() also sets at least one of
the tlb->freed_tables || tlb->cleared_p* bits, and those are
unconditionally cleared by __tlb_reset_range().

Change the condition for actually issuing TLBI to having one of those bits
set, as opposed to having tlb->end != 0.

Link: http://lkml.kernel.org/r/20200116064531.483522-4-aneesh.kumar@linux.ibm.com
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.ibm.com>
Reported-by: "Aneesh Kumar K.V" <aneesh.kumar@linux.ibm.com>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2020-02-04 03:05:26 +00:00
..
acpi
asm-generic asm-generic/tlb: avoid potential double flush 2020-02-04 03:05:26 +00:00
clocksource clocksource/drivers/hyper-v: Untangle stimers and timesync from clocksources 2020-01-16 19:09:02 +01:00
crypto crypto: poly1305 - add new 32 and 64-bit generic versions 2020-01-16 15:18:12 +08:00
drm Linux 5.5-rc7 2020-01-20 11:42:57 +10:00
dt-bindings Char/Misc driver changes for 5.6-rc1 2020-01-29 10:35:54 -08:00
keys
kunit
kvm
linux x86: mm: avoid allocating struct mm_struct on the stack 2020-02-04 03:05:25 +00:00
math-emu
media
misc
net mptcp: Fix undefined mptcp_handle_ipv6_mapped for modular IPV6 2020-01-30 10:55:54 +01:00
pcmcia
ras
rdma RDMA/core: Make the entire API tree static 2020-01-30 16:28:52 -04:00
scsi
soc Merge ra.kernel.org:/pub/scm/linux/kernel/git/netdev/net 2020-01-19 22:10:04 +01:00
sound ASoC: Updates for v5.6 2020-01-27 17:45:44 +01:00
target
trace media updates for v5.6-rc1 2020-01-31 14:43:23 -08:00
uapi Change /dev/random so that it uses the CRNG and only blocking if the 2020-02-01 09:48:37 -08:00
vdso
video
xen