# git rev-parse -q --verify 7dbd98b1927bee4be878ab2caa13546256db40e9^{commit} 7dbd98b1927bee4be878ab2caa13546256db40e9 already have revision, skipping fetch # git checkout -q -f -B kisskb 7dbd98b1927bee4be878ab2caa13546256db40e9 # git clean -qxdf # < git log -1 # commit 7dbd98b1927bee4be878ab2caa13546256db40e9 # Author: Alexey Kardashevskiy # Date: Thu Sep 29 12:08:23 2022 +1000 # # zstd: Fixing mixed module-builtin objects # # With CONFIG_ZSTD_COMPRESS=m and CONFIG_ZSTD_DECOMPRESS=y we end up in # a situation when files from lib/zstd/common/ are compiled once to be # linked later for ZSTD_DECOMPRESS (build-in) and ZSTD_COMPRESS (module) # even though CFLAGS are different for builtins and modules. # So far somehow this was not a problem but enabling LLVM LTO exposes # the problem as: # # ld.lld: error: linking module flags 'Code Model': IDs have conflicting values in 'lib/built-in.a(zstd_common.o at 5868)' and 'ld-temp.o' # # This particular conflict is caused by KBUILD_CFLAGS=-mcmodel=medium vs. # KBUILD_CFLAGS_MODULE=-mcmodel=large , modules use the large model on # POWERPC as explained at # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/powerpc/Makefile?h=v5.18-rc4#n127 # but the current use of common files is wrong anyway. # # This works around the issue by introducing a zstd_common module with # shared code. # # Signed-off-by: Alexey Kardashevskiy # Signed-off-by: Masahiro Yamada # < /opt/cross/kisskb/korg/gcc-11.1.0-nolibc/sparc64-linux/bin/sparc64-linux-gcc --version # < /opt/cross/kisskb/korg/gcc-11.1.0-nolibc/sparc64-linux/bin/sparc64-linux-ld --version # < git log --format=%s --max-count=1 7dbd98b1927bee4be878ab2caa13546256db40e9 # < make -s -j 24 ARCH=sparc64 O=/kisskb/build/kbuild_sparc64-defconfig_sparc64-gcc11 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-11.1.0-nolibc/sparc64-linux/bin/sparc64-linux- defconfig # < make -s -j 24 ARCH=sparc64 O=/kisskb/build/kbuild_sparc64-defconfig_sparc64-gcc11 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-11.1.0-nolibc/sparc64-linux/bin/sparc64-linux- help # make -s -j 24 ARCH=sparc64 O=/kisskb/build/kbuild_sparc64-defconfig_sparc64-gcc11 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-11.1.0-nolibc/sparc64-linux/bin/sparc64-linux- olddefconfig # make -s -j 24 ARCH=sparc64 O=/kisskb/build/kbuild_sparc64-defconfig_sparc64-gcc11 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-11.1.0-nolibc/sparc64-linux/bin/sparc64-linux- :1517:2: warning: #warning syscall clone3 not implemented [-Wcpp] WARNING: modpost: EXPORT symbol "_mcount" [vmlinux] version generation failed, symbol will not be versioned. Is "_mcount" prototyped in ? kernel: arch/sparc/boot/image is ready kernel: arch/sparc/boot/zImage is ready Completed OK # rm -rf /kisskb/build/kbuild_sparc64-defconfig_sparc64-gcc11 # Build took: 0:02:18.428143