x86/mm/tlb: Privatize cpu_tlbstate
authorNadav Amit <namit@vmware.com>
Sat, 20 Feb 2021 23:17:08 +0000 (15:17 -0800)
committerIngo Molnar <mingo@kernel.org>
Sat, 6 Mar 2021 11:59:10 +0000 (12:59 +0100)
commit2f4305b19fe6a2a261d76c21856c5598f7d878fe
tree061ebf3ef8372e4da41a4c113127381207bc1d0c
parent4ce94eabac16b1d2c95762b40f49e5654ab288d7
x86/mm/tlb: Privatize cpu_tlbstate

cpu_tlbstate is mostly private and only the variable is_lazy is shared.
This causes some false-sharing when TLB flushes are performed.

Break cpu_tlbstate intro cpu_tlbstate and cpu_tlbstate_shared, and mark
each one accordingly.

Signed-off-by: Nadav Amit <namit@vmware.com>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Reviewed-by: Dave Hansen <dave.hansen@linux.intel.com>
Link: https://lore.kernel.org/r/20210220231712.2475218-6-namit@vmware.com
arch/x86/include/asm/tlbflush.h
arch/x86/kernel/alternative.c
arch/x86/mm/init.c
arch/x86/mm/tlb.c