linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* re: msi2500: move msi3101 out of staging and rename
@ 2014-07-25 12:21 Dan Carpenter
  0 siblings, 0 replies; only message in thread
From: Dan Carpenter @ 2014-07-25 12:21 UTC (permalink / raw)
  To: crope; +Cc: linux-media

Hello Antti Palosaari,

The patch fd8b5f502929: "msi2500: move msi3101 out of staging and
rename" from Jul 13, 2014, leads to the following static checker
warning:

drivers/media/usb/msi2500/msi2500.c:887 msi2500_stop_streaming()
	 error: we previously assumed 's->udev' could be null (see line 880)

drivers/media/usb/msi2500/msi2500.c
   872  static void msi2500_stop_streaming(struct vb2_queue *vq)
   873  {
   874          struct msi2500_state *s = vb2_get_drv_priv(vq);
   875  
   876          dev_dbg(&s->udev->dev, "%s:\n", __func__);
   877  
   878          mutex_lock(&s->v4l2_lock);
   879  
   880          if (s->udev)
                    ^^^^^^^
Check.

   881                  msi2500_isoc_cleanup(s);
   882  
   883          msi2500_cleanup_queued_bufs(s);
   884  
   885          /* according to tests, at least 700us delay is required  */
   886          msleep(20);
   887          if (!msi2500_ctrl_msg(s, CMD_STOP_STREAMING, 0)) {
                     ^^^^^^^^^^^^^^^^^^
Unchecked dereference if you have debugging enabled.

   888                  /* sleep USB IF / ADC */
   889                  msi2500_ctrl_msg(s, CMD_WREG, 0x01000003);
   890          }

regards,
dan carpenter

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2014-07-25 12:22 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-07-25 12:21 msi2500: move msi3101 out of staging and rename Dan Carpenter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).