linux-api.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH/RFC 0/2] Repurpose the v4l2_plane data_offset field
@ 2015-04-14 19:44 Laurent Pinchart
  2015-04-14 19:44 ` [PATCH/RFC 1/2] v4l: " Laurent Pinchart
                   ` (2 more replies)
  0 siblings, 3 replies; 14+ messages in thread
From: Laurent Pinchart @ 2015-04-14 19:44 UTC (permalink / raw)
  To: linux-media-u79uwXL29TY76Z2rM5mHXA
  Cc: linux-api-u79uwXL29TY76Z2rM5mHXA, Sakari Ailus, Hans Verkuil,
	Pawel Osciak, Marek Szyprowski, Mauro Carvalho Chehab

Hello,

The v4l2_plane data_offset field has been introduced at the same time as the
the multiplane API to convey header size information between kernelspace and
userspace.

The API then became slightly controversial, both because different developers
understood the purpose of the field differently (resulting for instance in an
out-of-tree driver abusing the field for a different purpose), and because of
competing proposals (see for instance "[RFC] Multi format stream support" at
http://www.spinics.net/lists/linux-media/msg69130.html).

Furthermore, the data_offset field isn't used by any mainline driver except
vivid (for testing purpose).

I need a different data offset in planes to allow data capture to or data
output from a userspace-selected offset within a buffer (mainly for the
DMABUF and MMAP memory types). As the data_offset field already has the
right name, is unused, and ill-defined, I propose repurposing it. This is what
this RFC is about.

If the proposal is accepted I'll add another patch to update data_offset usage
in the vivid driver.

Laurent Pinchart (2):
  v4l: Repurpose the v4l2_plane data_offset field
  videobuf2: Repurpose the v4l2_plane data_offset field

 Documentation/DocBook/media/v4l/io.xml   | 19 +++++++------
 drivers/media/v4l2-core/videobuf2-core.c | 46 +++++++++++++++++++++++---------
 include/media/videobuf2-core.h           |  4 +++
 include/media/videobuf2-dma-contig.h     |  2 +-
 include/uapi/linux/videodev2.h           |  6 +++--
 5 files changed, 54 insertions(+), 23 deletions(-)

-- 
Regards,

Laurent Pinchart

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2015-04-22 13:19 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-04-14 19:44 [PATCH/RFC 0/2] Repurpose the v4l2_plane data_offset field Laurent Pinchart
2015-04-14 19:44 ` [PATCH/RFC 1/2] v4l: " Laurent Pinchart
2015-04-14 20:10   ` Sakari Ailus
     [not found]     ` <20150414201004.GA27451-S+BSfZ9RZZmRSg0ZkenSGLdO1Tsj/99ntUK59QYPAWc@public.gmane.org>
2015-04-15 20:37       ` Laurent Pinchart
     [not found] ` <1429040689-23808-1-git-send-email-laurent.pinchart-ryLnwIuWjnjg/C1BVhZhaw@public.gmane.org>
2015-04-14 19:44   ` [PATCH/RFC 2/2] videobuf2: " Laurent Pinchart
2015-04-17 10:27 ` [PATCH/RFC 0/2] " Hans Verkuil
     [not found]   ` <5530E01D.3050105-qWit8jRvyhVmR6Xm/wNWPw@public.gmane.org>
2015-04-17 12:53     ` Laurent Pinchart
2015-04-20  9:34       ` Hans Verkuil
2015-04-20  9:43         ` Laurent Pinchart
2015-04-22 13:02       ` Nicolas Dufresne
2015-04-18 13:04   ` Sakari Ailus
2015-04-20  9:16     ` Hans Verkuil
     [not found]       ` <5534C405.9010307-qWit8jRvyhVmR6Xm/wNWPw@public.gmane.org>
2015-04-20 15:44         ` Laurent Pinchart
2015-04-22 13:19         ` Sakari Ailus

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).