summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/stackcollapse.py
diff options
context:
space:
mode:
authorArd Biesheuvel <ardb@kernel.org>2026-09-25 09:51:40 +0200
committerBorislav Petkov (AMD) <bp@alien8.de>2026-09-28 17:41:46 -0700
commita9bc562daaf2596e6eab5f1a5e3a5880c4b2a1ee (patch)
tree83b0105fc0be96c6bb0859acac4b17e9749f6a3d /tools/perf/scripts/python/stackcollapse.py
parent0ffdb6c1ea44ddb40794b9c20a39b8fb30551875 (diff)
downloadlinux-next-a9bc562daaf2596e6eab5f1a5e3a5880c4b2a1ee.tar.gz
linux-next-a9bc562daaf2596e6eab5f1a5e3a5880c4b2a1ee.zip
x86/boot: Move unaccepted memory handling out of the decompressor
arch_accept_memory() is an arch-specific hook that is required by the EFI stub when processing memory that the firmware reports to the OS as EFI_UNACCEPTED_MEMORY. This hook is called after ExitBootServices() has been called, as before that point, the EFI memory map may get updated behind the back of the running EFI stub, making it difficult to get a stable view on it while iterating over the entries. Currently, the x86 version of this hook is implemented in its decompressor rather than in the EFI stub itself, in a manner that is problematic: when an error occurs, it calls the decompressor's error() routine, but without having gone through the decompressor initialization code. This means it will resort to direct port I/O rather than the hypercall based interface that TDX guests would use otherwise. Conceptually, code that is only called from the EFI stub, and never by the decompressor when doing legacy boot, belongs in the EFI stub and not in the decompressor. So move it into the x86-specific EFI stub code, replacing the error() on the TDX path with tdx_panic(), and dropping the error() when no CC support is detected - the kernel can decide what to do in this case after it has booted. Signed-off-by: Ard Biesheuvel <ardb@kernel.org> Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de> Reviewed-by: Kiryl Shutsemau (Meta) <kas@kernel.org> Link: https://patch.msgid.link/20260925075137.44298-7-ardb@kernel.org
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions