android_kernel_motorola_sm6225/arch/x86
Borislav Petkov (AMD) 5ac3c7a830 x86/CPU/AMD: Check vendor in the AMD microcode callback
commit 9b8493dc43044376716d789d07699f17d538a7c4 upstream.

Commit in Fixes added an AMD-specific microcode callback. However, it
didn't check the CPU vendor the kernel runs on explicitly.

The only reason the Zenbleed check in it didn't run on other x86 vendors
hardware was pure coincidental luck:

  if (!cpu_has_amd_erratum(c, amd_zenbleed))
	  return;

gives true on other vendors because they don't have those families and
models.

However, with the removal of the cpu_has_amd_erratum() in

  05f5f73936fa ("x86/CPU/AMD: Drop now unused CPU erratum checking function")

that coincidental condition is gone, leading to the zenbleed check
getting executed on other vendors too.

Add the explicit vendor check for the whole callback as it should've
been done in the first place.

Fixes: 522b1d69219d ("x86/cpu/amd: Add a Zenbleed fix")
Cc: <stable@kernel.org>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Link: https://lore.kernel.org/r/20231201184226.16749-1-bp@alien8.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-12-13 17:42:20 +01:00
..
boot x86/boot: Wrap literal addresses in absolute_pointer() 2023-06-09 10:24:02 +02:00
configs x86/defconfig: Enable CONFIG_USB_XHCI_HCD=y 2020-09-23 12:11:02 +02:00
crypto crypto: x86/crc32c - fix building with clang ias 2021-01-23 15:49:55 +01:00
entry x86/mm: Fix VDSO and VVAR placement on 5-level paging machines 2023-08-16 18:13:00 +02:00
events perf/x86/intel/uncore: Fix reference count leak in hswep_has_limit_sbox() 2023-01-18 11:30:05 +01:00
hyperv x86/hyperv: Fix NULL deref in set_hv_tscchange_cb() if Hyper-V setup fails 2021-11-26 11:36:23 +01:00
ia32 binfmt: Move install_exec_creds after setup_new_exec to match binfmt_elf 2023-01-18 11:30:42 +01:00
include KVM: x86: Ignore MSR_AMD64_TW_CFG access 2023-11-28 16:46:34 +00:00
kernel x86/CPU/AMD: Check vendor in the AMD microcode callback 2023-12-13 17:42:20 +01:00
kvm KVM: x86: Ignore MSR_AMD64_TW_CFG access 2023-11-28 16:46:34 +00:00
lib x86/asm: Fix an assembler warning with current binutils 2023-02-06 07:49:44 +01:00
math-emu x86: math-emu: Fix up 'cmp' insn for clang ias 2020-07-29 10:16:54 +02:00
mm x86/mm: Drop the 4 MB restriction on minimal NUMA node memory size 2023-11-28 16:46:31 +00:00
net bpf: Introduce BPF nospec instruction for mitigating Spectre v4 2021-09-22 11:47:58 +02:00
oprofile
pci x86/PCI: Add quirk for AMD XHCI controller that loses MSI-X state in D3hot 2023-04-20 12:04:40 +02:00
platform x86/olpc: fix 'logical not is only applied to the left hand side' 2022-08-25 11:15:27 +02:00
power x86/pm: Add enumeration check before spec MSRs save/restore setup 2022-12-08 11:18:34 +01:00
purgatory x86/purgatory: remove PGO flags 2023-06-28 10:15:27 +02:00
ras
realmode x86/64/mm: Map all kernel memory into trampoline_pgd 2021-12-08 08:50:14 +01:00
tools x86/tools: Fix objdump version check again 2021-08-26 08:36:39 -04:00
um x86: um: vdso: Add '%rcx' and '%r11' to the syscall clobber list 2023-03-11 16:31:58 +01:00
video
xen x86/xen: Fix secondary processors' FPU initialization 2023-08-08 19:49:19 +02:00
.gitignore
Kbuild
Kconfig x86/speculation: Add Kconfig option for GDS 2023-08-08 19:49:19 +02:00
Kconfig.cpu
Kconfig.debug x86, perf: Fix the dependency of the x86 insn decoder selftest 2020-01-27 14:51:08 +01:00
Makefile x86/build: Propagate $(CLANG_FLAGS) to $(REALMODE_FLAGS) 2021-05-22 10:59:15 +02:00
Makefile.um
Makefile_32.cpu