# git rev-parse -q --verify ab6aaea6835b5d6da15f4d14d4af8b1a9a1c609b^{commit} ab6aaea6835b5d6da15f4d14d4af8b1a9a1c609b already have revision, skipping fetch # git checkout -q -f -B kisskb ab6aaea6835b5d6da15f4d14d4af8b1a9a1c609b # git clean -qxdf # < git log -1 # commit ab6aaea6835b5d6da15f4d14d4af8b1a9a1c609b # Author: Masahiro Yamada # Date: Thu Jul 4 22:13:58 2024 +0900 # # kbuild: avoid build error when single DTB is turned into composite DTB # # As commit afa974b77128 ("kbuild: add real-prereqs shorthand for # $(filter-out FORCE,$^)") explained, $(real-prereqs) is not just a list # of objects when linking a multi-object module. If a single-object module # is turned into a multi-object module, $^ (and therefore $(real-prereqs) # as well) contains header files recorded in the *.cmd file. Such headers # must be filtered out. # # Now that a DTB can be built either from a single source or multiple # source files, the same issue can occur. # # Consider the following scenario: # # First, foo.dtb is implemented as a single-blob device tree. # # The code looks something like this: # # [Sample Code 1] # # Makefile: # # dtb-y += foo.dtb # # foo.dts: # # #include # /dts-v1/; # / { }; # # When it is compiled, .foo.dtb.cmd records that foo.dtb depends on # scripts/dtc/include-prefixes/dt-bindings/gpio/gpio.h. # # Later, foo.dtb is split into a base and an overlay. The code looks # something like this: # # [Sample Code 2] # # Makefile: # # dtb-y += foo.dtb # foo-dtbs := foo-base.dtb foo-addon.dtbo # # foo-base.dts: # # #include # /dts-v1/; # / { }; # # foo-addon.dtso: # # /dts-v1/; # /plugin/; # / { }; # # If you rebuild foo.dtb without 'make clean', you will get this error: # # Overlay 'scripts/dtc/include-prefixes/dt-bindings/gpio/gpio.h' is incomplete # # $(real-prereqs) contains not only foo-base.dtb and foo-addon.dtbo but # also scripts/dtc/include-prefixes/dt-bindings/gpio/gpio.h, which is # passed to scripts/dtc/fdtoverlay. # # Fixes: 15d16d6dadf6 ("kbuild: Add generic rule to apply fdtoverlay") # Signed-off-by: Masahiro Yamada # < /opt/cross/kisskb/korg/gcc-13.1.0-nolibc/sparc64-linux/bin/sparc64-linux-gcc --version # < /opt/cross/kisskb/korg/gcc-13.1.0-nolibc/sparc64-linux/bin/sparc64-linux-ld --version # < git log --format=%s --max-count=1 ab6aaea6835b5d6da15f4d14d4af8b1a9a1c609b # make -s -j 160 ARCH=sparc64 O=/kisskb/build/kbuild_defconfig_sparc64-gcc13 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-13.1.0-nolibc/sparc64-linux/bin/sparc64-linux- defconfig # < make -s -j 160 ARCH=sparc64 O=/kisskb/build/kbuild_defconfig_sparc64-gcc13 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-13.1.0-nolibc/sparc64-linux/bin/sparc64-linux- help # make -s -j 160 ARCH=sparc64 O=/kisskb/build/kbuild_defconfig_sparc64-gcc13 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-13.1.0-nolibc/sparc64-linux/bin/sparc64-linux- olddefconfig # make -s -j 160 ARCH=sparc64 O=/kisskb/build/kbuild_defconfig_sparc64-gcc13 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-13.1.0-nolibc/sparc64-linux/bin/sparc64-linux- :1519:2: warning: #warning syscall clone3 not implemented [-Wcpp] /kisskb/src/arch/sparc/prom/misc_64.c:165:5: warning: no previous prototype for 'prom_get_mmu_ihandle' [-Wmissing-prototypes] 165 | int prom_get_mmu_ihandle(void) | ^~~~~~~~~~~~~~~~~~~~ /kisskb/src/arch/sparc/prom/p1275.c:52:6: warning: no previous prototype for 'prom_cif_init' [-Wmissing-prototypes] 52 | void prom_cif_init(void *cif_handler, void *cif_stack) | ^~~~~~~~~~~~~ /kisskb/src/arch/sparc/vdso/vclock_gettime.c:254:1: warning: no previous prototype for '__vdso_clock_gettime' [-Wmissing-prototypes] 254 | __vdso_clock_gettime(clockid_t clock, struct __kernel_old_timespec *ts) | ^~~~~~~~~~~~~~~~~~~~ /kisskb/src/arch/sparc/vdso/vclock_gettime.c:282:1: warning: no previous prototype for '__vdso_clock_gettime_stick' [-Wmissing-prototypes] 282 | __vdso_clock_gettime_stick(clockid_t clock, struct __kernel_old_timespec *ts) | ^~~~~~~~~~~~~~~~~~~~~~~~~~ /kisskb/src/arch/sparc/vdso/vclock_gettime.c:307:1: warning: no previous prototype for '__vdso_gettimeofday' [-Wmissing-prototypes] 307 | __vdso_gettimeofday(struct __kernel_old_timeval *tv, struct timezone *tz) | ^~~~~~~~~~~~~~~~~~~ /kisskb/src/arch/sparc/vdso/vclock_gettime.c:343:1: warning: no previous prototype for '__vdso_gettimeofday_stick' [-Wmissing-prototypes] 343 | __vdso_gettimeofday_stick(struct __kernel_old_timeval *tv, struct timezone *tz) | ^~~~~~~~~~~~~~~~~~~~~~~~~ In file included from /kisskb/src/arch/sparc/vdso/vdso32/vclock_gettime.c:22: /kisskb/src/arch/sparc/vdso/vdso32/../vclock_gettime.c:254:1: warning: no previous prototype for '__vdso_clock_gettime' [-Wmissing-prototypes] 254 | __vdso_clock_gettime(clockid_t clock, struct __kernel_old_timespec *ts) | ^~~~~~~~~~~~~~~~~~~~ /kisskb/src/arch/sparc/vdso/vdso32/../vclock_gettime.c:282:1: warning: no previous prototype for '__vdso_clock_gettime_stick' [-Wmissing-prototypes] 282 | __vdso_clock_gettime_stick(clockid_t clock, struct __kernel_old_timespec *ts) | ^~~~~~~~~~~~~~~~~~~~~~~~~~ /kisskb/src/arch/sparc/vdso/vdso32/../vclock_gettime.c:307:1: warning: no previous prototype for '__vdso_gettimeofday' [-Wmissing-prototypes] 307 | __vdso_gettimeofday(struct __kernel_old_timeval *tv, struct timezone *tz) | ^~~~~~~~~~~~~~~~~~~ /kisskb/src/arch/sparc/vdso/vdso32/../vclock_gettime.c:343:1: warning: no previous prototype for '__vdso_gettimeofday_stick' [-Wmissing-prototypes] 343 | __vdso_gettimeofday_stick(struct __kernel_old_timeval *tv, struct timezone *tz) | ^~~~~~~~~~~~~~~~~~~~~~~~~ /opt/cross/kisskb/korg/gcc-13.1.0-nolibc/sparc64-linux/bin/sparc64-linux-ld: warning: arch/sparc/vdso/vdso-note.o: missing .note.GNU-stack section implies executable stack /opt/cross/kisskb/korg/gcc-13.1.0-nolibc/sparc64-linux/bin/sparc64-linux-ld: NOTE: This behaviour is deprecated and will be removed in a future version of the linker /opt/cross/kisskb/korg/gcc-13.1.0-nolibc/sparc64-linux/bin/sparc64-linux-ld: warning: arch/sparc/vdso/vdso32/vdso-note.o: missing .note.GNU-stack section implies executable stack /opt/cross/kisskb/korg/gcc-13.1.0-nolibc/sparc64-linux/bin/sparc64-linux-ld: NOTE: This behaviour is deprecated and will be removed in a future version of the linker WARNING: modpost: EXPORT symbol "_mcount" [vmlinux] version generation failed, symbol will not be versioned. Is "_mcount" prototyped in ? Completed OK # rm -rf /kisskb/build/kbuild_defconfig_sparc64-gcc13 # Build took: 0:00:47.233211