linux/arch
Mark Rutland a07a594152 arm64: smp: avoid NMI IPIs with broken MediaTek FW
Some MediaTek devices have broken firmware which corrupts some GICR
registers behind the back of the OS, and pseudo-NMIs cannot be used on
these devices. For more details see commit:

  44bd78dd2b ("irqchip/gic-v3: Disable pseudo NMIs on Mediatek devices w/ firmware issues")

We did not take this problem into account in commit:

  331a1b3a83 ("arm64: smp: Add arch support for backtrace using pseudo-NMI")

Since that commit arm64's SMP code will try to setup some IPIs as
pseudo-NMIs, even on systems with broken FW. The GICv3 code will
(rightly) reject attempts to request interrupts as pseudo-NMIs,
resulting in boot-time failures.

Avoid the problem by taking the broken FW into account when deciding to
request IPIs as pseudo-NMIs. The GICv3 driver maintains a static_key
named "supports_pseudo_nmis" which is false on systems with broken FW,
and we can consult this within ipi_should_be_nmi().

Fixes: 331a1b3a83 ("arm64: smp: Add arch support for backtrace using pseudo-NMI")
Reported-by: Chen-Yu Tsai <wenst@chromium.org>
Closes: https://issuetracker.google.com/issues/197061987#comment68
Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Tested-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: Marc Zyngier <maz@kernel.org>
Tested-by: Chen-Yu Tsai <wenst@chromium.org>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2023-10-06 12:34:41 +01:00
..
alpha Kbuild updates for v6.6 2023-09-05 11:01:47 -07:00
arc ARC updates for v6.6 2023-09-04 15:38:24 -07:00
arm xen: simplify evtchn_do_upcall() call maze 2023-09-19 07:04:49 +02:00
arm64 arm64: smp: avoid NMI IPIs with broken MediaTek FW 2023-10-06 12:34:41 +01:00
csky arch/csky 2nd patches for 6.6 2023-09-01 08:02:45 -07:00
hexagon Add x86 shadow stack support 2023-08-31 12:20:12 -07:00
ia64 acpi: Provide ia64 dummy implementation of acpi_proc_quirk_mwait_check() 2023-09-11 08:13:17 +00:00
loongarch LoongArch: Don't inline kasan_mem_to_shadow()/kasan_shadow_to_mem() 2023-09-20 14:26:29 +08:00
m68k ata changes for 6.6 2023-09-05 12:37:28 -07:00
microblaze Microblaze patches for 6.6-rc1 2023-09-05 10:15:22 -07:00
mips ARM: 2023-09-07 13:52:20 -07:00
nios2 Add x86 shadow stack support 2023-08-31 12:20:12 -07:00
openrisc OpenRISC updates for 6.6 2023-09-05 10:09:31 -07:00
parisc parisc architecture fixes and enhancements for kernel v6.6-rc2: 2023-09-13 11:35:53 -07:00
powerpc powerpc/dexcr: Move HASHCHK trap handler 2023-09-18 12:23:48 +10:00
riscv RISC-V: KVM: Fix riscv_vcpu_get_isa_ext_single() for missing extensions 2023-09-21 15:04:01 +05:30
s390 s390/cert_store: fix string length handling 2023-09-19 13:25:44 +02:00
sh sh: mm: re-add lost __ref to ioremap_prot() to fix modpost warning 2023-09-19 13:21:32 -07:00
sparc ata changes for 6.6 2023-09-05 12:37:28 -07:00
um This pull request contains the following changes for UML: 2023-09-04 11:32:21 -07:00
x86 ARM: 2023-09-24 14:14:35 -07:00
xtensa Xtensa updates for v6.6 2023-09-07 10:30:17 -07:00
.gitignore
Kconfig Add x86 shadow stack support 2023-08-31 12:20:12 -07:00