WSL2-Linux-Kernel/arch/arm64
Jonathan Cameron 945be49f4e 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>
2024-09-12 11:07:52 +02:00
..
boot arm64: dts: qcom: msm8996: correct #clock-cells for QMP PHY nodes 2024-08-19 05:45:51 +02:00
configs
crypto
hyperv
include arm64: acpi: Harden get_cpu_for_acpi_id() against missing CPU entry 2024-09-12 11:07:52 +02:00
kernel arm64: acpi: Move get_cpu_for_acpi_id() to a header 2024-09-12 11:07:52 +02:00
kvm KVM: arm64: Make ICC_*SGI*_EL1 undef in the absence of a vGICv3 2024-09-04 13:23:36 +02:00
lib
mm arm64: hibernate: Fix level3 translation fault in swsusp_save() 2024-04-27 17:05:28 +02:00
net
tools arm64: errata: Add workaround for Arm errata 3194386 and 3312417 2024-08-19 05:45:40 +02:00
xen
Kbuild
Kconfig arm64: errata: Expand speculative SSBS workaround (again) 2024-08-19 05:45:41 +02:00
Kconfig.debug
Kconfig.platforms
Makefile