]> www.infradead.org Git - users/hch/misc.git/commit
s390: vmlinux.lds.S: Reorder sections
authorAlexey Gladkov <legion@kernel.org>
Thu, 18 Sep 2025 08:05:45 +0000 (10:05 +0200)
committerNathan Chancellor <nathan@kernel.org>
Wed, 24 Sep 2025 16:10:44 +0000 (09:10 -0700)
commit8d18ef04f940a8d336fe7915b5ea419c3eb0c0a6
tree31d0c4d8dca3a6575002bf2d6c3400126ba0fc5f
parentaa943a280e88e3585ed5a06d55e78c4123fcead3
s390: vmlinux.lds.S: Reorder sections

In the upcoming changes, the ELF_DETAILS macro will be extended with
the ".modinfo" section, which will cause an error:

>> s390x-linux-ld: .tmp_vmlinux1: warning: allocated section `.modinfo' not in segment
>> s390x-linux-ld: .tmp_vmlinux2: warning: allocated section `.modinfo' not in segment
>> s390x-linux-ld: vmlinux.unstripped: warning: allocated section `.modinfo' not in segment

This happens because the .vmlinux.info use :NONE to override the default
segment and tell the linker to not put the section in any segment at all.

To avoid this, we need to change the sections order that will be placed
in the default segment.

Cc: Heiko Carstens <hca@linux.ibm.com>
Cc: Vasily Gorbik <gor@linux.ibm.com>
Cc: Alexander Gordeev <agordeev@linux.ibm.com>
Cc: linux-s390@vger.kernel.org
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202506062053.zbkFBEnJ-lkp@intel.com/
Signed-off-by: Alexey Gladkov <legion@kernel.org>
Acked-by: Heiko Carstens <hca@linux.ibm.com>
Link: https://patch.msgid.link/20d40a7a3a053ba06a54155e777dcde7fdada1db.1758182101.git.legion@kernel.org
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
arch/s390/kernel/vmlinux.lds.S