summaryrefslogtreecommitdiff
path: root/drivers/media/pci/cx23885/cx23885-vbi.c
diff options
context:
space:
mode:
authorHans Verkuil <hans.verkuil@cisco.com>2014-04-23 08:43:51 -0300
committerMauro Carvalho Chehab <m.chehab@samsung.com>2014-09-03 07:57:38 -0300
commit568f44a18e9b63fbb44fcb3292c3530087ae527b (patch)
tree927e06dabdc7228fb3fe7599e91f0a27c8770d7f /drivers/media/pci/cx23885/cx23885-vbi.c
parent9529a4b0cf49163e489446ec159a2dfb64f78df8 (diff)
[media] cx23885: use video_drvdata to get cx23885_dev pointer
Use video_drvdata(file) instead of fh->dev to get the cx23885_dev pointer. This prepares for the vb2 conversion where fh->dev (renamed to fh->q_dev in this patch) will be removed completely. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'drivers/media/pci/cx23885/cx23885-vbi.c')
-rw-r--r--drivers/media/pci/cx23885/cx23885-vbi.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/media/pci/cx23885/cx23885-vbi.c b/drivers/media/pci/cx23885/cx23885-vbi.c
index a1154f035bc1..1cb67d38022a 100644
--- a/drivers/media/pci/cx23885/cx23885-vbi.c
+++ b/drivers/media/pci/cx23885/cx23885-vbi.c
@@ -50,8 +50,7 @@ MODULE_PARM_DESC(vbi_debug, "enable debug messages [vbi]");
int cx23885_vbi_fmt(struct file *file, void *priv,
struct v4l2_format *f)
{
- struct cx23885_fh *fh = priv;
- struct cx23885_dev *dev = fh->dev;
+ struct cx23885_dev *dev = video_drvdata(file);
if (dev->tvnorm & V4L2_STD_525_60) {
/* ntsc */
@@ -201,7 +200,7 @@ vbi_prepare(struct videobuf_queue *q, struct videobuf_buffer *vb,
enum v4l2_field field)
{
struct cx23885_fh *fh = q->priv_data;
- struct cx23885_dev *dev = fh->dev;
+ struct cx23885_dev *dev = fh->q_dev;
struct cx23885_buffer *buf = container_of(vb,
struct cx23885_buffer, vb);
struct videobuf_dmabuf *dma = videobuf_to_dma(&buf->vb);
@@ -242,7 +241,7 @@ vbi_queue(struct videobuf_queue *vq, struct videobuf_buffer *vb)
container_of(vb, struct cx23885_buffer, vb);
struct cx23885_buffer *prev;
struct cx23885_fh *fh = vq->priv_data;
- struct cx23885_dev *dev = fh->dev;
+ struct cx23885_dev *dev = fh->q_dev;
struct cx23885_dmaqueue *q = &dev->vbiq;
/* add jump to stopper */