x86/boot: Move startup code out of __head section
authorArd Biesheuvel <ardb@kernel.org>
Thu, 28 Aug 2025 10:22:24 +0000 (12:22 +0200)
committerBorislav Petkov (AMD) <bp@alien8.de>
Wed, 3 Sep 2025 16:06:04 +0000 (18:06 +0200)
commitc5c30a37369313d1f8b84e96e6a4397b4e2b4eb8
treeffc41596d742acbe53a80fabf784f5d3204e0d8d
parente7b88bc0051c5062bdd73b58837cf277d0057358
x86/boot: Move startup code out of __head section

Move startup code out of the __head section, now that this no longer has
a special significance. Move everything into .text or .init.text as
appropriate, so that startup code is not kept around unnecessarily.

  [ bp: Fold in hunk to fix 32-bit CPU hotplug:
Reported-by: kernel test robot <oliver.sang@intel.com>
    Closes: https://lore.kernel.org/oe-lkp/202509022207.56fd97f4-lkp@intel.com ]

Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Link: https://lore.kernel.org/20250828102202.1849035-45-ardb+git@google.com
arch/x86/boot/compressed/sev.c
arch/x86/boot/startup/gdt_idt.c
arch/x86/boot/startup/map_kernel.c
arch/x86/boot/startup/sev-shared.c
arch/x86/boot/startup/sev-startup.c
arch/x86/boot/startup/sme.c
arch/x86/include/asm/init.h
arch/x86/kernel/head_32.S
arch/x86/kernel/head_64.S
arch/x86/platform/pvh/head.S