aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media
diff options
context:
space:
mode:
authorHans Verkuil <hans.verkuil@cisco.com>2012-09-04 09:26:45 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2012-09-26 09:42:36 -0400
commite6eb28c2207b9397d0ab56e238865a4ee95b7ef9 (patch)
tree5914411d203c71b6b1446e2e4ad592c92331f6da /drivers/media
parent06fce2861d5a4ebcff65e253b2b3e4406dc3ab24 (diff)
[media] v4l2: make vidioc_s_fbuf const
Write-only ioctls should have a const argument in the ioctl op. Do this conversion for vidioc_s_fbuf. Adding const for write-only ioctls was decided during the 2012 Media Workshop. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/common/saa7146/saa7146_video.c2
-rw-r--r--drivers/media/pci/bt8xx/bttv-driver.c2
-rw-r--r--drivers/media/pci/ivtv/ivtv-ioctl.c4
-rw-r--r--drivers/media/pci/saa7134/saa7134-video.c2
-rw-r--r--drivers/media/pci/zoran/zoran_driver.c2
-rw-r--r--drivers/media/platform/fsl-viu.c2
-rw-r--r--drivers/media/platform/omap/omap_vout.c2
7 files changed, 8 insertions, 8 deletions
diff --git a/drivers/media/common/saa7146/saa7146_video.c b/drivers/media/common/saa7146/saa7146_video.c
index 6d14785d4747..4143d61f79b1 100644
--- a/drivers/media/common/saa7146/saa7146_video.c
+++ b/drivers/media/common/saa7146/saa7146_video.c
@@ -479,7 +479,7 @@ static int vidioc_g_fbuf(struct file *file, void *fh, struct v4l2_framebuffer *f
479 return 0; 479 return 0;
480} 480}
481 481
482static int vidioc_s_fbuf(struct file *file, void *fh, struct v4l2_framebuffer *fb) 482static int vidioc_s_fbuf(struct file *file, void *fh, const struct v4l2_framebuffer *fb)
483{ 483{
484 struct saa7146_dev *dev = ((struct saa7146_fh *)fh)->dev; 484 struct saa7146_dev *dev = ((struct saa7146_fh *)fh)->dev;
485 struct saa7146_vv *vv = dev->vv_data; 485 struct saa7146_vv *vv = dev->vv_data;
diff --git a/drivers/media/pci/bt8xx/bttv-driver.c b/drivers/media/pci/bt8xx/bttv-driver.c
index b58ff87db771..26bf309c41c2 100644
--- a/drivers/media/pci/bt8xx/bttv-driver.c
+++ b/drivers/media/pci/bt8xx/bttv-driver.c
@@ -2740,7 +2740,7 @@ static int bttv_overlay(struct file *file, void *f, unsigned int on)
2740} 2740}
2741 2741
2742static int bttv_s_fbuf(struct file *file, void *f, 2742static int bttv_s_fbuf(struct file *file, void *f,
2743 struct v4l2_framebuffer *fb) 2743 const struct v4l2_framebuffer *fb)
2744{ 2744{
2745 struct bttv_fh *fh = f; 2745 struct bttv_fh *fh = f;
2746 struct bttv *btv = fh->btv; 2746 struct bttv *btv = fh->btv;
diff --git a/drivers/media/pci/ivtv/ivtv-ioctl.c b/drivers/media/pci/ivtv/ivtv-ioctl.c
index 32a591062d0b..d3b32c2d034e 100644
--- a/drivers/media/pci/ivtv/ivtv-ioctl.c
+++ b/drivers/media/pci/ivtv/ivtv-ioctl.c
@@ -1427,7 +1427,7 @@ static int ivtv_g_fbuf(struct file *file, void *fh, struct v4l2_framebuffer *fb)
1427 return 0; 1427 return 0;
1428} 1428}
1429 1429
1430static int ivtv_s_fbuf(struct file *file, void *fh, struct v4l2_framebuffer *fb) 1430static int ivtv_s_fbuf(struct file *file, void *fh, const struct v4l2_framebuffer *fb)
1431{ 1431{
1432 struct ivtv_open_id *id = fh2id(fh); 1432 struct ivtv_open_id *id = fh2id(fh);
1433 struct ivtv *itv = id->itv; 1433 struct ivtv *itv = id->itv;
@@ -1444,7 +1444,7 @@ static int ivtv_s_fbuf(struct file *file, void *fh, struct v4l2_framebuffer *fb)
1444 itv->osd_chroma_key_state = (fb->flags & V4L2_FBUF_FLAG_CHROMAKEY) != 0; 1444 itv->osd_chroma_key_state = (fb->flags & V4L2_FBUF_FLAG_CHROMAKEY) != 0;
1445 ivtv_set_osd_alpha(itv); 1445 ivtv_set_osd_alpha(itv);
1446 yi->track_osd = (fb->flags & V4L2_FBUF_FLAG_OVERLAY) != 0; 1446 yi->track_osd = (fb->flags & V4L2_FBUF_FLAG_OVERLAY) != 0;
1447 return ivtv_g_fbuf(file, fh, fb); 1447 return 0;
1448} 1448}
1449 1449
1450static int ivtv_overlay(struct file *file, void *fh, unsigned int on) 1450static int ivtv_overlay(struct file *file, void *fh, unsigned int on)
diff --git a/drivers/media/pci/saa7134/saa7134-video.c b/drivers/media/pci/saa7134/saa7134-video.c
index 6de10b1e7251..bac4386c64b9 100644
--- a/drivers/media/pci/saa7134/saa7134-video.c
+++ b/drivers/media/pci/saa7134/saa7134-video.c
@@ -2158,7 +2158,7 @@ static int saa7134_g_fbuf(struct file *file, void *f,
2158} 2158}
2159 2159
2160static int saa7134_s_fbuf(struct file *file, void *f, 2160static int saa7134_s_fbuf(struct file *file, void *f,
2161 struct v4l2_framebuffer *fb) 2161 const struct v4l2_framebuffer *fb)
2162{ 2162{
2163 struct saa7134_fh *fh = f; 2163 struct saa7134_fh *fh = f;
2164 struct saa7134_dev *dev = fh->dev; 2164 struct saa7134_dev *dev = fh->dev;
diff --git a/drivers/media/pci/zoran/zoran_driver.c b/drivers/media/pci/zoran/zoran_driver.c
index c6ccdeb6d8d6..f91b551e6a52 100644
--- a/drivers/media/pci/zoran/zoran_driver.c
+++ b/drivers/media/pci/zoran/zoran_driver.c
@@ -1978,7 +1978,7 @@ static int zoran_g_fbuf(struct file *file, void *__fh,
1978} 1978}
1979 1979
1980static int zoran_s_fbuf(struct file *file, void *__fh, 1980static int zoran_s_fbuf(struct file *file, void *__fh,
1981 struct v4l2_framebuffer *fb) 1981 const struct v4l2_framebuffer *fb)
1982{ 1982{
1983 struct zoran_fh *fh = __fh; 1983 struct zoran_fh *fh = __fh;
1984 struct zoran *zr = fh->zr; 1984 struct zoran *zr = fh->zr;
diff --git a/drivers/media/platform/fsl-viu.c b/drivers/media/platform/fsl-viu.c
index 20f981008faf..897250b88647 100644
--- a/drivers/media/platform/fsl-viu.c
+++ b/drivers/media/platform/fsl-viu.c
@@ -860,7 +860,7 @@ int vidioc_g_fbuf(struct file *file, void *priv, struct v4l2_framebuffer *arg)
860 return 0; 860 return 0;
861} 861}
862 862
863int vidioc_s_fbuf(struct file *file, void *priv, struct v4l2_framebuffer *arg) 863int vidioc_s_fbuf(struct file *file, void *priv, const struct v4l2_framebuffer *arg)
864{ 864{
865 struct viu_fh *fh = priv; 865 struct viu_fh *fh = priv;
866 struct viu_dev *dev = fh->dev; 866 struct viu_dev *dev = fh->dev;
diff --git a/drivers/media/platform/omap/omap_vout.c b/drivers/media/platform/omap/omap_vout.c
index 88cf9d952631..92845f835607 100644
--- a/drivers/media/platform/omap/omap_vout.c
+++ b/drivers/media/platform/omap/omap_vout.c
@@ -1744,7 +1744,7 @@ static int vidioc_streamoff(struct file *file, void *fh, enum v4l2_buf_type i)
1744} 1744}
1745 1745
1746static int vidioc_s_fbuf(struct file *file, void *fh, 1746static int vidioc_s_fbuf(struct file *file, void *fh,
1747 struct v4l2_framebuffer *a) 1747 const struct v4l2_framebuffer *a)
1748{ 1748{
1749 int enable = 0; 1749 int enable = 0;
1750 struct omap_overlay *ovl; 1750 struct omap_overlay *ovl;