drivers/media/platform/mediatek/jpeg/mtk_jpeg_core.c:1859:38: warning: unused variable 'mtk8195_jpegdec_drvdata'

From: kernel test robot
Date: Thu Feb 09 2023 - 07:11:01 EST


Hi kyrie,

FYI, the error/warning still remains.

tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 0983f6bf2bfc0789b51ddf7315f644ff4da50acb
commit: dedc21500334b97b80d4ca37ab683cde214fcb03 media: mtk-jpegdec: add jpeg decode worker interface
date: 4 months ago
config: mips-randconfig-r005-20230209 (https://download.01.org/0day-ci/archive/20230209/202302092008.IgpNeNCW-lkp@xxxxxxxxx/config)
compiler: clang version 17.0.0 (https://github.com/llvm/llvm-project db0e6591612b53910a1b366863348bdb9d7d2fb1)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# install mips cross compiling tool for clang build
# apt-get install binutils-mipsel-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=dedc21500334b97b80d4ca37ab683cde214fcb03
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout dedc21500334b97b80d4ca37ab683cde214fcb03
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=mips olddefconfig
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=mips SHELL=/bin/bash drivers/media/platform/mediatek/jpeg/ drivers/soc/renesas/

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@xxxxxxxxx>
| Link: https://lore.kernel.org/oe-kbuild-all/202302092008.IgpNeNCW-lkp@xxxxxxxxx

All warnings (new ones prefixed by >>):

drivers/media/platform/mediatek/jpeg/mtk_jpeg_core.c:1818:38: warning: unused variable 'mt8173_jpeg_drvdata' [-Wunused-const-variable]
static const struct mtk_jpeg_variant mt8173_jpeg_drvdata = {
^
drivers/media/platform/mediatek/jpeg/mtk_jpeg_core.c:1833:38: warning: unused variable 'mtk_jpeg_drvdata' [-Wunused-const-variable]
static const struct mtk_jpeg_variant mtk_jpeg_drvdata = {
^
drivers/media/platform/mediatek/jpeg/mtk_jpeg_core.c:1848:32: warning: unused variable 'mtk8195_jpegenc_drvdata' [-Wunused-variable]
static struct mtk_jpeg_variant mtk8195_jpegenc_drvdata = {
^
>> drivers/media/platform/mediatek/jpeg/mtk_jpeg_core.c:1859:38: warning: unused variable 'mtk8195_jpegdec_drvdata' [-Wunused-const-variable]
static const struct mtk_jpeg_variant mtk8195_jpegdec_drvdata = {
^
4 warnings generated.


vim +/mtk8195_jpegdec_drvdata +1859 drivers/media/platform/mediatek/jpeg/mtk_jpeg_core.c

1858
> 1859 static const struct mtk_jpeg_variant mtk8195_jpegdec_drvdata = {
1860 .formats = mtk_jpeg_dec_formats,
1861 .num_formats = MTK_JPEG_DEC_NUM_FORMATS,
1862 .qops = &mtk_jpeg_dec_qops,
1863 .m2m_ops = &mtk_jpeg_multicore_dec_m2m_ops,
1864 .dev_name = "mtk-jpeg-dec",
1865 .ioctl_ops = &mtk_jpeg_dec_ioctl_ops,
1866 .out_q_default_fourcc = V4L2_PIX_FMT_JPEG,
1867 .cap_q_default_fourcc = V4L2_PIX_FMT_YUV420M,
1868 };
1869

--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests