diff options
Diffstat (limited to 'include/uapi/linux/dvb/dmx.h')
-rw-r--r-- | include/uapi/linux/dvb/dmx.h | 63 |
1 files changed, 62 insertions, 1 deletions
diff --git a/include/uapi/linux/dvb/dmx.h b/include/uapi/linux/dvb/dmx.h index c10f1324b4ca..5f3c5a918f00 100644 --- a/include/uapi/linux/dvb/dmx.h +++ b/include/uapi/linux/dvb/dmx.h | |||
@@ -211,6 +211,61 @@ struct dmx_stc { | |||
211 | __u64 stc; | 211 | __u64 stc; |
212 | }; | 212 | }; |
213 | 213 | ||
214 | /** | ||
215 | * struct dmx_buffer - dmx buffer info | ||
216 | * | ||
217 | * @index: id number of the buffer | ||
218 | * @bytesused: number of bytes occupied by data in the buffer (payload); | ||
219 | * @offset: for buffers with memory == DMX_MEMORY_MMAP; | ||
220 | * offset from the start of the device memory for this plane, | ||
221 | * (or a "cookie" that should be passed to mmap() as offset) | ||
222 | * @length: size in bytes of the buffer | ||
223 | * | ||
224 | * Contains data exchanged by application and driver using one of the streaming | ||
225 | * I/O methods. | ||
226 | */ | ||
227 | struct dmx_buffer { | ||
228 | __u32 index; | ||
229 | __u32 bytesused; | ||
230 | __u32 offset; | ||
231 | __u32 length; | ||
232 | }; | ||
233 | |||
234 | /** | ||
235 | * struct dmx_requestbuffers - request dmx buffer information | ||
236 | * | ||
237 | * @count: number of requested buffers, | ||
238 | * @size: size in bytes of the requested buffer | ||
239 | * | ||
240 | * Contains data used for requesting a dmx buffer. | ||
241 | * All reserved fields must be set to zero. | ||
242 | */ | ||
243 | struct dmx_requestbuffers { | ||
244 | __u32 count; | ||
245 | __u32 size; | ||
246 | }; | ||
247 | |||
248 | /** | ||
249 | * struct dmx_exportbuffer - export of dmx buffer as DMABUF file descriptor | ||
250 | * | ||
251 | * @index: id number of the buffer | ||
252 | * @flags: flags for newly created file, currently only O_CLOEXEC is | ||
253 | * supported, refer to manual of open syscall for more details | ||
254 | * @fd: file descriptor associated with DMABUF (set by driver) | ||
255 | * | ||
256 | * Contains data used for exporting a dmx buffer as DMABUF file descriptor. | ||
257 | * The buffer is identified by a 'cookie' returned by DMX_QUERYBUF | ||
258 | * (identical to the cookie used to mmap() the buffer to userspace). All | ||
259 | * reserved fields must be set to zero. The field reserved0 is expected to | ||
260 | * become a structure 'type' allowing an alternative layout of the structure | ||
261 | * content. Therefore this field should not be used for any other extensions. | ||
262 | */ | ||
263 | struct dmx_exportbuffer { | ||
264 | __u32 index; | ||
265 | __u32 flags; | ||
266 | __s32 fd; | ||
267 | }; | ||
268 | |||
214 | #define DMX_START _IO('o', 41) | 269 | #define DMX_START _IO('o', 41) |
215 | #define DMX_STOP _IO('o', 42) | 270 | #define DMX_STOP _IO('o', 42) |
216 | #define DMX_SET_FILTER _IOW('o', 43, struct dmx_sct_filter_params) | 271 | #define DMX_SET_FILTER _IOW('o', 43, struct dmx_sct_filter_params) |
@@ -231,4 +286,10 @@ typedef struct dmx_filter dmx_filter_t; | |||
231 | 286 | ||
232 | #endif | 287 | #endif |
233 | 288 | ||
234 | #endif /* _UAPI_DVBDMX_H_ */ | 289 | #define DMX_REQBUFS _IOWR('o', 60, struct dmx_requestbuffers) |
290 | #define DMX_QUERYBUF _IOWR('o', 61, struct dmx_buffer) | ||
291 | #define DMX_EXPBUF _IOWR('o', 62, struct dmx_exportbuffer) | ||
292 | #define DMX_QBUF _IOWR('o', 63, struct dmx_buffer) | ||
293 | #define DMX_DQBUF _IOWR('o', 64, struct dmx_buffer) | ||
294 | |||
295 | #endif /* _DVBDMX_H_ */ | ||