# git rev-parse -q --verify 1619b69edce14c4a4665fa8ff4c587dcc77202a9^{commit} 1619b69edce14c4a4665fa8ff4c587dcc77202a9 already have revision, skipping fetch # git checkout -q -f -B kisskb 1619b69edce14c4a4665fa8ff4c587dcc77202a9 # git clean -qxdf # < git log -1 # commit 1619b69edce14c4a4665fa8ff4c587dcc77202a9 # Author: Michael Ellerman # Date: Tue Sep 14 22:17:23 2021 +1000 # # powerpc/boot: Fix build failure since GCC 4.9 removal # # Stephen reported that the build was broken since commit # 6d2ef226f2f1 ("compiler_attributes.h: drop __has_attribute() support for # gcc4"), with errors such as: # # include/linux/compiler_attributes.h:296:5: warning: "__has_attribute" is not defined, evaluates to 0 [-Wundef] # 296 | #if __has_attribute(__warning__) # | ^~~~~~~~~~~~~~~ # make[2]: *** [arch/powerpc/boot/Makefile:225: arch/powerpc/boot/crt0.o] Error 1 # # But we expect __has_attribute() to always be defined now that we've # stopped using GCC 4. # # Linus debugged it to the point of reading the GCC sources, and noticing # that the problem is that __has_attribute() is not defined when # preprocessing assembly files, which is what we're doing here. # # Our assembly files don't include, or need, compiler_attributes.h, but # they are getting it unconditionally from the -include in BOOT_CFLAGS, # which is then added in its entirety to BOOT_AFLAGS. # # That -include was added in commit 77433830ed16 ("powerpc: boot: include # compiler_attributes.h") so that we'd have "fallthrough" and other # attributes defined for the C files in arch/powerpc/boot. But it's not # needed for assembly files. # # The minimal fix is to move the addition to BOOT_CFLAGS of -include # compiler_attributes.h until after we've copied BOOT_CFLAGS into # BOOT_AFLAGS. That avoids including compiler_attributes.h for asm files, # but makes no other change to BOOT_CFLAGS or BOOT_AFLAGS. # # Reported-by: Stephen Rothwell # Debugged-by: Linus Torvalds # Signed-off-by: Michael Ellerman # Tested-by: Guenter Roeck # Signed-off-by: Linus Torvalds # < /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/hppa-linux/bin/hppa-linux-gcc --version # < /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/hppa-linux/bin/hppa-linux-ld --version # < git log --format=%s --max-count=1 1619b69edce14c4a4665fa8ff4c587dcc77202a9 # < make -s -j 32 ARCH=parisc O=/kisskb/build/linus_parisc-allmodconfig_parisc-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/hppa-linux/bin/hppa-linux- allmodconfig # Added to kconfig CONFIG_BUILD_DOCSRC=n # Added to kconfig CONFIG_MODULE_SIG=n # Added to kconfig CONFIG_SAMPLES=n # < make -s -j 32 ARCH=parisc O=/kisskb/build/linus_parisc-allmodconfig_parisc-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/hppa-linux/bin/hppa-linux- help # make -s -j 32 ARCH=parisc O=/kisskb/build/linus_parisc-allmodconfig_parisc-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/hppa-linux/bin/hppa-linux- olddefconfig # make -s -j 32 ARCH=parisc O=/kisskb/build/linus_parisc-allmodconfig_parisc-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/hppa-linux/bin/hppa-linux- /kisskb/src/lib/xxhash.c: In function 'xxh64': /kisskb/src/lib/xxhash.c:236:1: error: the frame size of 1624 bytes is larger than 1536 bytes [-Werror=frame-larger-than=] } ^ cc1: all warnings being treated as errors make[2]: *** [/kisskb/src/scripts/Makefile.build:277: lib/xxhash.o] Error 1 make[1]: *** [/kisskb/src/Makefile:1868: lib] Error 2 make[1]: *** Waiting for unfinished jobs.... /kisskb/src/drivers/spi/spi-tegra20-slink.c:1200:12: error: 'tegra_slink_runtime_resume' defined but not used [-Werror=unused-function] static int tegra_slink_runtime_resume(struct device *dev) ^~~~~~~~~~~~~~~~~~~~~~~~~~ /kisskb/src/drivers/spi/spi-tegra20-slink.c:1188:12: error: 'tegra_slink_runtime_suspend' defined but not used [-Werror=unused-function] static int tegra_slink_runtime_suspend(struct device *dev) ^~~~~~~~~~~~~~~~~~~~~~~~~~~ cc1: all warnings being treated as errors make[3]: *** [/kisskb/src/scripts/Makefile.build:277: drivers/spi/spi-tegra20-slink.o] Error 1 make[3]: *** Waiting for unfinished jobs.... make[2]: *** [/kisskb/src/scripts/Makefile.build:540: drivers/spi] Error 2 make[2]: *** Waiting for unfinished jobs.... In file included from /kisskb/src/drivers/net/phy/dp83640.c:23: /kisskb/src/drivers/net/phy/dp83640_reg.h:8: error: "PAGE0" redefined [-Werror] #define PAGE0 0x0000 In file included from /kisskb/src/include/linux/mm_types_task.h:16, from /kisskb/src/include/linux/mm_types.h:5, from /kisskb/src/include/linux/mmzone.h:21, from /kisskb/src/include/linux/gfp.h:6, from /kisskb/src/include/linux/xarray.h:14, from /kisskb/src/include/linux/radix-tree.h:19, from /kisskb/src/include/linux/fs.h:15, from /kisskb/src/include/linux/compat.h:17, from /kisskb/src/include/linux/ethtool.h:17, from /kisskb/src/drivers/net/phy/dp83640.c:11: /kisskb/src/arch/parisc/include/asm/page.h:187: note: this is the location of the previous definition #define PAGE0 ((struct zeropage *)__PAGE_OFFSET) cc1: all warnings being treated as errors make[4]: *** [/kisskb/src/scripts/Makefile.build:277: drivers/net/phy/dp83640.o] Error 1 make[4]: *** Waiting for unfinished jobs.... make[3]: *** [/kisskb/src/scripts/Makefile.build:540: drivers/net/phy] Error 2 make[2]: *** [/kisskb/src/scripts/Makefile.build:540: drivers/net] Error 2 /kisskb/src/drivers/gpu/drm/rockchip/cdn-dp-core.c:1126:12: error: 'cdn_dp_resume' defined but not used [-Werror=unused-function] static int cdn_dp_resume(struct device *dev) ^~~~~~~~~~~~~ cc1: all warnings being treated as errors make[5]: *** [/kisskb/src/scripts/Makefile.build:277: drivers/gpu/drm/rockchip/cdn-dp-core.o] Error 1 make[5]: *** Waiting for unfinished jobs.... make[4]: *** [/kisskb/src/scripts/Makefile.build:540: drivers/gpu/drm/rockchip] Error 2 make[4]: *** Waiting for unfinished jobs.... /kisskb/src/drivers/scsi/ncr53c8xx.c:8000:26: error: 'retrieve_from_waiting_list' defined but not used [-Werror=unused-function] static struct scsi_cmnd *retrieve_from_waiting_list(int to_remove, struct ncb *np, struct scsi_cmnd *cmd) ^~~~~~~~~~~~~~~~~~~~~~~~~~ cc1: all warnings being treated as errors make[3]: *** [/kisskb/src/scripts/Makefile.build:277: drivers/scsi/ncr53c8xx.o] Error 1 make[3]: *** Waiting for unfinished jobs.... make[2]: *** [/kisskb/src/scripts/Makefile.build:540: drivers/scsi] Error 2 /kisskb/src/drivers/gpu/drm/nouveau/nvkm/engine/device/ctrl.c: In function 'nvkm_control_mthd_pstate_info': /kisskb/src/drivers/gpu/drm/nouveau/nvkm/engine/device/ctrl.c:60:21: error: overflow in conversion from 'int' to '__s8' {aka 'signed char'} changes value from '-251' to '5' [-Werror=overflow] args->v0.pwrsrc = -ENOSYS; ^ cc1: all warnings being treated as errors make[5]: *** [/kisskb/src/scripts/Makefile.build:277: drivers/gpu/drm/nouveau/nvkm/engine/device/ctrl.o] Error 1 make[5]: *** Waiting for unfinished jobs.... make[4]: *** [/kisskb/src/scripts/Makefile.build:540: drivers/gpu/drm/nouveau] Error 2 make[3]: *** [/kisskb/src/scripts/Makefile.build:540: drivers/gpu/drm] Error 2 make[2]: *** [/kisskb/src/scripts/Makefile.build:540: drivers/gpu] Error 2 make[1]: *** [/kisskb/src/Makefile:1868: drivers] Error 2 make: *** [Makefile:219: __sub-make] Error 2 Command 'make -s -j 32 ARCH=parisc O=/kisskb/build/linus_parisc-allmodconfig_parisc-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/hppa-linux/bin/hppa-linux- ' returned non-zero exit status 2 # rm -rf /kisskb/build/linus_parisc-allmodconfig_parisc-gcc8 # Build took: 0:10:42.489837