Re: [PATCH v4 2/3] media: rockchip: Introduce driver for Rockhip's camera interface

From: kernel test robot
Date: Wed Dec 09 2020 - 18:28:00 EST


Hi Maxime,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on rockchip/for-next]
[also build test WARNING on robh/for-next v5.10-rc7 next-20201209]
[cannot apply to linuxtv-media/master]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url: https://github.com/0day-ci/linux/commits/Maxime-Chevallier/media-rockchip-Introduce-driver-for-Rockchip-s-camera-interface/20201209-002715
base: https://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip.git for-next
config: arc-randconfig-r032-20201209 (attached as .config)
compiler: arceb-elf-gcc (GCC) 9.3.0
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
# https://github.com/0day-ci/linux/commit/8c74146ec237f44d2b5f26a38765e1d2948035d3
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Maxime-Chevallier/media-rockchip-Introduce-driver-for-Rockchip-s-camera-interface/20201209-002715
git checkout 8c74146ec237f44d2b5f26a38765e1d2948035d3
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arc

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All warnings (new ones prefixed by >>):

drivers/media/platform/rockchip/vip/capture.c: In function 'rk_vip_queue_setup':
>> drivers/media/platform/rockchip/vip/capture.c:397:31: warning: variable 'vip_fmt' set but not used [-Wunused-but-set-variable]
397 | const struct vip_output_fmt *vip_fmt;
| ^~~~~~~

vim +/vip_fmt +397 drivers/media/platform/rockchip/vip/capture.c

387
388 static int rk_vip_queue_setup(struct vb2_queue *queue,
389 unsigned int *num_buffers,
390 unsigned int *num_planes,
391 unsigned int sizes[],
392 struct device *alloc_devs[])
393 {
394 struct rk_vip_stream *stream = queue->drv_priv;
395 const struct v4l2_plane_pix_format *plane_fmt;
396 const struct v4l2_pix_format_mplane *pixm;
> 397 const struct vip_output_fmt *vip_fmt;
398
399 pixm = &stream->pixm;
400 vip_fmt = stream->vip_fmt_out;
401
402 if (*num_planes) {
403 if (*num_planes != 1)
404 return -EINVAL;
405
406 if (sizes[0] < pixm->plane_fmt[0].sizeimage)
407 return -EINVAL;
408 return 0;
409 }
410
411 *num_planes = 1;
412
413 plane_fmt = &pixm->plane_fmt[0];
414 sizes[0] = plane_fmt->sizeimage;
415
416 *num_buffers = VIP_REQ_BUFS_MIN;
417
418 return 0;
419 }
420

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx

Attachment: .config.gz
Description: application/gzip