Hi Thomas Media-CI has found a couple of new warnings in the latest kernel version for aarch64 and powerpc. They get fixed with this patch and before moving I wanted to know if this was under your radar.
diff --git a/arch/arm64/kernel/vdso/Makefile b/arch/arm64/kernel/vdso/Makefile index 7dec05dd33b7..65914842fae0 100644 --- a/arch/arm64/kernel/vdso/Makefile +++ b/arch/arm64/kernel/vdso/Makefile @@ -50,7 +50,7 @@ CFLAGS_vgettimeofday.o = $(CC_FLAGS_ADD_VDSO) CFLAGS_vgetrandom.o = $(CC_FLAGS_ADD_VDSO) ifneq ($(c-gettimeofday-y),) - CFLAGS_vgettimeofday.o += -include $(c-gettimeofday-y) + CFLAGS_vgettimeofday.o += -include $(c-gettimeofday-y) -Wno-maybe-uninitialized endif ifneq ($(c-getrandom-y),) diff --git a/arch/powerpc/kernel/vdso/Makefile b/arch/powerpc/kernel/vdso/Makefile index 8834dfe9d727..4b8d40b1dfeb 100644 --- a/arch/powerpc/kernel/vdso/Makefile +++ b/arch/powerpc/kernel/vdso/Makefile @@ -12,12 +12,12 @@ obj-vdso32 += getrandom-32.o vgetrandom-chacha-32.o obj-vdso64 += getrandom-64.o vgetrandom-chacha-64.o ifneq ($(c-gettimeofday-y),) - CFLAGS_vgettimeofday-32.o += -include $(c-gettimeofday-y) + CFLAGS_vgettimeofday-32.o += -include $(c-gettimeofday-y) -Wno-maybe-uninitialized # Go prior to 1.16.x assumes r30 is not clobbered by any VDSO code. That used to be true # by accident when the VDSO was hand-written asm code, but may not be now that the VDSO is # compiler generated. To avoid breaking Go tell GCC not to use r30. Impact on code # generation is minimal, it will just use r29 instead. - CFLAGS_vgettimeofday-64.o += -include $(c-gettimeofday-y) $(call cc-option, -ffixed-r30) + CFLAGS_vgettimeofday-64.o += -include $(c-gettimeofday-y) $(call cc-option, -ffixed-r30) -Wno-maybe-uninitialized endif ifneq ($(c-getrandom-y),) https://gitlab.freedesktop.org/linux-media/users/ribalda/-/pipelines/1649144/test_report?job_name=cross-gcc CONFIG_CC_VERSION_TEXT="aarch64-linux-gnu-gcc (Debian 15.2.0-16) 15.2.0" SYNC include/config/auto.conf CC arch/arm64/kernel/vdso/vgettimeofday.o In file included from <command-line>: In function ‘vdso_set_timespec’, inlined from ‘do_aux’ at /workdir/lib/vdso/gettimeofday.c:266:2, inlined from ‘__cvdso_clock_gettime_common’ at /workdir/lib/vdso/gettimeofday.c:293:10, inlined from ‘__cvdso_clock_gettime_data.constprop’ at /workdir/lib/vdso/gettimeofday.c:306:7: /workdir/lib/vdso/gettimeofday.c:104:26: warning: ‘sec’ may be used uninitialized [-Wmaybe-uninitialized] 104 | ts->tv_sec = sec + __iter_div_u64_rem(ns, NSEC_PER_SEC, &ns); | ~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /workdir/lib/vdso/gettimeofday.c: In function ‘__cvdso_clock_gettime_data.constprop’: /workdir/lib/vdso/gettimeofday.c:242:13: note: ‘sec’ was declared here 242 | u64 sec, ns; | ^~~ In file included from /workdir/lib/vdso/gettimeofday.c:11: In function ‘__iter_div_u64_rem’, inlined from ‘vdso_set_timespec’ at /workdir/lib/vdso/gettimeofday.c:104:21, inlined from ‘do_aux’ at /workdir/lib/vdso/gettimeofday.c:266:2, inlined from ‘__cvdso_clock_gettime_common’ at /workdir/lib/vdso/gettimeofday.c:293:10, inlined from ‘__cvdso_clock_gettime_data.constprop’ at /workdir/lib/vdso/gettimeofday.c:306:7: ./include/vdso/math64.h:10:25: warning: ‘ns’ may be used uninitialized [-Wmaybe-uninitialized] 10 | while (dividend >= divisor) { | ~~~~~~~~~^~~~~~~~~~ /workdir/lib/vdso/gettimeofday.c: In function ‘__cvdso_clock_gettime_data.constprop’: /workdir/lib/vdso/gettimeofday.c:242:18: note: ‘ns’ was declared here 242 | u64 sec, ns; | ^~ LD arch/arm64/kernel/vdso/vdso.so.dbg VDSOSYM include/generated/vdso-offsets.h OBJCOPY arch/arm64/kernel/vdso/vdso.so /workdir/lib/vdso/gettimeofday.c:104:26: warning: ‘sec’ may be used uninitialized [-Wmaybe-uninitialized] ./include/vdso/math64.h:10:25: warning: ‘ns’ may be used uninitialized [-Wmaybe-uninitialized] CONFIG_CC_VERSION_TEXT="powerpc64-linux-gnu-gcc (Debian 15.2.0-15) 15.2.0" SYNC include/config/auto.conf VDSO32C arch/powerpc/kernel/vdso/vgettimeofday-32.o In file included from <command-line>: In function ‘vdso_set_timespec’, inlined from ‘do_aux’ at /workdir/lib/vdso/gettimeofday.c:266:2, inlined from ‘__cvdso_clock_gettime_common’ at /workdir/lib/vdso/gettimeofday.c:293:10, inlined from ‘__cvdso_clock_gettime32_data’ at /workdir/lib/vdso/gettimeofday.c:327:7: /workdir/lib/vdso/gettimeofday.c:104:26: warning: ‘sec’ may be used uninitialized [-Wmaybe-uninitialized] 104 | ts->tv_sec = sec + __iter_div_u64_rem(ns, NSEC_PER_SEC, &ns); | ~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /workdir/lib/vdso/gettimeofday.c: In function ‘__cvdso_clock_gettime32_data’: /workdir/lib/vdso/gettimeofday.c:242:13: note: ‘sec’ was declared here 242 | u64 sec, ns; | ^~~ In file included from /workdir/lib/vdso/gettimeofday.c:11: In function ‘__iter_div_u64_rem’, inlined from ‘vdso_set_timespec’ at /workdir/lib/vdso/gettimeofday.c:104:21, inlined from ‘do_aux’ at /workdir/lib/vdso/gettimeofday.c:266:2, inlined from ‘__cvdso_clock_gettime_common’ at /workdir/lib/vdso/gettimeofday.c:293:10, inlined from ‘__cvdso_clock_gettime32_data’ at /workdir/lib/vdso/gettimeofday.c:327:7: ./include/vdso/math64.h:10:25: warning: ‘ns’ may be used uninitialized [-Wmaybe-uninitialized] 10 | while (dividend >= divisor) { | ~~~~~~~~~^~~~~~~~~~ /workdir/lib/vdso/gettimeofday.c: In function ‘__cvdso_clock_gettime32_data’: /workdir/lib/vdso/gettimeofday.c:242:18: note: ‘ns’ was declared here 242 | u64 sec, ns; | ^~ In function ‘vdso_set_timespec’, inlined from ‘do_aux’ at /workdir/lib/vdso/gettimeofday.c:266:2, inlined from ‘__cvdso_clock_gettime_common’ at /workdir/lib/vdso/gettimeofday.c:293:10, inlined from ‘__cvdso_clock_gettime_data’ at /workdir/lib/vdso/gettimeofday.c:306:7: /workdir/lib/vdso/gettimeofday.c:104:26: warning: ‘sec’ may be used uninitialized [-Wmaybe-uninitialized] 104 | ts->tv_sec = sec + __iter_div_u64_rem(ns, NSEC_PER_SEC, &ns); | ~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /workdir/lib/vdso/gettimeofday.c: In function ‘__cvdso_clock_gettime_data’: /workdir/lib/vdso/gettimeofday.c:242:13: note: ‘sec’ was declared here 242 | u64 sec, ns; | ^~~ In function ‘__iter_div_u64_rem’, inlined from ‘vdso_set_timespec’ at /workdir/lib/vdso/gettimeofday.c:104:21, inlined from ‘do_aux’ at /workdir/lib/vdso/gettimeofday.c:266:2, inlined from ‘__cvdso_clock_gettime_common’ at /workdir/lib/vdso/gettimeofday.c:293:10, inlined from ‘__cvdso_clock_gettime_data’ at /workdir/lib/vdso/gettimeofday.c:306:7: ./include/vdso/math64.h:10:25: warning: ‘ns’ may be used uninitialized [-Wmaybe-uninitialized] 10 | while (dividend >= divisor) { | ~~~~~~~~~^~~~~~~~~~ /workdir/lib/vdso/gettimeofday.c: In function ‘__cvdso_clock_gettime_data’: /workdir/lib/vdso/gettimeofday.c:242:18: note: ‘ns’ was declared here 242 | u64 sec, ns; | ^~ VDSO32L arch/powerpc/kernel/vdso/vdso32.so.dbg VDSO32SYM include/generated/vdso32-offsets.h CC arch/powerpc/kernel/vdso/vgettimeofday-64.o VDSO64L arch/powerpc/kernel/vdso/vdso64.so.dbg VDSO64SYM include/generated/vdso64-offsets.h /workdir/lib/vdso/gettimeofday.c:104:26: warning: ‘sec’ may be used uninitialized [-Wmaybe-uninitialized] ./include/vdso/math64.h:10:25: warning: ‘ns’ may be used uninitialized [-Wmaybe-uninitialized] /workdir/lib/vdso/gettimeofday.c:104:26: warning: ‘sec’ may be used uninitialized [-Wmaybe-uninitialized] ./include/vdso/math64.h:10:25: warning: ‘ns’ may be used uninitialized [-Wmaybe-uninitialized] Thanks -- Ricardo Ribalda
