summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorTomasz Stanislawski <t.stanislaws@samsung.com>2012-06-14 11:32:27 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2012-11-25 17:21:51 -0200
commit3c44efd3b2af20c50769998e496d744a6d490e66 (patch)
tree2867af65558090d616f8cf9ef1e9ecaa904e01be /drivers
parentb28d61b622496038db621fe1dab1caf0e91c6c94 (diff)
downloadlinux-3.10-3c44efd3b2af20c50769998e496d744a6d490e66.tar.gz
linux-3.10-3c44efd3b2af20c50769998e496d744a6d490e66.tar.bz2
linux-3.10-3c44efd3b2af20c50769998e496d744a6d490e66.zip
[media] v4l: s5p-tv: mixer: support for dmabuf exporting
This patch enhances s5p-tv with support for DMABUF exporting via VIDIOC_EXPBUF ioctl. Signed-off-by: Tomasz Stanislawski <t.stanislaws@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Tested-by: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/platform/s5p-tv/mixer_video.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/media/platform/s5p-tv/mixer_video.c b/drivers/media/platform/s5p-tv/mixer_video.c
index 79a7ea3ae04..7379e77bf4e 100644
--- a/drivers/media/platform/s5p-tv/mixer_video.c
+++ b/drivers/media/platform/s5p-tv/mixer_video.c
@@ -697,6 +697,15 @@ static int mxr_dqbuf(struct file *file, void *priv, struct v4l2_buffer *p)
return vb2_dqbuf(&layer->vb_queue, p, file->f_flags & O_NONBLOCK);
}
+static int mxr_expbuf(struct file *file, void *priv,
+ struct v4l2_exportbuffer *eb)
+{
+ struct mxr_layer *layer = video_drvdata(file);
+
+ mxr_dbg(layer->mdev, "%s:%d\n", __func__, __LINE__);
+ return vb2_expbuf(&layer->vb_queue, eb);
+}
+
static int mxr_streamon(struct file *file, void *priv, enum v4l2_buf_type i)
{
struct mxr_layer *layer = video_drvdata(file);
@@ -724,6 +733,7 @@ static const struct v4l2_ioctl_ops mxr_ioctl_ops = {
.vidioc_querybuf = mxr_querybuf,
.vidioc_qbuf = mxr_qbuf,
.vidioc_dqbuf = mxr_dqbuf,
+ .vidioc_expbuf = mxr_expbuf,
/* Streaming control */
.vidioc_streamon = mxr_streamon,
.vidioc_streamoff = mxr_streamoff,