]> git.ipfire.org Git - thirdparty/linux.git/commit
x86/decompressor: Pass pgtable address to trampoline directly
authorArd Biesheuvel <ardb@kernel.org>
Mon, 7 Aug 2023 16:27:11 +0000 (18:27 +0200)
committerBorislav Petkov (AMD) <bp@alien8.de>
Mon, 7 Aug 2023 18:49:26 +0000 (20:49 +0200)
commitcb83cece57e1889109dd73ea08ee338668c9d1b8
treee2eed338ae1d091200375cc7803d41c01a237041
parentf97b67a773cd84bd8b55c0a0ec32448a87fc56bb
x86/decompressor: Pass pgtable address to trampoline directly

The only remaining use of the trampoline address by the trampoline
itself is deriving the page table address from it, and this involves
adding an offset of 0x0. So simplify this, and pass the new CR3 value
directly.

This makes the fact that the page table happens to be at the start of
the trampoline allocation an implementation detail of the caller.

Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Link: https://lore.kernel.org/r/20230807162720.545787-15-ardb@kernel.org
arch/x86/boot/compressed/head_64.S
arch/x86/boot/compressed/pgtable.h
arch/x86/boot/compressed/pgtable_64.c