android_kernel_motorola_sm6225/arch
Ingo Molnar 8708714728 x86/platform/uv: Fix !KEXEC build failure
[ Upstream commit c2209ea55612efac75de0a58ef5f7394fae7fa0f ]

When KEXEC is disabled, the UV build fails:

  arch/x86/platform/uv/uv_nmi.c:875:14: error: ‘uv_nmi_kexec_failed’ undeclared (first use in this function)

Since uv_nmi_kexec_failed is only defined in the KEXEC_CORE #ifdef branch,
this code cannot ever have been build tested:

	if (main)
		pr_err("UV: NMI kdump: KEXEC not supported in this kernel\n");
	atomic_set(&uv_nmi_kexec_failed, 1);

Nor is this use possible in uv_handle_nmi():

                atomic_set(&uv_nmi_kexec_failed, 0);

These bugs were introduced in this commit:

    d0a9964e98: ("x86/platform/uv: Implement simple dump failover if kdump fails")

Which added the uv_nmi_kexec_failed assignments to !KEXEC code, while making the
definition KEXEC-only - apparently without testing the !KEXEC case.

Instead of complicating the #ifdef maze, simplify the code by requiring X86_UV
to depend on KEXEC_CORE. This pattern is present in other architectures as well.

( We'll remove the untested, 7 years old !KEXEC complications from the file in a
  separate commit. )

Fixes: d0a9964e98: ("x86/platform/uv: Implement simple dump failover if kdump fails")
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Cc: Mike Travis <travis@sgi.com>
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-05-22 10:59:32 +02:00
..
alpha alpha: fix annotation of io{read,write}{16,32}be() 2020-08-26 10:31:02 +02:00
arc arc: kernel: Return -EFAULT if copy_to_user() fails 2021-04-28 13:16:48 +02:00
arm ARM: dts: exynos: correct PMIC interrupt trigger level on Snow 2021-05-22 10:59:27 +02:00
arm64 arm64: vdso: remove commas between macro name and arguments 2021-05-22 10:59:21 +02:00
c6x
h8300 h8300: fix PREEMPTION build, TI_PRE_COUNT undefined 2021-02-23 15:00:58 +01:00
hexagon hexagon: define ioremap_uc 2020-05-10 10:30:11 +02:00
ia64 ia64: fix discontig.c section mismatches 2021-04-28 13:16:52 +02:00
m68k m68k: q40: Fix info-leak in rtc_ioctl 2020-10-01 13:14:24 +02:00
microblaze microblaze: Prevent the overflow of the start 2020-02-24 08:34:53 +01:00
mips MIPS: pci-rt2880: fix slot 0 configuration 2021-05-22 10:59:24 +02:00
nds32 nds32: flush_dcache_page: use page_mapping_file to avoid races with swapoff 2021-04-14 08:22:32 +02:00
nios2 nios2: ksyms: Add missing symbol exports 2020-01-27 14:50:30 +01:00
openrisc openrisc: Fix cache API compile issue when not inlining 2020-09-23 12:10:58 +02:00
parisc parisc: avoid a warning on u8 cast for cmpxchg on u8 pointers 2021-04-14 08:22:33 +02:00
powerpc powerpc: fix EDEADLOCK redefinition error in uapi/asm/errno.h 2021-05-22 10:59:20 +02:00
riscv riscv,entry: fix misaligned base for excp_vect_table 2021-04-16 11:49:30 +02:00
s390 KVM: s390: split kvm_s390_real_to_abs 2021-05-22 10:59:26 +02:00
sh sh: dma: fix kconfig dependency for G2_DMA 2021-01-27 11:05:42 +01:00
sparc sparc64: Fix opcode filtering in handling of no fault loads 2021-03-30 14:36:58 +02:00
um block: genhd: add 'groups' argument to device_add_disk 2021-03-11 14:04:59 +01:00
unicore32
x86 x86/platform/uv: Fix !KEXEC build failure 2021-05-22 10:59:32 +02:00
xtensa xtensa: uaccess: Add missing __user to strncpy_from_user() prototype 2020-12-02 08:48:10 +01:00
.gitignore
Kconfig mm: fix exec activate_mm vs TLB shootdown and lazy tlb switching race 2020-11-05 11:08:38 +01:00