From: kernel test robot <lkp@intel.com>
To: Daniel Scally <djrscally@gmail.com>, linux-media@vger.kernel.org
Cc: kbuild-all@lists.01.org, yong.zhi@intel.com,
sakari.ailus@linux.intel.com, bingbu.cao@intel.com,
tian.shu.qiu@intel.com, andriy.shevchenko@linux.intel.com,
hverkuil-cisco@xs4all.nl
Subject: Re: [PATCH v3 15/15] media: i2c: Add vblank control to ov7251 driver
Date: Thu, 5 May 2022 09:02:58 +0800 [thread overview]
Message-ID: <202205050844.k1CPWqtV-lkp@intel.com> (raw)
In-Reply-To: <20220504223027.3480287-16-djrscally@gmail.com>
Hi Daniel,
I love your patch! Perhaps something to improve:
[auto build test WARNING on media-tree/master]
[also build test WARNING on v5.18-rc5 next-20220504]
[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/intel-lab-lkp/linux/commits/Daniel-Scally/Support-OVTI7251-on-Microsoft-Surface-line/20220505-063608
base: git://linuxtv.org/media_tree.git master
config: m68k-allyesconfig (https://download.01.org/0day-ci/archive/20220505/202205050844.k1CPWqtV-lkp@intel.com/config)
compiler: m68k-linux-gcc (GCC) 11.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/intel-lab-lkp/linux/commit/132a5a799bbe214b679bc8e242193c5c1ff1d967
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Daniel-Scally/Support-OVTI7251-on-Microsoft-Surface-line/20220505-063608
git checkout 132a5a799bbe214b679bc8e242193c5c1ff1d967
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.3.0 make.cross W=1 O=build_dir ARCH=m68k SHELL=/bin/bash drivers/media/i2c/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
drivers/media/i2c/ov7251.c: In function 'ov7251_set_format':
>> drivers/media/i2c/ov7251.c:1218:25: warning: variable 'vblank_def' set but not used [-Wunused-but-set-variable]
1218 | int vblank_max, vblank_def;
| ^~~~~~~~~~
At top level:
drivers/media/i2c/ov7251.c:193:37: warning: 'ov7251_pll1_cfg_24_mhz_319_2_mhz' defined but not used [-Wunused-const-variable=]
193 | static const struct ov7251_pll1_cfg ov7251_pll1_cfg_24_mhz_319_2_mhz = {
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
vim +/vblank_def +1218 drivers/media/i2c/ov7251.c
1211
1212 static int ov7251_set_format(struct v4l2_subdev *sd,
1213 struct v4l2_subdev_state *sd_state,
1214 struct v4l2_subdev_format *format)
1215 {
1216 struct ov7251 *ov7251 = to_ov7251(sd);
1217 struct v4l2_mbus_framefmt *__format;
> 1218 int vblank_max, vblank_def;
1219 struct v4l2_rect *__crop;
1220 const struct ov7251_mode_info *new_mode;
1221 int ret = 0;
1222
1223 mutex_lock(&ov7251->lock);
1224
1225 __crop = __ov7251_get_pad_crop(ov7251, sd_state, format->pad,
1226 format->which);
1227
1228 new_mode = v4l2_find_nearest_size(ov7251_mode_info_data,
1229 ARRAY_SIZE(ov7251_mode_info_data),
1230 width, height,
1231 format->format.width, format->format.height);
1232
1233 __crop->width = new_mode->width;
1234 __crop->height = new_mode->height;
1235
1236 if (format->which == V4L2_SUBDEV_FORMAT_ACTIVE) {
1237 ret = __v4l2_ctrl_modify_range(ov7251->exposure,
1238 1, new_mode->exposure_max,
1239 1, new_mode->exposure_def);
1240 if (ret < 0)
1241 goto exit;
1242
1243 ret = __v4l2_ctrl_s_ctrl(ov7251->exposure,
1244 new_mode->exposure_def);
1245 if (ret < 0)
1246 goto exit;
1247
1248 ret = __v4l2_ctrl_s_ctrl(ov7251->gain, 16);
1249 if (ret < 0)
1250 goto exit;
1251
1252 vblank_max = OV7251_TIMING_MAX_VTS - new_mode->height;
1253 vblank_def = new_mode->vts - new_mode->height;
1254 ret = __v4l2_ctrl_modify_range(ov7251->vblank,
1255 OV7251_TIMING_MIN_VTS,
1256 vblank_max, 1, vblank_max);
1257 if (ret < 0)
1258 goto exit;
1259
1260 ov7251->current_mode = new_mode;
1261 }
1262
1263 __format = __ov7251_get_pad_format(ov7251, sd_state, format->pad,
1264 format->which);
1265 __format->width = __crop->width;
1266 __format->height = __crop->height;
1267 __format->code = MEDIA_BUS_FMT_Y10_1X10;
1268 __format->field = V4L2_FIELD_NONE;
1269 __format->colorspace = V4L2_COLORSPACE_SRGB;
1270 __format->ycbcr_enc = V4L2_MAP_YCBCR_ENC_DEFAULT(__format->colorspace);
1271 __format->quantization = V4L2_MAP_QUANTIZATION_DEFAULT(true,
1272 __format->colorspace, __format->ycbcr_enc);
1273 __format->xfer_func = V4L2_MAP_XFER_FUNC_DEFAULT(__format->colorspace);
1274
1275 format->format = *__format;
1276
1277 exit:
1278 mutex_unlock(&ov7251->lock);
1279
1280 return ret;
1281 }
1282
--
0-DAY CI Kernel Test Service
https://01.org/lkp
next prev parent reply other threads:[~2022-05-05 1:03 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-04 22:30 [PATCH v3 00/15] Support OVTI7251 on Microsoft Surface line Daniel Scally
2022-05-04 22:30 ` [PATCH v3 01/15] media: uapi: Add IPU3 packed Y10 format Daniel Scally
2022-05-04 22:30 ` [PATCH v3 02/15] media: ipu3-cio2: Add support for V4L2_PIX_FMT_IPU3_Y10 Daniel Scally
2022-05-04 22:30 ` [PATCH v3 03/15] media: i2c: Add acpi support to ov7251 Daniel Scally
2022-05-04 22:30 ` [PATCH v3 04/15] media: i2c: Provide ov7251_check_hwcfg() Daniel Scally
2022-05-05 10:16 ` Andy Shevchenko
2022-05-05 10:41 ` Daniel Scally
2022-05-04 22:30 ` [PATCH v3 05/15] media: i2c: Remove per-mode frequencies from ov7251 Daniel Scally
2022-05-04 22:30 ` [PATCH v3 06/15] media: i2c: Add ov7251_pll_configure() Daniel Scally
2022-05-04 22:30 ` [PATCH v3 07/15] media: i2c: Add support for new frequencies to ov7251 Daniel Scally
2022-05-05 12:49 ` kernel test robot
2022-05-04 22:30 ` [PATCH v3 08/15] media: i2c: Add ov7251_detect_chip() Daniel Scally
2022-05-04 22:30 ` [PATCH v3 09/15] media: i2c: Add pm_runtime support to ov7251 Daniel Scally
2022-05-04 22:30 ` [PATCH v3 10/15] media: i2c: Remove .s_power() from ov7251 Daniel Scally
2022-05-04 22:30 ` [PATCH v3 11/15] media: ipu3-cio2: Add INT347E to cio2-bridge Daniel Scally
2022-05-04 22:30 ` [PATCH v3 12/15] media: i2c: Extend .get_selection() for ov7251 Daniel Scally
2022-05-04 22:30 ` [PATCH v3 13/15] media: i2c: add ov7251_init_ctrls() Daniel Scally
2022-05-04 22:30 ` [PATCH v3 14/15] media: i2c: Add hblank control to ov7251 Daniel Scally
2022-05-04 22:30 ` [PATCH v3 15/15] media: i2c: Add vblank control to ov7251 driver Daniel Scally
2022-05-05 1:02 ` kernel test robot [this message]
2022-05-05 8:04 ` Daniel Scally
2022-05-05 8:32 ` Sakari Ailus
2022-05-05 9:10 ` Daniel Scally
2022-05-05 10:31 ` Andy Shevchenko
2022-05-05 22:04 ` Daniel Scally
2022-05-06 21:22 ` Andy Shevchenko
2022-05-05 17:11 ` kernel test robot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202205050844.k1CPWqtV-lkp@intel.com \
--to=lkp@intel.com \
--cc=andriy.shevchenko@linux.intel.com \
--cc=bingbu.cao@intel.com \
--cc=djrscally@gmail.com \
--cc=hverkuil-cisco@xs4all.nl \
--cc=kbuild-all@lists.01.org \
--cc=linux-media@vger.kernel.org \
--cc=sakari.ailus@linux.intel.com \
--cc=tian.shu.qiu@intel.com \
--cc=yong.zhi@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox