From 2e136f9a60b31ba53501336a89c8c7367b2b0b2f Mon Sep 17 00:00:00 2001 From: Antonio Huete Jimenez Date: Sun, 1 Nov 2015 13:48:25 +0100 Subject: [PATCH] vkernel - Override max-page-size for ld.* - Move max-page-size setting to the vkernel-specific SYSTEM_LD as it was probably intended in ed9f17e. This overrides whatever the default is in ld.bfd or ld.gold. --- sys/conf/kern.pre.mk | 2 +- sys/platform/vkernel64/conf/Makefile | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/sys/conf/kern.pre.mk b/sys/conf/kern.pre.mk index 6077e4e9e2..0bad742acf 100644 --- a/sys/conf/kern.pre.mk +++ b/sys/conf/kern.pre.mk @@ -106,7 +106,7 @@ SYSTEM_LD= @${LD} -Bdynamic -T $S/platform/$P/conf/ldscript.$M \ # kernel itself, so leave the gold default alone and treat the kernel # page size as an exception. # -.if ${P} == "pc64" || ${P} == "vkernel64" +.if ${P} == "pc64" SYSTEM_LD+= -z max-page-size=0x200000 .endif diff --git a/sys/platform/vkernel64/conf/Makefile b/sys/platform/vkernel64/conf/Makefile index 23ec8c9918..f23743b10c 100644 --- a/sys/platform/vkernel64/conf/Makefile +++ b/sys/platform/vkernel64/conf/Makefile @@ -17,8 +17,12 @@ S= ../.. # Note that the vkernel requires .hash section to be present as the kernel # linker uses it to resolve its symbols. # +# Additionally, the max-page-size is set to 0x200000 regardless of the ld +# default setting. +# SYSTEM_LD= @${CC} ${DEBUG} ${PROF} -export-dynamic -o ${.TARGET} ${SYSTEM_OBJS} vers.o -pthread SYSTEM_LD+= -Wl,--hash-style=sysv +SYSTEM_LD+= -z max-page-size=0x200000 %BEFORE_DEPEND -- 2.41.0