Patch "s390/vdso: drop '-fPIC' from LDFLAGS" has been added to the 6.1-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    s390/vdso: drop '-fPIC' from LDFLAGS

to the 6.1-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     s390-vdso-drop-fpic-from-ldflags.patch
and it can be found in the queue-6.1 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit c89cf98d1655b2639b433b714f21996f3542a106
Author: Nathan Chancellor <nathan@xxxxxxxxxx>
Date:   Tue Jan 30 20:14:28 2024 -0700

    s390/vdso: drop '-fPIC' from LDFLAGS
    
    [ Upstream commit 0628c03934187be33942580e10bb9afcc61adeed ]
    
    '-fPIC' as an option to the linker does not do what it seems like it
    should. With ld.bfd, it is treated as '-f PIC', which does not make
    sense based on the meaning of '-f':
    
      -f SHLIB, --auxiliary SHLIB Auxiliary filter for shared object symbol table
    
    When building with ld.lld (currently under review in a GitHub pull
    request), it just errors out because '-f' means nothing and neither does
    '-fPIC':
    
      ld.lld: error: unknown argument '-fPIC'
    
    '-fPIC' was blindly copied from CFLAGS when the vDSO stopped being
    linked with '$(CC)', it should not be needed. Remove it to clear up the
    build failure with ld.lld.
    
    Fixes: 2b2a25845d53 ("s390/vdso: Use $(LD) instead of $(CC) to link vDSO")
    Link: https://github.com/llvm/llvm-project/pull/75643
    Signed-off-by: Nathan Chancellor <nathan@xxxxxxxxxx>
    Reviewed-by: Fangrui Song <maskray@xxxxxxxxxx>
    Link: https://lore.kernel.org/r/20240130-s390-vdso-drop-fpic-from-ldflags-v1-1-094ad104fc55@xxxxxxxxxx
    Signed-off-by: Heiko Carstens <hca@xxxxxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/arch/s390/kernel/vdso32/Makefile b/arch/s390/kernel/vdso32/Makefile
index 245bddfe9bc0e..cc513add48eb5 100644
--- a/arch/s390/kernel/vdso32/Makefile
+++ b/arch/s390/kernel/vdso32/Makefile
@@ -22,7 +22,7 @@ KBUILD_AFLAGS_32 += -m31 -s
 KBUILD_CFLAGS_32 := $(filter-out -m64,$(KBUILD_CFLAGS))
 KBUILD_CFLAGS_32 += -m31 -fPIC -shared -fno-common -fno-builtin
 
-LDFLAGS_vdso32.so.dbg += -fPIC -shared -soname=linux-vdso32.so.1 \
+LDFLAGS_vdso32.so.dbg += -shared -soname=linux-vdso32.so.1 \
 	--hash-style=both --build-id=sha1 -melf_s390 -T
 
 $(targets:%=$(obj)/%.dbg): KBUILD_CFLAGS = $(KBUILD_CFLAGS_32)
diff --git a/arch/s390/kernel/vdso64/Makefile b/arch/s390/kernel/vdso64/Makefile
index 1605ba45ac4c0..42d918d50a1ff 100644
--- a/arch/s390/kernel/vdso64/Makefile
+++ b/arch/s390/kernel/vdso64/Makefile
@@ -26,7 +26,7 @@ KBUILD_AFLAGS_64 += -m64 -s
 
 KBUILD_CFLAGS_64 := $(filter-out -m64,$(KBUILD_CFLAGS))
 KBUILD_CFLAGS_64 += -m64 -fPIC -fno-common -fno-builtin
-ldflags-y := -fPIC -shared -soname=linux-vdso64.so.1 \
+ldflags-y := -shared -soname=linux-vdso64.so.1 \
 	     --hash-style=both --build-id=sha1 -T
 
 $(targets:%=$(obj)/%.dbg): KBUILD_CFLAGS = $(KBUILD_CFLAGS_64)




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux