This is a note to let you know that I've just added the patch titled MIPS: VDSO: Use CLANG_FLAGS instead of filtering out '--target=' to the 5.11-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: mips-vdso-use-clang_flags-instead-of-filtering-out-target.patch and it can be found in the queue-5.11 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. >From 76d7fff22be3e4185ee5f9da2eecbd8188e76b2c Mon Sep 17 00:00:00 2001 From: Nathan Chancellor <natechancellor@xxxxxxxxx> Date: Fri, 15 Jan 2021 12:26:22 -0700 Subject: MIPS: VDSO: Use CLANG_FLAGS instead of filtering out '--target=' From: Nathan Chancellor <natechancellor@xxxxxxxxx> commit 76d7fff22be3e4185ee5f9da2eecbd8188e76b2c upstream. Commit ee67855ecd9d ("MIPS: vdso: Allow clang's --target flag in VDSO cflags") allowed the '--target=' flag from the main Makefile to filter through to the vDSO. However, it did not bring any of the other clang specific flags for controlling the integrated assembler and the GNU tools locations (--prefix=, --gcc-toolchain=, and -no-integrated-as). Without these, we will get a warning (visible with tinyconfig): arch/mips/vdso/elf.S:14:1: warning: DWARF2 only supports one section per compilation unit .pushsection .note.Linux, "a",@note ; .balign 4 ; .long 2f - 1f ; .long 4484f - 3f ; .long 0 ; 1:.asciz "Linux" ; 2:.balign 4 ; 3: ^ arch/mips/vdso/elf.S:34:2: warning: DWARF2 only supports one section per compilation unit .section .mips_abiflags, "a" ^ All of these flags are bundled up under CLANG_FLAGS in the main Makefile and exported so that they can be added to Makefiles that set their own CFLAGS. Use this value instead of filtering out '--target=' so there is no warning and all of the tools are properly used. Cc: stable@xxxxxxxxxxxxxxx Fixes: ee67855ecd9d ("MIPS: vdso: Allow clang's --target flag in VDSO cflags") Link: https://github.com/ClangBuiltLinux/linux/issues/1256 Reported-by: Anders Roxell <anders.roxell@xxxxxxxxxx> Signed-off-by: Nathan Chancellor <natechancellor@xxxxxxxxx> Tested-by: Anders Roxell <anders.roxell@xxxxxxxxxx> Signed-off-by: Thomas Bogendoerfer <tsbogend@xxxxxxxxxxxxxxxx> Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- arch/mips/vdso/Makefile | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) --- a/arch/mips/vdso/Makefile +++ b/arch/mips/vdso/Makefile @@ -16,16 +16,13 @@ ccflags-vdso := \ $(filter -march=%,$(KBUILD_CFLAGS)) \ $(filter -m%-float,$(KBUILD_CFLAGS)) \ $(filter -mno-loongson-%,$(KBUILD_CFLAGS)) \ + $(CLANG_FLAGS) \ -D__VDSO__ ifndef CONFIG_64BIT ccflags-vdso += -DBUILD_VDSO32 endif -ifdef CONFIG_CC_IS_CLANG -ccflags-vdso += $(filter --target=%,$(KBUILD_CFLAGS)) -endif - # # The -fno-jump-tables flag only prevents the compiler from generating # jump tables but does not prevent the compiler from emitting absolute Patches currently in stable-queue which might be from natechancellor@xxxxxxxxx are queue-5.11/mips-vmlinux.lds.s-add-missing-page_aligned_data-section.patch queue-5.11/dmaengine-qcom-always-inline-gpi_update_reg.patch queue-5.11/mips-compare-__sync_loongson3_war-against-0.patch queue-5.11/mips-properly-stop-.eh_frame-generation.patch queue-5.11/mips-lantiq-explicitly-compare-ltq_ebu_pcc_istat-aga.patch queue-5.11/mips-c-r4k-fix-section-mismatch-for-loongson2_sc_ini.patch queue-5.11/jffs2-fix-use-after-free-in-jffs2_sum_write_data.patch queue-5.11/mips-vdso-use-clang_flags-instead-of-filtering-out-target.patch queue-5.11/mm-rmap-fix-potential-pte_unmap-on-an-not-mapped-pte.patch queue-5.11/ubifs-replay-fix-high-stack-usage-again.patch