]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit - arch/x86/kernel/cpu/common.c
x86/tsx: Disable TSX development mode at boot
authorPawan Gupta <pawan.kumar.gupta@linux.intel.com>
Thu, 10 Mar 2022 22:02:09 +0000 (14:02 -0800)
committerStefan Bader <stefan.bader@canonical.com>
Fri, 20 May 2022 12:42:37 +0000 (14:42 +0200)
commit15db8764d0e6bb4548dbd686d4f851159793fe70
tree124d42991a89ed6f618b829ea4b7a31b76fba668
parentba9206f9c07de359bb0a7fe962eac55e79d3b292
x86/tsx: Disable TSX development mode at boot

BugLink: https://bugs.launchpad.net/bugs/1969857
commit 400331f8ffa3bec5c561417e5eec6848464e9160 upstream.

A microcode update on some Intel processors causes all TSX transactions
to always abort by default[*]. Microcode also added functionality to
re-enable TSX for development purposes. With this microcode loaded, if
tsx=on was passed on the cmdline, and TSX development mode was already
enabled before the kernel boot, it may make the system vulnerable to TSX
Asynchronous Abort (TAA).

To be on safer side, unconditionally disable TSX development mode during
boot. If a viable use case appears, this can be revisited later.

  [*]: Intel TSX Disable Update for Selected Processors, doc ID: 643557

  [ bp: Drop unstable web link, massage heavily. ]

Suggested-by: Andrew Cooper <andrew.cooper3@citrix.com>
Suggested-by: Borislav Petkov <bp@alien8.de>
Signed-off-by: Pawan Gupta <pawan.kumar.gupta@linux.intel.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Tested-by: Neelima Krishnan <neelima.krishnan@intel.com>
Cc: <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/347bd844da3a333a9793c6687d4e4eb3b2419a3e.1646943780.git.pawan.kumar.gupta@linux.intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
arch/x86/include/asm/msr-index.h
arch/x86/kernel/cpu/common.c
arch/x86/kernel/cpu/cpu.h
arch/x86/kernel/cpu/intel.c
arch/x86/kernel/cpu/tsx.c
tools/arch/x86/include/asm/msr-index.h