linux/arch/arm
Nathan Chancellor 8678591b47
kbuild: Split .modinfo out from ELF_DETAILS
Commit 3e86e4d74c ("kbuild: keep .modinfo section in
vmlinux.unstripped") added .modinfo to ELF_DETAILS while removing it
from COMMON_DISCARDS, as it was needed in vmlinux.unstripped and
ELF_DETAILS was present in all architecture specific vmlinux linker
scripts. While this shuffle is fine for vmlinux, ELF_DETAILS and
COMMON_DISCARDS may be used by other linker scripts, such as the s390
and x86 compressed boot images, which may not expect to have a .modinfo
section. In certain circumstances, this could result in a bootloader
failing to load the compressed kernel [1].

Commit ddc6cbef3e ("s390/boot/vmlinux.lds.S: Ensure bzImage ends with
SecureBoot trailer") recently addressed this for the s390 bzImage but
the same bug remains for arm, parisc, and x86. The presence of .modinfo
in the x86 bzImage was the root cause of the issue worked around with
commit d50f210913 ("kbuild: align modinfo section for Secureboot
Authenticode EDK2 compat"). misc.c in arch/x86/boot/compressed includes
lib/decompress_unzstd.c, which in turn includes lib/xxhash.c and its
MODULE_LICENSE / MODULE_DESCRIPTION macros due to the STATIC definition.

Split .modinfo out from ELF_DETAILS into its own macro and handle it in
all vmlinux linker scripts. Discard .modinfo in the places where it was
previously being discarded from being in COMMON_DISCARDS, as it has
never been necessary in those uses.

Cc: stable@vger.kernel.org
Fixes: 3e86e4d74c ("kbuild: keep .modinfo section in vmlinux.unstripped")
Reported-by: Ed W <lists@wildgooses.com>
Closes: https://lore.kernel.org/587f25e0-a80e-46a5-9f01-87cb40cfa377@wildgooses.com/ [1]
Tested-by: Ed W <lists@wildgooses.com> # x86_64
Link: https://patch.msgid.link/20260225-separate-modinfo-from-elf-details-v1-1-387ced6baf4b@kernel.org
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
2026-02-26 11:50:19 -07:00
..
boot kbuild: Split .modinfo out from ELF_DETAILS 2026-02-26 11:50:19 -07:00
common Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
configs mm.git review status for linus..mm-nonmm-stable 2026-02-12 12:13:01 -08:00
crypto crypto: arm/ghash - Use new AES library API 2026-01-15 14:09:08 -08:00
include ARM: clean up the memset64() C wrapper 2026-02-13 11:15:05 -08:00
kernel kbuild: Split .modinfo out from ELF_DETAILS 2026-02-26 11:50:19 -07:00
lib Crypto library updates for 6.17 2025-07-28 17:58:52 -07:00
mach-actions
mach-alpine
mach-artpec
mach-aspeed ARM: aspeed: Don't select SRAM 2025-05-21 23:07:08 +02:00
mach-at91 Devicetree updates for v7.0: 2026-02-11 18:27:08 -08:00
mach-axxia
mach-bcm
mach-berlin
mach-clps711x
mach-davinci ARM: davinci: remove support for da830 2025-04-16 18:02:20 +02:00
mach-digicolor
mach-dove
mach-ep93xx
mach-exynos ARM: exynos: Simplify with scoped for each OF child loop 2026-02-03 20:58:12 -06:00
mach-footbridge Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
mach-gemini ARM: gemini: fix typos in comments 2025-11-21 22:16:39 +01:00
mach-highbank ARM: Switch to new sys-off handler API 2025-07-04 09:31:17 +02:00
mach-hisi
mach-imx Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
mach-ixp4xx
mach-keystone
mach-lpc18xx
mach-lpc32xx
mach-mediatek ARM: mediatek: add MT6582 smp bring up code 2025-10-13 11:46:58 +02:00
mach-meson
mach-milbeaut
mach-mmp
mach-mstar
mach-mv78xx0
mach-mvebu Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
mach-mxs Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
mach-nomadik
mach-npcm arm: npcm: drop unused Kconfig ERRATA symbol 2026-01-08 17:11:35 +10:30
mach-omap1 Convert more 'alloc_obj' cases to default GFP_KERNEL arguments 2026-02-21 20:03:00 -08:00
mach-omap2 Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
mach-orion5x Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
mach-pxa syscore: Pass context data to callbacks 2025-11-14 10:01:52 +01:00
mach-qcom
mach-realtek
mach-rockchip ARM: rockchip: remove REGULATOR conditional to PM 2025-09-18 21:05:39 +02:00
mach-rpc Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
mach-s3c syscore: Pass context data to callbacks 2025-11-14 10:01:52 +01:00
mach-s5pv210 syscore: Pass context data to callbacks 2025-11-14 10:01:52 +01:00
mach-sa1100 Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
mach-shmobile Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
mach-socfpga
mach-spear
mach-sti ARM: sti: removal of stih415/stih416 related entries 2025-08-18 15:48:00 +02:00
mach-stm32 ARM: stm32: add a new SoC - STM32H747 2025-05-14 10:36:14 +02:00
mach-sunxi
mach-tegra ARM: tegra: Use I/O memcpy to write to IRAM 2025-07-09 14:20:31 +02:00
mach-ux500
mach-versatile Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
mach-vt8500 ARM: Switch to new sys-off handler API 2025-07-04 09:31:17 +02:00
mach-zynq Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
mm Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
net
nwfpe
plat-orion treewide: rename GPIO set callbacks back to their original names 2025-08-07 10:07:06 +02:00
probes Convert remaining multi-line kmalloc_obj/flex GFP_KERNEL uses 2026-02-22 08:26:33 -08:00
tools rseq: Implement sys_rseq_slice_yield() 2026-01-22 11:11:17 +01:00
vdso ARM: VDSO: Provide clock_getres_time64() 2026-01-13 14:42:23 +01:00
vfp ARM: 9446/1: Disallow kernel mode NEON when IRQs are disabled 2025-05-29 11:22:25 +01:00
xen Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
Kbuild
Kconfig ARM development for 7.0-rc1 2026-02-20 12:21:00 -08:00
Kconfig-nommu
Kconfig.debug
Kconfig.platforms ARM: mach-hpe: Rework support and directory structure 2025-09-15 15:07:38 +02:00
Makefile ARM: mach-hpe: Rework support and directory structure 2025-09-15 15:07:38 +02:00