kernel_samsung_a53x/arch
Jonathan Cameron 8ccfca2782 arm64: acpi: Harden get_cpu_for_acpi_id() against missing CPU entry
[ Upstream commit 2488444274c70038eb6b686cba5f1ce48ebb9cdd ]

In a review discussion of the changes to support vCPU hotplug where
a check was added on the GICC being enabled if was online, it was
noted that there is need to map back to the cpu and use that to index
into a cpumask. As such, a valid ID is needed.

If an MPIDR check fails in acpi_map_gic_cpu_interface() it is possible
for the entry in cpu_madt_gicc[cpu] == NULL.  This function would
then cause a NULL pointer dereference.   Whilst a path to trigger
this has not been established, harden this caller against the
possibility.

Reviewed-by: Gavin Shan <gshan@redhat.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Link: https://lore.kernel.org/r/20240529133446.28446-13-Jonathan.Cameron@huawei.com
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-01-19 00:09:58 +01:00
..
alpha
arc ARC: build: Try to guess GCC variant of cross compiler 2025-01-15 16:29:56 +01:00
arm Revert "clkdev: remove CONFIG_CLKDEV_LOOKUP" 2025-01-02 17:01:18 +01:00
arm64 arm64: acpi: Harden get_cpu_for_acpi_id() against missing CPU entry 2025-01-19 00:09:58 +01:00
c6x
csky csky, hexagon: fix broken sys_sync_file_range 2024-11-19 14:19:34 +01:00
h8300
hexagon hexagon: fix fadvise64_64 calling conventions 2024-11-19 14:19:34 +01:00
ia64 efi: ia64: move IA64-only declarations to new asm/efi.h header 2024-11-19 14:19:45 +01:00
m68k m68k: coldfire/device.c: only build FEC when HW macros are defined 2024-12-17 13:24:12 +01:00
microblaze Revert "microblaze: don't treat zero reserved memory regions as error" 2024-11-24 00:23:33 +01:00
mips MIPS: Probe toolchain support of -msym32 2025-01-15 16:29:50 +01:00
nds32
nios2
openrisc openrisc: Call setup_memory() earlier in the init sequence 2024-11-23 23:20:47 +01:00
parisc Revert "parisc: Fix itlb miss handler for 64-bit programs" 2024-11-24 00:23:05 +01:00
powerpc powerpc/prom_init: Fixup missing powermac #size-cells 2024-12-17 13:24:32 +01:00
riscv Revert "riscv: Fix fp alignment bug in perf_callchain_user()" 2024-11-24 00:23:20 +01:00
s390 s390/cpum_sf: Handle CPU hotplug remove during sampling 2024-12-17 13:24:29 +01:00
sh Revert "clkdev: remove CONFIG_CLKDEV_LOOKUP" 2025-01-02 17:01:18 +01:00
sparc sparc64: Fix incorrect function signature and add prototype for prom_cif_init 2024-11-23 23:20:10 +01:00
um um: Always dump trace for specified task in show_stack 2024-12-17 13:24:21 +01:00
x86 ANDROID: fix up change to pti_clone_pgtable() 2025-01-19 00:09:58 +01:00
xtensa
Kconfig cpu: Re-enable CPU mitigations by default for !X86 architectures 2024-11-19 11:32:38 +01:00