u-boot icon indicating copy to clipboard operation
u-boot copied to clipboard

error: 'hdmi_len' may be used uninitialized

Open KubaPro010 opened this issue 1 year ago • 1 comments

cant compile:

cloned this ran make rk3128_config ran make CROSS_COMPILE=arm-linux-gnueabi-

result:

  CHK     include/config/uboot.release
  CHK     include/generated/version_autogenerated.h
  CHK     include/generated/timestamp_autogenerated.h
  UPD     include/generated/timestamp_autogenerated.h
  CHK     include/generated/generic-asm-offsets.h
  CHK     include/generated/asm-offsets.h
  HOSTCC  tools/mkenvimage.o
  HOSTLD  tools/mkenvimage
  HOSTCC  tools/fit_image.o
  HOSTCC  tools/image-host.o
  HOSTCC  tools/dumpimage.o
  HOSTLD  tools/dumpimage
  HOSTCC  tools/mkimage.o
  HOSTLD  tools/mkimage
  CC      arch/arm/mach-rockchip/board.o
  LD      arch/arm/mach-rockchip/built-in.o
arm-linux-gnueabi-ld.bfd: warning: arch/arm/mach-rockchip/lowlevel_init.o: missing .note.GNU-stack section implies executable stack
arm-linux-gnueabi-ld.bfd: NOTE: This behaviour is deprecated and will be removed in a future version of the linker
  CC      cmd/version.o
  LD      cmd/built-in.o
  CC      common/main.o
  CC      common/edid.o
In function 'do_hdmi_vsdb_modes',
    inlined from 'add_cea_modes' at common/edid.c:3617:12,
    inlined from 'drm_add_edid_modes' at common/edid.c:5542:15:
common/edid.c:2934:17: error: 'hdmi_len' may be used uninitialized [-Werror=maybe-uninitialized]
 2934 |         if (len < (8 + offset + 2))
      |             ~~~~^~~~~~~~~~~~~~~~~~
common/edid.c: In function 'drm_add_edid_modes':
common/edid.c:3582:17: note: 'hdmi_len' was declared here
 3582 |         u8 dbl, hdmi_len, video_len = 0;
      |                 ^~~~~~~~
cc1: all warnings being treated as errors
make[1]: *** [scripts/Makefile.build:281: common/edid.o] Error 1
make: *** [Makefile:1314: common] Error 2

KubaPro010 avatar Oct 19 '24 19:10 KubaPro010