All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild@lists.01.org
Subject: drivers/staging/vc04_services/bcm2835-camera/controls.c:1365 bm2835_mmal_init_controls() warn: should '(((1))) << be a 64 bit
Date: Tue, 02 Mar 2021 12:14:09 +0800	[thread overview]
Message-ID: <202103021206.1JJ0MEPD-lkp@intel.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 6533 bytes --]

CC: kbuild-all(a)lists.01.org
CC: linux-kernel(a)vger.kernel.org
TO: Mauro Carvalho Chehab <mchehab@kernel.org>
CC: linux-media(a)vger.kernel.org

Hi Mauro,

First bad commit (maybe != root cause):

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   7a7fd0de4a9804299793e564a555a49c1fc924cb
commit: a3b91d8bd1e034c8ed89d3f55243478af97a0a52 media: Kconfig: better support hybrid TV devices
date:   11 months ago
:::::: branch date: 9 hours ago
:::::: commit date: 11 months ago
config: xtensa-randconfig-m031-20210302 (attached as .config)
compiler: xtensa-linux-gcc (GCC) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>

smatch warnings:
drivers/staging/vc04_services/bcm2835-camera/controls.c:1365 bm2835_mmal_init_controls() warn: should '(((1))) << (scene_configs[i]->v4l2_scene)' be a 64 bit type?

vim +1365 drivers/staging/vc04_services/bcm2835-camera/controls.c

7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1327  
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1328  int bm2835_mmal_init_controls(struct bm2835_mmal_dev *dev,
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1329  			      struct v4l2_ctrl_handler *hdl)
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1330  {
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1331  	int c;
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1332  	const struct bm2835_mmal_v4l2_ctrl *ctrl;
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1333  
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1334  	v4l2_ctrl_handler_init(hdl, V4L2_CTRL_COUNT);
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1335  
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1336  	for (c = 0; c < V4L2_CTRL_COUNT; c++) {
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1337  		ctrl = &v4l2_ctrls[c];
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1338  
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1339  		switch (ctrl->type) {
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1340  		case MMAL_CONTROL_TYPE_STD:
fcdd047e8ae9b8 drivers/staging/vc04_services/bcm2835-camera/controls.c Dave Stevenson  2019-06-29  1341  			dev->ctrls[c] =
fcdd047e8ae9b8 drivers/staging/vc04_services/bcm2835-camera/controls.c Dave Stevenson  2019-06-29  1342  				v4l2_ctrl_new_std(hdl,
fcdd047e8ae9b8 drivers/staging/vc04_services/bcm2835-camera/controls.c Dave Stevenson  2019-06-29  1343  						  &bm2835_mmal_ctrl_ops,
fcdd047e8ae9b8 drivers/staging/vc04_services/bcm2835-camera/controls.c Dave Stevenson  2019-06-29  1344  						  ctrl->id, ctrl->min,
fcdd047e8ae9b8 drivers/staging/vc04_services/bcm2835-camera/controls.c Dave Stevenson  2019-06-29  1345  						  ctrl->max, ctrl->step,
fcdd047e8ae9b8 drivers/staging/vc04_services/bcm2835-camera/controls.c Dave Stevenson  2019-06-29  1346  						  ctrl->def);
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1347  			break;
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1348  
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1349  		case MMAL_CONTROL_TYPE_STD_MENU:
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1350  		{
78f2e83dad7bf1 drivers/staging/vc04_services/bcm2835-camera/controls.c Dave Stevenson  2019-06-29  1351  			u64 mask = ctrl->min;
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1352  
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1353  			if (ctrl->id == V4L2_CID_SCENE_MODE) {
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1354  				/* Special handling to work out the mask
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1355  				 * value based on the scene_configs array
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1356  				 * at runtime. Reduces the chance of
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1357  				 * mismatches.
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1358  				 */
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1359  				int i;
7c1f094ac6a913 drivers/staging/vc04_services/bcm2835-camera/controls.c Nishka Dasgupta 2018-03-20  1360  
78f2e83dad7bf1 drivers/staging/vc04_services/bcm2835-camera/controls.c Dave Stevenson  2019-06-29  1361  				mask = BIT(V4L2_SCENE_MODE_NONE);
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1362  				for (i = 0;
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1363  				     i < ARRAY_SIZE(scene_configs);
7b3ad5abf027b7 drivers/staging/media/platform/bcm2835/controls.c       Eric Anholt     2017-01-27  1364  				     i++) {
78f2e83dad7bf1 drivers/staging/vc04_services/bcm2835-camera/controls.c Dave Stevenson  2019-06-29 @1365  					mask |= BIT(scene_configs[i].v4l2_scene);

:::::: The code@line 1365 was first introduced by commit
:::::: 78f2e83dad7bf1b1337f7e0fc5c6add7cab81d62 staging: bcm2835-camera: Correct ctrl min/max/step/def to 64bit

:::::: TO: Dave Stevenson <dave.stevenson@raspberrypi.org>
:::::: CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

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

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 26794 bytes --]

                 reply	other threads:[~2021-03-02  4:14 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=202103021206.1JJ0MEPD-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild@lists.01.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.