summaryrefslogtreecommitdiff
path: root/include/media/v4l2-mem2mem.h
AgeCommit message (Collapse)Author
2014-07-22[media] v4l2-mem2mem: export v4l2_m2m_try_scheduleMichael Olbrich
Some drivers might allow to decode remaining frames from an internal ringbuffer after a decoder stop command. Allow those to call v4l2_m2m_try_schedule directly. Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de> Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-12-04[media] V4L: Add mem2mem ioctl and file operation helpersSylwester Nawrocki
This patch adds ioctl helpers to the V4L2 mem-to-mem API, so we can avoid several ioctl handlers in the mem-to-mem video node drivers that are simply a pass-through to the v4l2_m2m_* calls. These helpers will only be useful for drivers that use same mutex for both OUTPUT and CAPTURE queue, which is the case for all currently in tree v4l2 m2m drivers. In order to use the helpers the drivers are required to use struct v4l2_fh. Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-07-26[media] mem2mem: add support for hardware buffered queuePhilipp Zabel
On mem2mem decoders with a hardware bitstream ringbuffer, to drain the buffer at the end of the stream, remaining frames might need to be decoded from the bitstream buffer without additional input buffers being provided. To achieve this, allow a queue to be marked as buffered by the driver, and allow scheduling of device_runs when buffered ready queues are empty. This also allows a driver to copy input buffers into their bitstream ringbuffer and immediately mark them as done to be dequeued. The motivation for this patch is hardware assisted h.264 reordering support in the coda driver. For high profile streams, the coda can hold back out-of-order frames, causing a few mem2mem device runs in the beginning, that don't produce any decompressed buffer at the v4l2 capture side. At the same time, the last few frames can be decoded from the bitstream with mem2mem device runs that don't need a new input buffer at the v4l2 output side. The decoder command ioctl can be used to put the decoder into the ringbuffer draining end-of-stream mode. Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Acked-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Kamil Debski <k.debski@samsung.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
2013-06-03[media] v4l2-mem2mem: add v4l2_m2m_create_bufs helperPhilipp Zabel
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Kamil Debski <k.debski@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-12-19[media] media: mem2mem: make reference to struct m2m_ops in the core constGuennadi Liakhovetski
The mem2mem core doesn't change struct m2m_ops, provided by the driver, make references to it const. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-11-25[media] v4l: vb2: add buffer exporting via dmabufTomasz Stanislawski
This patch adds extension to videobuf2-core. It allow to export an mmap buffer as a DMABUF file descriptor. Signed-off-by: Tomasz Stanislawski <t.stanislaws@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.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>
2012-09-18[media] media v4l2-mem2mem: fix src/out and dst/cap num_rdySascha Hauer
src bufs belong to out queue, dst bufs belong to in queue. Currently this is not a real problem since all users currently need exactly one input and one output buffer. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Acked-by: Marek Szyprowski <m.szyprowski@samsung.com> Acked-by: Pawel Osciak <pawel@osciak.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-03-22[media] Update Pawel Osciak's e-mail addressPawel Osciak
Signed-off-by: Pawel Osciak <pawel@osciak.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-03-21[media] v4l: mem2mem: port to videobuf2Marek Szyprowski
Port memory-to-memory framework to videobuf2 framework. Add support for multi-planar Video for Linux 2 API extensions to the memory-to-memory driver framework. Based on the original patch written by Pawel Osciak. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-05-19V4L/DVB: add memory-to-memory device helper framework for videobufPawel Osciak
A mem-to-mem device is a device that uses memory buffers passed by userspace applications for both their source and destination data. This is different from existing drivers, which utilize memory buffers for either input or output, but not both. In terms of V4L2 such a device would be both of OUTPUT and CAPTURE type. Examples of such devices would be: image 'resizers', 'rotators', 'colorspace converters', etc. This patch adds a separate Kconfig sub-menu for mem-to-mem devices as well. Signed-off-by: Pawel Osciak <p.osciak@samsung.com> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Reviewed-by: Vaibhav Hiremath <hvaibhav@ti.com> Tested-by: Vaibhav Hiremath <hvaibhav@ti.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>