# git rev-parse -q --verify b12483618d73c954c00faa49c276b4d9995fb95a^{commit} b12483618d73c954c00faa49c276b4d9995fb95a already have revision, skipping fetch # git checkout -q -f -B kisskb b12483618d73c954c00faa49c276b4d9995fb95a # git clean -qxdf # < git log -1 # commit b12483618d73c954c00faa49c276b4d9995fb95a # Author: Michael Ellerman # Date: Thu Feb 18 23:30:58 2021 +1100 # # powerpc/4xx: Fix build errors from mfdcr() # # lkp reported a build error in fsp2.o: # # CC arch/powerpc/platforms/44x/fsp2.o # {standard input}:577: Error: unsupported relocation against base # # Which comes from: # # pr_err("GESR0: 0x%08x\n", mfdcr(base + PLB4OPB_GESR0)); # # Where our mfdcr() macro is stringifying "base + PLB4OPB_GESR0", and # passing that to the assembler, which obviously doesn't work. # # The mfdcr() macro already checks that the argument is constant using # __builtin_constant_p(), and if not calls the out-of-line version of # mfdcr(). But in this case GCC is smart enough to notice that "base + # PLB4OPB_GESR0" will be constant, even though it's not something we can # immediately stringify into a register number. # # Segher pointed out that passing the register number to the inline asm # as a constant would be better, and in fact it fixes the build error, # presumably because it gives GCC a chance to resolve the value. # # While we're at it, change mtdcr() similarly. # # Reported-by: kernel test robot # Suggested-by: Segher Boessenkool # Signed-off-by: Michael Ellerman # Acked-by: Feng Tang # Link: https://lore.kernel.org/r/20210218123058.748882-1-mpe@ellerman.id.au # < /opt/cross/kisskb/korg/gcc-4.9.4-nolibc/ia64-linux/bin/ia64-linux-gcc --version # < /opt/cross/kisskb/korg/gcc-4.9.4-nolibc/ia64-linux/bin/ia64-linux-ld --version # < git log --format=%s --max-count=1 b12483618d73c954c00faa49c276b4d9995fb95a # < make -s -j 48 ARCH=ia64 O=/kisskb/build/powerpc-next_ia64-defconfig_ia64-gcc4.9 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-4.9.4-nolibc/ia64-linux/bin/ia64-linux- defconfig arch/ia64/configs/generic_defconfig:58:warning: override: reassigning to symbol ATA arch/ia64/configs/generic_defconfig:59:warning: override: reassigning to symbol ATA_PIIX # < make -s -j 48 ARCH=ia64 O=/kisskb/build/powerpc-next_ia64-defconfig_ia64-gcc4.9 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-4.9.4-nolibc/ia64-linux/bin/ia64-linux- help # make -s -j 48 ARCH=ia64 O=/kisskb/build/powerpc-next_ia64-defconfig_ia64-gcc4.9 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-4.9.4-nolibc/ia64-linux/bin/ia64-linux- olddefconfig # make -s -j 48 ARCH=ia64 O=/kisskb/build/powerpc-next_ia64-defconfig_ia64-gcc4.9 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-4.9.4-nolibc/ia64-linux/bin/ia64-linux- :1511:2: warning: #warning syscall clone3 not implemented [-Wcpp] In file included from /kisskb/src/include/linux/numa.h:25:0, from /kisskb/src/include/linux/async.h:13, from /kisskb/src/kernel/async.c:47: /kisskb/src/arch/ia64/include/asm/sparsemem.h:14:40: warning: "PAGE_SHIFT" is not defined [-Wundef] #if ((CONFIG_FORCE_MAX_ZONEORDER - 1 + PAGE_SHIFT) > SECTION_SIZE_BITS) ^ In file included from /kisskb/src/include/linux/gfp.h:6:0, from /kisskb/src/include/linux/xarray.h:14, from /kisskb/src/include/linux/radix-tree.h:19, from /kisskb/src/include/linux/idr.h:15, from /kisskb/src/include/linux/kernfs.h:13, from /kisskb/src/include/linux/sysfs.h:16, from /kisskb/src/include/linux/kobject.h:20, from /kisskb/src/include/linux/energy_model.h:7, from /kisskb/src/include/linux/device.h:16, from /kisskb/src/include/linux/async.h:14, from /kisskb/src/kernel/async.c:47: /kisskb/src/include/linux/mmzone.h:1156:2: error: #error Allocator MAX_ORDER exceeds SECTION_SIZE #error Allocator MAX_ORDER exceeds SECTION_SIZE ^ make[2]: *** [/kisskb/src/scripts/Makefile.build:279: kernel/async.o] Error 1 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [/kisskb/src/Makefile:1805: kernel] Error 2 make[1]: *** Waiting for unfinished jobs.... In file included from /kisskb/src/include/linux/numa.h:25:0, from /kisskb/src/include/linux/async.h:13, from /kisskb/src/drivers/acpi/battery.c:13: /kisskb/src/arch/ia64/include/asm/sparsemem.h:14:40: warning: "PAGE_SHIFT" is not defined [-Wundef] #if ((CONFIG_FORCE_MAX_ZONEORDER - 1 + PAGE_SHIFT) > SECTION_SIZE_BITS) ^ In file included from /kisskb/src/include/linux/gfp.h:6:0, from /kisskb/src/include/linux/xarray.h:14, from /kisskb/src/include/linux/radix-tree.h:19, from /kisskb/src/include/linux/idr.h:15, from /kisskb/src/include/linux/kernfs.h:13, from /kisskb/src/include/linux/sysfs.h:16, from /kisskb/src/include/linux/kobject.h:20, from /kisskb/src/include/linux/energy_model.h:7, from /kisskb/src/include/linux/device.h:16, from /kisskb/src/include/linux/async.h:14, from /kisskb/src/drivers/acpi/battery.c:13: /kisskb/src/include/linux/mmzone.h:1156:2: error: #error Allocator MAX_ORDER exceeds SECTION_SIZE #error Allocator MAX_ORDER exceeds SECTION_SIZE ^ In file included from /kisskb/src/include/linux/numa.h:25:0, from /kisskb/src/include/linux/nodemask.h:96, from /kisskb/src/lib/nodemask.c:2: /kisskb/src/arch/ia64/include/asm/sparsemem.h:14:40: warning: "PAGE_SHIFT" is not defined [-Wundef] #if ((CONFIG_FORCE_MAX_ZONEORDER - 1 + PAGE_SHIFT) > SECTION_SIZE_BITS) ^ In file included from /kisskb/src/include/linux/gfp.h:6:0, from /kisskb/src/include/linux/umh.h:4, from /kisskb/src/include/linux/kmod.h:9, from /kisskb/src/include/linux/module.h:16, from /kisskb/src/lib/nodemask.c:3: /kisskb/src/include/linux/mmzone.h:1156:2: error: #error Allocator MAX_ORDER exceeds SECTION_SIZE #error Allocator MAX_ORDER exceeds SECTION_SIZE ^ make[3]: *** [/kisskb/src/scripts/Makefile.build:279: drivers/acpi/battery.o] Error 1 make[3]: *** Waiting for unfinished jobs.... make[2]: *** [/kisskb/src/scripts/Makefile.build:279: lib/nodemask.o] Error 1 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [/kisskb/src/Makefile:1805: lib] Error 2 In file included from /kisskb/src/include/linux/numa.h:25:0, from /kisskb/src/include/linux/async.h:13, from /kisskb/src/drivers/base/bus.c:11: /kisskb/src/arch/ia64/include/asm/sparsemem.h:14:40: warning: "PAGE_SHIFT" is not defined [-Wundef] #if ((CONFIG_FORCE_MAX_ZONEORDER - 1 + PAGE_SHIFT) > SECTION_SIZE_BITS) ^ In file included from /kisskb/src/include/linux/gfp.h:6:0, from /kisskb/src/include/linux/xarray.h:14, from /kisskb/src/include/linux/radix-tree.h:19, from /kisskb/src/include/linux/idr.h:15, from /kisskb/src/include/linux/kernfs.h:13, from /kisskb/src/include/linux/sysfs.h:16, from /kisskb/src/include/linux/kobject.h:20, from /kisskb/src/include/linux/energy_model.h:7, from /kisskb/src/include/linux/device.h:16, from /kisskb/src/include/linux/async.h:14, from /kisskb/src/drivers/base/bus.c:11: /kisskb/src/include/linux/mmzone.h:1156:2: error: #error Allocator MAX_ORDER exceeds SECTION_SIZE #error Allocator MAX_ORDER exceeds SECTION_SIZE ^ make[3]: *** [/kisskb/src/scripts/Makefile.build:279: drivers/base/bus.o] Error 1 make[3]: *** Waiting for unfinished jobs.... make[2]: *** [/kisskb/src/scripts/Makefile.build:496: drivers/base] Error 2 make[2]: *** Waiting for unfinished jobs.... In file included from /kisskb/src/arch/ia64/include/uapi/asm/intrinsics.h:22:0, from /kisskb/src/arch/ia64/include/asm/intrinsics.h:11, from /kisskb/src/arch/ia64/include/asm/timex.h:14, from /kisskb/src/include/linux/timex.h:65, from /kisskb/src/include/linux/time32.h:13, from /kisskb/src/include/linux/time.h:60, from /kisskb/src/fs/nfs/read.c:11: /kisskb/src/fs/nfs/read.c: In function 'nfs_read_completion': /kisskb/src/arch/ia64/include/uapi/asm/cmpxchg.h:57:2: warning: value computed is not used [-Wunused-value] ((__typeof__(*(ptr))) __xchg((unsigned long) (x), (ptr), sizeof(*(ptr)))) ^ /kisskb/src/fs/nfs/read.c:196:5: note: in expansion of macro 'xchg' xchg(&nfs_req_openctx(req)->error, error); ^ /kisskb/src/fs/nfs/read.c: In function 'nfs_readpage': /kisskb/src/arch/ia64/include/uapi/asm/cmpxchg.h:57:2: warning: value computed is not used [-Wunused-value] ((__typeof__(*(ptr))) __xchg((unsigned long) (x), (ptr), sizeof(*(ptr)))) ^ /kisskb/src/fs/nfs/read.c:355:2: note: in expansion of macro 'xchg' xchg(&ctx->error, 0); ^ In file included from /kisskb/src/include/linux/numa.h:25:0, from /kisskb/src/include/linux/nodemask.h:96, from /kisskb/src/include/linux/mount.h:15, from /kisskb/src/fs/pnode.c:9: /kisskb/src/arch/ia64/include/asm/sparsemem.h:14:40: warning: "PAGE_SHIFT" is not defined [-Wundef] #if ((CONFIG_FORCE_MAX_ZONEORDER - 1 + PAGE_SHIFT) > SECTION_SIZE_BITS) ^ In file included from /kisskb/src/include/linux/gfp.h:6:0, 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/fs/pnode.c:10: /kisskb/src/include/linux/mmzone.h:1156:2: error: #error Allocator MAX_ORDER exceeds SECTION_SIZE #error Allocator MAX_ORDER exceeds SECTION_SIZE ^ In file included from /kisskb/src/include/linux/numa.h:25:0, from /kisskb/src/include/linux/nodemask.h:96, from /kisskb/src/include/linux/mount.h:15, from /kisskb/src/fs/utimes.c:3: /kisskb/src/arch/ia64/include/asm/sparsemem.h:14:40: warning: "PAGE_SHIFT" is not defined [-Wundef] #if ((CONFIG_FORCE_MAX_ZONEORDER - 1 + PAGE_SHIFT) > SECTION_SIZE_BITS) ^ make[2]: *** [/kisskb/src/scripts/Makefile.build:279: fs/pnode.o] Error 1 make[2]: *** Waiting for unfinished jobs.... In file included from /kisskb/src/include/linux/gfp.h:6:0, 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/namei.h:5, from /kisskb/src/fs/utimes.c:4: /kisskb/src/include/linux/mmzone.h:1156:2: error: #error Allocator MAX_ORDER exceeds SECTION_SIZE #error Allocator MAX_ORDER exceeds SECTION_SIZE ^ make[2]: *** [/kisskb/src/scripts/Makefile.build:279: fs/utimes.o] Error 1 make[1]: *** [/kisskb/src/Makefile:1805: fs] Error 2 make[2]: *** [/kisskb/src/scripts/Makefile.build:496: drivers/acpi] Error 2 make[1]: *** [/kisskb/src/Makefile:1805: drivers] Error 2 make: *** [Makefile:185: __sub-make] Error 2 Command 'make -s -j 48 ARCH=ia64 O=/kisskb/build/powerpc-next_ia64-defconfig_ia64-gcc4.9 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-4.9.4-nolibc/ia64-linux/bin/ia64-linux- ' returned non-zero exit status 2 # rm -rf /kisskb/build/powerpc-next_ia64-defconfig_ia64-gcc4.9 # Build took: 0:01:44.254510