aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/saa7134/saa7134-video.c
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2010-05-01 07:03:24 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2010-05-19 11:58:54 -0400
commitffb4877ba013f94322083f77cbb05b35c2a218aa (patch)
tree0d041da73986e1dc7c845ff4418fb20f46bd7506 /drivers/media/video/saa7134/saa7134-video.c
parent530d2d32068eaf3616e0ce9e58a5fde5701c3380 (diff)
V4L/DVB: v4l2-common: simplify prio utility functions
v4l2_prio_init/open/close returned an int when in fact they would always return 0. Make these void functions. v4l2_prio_close and v4l2_prio_check pass an enum v4l2_priority as a pointer for no good reason. Replace with a normal enum v4l2_priority argument. These changes will simplify the work of moving priority handling into the v4l core. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/saa7134/saa7134-video.c')
-rw-r--r--drivers/media/video/saa7134/saa7134-video.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/media/video/saa7134/saa7134-video.c b/drivers/media/video/saa7134/saa7134-video.c
index 7806fb17e742..45f0ac8f3c0f 100644
--- a/drivers/media/video/saa7134/saa7134-video.c
+++ b/drivers/media/video/saa7134/saa7134-video.c
@@ -1180,7 +1180,7 @@ int saa7134_s_ctrl_internal(struct saa7134_dev *dev, struct saa7134_fh *fh, str
1180 That needs to be fixed somehow, but for now this is 1180 That needs to be fixed somehow, but for now this is
1181 good enough. */ 1181 good enough. */
1182 if (fh) { 1182 if (fh) {
1183 err = v4l2_prio_check(&dev->prio, &fh->prio); 1183 err = v4l2_prio_check(&dev->prio, fh->prio);
1184 if (0 != err) 1184 if (0 != err)
1185 return err; 1185 return err;
1186 } 1186 }
@@ -1359,7 +1359,7 @@ static int video_open(struct file *file)
1359 fh->fmt = format_by_fourcc(V4L2_PIX_FMT_BGR24); 1359 fh->fmt = format_by_fourcc(V4L2_PIX_FMT_BGR24);
1360 fh->width = 720; 1360 fh->width = 720;
1361 fh->height = 576; 1361 fh->height = 576;
1362 v4l2_prio_open(&dev->prio,&fh->prio); 1362 v4l2_prio_open(&dev->prio, &fh->prio);
1363 1363
1364 videobuf_queue_sg_init(&fh->cap, &video_qops, 1364 videobuf_queue_sg_init(&fh->cap, &video_qops,
1365 &dev->pci->dev, &dev->slock, 1365 &dev->pci->dev, &dev->slock,
@@ -1502,7 +1502,7 @@ static int video_release(struct file *file)
1502 saa7134_pgtable_free(dev->pci,&fh->pt_cap); 1502 saa7134_pgtable_free(dev->pci,&fh->pt_cap);
1503 saa7134_pgtable_free(dev->pci,&fh->pt_vbi); 1503 saa7134_pgtable_free(dev->pci,&fh->pt_vbi);
1504 1504
1505 v4l2_prio_close(&dev->prio,&fh->prio); 1505 v4l2_prio_close(&dev->prio, fh->prio);
1506 file->private_data = NULL; 1506 file->private_data = NULL;
1507 kfree(fh); 1507 kfree(fh);
1508 return 0; 1508 return 0;
@@ -1785,7 +1785,7 @@ static int saa7134_s_input(struct file *file, void *priv, unsigned int i)
1785 struct saa7134_dev *dev = fh->dev; 1785 struct saa7134_dev *dev = fh->dev;
1786 int err; 1786 int err;
1787 1787
1788 err = v4l2_prio_check(&dev->prio, &fh->prio); 1788 err = v4l2_prio_check(&dev->prio, fh->prio);
1789 if (0 != err) 1789 if (0 != err)
1790 return err; 1790 return err;
1791 1791
@@ -1839,7 +1839,7 @@ int saa7134_s_std_internal(struct saa7134_dev *dev, struct saa7134_fh *fh, v4l2_
1839 That needs to be fixed somehow, but for now this is 1839 That needs to be fixed somehow, but for now this is
1840 good enough. */ 1840 good enough. */
1841 if (fh) { 1841 if (fh) {
1842 err = v4l2_prio_check(&dev->prio, &fh->prio); 1842 err = v4l2_prio_check(&dev->prio, fh->prio);
1843 if (0 != err) 1843 if (0 != err)
1844 return err; 1844 return err;
1845 } else if (res_locked(dev, RESOURCE_OVERLAY)) { 1845 } else if (res_locked(dev, RESOURCE_OVERLAY)) {
@@ -2023,7 +2023,7 @@ static int saa7134_s_tuner(struct file *file, void *priv,
2023 struct saa7134_dev *dev = fh->dev; 2023 struct saa7134_dev *dev = fh->dev;
2024 int rx, mode, err; 2024 int rx, mode, err;
2025 2025
2026 err = v4l2_prio_check(&dev->prio, &fh->prio); 2026 err = v4l2_prio_check(&dev->prio, fh->prio);
2027 if (0 != err) 2027 if (0 != err)
2028 return err; 2028 return err;
2029 2029
@@ -2057,7 +2057,7 @@ static int saa7134_s_frequency(struct file *file, void *priv,
2057 struct saa7134_dev *dev = fh->dev; 2057 struct saa7134_dev *dev = fh->dev;
2058 int err; 2058 int err;
2059 2059
2060 err = v4l2_prio_check(&dev->prio, &fh->prio); 2060 err = v4l2_prio_check(&dev->prio, fh->prio);
2061 if (0 != err) 2061 if (0 != err)
2062 return err; 2062 return err;
2063 2063