This is a note to let you know that I've just added the patch titled kbuild: replace AS=clang with LLVM_IAS=1 to the 5.4-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: kbuild-replace-as-clang-with-llvm_ias-1.patch and it can be found in the queue-5.4 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. >From foo@baz Fri 21 Aug 2020 04:30:09 PM CEST From: Masahiro Yamada <masahiroy@xxxxxxxxxx> Date: Wed, 8 Apr 2020 10:36:22 +0900 Subject: kbuild: replace AS=clang with LLVM_IAS=1 From: Masahiro Yamada <masahiroy@xxxxxxxxxx> commit 7e20e47c70f810d678d02941fa3c671209c4ca97 upstream. The 'AS' variable is unused for building the kernel. Only the remaining usage is to turn on the integrated assembler. A boolean flag is a better fit for this purpose. AS=clang was added for experts. So, I replaced it with LLVM_IAS=1, breaking the backward compatibility. Suggested-by: Nick Desaulniers <ndesaulniers@xxxxxxxxxx> Signed-off-by: Masahiro Yamada <masahiroy@xxxxxxxxxx> Reviewed-by: Nathan Chancellor <natechancellor@xxxxxxxxx> Reviewed-by: Nick Desaulniers <ndesaulniers@xxxxxxxxxx> Signed-off-by: Nick Desaulniers <ndesaulniers@xxxxxxxxxx> Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- Documentation/kbuild/llvm.rst | 5 ++++- Makefile | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) --- a/Documentation/kbuild/llvm.rst +++ b/Documentation/kbuild/llvm.rst @@ -50,11 +50,14 @@ LLVM Utilities LLVM has substitutes for GNU binutils utilities. These can be invoked as additional parameters to `make`. - make CC=clang AS=clang LD=ld.lld AR=llvm-ar NM=llvm-nm STRIP=llvm-strip \\ + make CC=clang LD=ld.lld AR=llvm-ar NM=llvm-nm STRIP=llvm-strip \\ OBJCOPY=llvm-objcopy OBJDUMP=llvm-objdump OBJSIZE=llvm-size \\ READELF=llvm-readelf HOSTCC=clang HOSTCXX=clang++ HOSTAR=llvm-ar \\ HOSTLD=ld.lld +Currently, the integrated assembler is disabled by default. You can pass +`LLVM_IAS=1` to enable it. + Getting Help ------------ --- a/Makefile +++ b/Makefile @@ -533,7 +533,7 @@ endif ifneq ($(GCC_TOOLCHAIN),) CLANG_FLAGS += --gcc-toolchain=$(GCC_TOOLCHAIN) endif -ifeq ($(if $(AS),$(shell $(AS) --version 2>&1 | head -n 1 | grep clang)),) +ifneq ($(LLVM_IAS),1) CLANG_FLAGS += -no-integrated-as endif CLANG_FLAGS += -Werror=unknown-warning-option Patches currently in stable-queue which might be from masahiroy@xxxxxxxxxx are queue-5.4/kbuild-support-llvm-1-to-switch-the-default-tools-to-clang-llvm.patch queue-5.4/kbuild-remove-python2-variable.patch queue-5.4/net-wan-wanxl-use-m68kcc-instead-of-m68kas-for-rebuilding-firmware.patch queue-5.4/kbuild-remove-as-variable.patch queue-5.4/net-wan-wanxl-use-allow-to-pass-cross_compile_m68k-for-rebuilding-firmware.patch queue-5.4/kbuild-replace-as-clang-with-llvm_ias-1.patch queue-5.4/documentation-llvm-fix-the-name-of-llvm-size.patch queue-5.4/documentation-llvm-add-documentation-on-building-w-clang-llvm.patch queue-5.4/x86-boot-kbuild-allow-readelf-executable-to-be-specified.patch