aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Documentation/DocBook/media/v4l/vidioc-streamon.xml28
1 files changed, 22 insertions, 6 deletions
diff --git a/Documentation/DocBook/media/v4l/vidioc-streamon.xml b/Documentation/DocBook/media/v4l/vidioc-streamon.xml
index 65dff55079d7..df2c63d07bac 100644
--- a/Documentation/DocBook/media/v4l/vidioc-streamon.xml
+++ b/Documentation/DocBook/media/v4l/vidioc-streamon.xml
@@ -52,16 +52,24 @@
52 <para>The <constant>VIDIOC_STREAMON</constant> and 52 <para>The <constant>VIDIOC_STREAMON</constant> and
53<constant>VIDIOC_STREAMOFF</constant> ioctl start and stop the capture 53<constant>VIDIOC_STREAMOFF</constant> ioctl start and stop the capture
54or output process during streaming (<link linkend="mmap">memory 54or output process during streaming (<link linkend="mmap">memory
55mapping</link> or <link linkend="userp">user pointer</link>) I/O.</para> 55mapping</link>, <link linkend="userp">user pointer</link> or
56<link linkend="dmabuf">DMABUF</link>) I/O.</para>
56 57
57 <para>Specifically the capture hardware is disabled and no input 58 <para>Capture hardware is disabled and no input
58buffers are filled (if there are any empty buffers in the incoming 59buffers are filled (if there are any empty buffers in the incoming
59queue) until <constant>VIDIOC_STREAMON</constant> has been called. 60queue) until <constant>VIDIOC_STREAMON</constant> has been called.
60Accordingly the output hardware is disabled, no video signal is 61Output hardware is disabled and no video signal is
61produced until <constant>VIDIOC_STREAMON</constant> has been called. 62produced until <constant>VIDIOC_STREAMON</constant> has been called.
62The ioctl will succeed when at least one output buffer is in the 63The ioctl will succeed when at least one output buffer is in the
63incoming queue.</para> 64incoming queue.</para>
64 65
66 <para>Memory-to-memory devices will not start until
67<constant>VIDIOC_STREAMON</constant> has been called for both the capture
68and output stream types.</para>
69
70 <para>If <constant>VIDIOC_STREAMON</constant> fails then any already
71queued buffers will remain queued.</para>
72
65 <para>The <constant>VIDIOC_STREAMOFF</constant> ioctl, apart of 73 <para>The <constant>VIDIOC_STREAMOFF</constant> ioctl, apart of
66aborting or finishing any DMA in progress, unlocks any user pointer 74aborting or finishing any DMA in progress, unlocks any user pointer
67buffers locked in physical memory, and it removes all buffers from the 75buffers locked in physical memory, and it removes all buffers from the
@@ -70,14 +78,22 @@ dequeued yet will be lost, likewise all images enqueued for output but
70not transmitted yet. I/O returns to the same state as after calling 78not transmitted yet. I/O returns to the same state as after calling
71&VIDIOC-REQBUFS; and can be restarted accordingly.</para> 79&VIDIOC-REQBUFS; and can be restarted accordingly.</para>
72 80
81 <para>If buffers have been queued with &VIDIOC-QBUF; and
82<constant>VIDIOC_STREAMOFF</constant> is called without ever having
83called <constant>VIDIOC_STREAMON</constant>, then those queued buffers
84will also be removed from the incoming queue and all are returned to the
85same state as after calling &VIDIOC-REQBUFS; and can be restarted
86accordingly.</para>
87
73 <para>Both ioctls take a pointer to an integer, the desired buffer or 88 <para>Both ioctls take a pointer to an integer, the desired buffer or
74stream type. This is the same as &v4l2-requestbuffers; 89stream type. This is the same as &v4l2-requestbuffers;
75<structfield>type</structfield>.</para> 90<structfield>type</structfield>.</para>
76 91
77 <para>If <constant>VIDIOC_STREAMON</constant> is called when streaming 92 <para>If <constant>VIDIOC_STREAMON</constant> is called when streaming
78is already in progress, or if <constant>VIDIOC_STREAMOFF</constant> is called 93is already in progress, or if <constant>VIDIOC_STREAMOFF</constant> is called
79when streaming is already stopped, then the ioctl does nothing and 0 is 94when streaming is already stopped, then 0 is returned. Nothing happens in the
80returned.</para> 95case of <constant>VIDIOC_STREAMON</constant>, but <constant>VIDIOC_STREAMOFF</constant>
96will return queued buffers to their starting state as mentioned above.</para>
81 97
82 <para>Note that applications can be preempted for unknown periods right 98 <para>Note that applications can be preempted for unknown periods right
83before or after the <constant>VIDIOC_STREAMON</constant> or 99before or after the <constant>VIDIOC_STREAMON</constant> or
@@ -93,7 +109,7 @@ synchronize with other events.</para>
93 <varlistentry> 109 <varlistentry>
94 <term><errorcode>EINVAL</errorcode></term> 110 <term><errorcode>EINVAL</errorcode></term>
95 <listitem> 111 <listitem>
96 <para>The buffer<structfield>type</structfield> is not supported, 112 <para>The buffer <structfield>type</structfield> is not supported,
97 or no buffers have been allocated (memory mapping) or enqueued 113 or no buffers have been allocated (memory mapping) or enqueued
98 (output) yet.</para> 114 (output) yet.</para>
99 </listitem> 115 </listitem>