• Home
  • Raw
  • Download

Lines Matching +full:wait +full:- +full:queue

1 .. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later
4 .. _media-request-api:
12 the same pipeline to reconfigure and collaborate closely on a per-frame basis.
14 to specific frames (aka 'per-frame controls') in order to be used efficiently.
16 While the initial use-case was V4L2, it can be extended to other subsystems
20 it is, it is terribly inefficient: user-space would have to flush all activity
21 on the media pipeline, reconfigure it for the next frame, queue the buffers to
22 be processed with that configuration, and wait until they are all available for
28 specific buffers. This allows user-space to schedule several tasks ("requests")
34 -------------
37 subsystem-specific APIs to support request usage. At the Media Controller
41 stored in requests are accessed through subsystem-specific APIs extended for
46 ------------------
48 User-space allocates requests using :ref:`MEDIA_IOC_REQUEST_ALLOC`
53 -------------------
60 enter the regular buffer queue until the request itself is queued.
63 ------------------
71 For :ref:`memory-to-memory devices <mem2mem>` you can use requests only for
85 :ref:`closed <func-close>`. Attempts to directly queue a buffer when earlier
97 User-space can :c:func:`poll()` a request file descriptor in
98 order to wait until the request completes. A request is considered complete
101 Note that user-space does not need to wait for the request to complete to
106 executed. User-space can query that state by calling
113 .. _media-request-life-time:
116 -------------------------
130 --------------------------
132 For use-cases such as :ref:`codecs <mem2mem>`, the request API can be used
134 be applied by the driver for the OUTPUT buffer, allowing user-space
135 to queue many such buffers in advance. It can also take advantage of requests'
139 Put into code, after obtaining a request, user-space can assign controls and one
142 .. code-block:: c
163 since there are no per-frame settings to report there.
167 .. code-block:: c
172 User-space can then either wait for the request to complete by calling poll() on
177 .. code-block:: c
195 .. code-block:: c
198 poll(&pfd, 1, -1);
208 .. code-block:: c
215 .. code-block:: c
220 -----------------------------------
225 .. code-block:: c
247 .. code-block:: c
252 User-space can then dequeue buffers, wait for the request completion, query