# git rev-parse -q --verify 7b50567bdcad8925ca1e075feb7171c12015afd1^{commit} 7b50567bdcad8925ca1e075feb7171c12015afd1 already have revision, skipping fetch # git checkout -q -f -B kisskb 7b50567bdcad8925ca1e075feb7171c12015afd1 # git clean -qxdf # < git log -1 # commit 7b50567bdcad8925ca1e075feb7171c12015afd1 # Author: Arnd Bergmann # Date: Tue Feb 7 17:13:12 2023 +0100 # # media: i2c: imx290: fix conditional function defintions # # The runtime suspend/resume functions are only referenced from the # dev_pm_ops, but they use the old SET_RUNTIME_PM_OPS() helper that # requires a __maybe_unused annotation to avoid a warning: # # drivers/media/i2c/imx290.c:1082:12: error: unused function 'imx290_runtime_resume' [-Werror,-Wunused-function] # static int imx290_runtime_resume(struct device *dev) # ^ # drivers/media/i2c/imx290.c:1090:12: error: unused function 'imx290_runtime_suspend' [-Werror,-Wunused-function] # static int imx290_runtime_suspend(struct device *dev) # ^ # # Convert this to the new RUNTIME_PM_OPS() helper that so this is not # required. To improve this further, also use the pm_ptr() helper that # lets the dev_pm_ops get dropped entirely when CONFIG_PM is disabled. # # A related mistake happened in the of_match_ptr() macro here, which like # SET_RUNTIME_PM_OPS() requires the match table to be marked as # __maybe_unused, though I could not reproduce building this without # CONFIG_OF. Remove the of_match_ptr() here as there is no point in # dropping the match table in configurations without CONFIG_OF. # # Fixes: 02852c01f654 ("media: i2c: imx290: Initialize runtime PM before subdev") # Signed-off-by: Arnd Bergmann # Reported-by: Guenter Roeck # Reported-by: Sudip Mukherjee # Reviewed-by: Manivannan Sadhasivam # Reviewed-by: Laurent Pinchart # Signed-off-by: Linus Torvalds # < /opt/cross/kisskb/korg/gcc-8.5.0-nolibc/m68k-linux/bin/m68k-linux-gcc --version # < /opt/cross/kisskb/korg/gcc-8.5.0-nolibc/m68k-linux/bin/m68k-linux-ld --version # < git log --format=%s --max-count=1 7b50567bdcad8925ca1e075feb7171c12015afd1 # < make -s -j 160 ARCH=m68k O=/kisskb/build/linus_m68k-allmodconfig_m68k-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.5.0-nolibc/m68k-linux/bin/m68k-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 160 ARCH=m68k O=/kisskb/build/linus_m68k-allmodconfig_m68k-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.5.0-nolibc/m68k-linux/bin/m68k-linux- help # make -s -j 160 ARCH=m68k O=/kisskb/build/linus_m68k-allmodconfig_m68k-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.5.0-nolibc/m68k-linux/bin/m68k-linux- olddefconfig # make -s -j 160 ARCH=m68k O=/kisskb/build/linus_m68k-allmodconfig_m68k-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.5.0-nolibc/m68k-linux/bin/m68k-linux- /kisskb/src/drivers/media/platform/nxp/imx-jpeg/mxc-jpeg.c: In function 'mxc_jpeg_dec_irq': /kisskb/src/drivers/media/platform/nxp/imx-jpeg/mxc-jpeg.c:641:28: error: array subscript 2 is above array bounds of 'u32[2]' {aka 'unsigned int[2]'} [-Werror=array-bounds] size += q_data->sizeimage[i]; ~~~~~~~~~~~~~~~~~^~~ /kisskb/src/drivers/media/platform/nxp/imx-jpeg/mxc-jpeg.c:641:28: error: array subscript 3 is above array bounds of 'u32[2]' {aka 'unsigned int[2]'} [-Werror=array-bounds] cc1: all warnings being treated as errors make[7]: *** [/kisskb/src/scripts/Makefile.build:252: drivers/media/platform/nxp/imx-jpeg/mxc-jpeg.o] Error 1 make[6]: *** [/kisskb/src/scripts/Makefile.build:494: drivers/media/platform/nxp/imx-jpeg] Error 2 make[5]: *** [/kisskb/src/scripts/Makefile.build:494: drivers/media/platform/nxp] Error 2 make[5]: *** Waiting for unfinished jobs.... make[4]: *** [/kisskb/src/scripts/Makefile.build:494: drivers/media/platform] Error 2 make[4]: *** Waiting for unfinished jobs.... make[3]: *** [/kisskb/src/scripts/Makefile.build:494: drivers/media] Error 2 make[3]: *** Waiting for unfinished jobs.... make[2]: *** [/kisskb/src/scripts/Makefile.build:494: drivers] Error 2 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [/kisskb/src/Makefile:2025: .] Error 2 make: *** [Makefile:226: __sub-make] Error 2 Command 'make -s -j 160 ARCH=m68k O=/kisskb/build/linus_m68k-allmodconfig_m68k-gcc8 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.5.0-nolibc/m68k-linux/bin/m68k-linux- ' returned non-zero exit status 2 # rm -rf /kisskb/build/linus_m68k-allmodconfig_m68k-gcc8 # Build took: 0:09:08.343073