Remove unneeded buffer type checks from FMT IOTCL handlers. Checks are already done by V4L core. Signed-off-by: Antti Palosaari <crope@xxxxxx> --- drivers/staging/media/msi3101/sdr-msi3101.c | 9 --------- 1 file changed, 9 deletions(-) diff --git a/drivers/staging/media/msi3101/sdr-msi3101.c b/drivers/staging/media/msi3101/sdr-msi3101.c index 02960c7..6b9f0da 100644 --- a/drivers/staging/media/msi3101/sdr-msi3101.c +++ b/drivers/staging/media/msi3101/sdr-msi3101.c @@ -1679,9 +1679,6 @@ static int msi3101_g_fmt_sdr_cap(struct file *file, void *priv, struct msi3101_state *s = video_drvdata(file); dev_dbg(&s->udev->dev, "%s:\n", __func__); - if (f->type != V4L2_BUF_TYPE_SDR_CAPTURE) - return -EINVAL; - f->fmt.sdr.pixelformat = s->pixelformat; return 0; @@ -1696,9 +1693,6 @@ static int msi3101_s_fmt_sdr_cap(struct file *file, void *priv, dev_dbg(&s->udev->dev, "%s: pixelformat fourcc %4.4s\n", __func__, (char *)&f->fmt.sdr.pixelformat); - if (f->type != V4L2_BUF_TYPE_SDR_CAPTURE) - return -EINVAL; - if (vb2_is_busy(q)) return -EBUSY; @@ -1723,9 +1717,6 @@ static int msi3101_try_fmt_sdr_cap(struct file *file, void *priv, dev_dbg(&s->udev->dev, "%s: pixelformat fourcc %4.4s\n", __func__, (char *)&f->fmt.sdr.pixelformat); - if (f->type != V4L2_BUF_TYPE_SDR_CAPTURE) - return -EINVAL; - for (i = 0; i < NUM_FORMATS; i++) { if (formats[i].pixelformat == f->fmt.sdr.pixelformat) return 0; -- 1.8.5.3 -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html