kernel_samsung_a53x/drivers/firmware
Ard Biesheuvel 206b7d66a4 efistub/tpm: Use ACPI reclaim memory for event log to avoid corruption
commit 77d48d39e99170b528e4f2e9fc5d1d64cdedd386 upstream.

The TPM event log table is a Linux specific construct, where the data
produced by the GetEventLog() boot service is cached in memory, and
passed on to the OS using an EFI configuration table.

The use of EFI_LOADER_DATA here results in the region being left
unreserved in the E820 memory map constructed by the EFI stub, and this
is the memory description that is passed on to the incoming kernel by
kexec, which is therefore unaware that the region should be reserved.

Even though the utility of the TPM2 event log after a kexec is
questionable, any corruption might send the parsing code off into the
weeds and crash the kernel. So let's use EFI_ACPI_RECLAIM_MEMORY
instead, which is always treated as reserved by the E820 conversion
logic.

Cc: <stable@vger.kernel.org>
Reported-by: Breno Leitao <leitao@debian.org>
Tested-by: Usama Arif <usamaarif642@gmail.com>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-11-23 23:21:31 +01:00
..
arm_scmi
broadcom
efi efistub/tpm: Use ACPI reclaim memory for event log to avoid corruption 2024-11-23 23:21:31 +01:00
google
imx
meson firmware: meson_sm: populate platform devices from sm device tree data 2024-11-18 12:12:28 +01:00
psci
smccc
tegra
xilinx
arm_scpi.c
arm_sdei.c
dmi-id.c firmware: dmi-id: add a release callback function 2024-11-19 12:27:01 +01:00
dmi-sysfs.c
dmi_scan.c firmware: dmi: Stop decoding on broken entry 2024-11-19 14:19:40 +01:00
edd.c
iscsi_ibft.c
iscsi_ibft_find.c
Kconfig
Makefile
memmap.c
pcdp.c
pcdp.h
qcom_scm-legacy.c
qcom_scm-smc.c
qcom_scm.c
qcom_scm.h
qemu_fw_cfg.c
raspberrypi.c firmware: raspberrypi: Use correct device for DMA mappings 2024-11-19 12:26:52 +01:00
scpi_pm_domain.c
stratix10-rsu.c
stratix10-svc.c
ti_sci.c firmware: ti_sci: Fix an off-by-one in ti_sci_debugfs_create() 2024-11-18 12:12:28 +01:00
ti_sci.h
trusted_foundations.c
turris-mox-rwtm.c firmware: turris-mox-rwtm: Initialize completion before mailbox 2024-11-23 23:20:06 +01:00