• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * This header was generated from the Linux kernel headers by update_headers.py,
3  * to provide necessary information from kernel to userspace, such as constants,
4  * structures, and macros, and thus, contains no copyrightable information.
5  */
6 #ifndef __LINUX_UVCVIDEO_H_
7 #define __LINUX_UVCVIDEO_H_
8 #include <linux/ioctl.h>
9 #include <linux/types.h>
10 #define UVC_CTRL_DATA_TYPE_RAW		0
11 #define UVC_CTRL_DATA_TYPE_SIGNED	1
12 #define UVC_CTRL_DATA_TYPE_UNSIGNED	2
13 #define UVC_CTRL_DATA_TYPE_BOOLEAN	3
14 #define UVC_CTRL_DATA_TYPE_ENUM		4
15 #define UVC_CTRL_DATA_TYPE_BITMASK	5
16 #define UVC_CTRL_FLAG_SET_CUR		(1 << 0)
17 #define UVC_CTRL_FLAG_GET_CUR		(1 << 1)
18 #define UVC_CTRL_FLAG_GET_MIN		(1 << 2)
19 #define UVC_CTRL_FLAG_GET_MAX		(1 << 3)
20 #define UVC_CTRL_FLAG_GET_RES		(1 << 4)
21 #define UVC_CTRL_FLAG_GET_DEF		(1 << 5)
22 #define UVC_CTRL_FLAG_RESTORE		(1 << 6)
23 #define UVC_CTRL_FLAG_AUTO_UPDATE	(1 << 7)
24 #define UVC_CTRL_FLAG_ASYNCHRONOUS	(1 << 8)
25 #define UVC_CTRL_FLAG_GET_RANGE \
26 	(UVC_CTRL_FLAG_GET_CUR | UVC_CTRL_FLAG_GET_MIN | \
27 	 UVC_CTRL_FLAG_GET_MAX | UVC_CTRL_FLAG_GET_RES | \
28 	 UVC_CTRL_FLAG_GET_DEF)
29 struct uvc_menu_info {
30 	__u32 value;
31 	__u8 name[32];
32 };
33 struct uvc_xu_control_mapping {
34 	__u32 id;
35 	__u8 name[32];
36 	__u8 entity[16];
37 	__u8 selector;
38 	__u8 size;
39 	__u8 offset;
40 	__u32 v4l2_type;
41 	__u32 data_type;
42 	struct uvc_menu_info __user *menu_info;
43 	__u32 menu_count;
44 	__u32 reserved[4];
45 };
46 struct uvc_xu_control_query {
47 	__u8 unit;
48 	__u8 selector;
49 	__u8 query;
50 
51 	__u16 size;
52 	__u8 __user *data;
53 };
54 #define UVCIOC_CTRL_MAP		_IOWR('u', 0x20, struct uvc_xu_control_mapping)
55 #define UVCIOC_CTRL_QUERY	_IOWR('u', 0x21, struct uvc_xu_control_query)
56 struct uvc_meta_buf {
57 	__u64 ns;
58 	__u16 sof;
59 	__u8 length;
60 	__u8 flags;
61 	__u8 buf[];
62 } __packed;
63 #endif
64