]> www.infradead.org Git - users/dwmw2/linux.git/commit
x86/kexec: Drop page_list argument from relocate_kernel()
authorDavid Woodhouse <dwmw@amazon.co.uk>
Fri, 22 Nov 2024 11:15:58 +0000 (11:15 +0000)
committerDavid Woodhouse <dwmw@amazon.co.uk>
Thu, 5 Dec 2024 15:05:07 +0000 (15:05 +0000)
commit2fa024e0e6fa956b9f5170d312321405c791fadc
tree4724e7dd1e95be0b243f06d34d5917a4f3fc1b7a
parent92fc7e04a4a177fff4a7a1042581c68f4f47949c
x86/kexec: Drop page_list argument from relocate_kernel()

The kernel's virtual mapping of the relocate_kernel page currently needs
to be RWX because it is written to before the %cr3 switch.

Now that the relocate_kernel page has its own .data section and local
variables, it can also have *global* variables. So eliminate the separate
page_list argument, and write the same information directly to variables
in the relocate_kernel page instead. This way, the relocate_kernel code
itself doesn't need to copy it.

Signed-off-by: David Woodhouse <dwmw@amazon.co.uk>
arch/x86/include/asm/kexec.h
arch/x86/kernel/machine_kexec_64.c
arch/x86/kernel/relocate_kernel_64.S