1 /****************************************************************************
2  ****************************************************************************
3  ***
4  ***   This header was automatically generated from a Linux kernel header
5  ***   of the same name, to make information necessary for userspace to
6  ***   call into the kernel available to libc.  It contains only constants,
7  ***   structures, and macros generated from the original header, and thus,
8  ***   contains no copyrightable information.
9  ***
10  ***   To edit the content of this header, modify the corresponding
11  ***   source file (e.g. under external/kernel-headers/original/) then
12  ***   run bionic/libc/kernel/tools/update_all.py
13  ***
14  ***   Any manual change here will be lost the next time this script will
15  ***   be run. You've been warned!
16  ***
17  ****************************************************************************
18  ****************************************************************************/
19 #ifndef __UAPI_MSM_CAMERA_H
20 #define __UAPI_MSM_CAMERA_H
21 #include <linux/videodev2.h>
22 #include <linux/types.h>
23 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
24 #include <linux/ioctl.h>
25 #include <linux/msm_ion.h>
26 #define BIT(nr) (1UL << (nr))
27 #define MSM_CAM_IOCTL_MAGIC 'm'
28 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
29 #define MAX_SERVER_PAYLOAD_LENGTH 8192
30 #define MSM_CAM_IOCTL_GET_SENSOR_INFO _IOR(MSM_CAM_IOCTL_MAGIC, 1, struct msm_camsensor_info *)
31 #define MSM_CAM_IOCTL_REGISTER_PMEM _IOW(MSM_CAM_IOCTL_MAGIC, 2, struct msm_pmem_info *)
32 #define MSM_CAM_IOCTL_UNREGISTER_PMEM _IOW(MSM_CAM_IOCTL_MAGIC, 3, unsigned)
33 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
34 #define MSM_CAM_IOCTL_CTRL_COMMAND _IOW(MSM_CAM_IOCTL_MAGIC, 4, struct msm_ctrl_cmd *)
35 #define MSM_CAM_IOCTL_CONFIG_VFE _IOW(MSM_CAM_IOCTL_MAGIC, 5, struct msm_camera_vfe_cfg_cmd *)
36 #define MSM_CAM_IOCTL_GET_STATS _IOR(MSM_CAM_IOCTL_MAGIC, 6, struct msm_camera_stats_event_ctrl *)
37 #define MSM_CAM_IOCTL_GETFRAME _IOR(MSM_CAM_IOCTL_MAGIC, 7, struct msm_camera_get_frame *)
38 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
39 #define MSM_CAM_IOCTL_ENABLE_VFE _IOW(MSM_CAM_IOCTL_MAGIC, 8, struct camera_enable_cmd *)
40 #define MSM_CAM_IOCTL_CTRL_CMD_DONE _IOW(MSM_CAM_IOCTL_MAGIC, 9, struct camera_cmd *)
41 #define MSM_CAM_IOCTL_CONFIG_CMD _IOW(MSM_CAM_IOCTL_MAGIC, 10, struct camera_cmd *)
42 #define MSM_CAM_IOCTL_DISABLE_VFE _IOW(MSM_CAM_IOCTL_MAGIC, 11, struct camera_enable_cmd *)
43 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
44 #define MSM_CAM_IOCTL_PAD_REG_RESET2 _IOW(MSM_CAM_IOCTL_MAGIC, 12, struct camera_enable_cmd *)
45 #define MSM_CAM_IOCTL_VFE_APPS_RESET _IOW(MSM_CAM_IOCTL_MAGIC, 13, struct camera_enable_cmd *)
46 #define MSM_CAM_IOCTL_RELEASE_FRAME_BUFFER _IOW(MSM_CAM_IOCTL_MAGIC, 14, struct camera_enable_cmd *)
47 #define MSM_CAM_IOCTL_RELEASE_STATS_BUFFER _IOW(MSM_CAM_IOCTL_MAGIC, 15, struct msm_stats_buf *)
48 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
49 #define MSM_CAM_IOCTL_AXI_CONFIG _IOW(MSM_CAM_IOCTL_MAGIC, 16, struct msm_camera_vfe_cfg_cmd *)
50 #define MSM_CAM_IOCTL_GET_PICTURE _IOW(MSM_CAM_IOCTL_MAGIC, 17, struct msm_frame *)
51 #define MSM_CAM_IOCTL_SET_CROP _IOW(MSM_CAM_IOCTL_MAGIC, 18, struct crop_info *)
52 #define MSM_CAM_IOCTL_PICT_PP _IOW(MSM_CAM_IOCTL_MAGIC, 19, uint8_t *)
53 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
54 #define MSM_CAM_IOCTL_PICT_PP_DONE _IOW(MSM_CAM_IOCTL_MAGIC, 20, struct msm_snapshot_pp_status *)
55 #define MSM_CAM_IOCTL_SENSOR_IO_CFG _IOW(MSM_CAM_IOCTL_MAGIC, 21, struct sensor_cfg_data *)
56 #define MSM_CAM_IOCTL_FLASH_LED_CFG _IOW(MSM_CAM_IOCTL_MAGIC, 22, unsigned *)
57 #define MSM_CAM_IOCTL_UNBLOCK_POLL_FRAME _IO(MSM_CAM_IOCTL_MAGIC, 23)
58 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
59 #define MSM_CAM_IOCTL_CTRL_COMMAND_2 _IOW(MSM_CAM_IOCTL_MAGIC, 24, struct msm_ctrl_cmd *)
60 #define MSM_CAM_IOCTL_AF_CTRL _IOR(MSM_CAM_IOCTL_MAGIC, 25, struct msm_ctrl_cmt_t *)
61 #define MSM_CAM_IOCTL_AF_CTRL_DONE _IOW(MSM_CAM_IOCTL_MAGIC, 26, struct msm_ctrl_cmt_t *)
62 #define MSM_CAM_IOCTL_CONFIG_VPE _IOW(MSM_CAM_IOCTL_MAGIC, 27, struct msm_camera_vpe_cfg_cmd *)
63 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
64 #define MSM_CAM_IOCTL_AXI_VPE_CONFIG _IOW(MSM_CAM_IOCTL_MAGIC, 28, struct msm_camera_vpe_cfg_cmd *)
65 #define MSM_CAM_IOCTL_STROBE_FLASH_CFG _IOW(MSM_CAM_IOCTL_MAGIC, 29, uint32_t *)
66 #define MSM_CAM_IOCTL_STROBE_FLASH_CHARGE _IOW(MSM_CAM_IOCTL_MAGIC, 30, uint32_t *)
67 #define MSM_CAM_IOCTL_STROBE_FLASH_RELEASE _IO(MSM_CAM_IOCTL_MAGIC, 31)
68 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
69 #define MSM_CAM_IOCTL_FLASH_CTRL _IOW(MSM_CAM_IOCTL_MAGIC, 32, struct flash_ctrl_data *)
70 #define MSM_CAM_IOCTL_ERROR_CONFIG _IOW(MSM_CAM_IOCTL_MAGIC, 33, uint32_t *)
71 #define MSM_CAM_IOCTL_ABORT_CAPTURE _IO(MSM_CAM_IOCTL_MAGIC, 34)
72 #define MSM_CAM_IOCTL_SET_FD_ROI _IOW(MSM_CAM_IOCTL_MAGIC, 35, struct fd_roi_info *)
73 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
74 #define MSM_CAM_IOCTL_GET_CAMERA_INFO _IOR(MSM_CAM_IOCTL_MAGIC, 36, struct msm_camera_info *)
75 #define MSM_CAM_IOCTL_UNBLOCK_POLL_PIC_FRAME _IO(MSM_CAM_IOCTL_MAGIC, 37)
76 #define MSM_CAM_IOCTL_RELEASE_PIC_BUFFER _IOW(MSM_CAM_IOCTL_MAGIC, 38, struct camera_enable_cmd *)
77 #define MSM_CAM_IOCTL_PUT_ST_FRAME _IOW(MSM_CAM_IOCTL_MAGIC, 39, struct msm_camera_st_frame *)
78 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
79 #define MSM_CAM_IOCTL_V4L2_EVT_NOTIFY _IOW(MSM_CAM_IOCTL_MAGIC, 40, struct v4l2_event_and_payload)
80 #define MSM_CAM_IOCTL_SET_MEM_MAP_INFO _IOR(MSM_CAM_IOCTL_MAGIC, 41, struct msm_mem_map_info *)
81 #define MSM_CAM_IOCTL_ACTUATOR_IO_CFG _IOW(MSM_CAM_IOCTL_MAGIC, 42, struct msm_actuator_cfg_data *)
82 #define MSM_CAM_IOCTL_MCTL_POST_PROC _IOW(MSM_CAM_IOCTL_MAGIC, 43, struct msm_mctl_post_proc_cmd *)
83 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
84 #define MSM_CAM_IOCTL_RESERVE_FREE_FRAME _IOW(MSM_CAM_IOCTL_MAGIC, 44, struct msm_cam_evt_divert_frame *)
85 #define MSM_CAM_IOCTL_RELEASE_FREE_FRAME _IOR(MSM_CAM_IOCTL_MAGIC, 45, struct msm_cam_evt_divert_frame *)
86 #define MSM_CAM_IOCTL_PICT_PP_DIVERT_DONE _IOR(MSM_CAM_IOCTL_MAGIC, 46, struct msm_pp_frame *)
87 #define MSM_CAM_IOCTL_SENSOR_V4l2_S_CTRL _IOR(MSM_CAM_IOCTL_MAGIC, 47, struct v4l2_control)
88 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
89 #define MSM_CAM_IOCTL_SENSOR_V4l2_QUERY_CTRL _IOR(MSM_CAM_IOCTL_MAGIC, 48, struct v4l2_queryctrl)
90 #define MSM_CAM_IOCTL_GET_KERNEL_SYSTEM_TIME _IOW(MSM_CAM_IOCTL_MAGIC, 49, struct timeval *)
91 #define MSM_CAM_IOCTL_SET_VFE_OUTPUT_TYPE _IOW(MSM_CAM_IOCTL_MAGIC, 50, uint32_t *)
92 #define MSM_CAM_IOCTL_MCTL_DIVERT_DONE _IOR(MSM_CAM_IOCTL_MAGIC, 51, struct msm_cam_evt_divert_frame *)
93 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
94 #define MSM_CAM_IOCTL_GET_ACTUATOR_INFO _IOW(MSM_CAM_IOCTL_MAGIC, 52, struct msm_actuator_cfg_data *)
95 #define MSM_CAM_IOCTL_EEPROM_IO_CFG _IOW(MSM_CAM_IOCTL_MAGIC, 53, struct msm_eeprom_cfg_data *)
96 #define MSM_CAM_IOCTL_ISPIF_IO_CFG _IOR(MSM_CAM_IOCTL_MAGIC, 54, struct ispif_cfg_data *)
97 #define MSM_CAM_IOCTL_STATS_REQBUF _IOR(MSM_CAM_IOCTL_MAGIC, 55, struct msm_stats_reqbuf *)
98 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
99 #define MSM_CAM_IOCTL_STATS_ENQUEUEBUF _IOR(MSM_CAM_IOCTL_MAGIC, 56, struct msm_stats_buf_info *)
100 #define MSM_CAM_IOCTL_STATS_FLUSH_BUFQ _IOR(MSM_CAM_IOCTL_MAGIC, 57, struct msm_stats_flush_bufq *)
101 #define MSM_CAM_IOCTL_SET_MCTL_SDEV _IOW(MSM_CAM_IOCTL_MAGIC, 58, struct msm_mctl_set_sdev_data *)
102 #define MSM_CAM_IOCTL_UNSET_MCTL_SDEV _IOW(MSM_CAM_IOCTL_MAGIC, 59, struct msm_mctl_set_sdev_data *)
103 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
104 #define MSM_CAM_IOCTL_GET_INST_HANDLE _IOR(MSM_CAM_IOCTL_MAGIC, 60, uint32_t *)
105 #define MSM_CAM_IOCTL_STATS_UNREG_BUF _IOR(MSM_CAM_IOCTL_MAGIC, 61, struct msm_stats_flush_bufq *)
106 #define MSM_CAM_IOCTL_CSIC_IO_CFG _IOWR(MSM_CAM_IOCTL_MAGIC, 62, struct csic_cfg_data *)
107 #define MSM_CAM_IOCTL_CSID_IO_CFG _IOWR(MSM_CAM_IOCTL_MAGIC, 63, struct csid_cfg_data *)
108 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
109 #define MSM_CAM_IOCTL_CSIPHY_IO_CFG _IOR(MSM_CAM_IOCTL_MAGIC, 64, struct csiphy_cfg_data *)
110 #define MSM_CAM_IOCTL_OEM _IOW(MSM_CAM_IOCTL_MAGIC, 65, struct sensor_cfg_data *)
111 #define MSM_CAM_IOCTL_AXI_INIT _IOWR(MSM_CAM_IOCTL_MAGIC, 66, uint8_t *)
112 #define MSM_CAM_IOCTL_AXI_RELEASE _IO(MSM_CAM_IOCTL_MAGIC, 67)
113 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
114 struct v4l2_event_and_payload {
115   struct v4l2_event evt;
116   uint32_t payload_length;
117   uint32_t transaction_id;
118 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
119   void * payload;
120 };
121 struct msm_stats_reqbuf {
122   int num_buf;
123 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
124   int stats_type;
125 };
126 struct msm_stats_flush_bufq {
127   int stats_type;
128 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
129 };
130 struct msm_mctl_pp_cmd {
131   int32_t id;
132   uint16_t length;
133 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
134   void * value;
135 };
136 struct msm_mctl_post_proc_cmd {
137   int32_t type;
138 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
139   struct msm_mctl_pp_cmd cmd;
140 };
141 #define MSM_CAMERA_LED_OFF 0
142 #define MSM_CAMERA_LED_LOW 1
143 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
144 #define MSM_CAMERA_LED_HIGH 2
145 #define MSM_CAMERA_LED_INIT 3
146 #define MSM_CAMERA_LED_RELEASE 4
147 #define MSM_CAMERA_STROBE_FLASH_NONE 0
148 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
149 #define MSM_CAMERA_STROBE_FLASH_XENON 1
150 #define MSM_MAX_CAMERA_SENSORS 5
151 #define MAX_SENSOR_NAME 32
152 #define MAX_CAM_NAME_SIZE 32
153 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
154 #define MAX_ACT_MOD_NAME_SIZE 32
155 #define MAX_ACT_NAME_SIZE 32
156 #define NUM_ACTUATOR_DIR 2
157 #define MAX_ACTUATOR_SCENARIO 8
158 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
159 #define MAX_ACTUATOR_REGION 5
160 #define MAX_ACTUATOR_INIT_SET 12
161 #define MAX_ACTUATOR_TYPE_SIZE 32
162 #define MAX_ACTUATOR_REG_TBL_SIZE 8
163 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
164 #define MSM_MAX_CAMERA_CONFIGS 2
165 #define PP_SNAP 0x01
166 #define PP_RAW_SNAP ((0x01) << 1)
167 #define PP_PREV ((0x01) << 2)
168 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
169 #define PP_THUMB ((0x01) << 3)
170 #define PP_MASK (PP_SNAP | PP_RAW_SNAP | PP_PREV | PP_THUMB)
171 #define MSM_CAM_CTRL_CMD_DONE 0
172 #define MSM_CAM_SENSOR_VFE_CMD 1
173 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
174 #define MAX_PLANES 8
175 struct msm_ctrl_cmd {
176   uint16_t type;
177   uint16_t length;
178 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
179   void * value;
180   uint16_t status;
181   uint32_t timeout_ms;
182   int resp_fd;
183 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
184   int vnode_id;
185   int queue_idx;
186   uint32_t evt_id;
187   uint32_t stream_type;
188 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
189   int config_ident;
190 };
191 struct msm_cam_evt_msg {
192   unsigned short type;
193 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
194   unsigned short msg_id;
195   unsigned int len;
196   uint32_t frame_id;
197   void * data;
198 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
199   struct timespec timestamp;
200 };
201 struct msm_pp_frame_sp {
202   unsigned long phy_addr;
203 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
204   uint32_t y_off;
205   uint32_t cbcr_off;
206   uint32_t length;
207   int32_t fd;
208 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
209   uint32_t addr_offset;
210   unsigned long vaddr;
211 };
212 struct msm_pp_frame_mp {
213 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
214   unsigned long phy_addr;
215   uint32_t data_offset;
216   uint32_t length;
217   int32_t fd;
218 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
219   uint32_t addr_offset;
220   unsigned long vaddr;
221 };
222 struct msm_pp_frame {
223 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
224   uint32_t handle;
225   uint32_t frame_id;
226   unsigned short buf_idx;
227   int path;
228 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
229   unsigned short image_type;
230   unsigned short num_planes;
231   struct timeval timestamp;
232   union {
233 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
234     struct msm_pp_frame_sp sp;
235     struct msm_pp_frame_mp mp[MAX_PLANES];
236   };
237   int node_type;
238 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
239   uint32_t inst_handle;
240 };
241 struct msm_pp_crop {
242   uint32_t src_x;
243 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
244   uint32_t src_y;
245   uint32_t src_w;
246   uint32_t src_h;
247   uint32_t dst_x;
248 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
249   uint32_t dst_y;
250   uint32_t dst_w;
251   uint32_t dst_h;
252   uint8_t update_flag;
253 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
254 };
255 struct msm_mctl_pp_frame_cmd {
256   uint32_t cookie;
257   uint8_t vpe_output_action;
258 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
259   struct msm_pp_frame src_frame;
260   struct msm_pp_frame dest_frame;
261   struct msm_pp_crop crop;
262   int path;
263 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
264 };
265 struct msm_cam_evt_divert_frame {
266   unsigned short image_mode;
267   unsigned short op_mode;
268 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
269   unsigned short inst_idx;
270   unsigned short node_idx;
271   struct msm_pp_frame frame;
272   int do_pp;
273 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
274 };
275 struct msm_mctl_pp_cmd_ack_event {
276   uint32_t cmd;
277   int status;
278 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
279   uint32_t cookie;
280 };
281 struct msm_mctl_pp_event_info {
282   int32_t event;
283 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
284   union {
285     struct msm_mctl_pp_cmd_ack_event ack;
286   };
287 };
288 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
289 struct msm_isp_event_ctrl {
290   unsigned short resptype;
291   union {
292     struct msm_cam_evt_msg isp_msg;
293 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
294     struct msm_ctrl_cmd ctrl;
295     struct msm_cam_evt_divert_frame div_frame;
296     struct msm_mctl_pp_event_info pp_event_info;
297   } isp_data;
298 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
299 };
300 #define MSM_CAM_RESP_CTRL 0
301 #define MSM_CAM_RESP_STAT_EVT_MSG 1
302 #define MSM_CAM_RESP_STEREO_OP_1 2
303 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
304 #define MSM_CAM_RESP_STEREO_OP_2 3
305 #define MSM_CAM_RESP_V4L2 4
306 #define MSM_CAM_RESP_DIV_FRAME_EVT_MSG 5
307 #define MSM_CAM_RESP_DONE_EVENT 6
308 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
309 #define MSM_CAM_RESP_MCTL_PP_EVENT 7
310 #define MSM_CAM_RESP_MAX 8
311 #define MSM_CAM_APP_NOTIFY_EVENT 0
312 #define MSM_CAM_APP_NOTIFY_ERROR_EVENT 1
313 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
314 struct msm_stats_event_ctrl {
315   int resptype;
316   int timeout_ms;
317   struct msm_ctrl_cmd ctrl_cmd;
318 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
319   struct msm_cam_evt_msg stats_event;
320 };
321 struct msm_camera_cfg_cmd {
322   uint16_t cfg_type;
323 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
324   uint16_t cmd_type;
325   uint16_t queue;
326   uint16_t length;
327   void * value;
328 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
329 };
330 #define CMD_GENERAL 0
331 #define CMD_AXI_CFG_OUT1 1
332 #define CMD_AXI_CFG_SNAP_O1_AND_O2 2
333 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
334 #define CMD_AXI_CFG_OUT2 3
335 #define CMD_PICT_T_AXI_CFG 4
336 #define CMD_PICT_M_AXI_CFG 5
337 #define CMD_RAW_PICT_AXI_CFG 6
338 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
339 #define CMD_FRAME_BUF_RELEASE 7
340 #define CMD_PREV_BUF_CFG 8
341 #define CMD_SNAP_BUF_RELEASE 9
342 #define CMD_SNAP_BUF_CFG 10
343 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
344 #define CMD_STATS_DISABLE 11
345 #define CMD_STATS_AEC_AWB_ENABLE 12
346 #define CMD_STATS_AF_ENABLE 13
347 #define CMD_STATS_AEC_ENABLE 14
348 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
349 #define CMD_STATS_AWB_ENABLE 15
350 #define CMD_STATS_ENABLE 16
351 #define CMD_STATS_AXI_CFG 17
352 #define CMD_STATS_AEC_AXI_CFG 18
353 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
354 #define CMD_STATS_AF_AXI_CFG 19
355 #define CMD_STATS_AWB_AXI_CFG 20
356 #define CMD_STATS_RS_AXI_CFG 21
357 #define CMD_STATS_CS_AXI_CFG 22
358 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
359 #define CMD_STATS_IHIST_AXI_CFG 23
360 #define CMD_STATS_SKIN_AXI_CFG 24
361 #define CMD_STATS_BUF_RELEASE 25
362 #define CMD_STATS_AEC_BUF_RELEASE 26
363 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
364 #define CMD_STATS_AF_BUF_RELEASE 27
365 #define CMD_STATS_AWB_BUF_RELEASE 28
366 #define CMD_STATS_RS_BUF_RELEASE 29
367 #define CMD_STATS_CS_BUF_RELEASE 30
368 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
369 #define CMD_STATS_IHIST_BUF_RELEASE 31
370 #define CMD_STATS_SKIN_BUF_RELEASE 32
371 #define UPDATE_STATS_INVALID 33
372 #define CMD_AXI_CFG_SNAP_GEMINI 34
373 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
374 #define CMD_AXI_CFG_SNAP 35
375 #define CMD_AXI_CFG_PREVIEW 36
376 #define CMD_AXI_CFG_VIDEO 37
377 #define CMD_STATS_IHIST_ENABLE 38
378 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
379 #define CMD_STATS_RS_ENABLE 39
380 #define CMD_STATS_CS_ENABLE 40
381 #define CMD_VPE 41
382 #define CMD_AXI_CFG_VPE 42
383 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
384 #define CMD_AXI_CFG_ZSL 43
385 #define CMD_AXI_CFG_SNAP_VPE 44
386 #define CMD_AXI_CFG_SNAP_THUMB_VPE 45
387 #define CMD_CONFIG_PING_ADDR 46
388 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
389 #define CMD_CONFIG_PONG_ADDR 47
390 #define CMD_CONFIG_FREE_BUF_ADDR 48
391 #define CMD_AXI_CFG_ZSL_ALL_CHNLS 49
392 #define CMD_AXI_CFG_VIDEO_ALL_CHNLS 50
393 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
394 #define CMD_VFE_BUFFER_RELEASE 51
395 #define CMD_VFE_PROCESS_IRQ 52
396 #define CMD_STATS_BG_ENABLE 53
397 #define CMD_STATS_BF_ENABLE 54
398 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
399 #define CMD_STATS_BHIST_ENABLE 55
400 #define CMD_STATS_BG_BUF_RELEASE 56
401 #define CMD_STATS_BF_BUF_RELEASE 57
402 #define CMD_STATS_BHIST_BUF_RELEASE 58
403 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
404 #define CMD_VFE_PIX_SOF_COUNT_UPDATE 59
405 #define CMD_VFE_COUNT_PIX_SOF_ENABLE 60
406 #define CMD_STATS_BE_ENABLE 61
407 #define CMD_STATS_BE_BUF_RELEASE 62
408 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
409 #define CMD_AXI_CFG_PRIM BIT(8)
410 #define CMD_AXI_CFG_PRIM_ALL_CHNLS BIT(9)
411 #define CMD_AXI_CFG_SEC BIT(10)
412 #define CMD_AXI_CFG_SEC_ALL_CHNLS BIT(11)
413 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
414 #define CMD_AXI_CFG_TERT1 BIT(12)
415 #define CMD_AXI_CFG_TERT2 BIT(13)
416 #define CMD_AXI_START 0xE1
417 #define CMD_AXI_STOP 0xE2
418 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
419 #define CMD_AXI_RESET 0xE3
420 #define CMD_AXI_ABORT 0xE4
421 #define AXI_CMD_PREVIEW BIT(0)
422 #define AXI_CMD_CAPTURE BIT(1)
423 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
424 #define AXI_CMD_RECORD BIT(2)
425 #define AXI_CMD_ZSL BIT(3)
426 #define AXI_CMD_RAW_CAPTURE BIT(4)
427 #define AXI_CMD_LIVESHOT BIT(5)
428 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
429 struct msm_vfe_cfg_cmd {
430   int cmd_type;
431   uint16_t length;
432   void * value;
433 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
434 };
435 struct msm_vpe_cfg_cmd {
436   int cmd_type;
437   uint16_t length;
438 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
439   void * value;
440 };
441 #define MAX_CAMERA_ENABLE_NAME_LEN 32
442 struct camera_enable_cmd {
443 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
444   char name[MAX_CAMERA_ENABLE_NAME_LEN];
445 };
446 #define MSM_PMEM_OUTPUT1 0
447 #define MSM_PMEM_OUTPUT2 1
448 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
449 #define MSM_PMEM_OUTPUT1_OUTPUT2 2
450 #define MSM_PMEM_THUMBNAIL 3
451 #define MSM_PMEM_MAINIMG 4
452 #define MSM_PMEM_RAW_MAINIMG 5
453 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
454 #define MSM_PMEM_AEC_AWB 6
455 #define MSM_PMEM_AF 7
456 #define MSM_PMEM_AEC 8
457 #define MSM_PMEM_AWB 9
458 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
459 #define MSM_PMEM_RS 10
460 #define MSM_PMEM_CS 11
461 #define MSM_PMEM_IHIST 12
462 #define MSM_PMEM_SKIN 13
463 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
464 #define MSM_PMEM_VIDEO 14
465 #define MSM_PMEM_PREVIEW 15
466 #define MSM_PMEM_VIDEO_VPE 16
467 #define MSM_PMEM_C2D 17
468 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
469 #define MSM_PMEM_MAINIMG_VPE 18
470 #define MSM_PMEM_THUMBNAIL_VPE 19
471 #define MSM_PMEM_BAYER_GRID 20
472 #define MSM_PMEM_BAYER_FOCUS 21
473 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
474 #define MSM_PMEM_BAYER_HIST 22
475 #define MSM_PMEM_BAYER_EXPOSURE 23
476 #define MSM_PMEM_MAX 24
477 #define STAT_AEAW 0
478 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
479 #define STAT_AEC 1
480 #define STAT_AF 2
481 #define STAT_AWB 3
482 #define STAT_RS 4
483 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
484 #define STAT_CS 5
485 #define STAT_IHIST 6
486 #define STAT_SKIN 7
487 #define STAT_BG 8
488 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
489 #define STAT_BF 9
490 #define STAT_BE 10
491 #define STAT_BHIST 11
492 #define STAT_MAX 12
493 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
494 #define FRAME_PREVIEW_OUTPUT1 0
495 #define FRAME_PREVIEW_OUTPUT2 1
496 #define FRAME_SNAPSHOT 2
497 #define FRAME_THUMBNAIL 3
498 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
499 #define FRAME_RAW_SNAPSHOT 4
500 #define FRAME_MAX 5
501 enum msm_stats_enum_type {
502   MSM_STATS_TYPE_AEC,
503 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
504   MSM_STATS_TYPE_AF,
505   MSM_STATS_TYPE_AWB,
506   MSM_STATS_TYPE_RS,
507   MSM_STATS_TYPE_CS,
508 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
509   MSM_STATS_TYPE_IHIST,
510   MSM_STATS_TYPE_SKIN,
511   MSM_STATS_TYPE_BG,
512   MSM_STATS_TYPE_BF,
513 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
514   MSM_STATS_TYPE_BE,
515   MSM_STATS_TYPE_BHIST,
516   MSM_STATS_TYPE_AE_AW,
517   MSM_STATS_TYPE_COMP,
518 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
519   MSM_STATS_TYPE_MAX
520 };
521 struct msm_stats_buf_info {
522   int type;
523 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
524   int fd;
525   void * vaddr;
526   uint32_t offset;
527   uint32_t len;
528 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
529   uint32_t y_off;
530   uint32_t cbcr_off;
531   uint32_t planar0_off;
532   uint32_t planar1_off;
533 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
534   uint32_t planar2_off;
535   uint8_t active;
536   int buf_idx;
537 };
538 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
539 struct msm_pmem_info {
540   int type;
541   int fd;
542   void * vaddr;
543 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
544   uint32_t offset;
545   uint32_t len;
546   uint32_t y_off;
547   uint32_t cbcr_off;
548 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
549   uint32_t planar0_off;
550   uint32_t planar1_off;
551   uint32_t planar2_off;
552   uint8_t active;
553 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
554 };
555 struct outputCfg {
556   uint32_t height;
557   uint32_t width;
558 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
559   uint32_t window_height_firstline;
560   uint32_t window_height_lastline;
561 };
562 #define VIDEO_NODE 0
563 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
564 #define MCTL_NODE 1
565 #define OUTPUT_1 0
566 #define OUTPUT_2 1
567 #define OUTPUT_1_AND_2 2
568 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
569 #define OUTPUT_1_AND_3 3
570 #define CAMIF_TO_AXI_VIA_OUTPUT_2 4
571 #define OUTPUT_1_AND_CAMIF_TO_AXI_VIA_OUTPUT_2 5
572 #define OUTPUT_2_AND_CAMIF_TO_AXI_VIA_OUTPUT_1 6
573 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
574 #define OUTPUT_1_2_AND_3 7
575 #define OUTPUT_ALL_CHNLS 8
576 #define OUTPUT_VIDEO_ALL_CHNLS 9
577 #define OUTPUT_ZSL_ALL_CHNLS 10
578 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
579 #define LAST_AXI_OUTPUT_MODE_ENUM OUTPUT_ZSL_ALL_CHNLS
580 #define OUTPUT_PRIM BIT(8)
581 #define OUTPUT_PRIM_ALL_CHNLS BIT(9)
582 #define OUTPUT_SEC BIT(10)
583 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
584 #define OUTPUT_SEC_ALL_CHNLS BIT(11)
585 #define OUTPUT_TERT1 BIT(12)
586 #define OUTPUT_TERT2 BIT(13)
587 #define MSM_FRAME_PREV_1 0
588 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
589 #define MSM_FRAME_PREV_2 1
590 #define MSM_FRAME_ENC 2
591 #define OUTPUT_TYPE_P BIT(0)
592 #define OUTPUT_TYPE_T BIT(1)
593 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
594 #define OUTPUT_TYPE_S BIT(2)
595 #define OUTPUT_TYPE_V BIT(3)
596 #define OUTPUT_TYPE_L BIT(4)
597 #define OUTPUT_TYPE_ST_L BIT(5)
598 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
599 #define OUTPUT_TYPE_ST_R BIT(6)
600 #define OUTPUT_TYPE_ST_D BIT(7)
601 #define OUTPUT_TYPE_R BIT(8)
602 #define OUTPUT_TYPE_R1 BIT(9)
603 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
604 #define OUTPUT_TYPE_SAEC BIT(10)
605 #define OUTPUT_TYPE_SAFC BIT(11)
606 #define OUTPUT_TYPE_SAWB BIT(12)
607 #define OUTPUT_TYPE_IHST BIT(13)
608 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
609 #define OUTPUT_TYPE_CSTA BIT(14)
610 struct fd_roi_info {
611   void * info;
612   int info_len;
613 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
614 };
615 struct msm_mem_map_info {
616   uint32_t cookie;
617   uint32_t length;
618 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
619   uint32_t mem_type;
620 };
621 #define MSM_MEM_MMAP 0
622 #define MSM_MEM_USERPTR 1
623 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
624 #define MSM_PLANE_MAX 8
625 #define MSM_PLANE_Y 0
626 #define MSM_PLANE_UV 1
627 struct msm_frame {
628 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
629   struct timespec ts;
630   int path;
631   int type;
632   unsigned long buffer;
633 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
634   uint32_t phy_offset;
635   uint32_t y_off;
636   uint32_t cbcr_off;
637   uint32_t planar0_off;
638 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
639   uint32_t planar1_off;
640   uint32_t planar2_off;
641   int fd;
642   void * cropinfo;
643 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
644   int croplen;
645   uint32_t error_code;
646   struct fd_roi_info roi_info;
647   uint32_t frame_id;
648 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
649   int stcam_quality_ind;
650   uint32_t stcam_conv_value;
651   struct ion_allocation_data ion_alloc;
652   struct ion_fd_data fd_data;
653 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
654   int ion_dev_fd;
655 };
656 enum msm_st_frame_packing {
657   SIDE_BY_SIDE_HALF,
658 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
659   SIDE_BY_SIDE_FULL,
660   TOP_DOWN_HALF,
661   TOP_DOWN_FULL,
662 };
663 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
664 struct msm_st_crop {
665   uint32_t in_w;
666   uint32_t in_h;
667   uint32_t out_w;
668 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
669   uint32_t out_h;
670 };
671 struct msm_st_half {
672   uint32_t buf_p0_off;
673 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
674   uint32_t buf_p1_off;
675   uint32_t buf_p0_stride;
676   uint32_t buf_p1_stride;
677   uint32_t pix_x_off;
678 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
679   uint32_t pix_y_off;
680   struct msm_st_crop stCropInfo;
681 };
682 struct msm_st_frame {
683 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
684   struct msm_frame buf_info;
685   int type;
686   enum msm_st_frame_packing packing;
687   struct msm_st_half L;
688 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
689   struct msm_st_half R;
690   int frame_id;
691 };
692 #define MSM_CAMERA_ERR_MASK (0xFFFFFFFF & 1)
693 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
694 struct stats_buff {
695   unsigned long buff;
696   int fd;
697 };
698 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
699 struct msm_stats_buf {
700   uint8_t awb_ymin;
701   struct stats_buff aec;
702   struct stats_buff awb;
703 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
704   struct stats_buff af;
705   struct stats_buff be;
706   struct stats_buff ihist;
707   struct stats_buff rs;
708 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
709   struct stats_buff cs;
710   struct stats_buff skin;
711   int type;
712   uint32_t status_bits;
713 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
714   unsigned long buffer;
715   int fd;
716   int length;
717   struct ion_handle * handle;
718 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
719   uint32_t frame_id;
720   int buf_idx;
721 };
722 #define MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT 0
723 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
724 #define MSM_V4L2_EXT_CAPTURE_MODE_PREVIEW (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 1)
725 #define MSM_V4L2_EXT_CAPTURE_MODE_VIDEO (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 2)
726 #define MSM_V4L2_EXT_CAPTURE_MODE_MAIN (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 3)
727 #define MSM_V4L2_EXT_CAPTURE_MODE_THUMBNAIL (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 4)
728 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
729 #define MSM_V4L2_EXT_CAPTURE_MODE_ISP_PIX_OUTPUT1 (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 5)
730 #define MSM_V4L2_EXT_CAPTURE_MODE_ISP_PIX_OUTPUT2 (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 6)
731 #define MSM_V4L2_EXT_CAPTURE_MODE_RAW (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 7)
732 #define MSM_V4L2_EXT_CAPTURE_MODE_RDI (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 8)
733 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
734 #define MSM_V4L2_EXT_CAPTURE_MODE_RDI1 (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 9)
735 #define MSM_V4L2_EXT_CAPTURE_MODE_RDI2 (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 10)
736 #define MSM_V4L2_EXT_CAPTURE_MODE_AEC (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 11)
737 #define MSM_V4L2_EXT_CAPTURE_MODE_AWB (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 12)
738 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
739 #define MSM_V4L2_EXT_CAPTURE_MODE_AF (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 13)
740 #define MSM_V4L2_EXT_CAPTURE_MODE_IHIST (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 14)
741 #define MSM_V4L2_EXT_CAPTURE_MODE_CS (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 15)
742 #define MSM_V4L2_EXT_CAPTURE_MODE_RS (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 16)
743 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
744 #define MSM_V4L2_EXT_CAPTURE_MODE_CSTA (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 17)
745 #define MSM_V4L2_EXT_CAPTURE_MODE_V2X_LIVESHOT (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 18)
746 #define MSM_V4L2_EXT_CAPTURE_MODE_MAX (MSM_V4L2_EXT_CAPTURE_MODE_DEFAULT + 19)
747 #define MSM_V4L2_PID_MOTION_ISO V4L2_CID_PRIVATE_BASE
748 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
749 #define MSM_V4L2_PID_EFFECT (V4L2_CID_PRIVATE_BASE + 1)
750 #define MSM_V4L2_PID_HJR (V4L2_CID_PRIVATE_BASE + 2)
751 #define MSM_V4L2_PID_LED_MODE (V4L2_CID_PRIVATE_BASE + 3)
752 #define MSM_V4L2_PID_PREP_SNAPSHOT (V4L2_CID_PRIVATE_BASE + 4)
753 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
754 #define MSM_V4L2_PID_EXP_METERING (V4L2_CID_PRIVATE_BASE + 5)
755 #define MSM_V4L2_PID_ISO (V4L2_CID_PRIVATE_BASE + 6)
756 #define MSM_V4L2_PID_CAM_MODE (V4L2_CID_PRIVATE_BASE + 7)
757 #define MSM_V4L2_PID_LUMA_ADAPTATION (V4L2_CID_PRIVATE_BASE + 8)
758 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
759 #define MSM_V4L2_PID_BEST_SHOT (V4L2_CID_PRIVATE_BASE + 9)
760 #define MSM_V4L2_PID_FOCUS_MODE (V4L2_CID_PRIVATE_BASE + 10)
761 #define MSM_V4L2_PID_BL_DETECTION (V4L2_CID_PRIVATE_BASE + 11)
762 #define MSM_V4L2_PID_SNOW_DETECTION (V4L2_CID_PRIVATE_BASE + 12)
763 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
764 #define MSM_V4L2_PID_CTRL_CMD (V4L2_CID_PRIVATE_BASE + 13)
765 #define MSM_V4L2_PID_EVT_SUB_INFO (V4L2_CID_PRIVATE_BASE + 14)
766 #define MSM_V4L2_PID_STROBE_FLASH (V4L2_CID_PRIVATE_BASE + 15)
767 #define MSM_V4L2_PID_INST_HANDLE (V4L2_CID_PRIVATE_BASE + 16)
768 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
769 #define MSM_V4L2_PID_MMAP_INST (V4L2_CID_PRIVATE_BASE + 17)
770 #define MSM_V4L2_PID_PP_PLANE_INFO (V4L2_CID_PRIVATE_BASE + 18)
771 #define MSM_V4L2_PID_MAX MSM_V4L2_PID_PP_PLANE_INFO
772 #define MSM_V4L2_CAM_OP_DEFAULT 0
773 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
774 #define MSM_V4L2_CAM_OP_PREVIEW (MSM_V4L2_CAM_OP_DEFAULT + 1)
775 #define MSM_V4L2_CAM_OP_VIDEO (MSM_V4L2_CAM_OP_DEFAULT + 2)
776 #define MSM_V4L2_CAM_OP_CAPTURE (MSM_V4L2_CAM_OP_DEFAULT + 3)
777 #define MSM_V4L2_CAM_OP_ZSL (MSM_V4L2_CAM_OP_DEFAULT + 4)
778 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
779 #define MSM_V4L2_CAM_OP_RAW (MSM_V4L2_CAM_OP_DEFAULT + 5)
780 #define MSM_V4L2_CAM_OP_JPEG_CAPTURE (MSM_V4L2_CAM_OP_DEFAULT + 6)
781 #define MSM_V4L2_VID_CAP_TYPE 0
782 #define MSM_V4L2_STREAM_ON 1
783 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
784 #define MSM_V4L2_STREAM_OFF 2
785 #define MSM_V4L2_SNAPSHOT 3
786 #define MSM_V4L2_QUERY_CTRL 4
787 #define MSM_V4L2_GET_CTRL 5
788 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
789 #define MSM_V4L2_SET_CTRL 6
790 #define MSM_V4L2_QUERY 7
791 #define MSM_V4L2_GET_CROP 8
792 #define MSM_V4L2_SET_CROP 9
793 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
794 #define MSM_V4L2_OPEN 10
795 #define MSM_V4L2_CLOSE 11
796 #define MSM_V4L2_SET_CTRL_CMD 12
797 #define MSM_V4L2_EVT_SUB_MASK 13
798 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
799 #define MSM_V4L2_PRIVATE_CMD 14
800 #define MSM_V4L2_MAX 15
801 #define V4L2_CAMERA_EXIT 43
802 struct crop_info {
803 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
804   void * info;
805   int len;
806 };
807 struct msm_postproc {
808 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
809   int ftnum;
810   struct msm_frame fthumnail;
811   int fmnum;
812   struct msm_frame fmain;
813 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
814 };
815 struct msm_snapshot_pp_status {
816   void * status;
817 };
818 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
819 #define CFG_SET_MODE 0
820 #define CFG_SET_EFFECT 1
821 #define CFG_START 2
822 #define CFG_PWR_UP 3
823 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
824 #define CFG_PWR_DOWN 4
825 #define CFG_WRITE_EXPOSURE_GAIN 5
826 #define CFG_SET_DEFAULT_FOCUS 6
827 #define CFG_MOVE_FOCUS 7
828 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
829 #define CFG_REGISTER_TO_REAL_GAIN 8
830 #define CFG_REAL_TO_REGISTER_GAIN 9
831 #define CFG_SET_FPS 10
832 #define CFG_SET_PICT_FPS 11
833 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
834 #define CFG_SET_BRIGHTNESS 12
835 #define CFG_SET_CONTRAST 13
836 #define CFG_SET_ZOOM 14
837 #define CFG_SET_EXPOSURE_MODE 15
838 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
839 #define CFG_SET_WB 16
840 #define CFG_SET_ANTIBANDING 17
841 #define CFG_SET_EXP_GAIN 18
842 #define CFG_SET_PICT_EXP_GAIN 19
843 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
844 #define CFG_SET_LENS_SHADING 20
845 #define CFG_GET_PICT_FPS 21
846 #define CFG_GET_PREV_L_PF 22
847 #define CFG_GET_PREV_P_PL 23
848 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
849 #define CFG_GET_PICT_L_PF 24
850 #define CFG_GET_PICT_P_PL 25
851 #define CFG_GET_AF_MAX_STEPS 26
852 #define CFG_GET_PICT_MAX_EXP_LC 27
853 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
854 #define CFG_SEND_WB_INFO 28
855 #define CFG_SENSOR_INIT 29
856 #define CFG_GET_3D_CALI_DATA 30
857 #define CFG_GET_CALIB_DATA 31
858 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
859 #define CFG_GET_OUTPUT_INFO 32
860 #define CFG_GET_EEPROM_INFO 33
861 #define CFG_GET_EEPROM_DATA 34
862 #define CFG_SET_ACTUATOR_INFO 35
863 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
864 #define CFG_GET_ACTUATOR_INFO 36
865 #define CFG_SET_SATURATION 37
866 #define CFG_SET_SHARPNESS 38
867 #define CFG_SET_TOUCHAEC 39
868 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
869 #define CFG_SET_AUTO_FOCUS 40
870 #define CFG_SET_AUTOFLASH 41
871 #define CFG_SET_EXPOSURE_COMPENSATION 42
872 #define CFG_SET_ISO 43
873 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
874 #define CFG_START_STREAM 44
875 #define CFG_STOP_STREAM 45
876 #define CFG_GET_CSI_PARAMS 46
877 #define CFG_POWER_UP 47
878 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
879 #define CFG_POWER_DOWN 48
880 #define CFG_WRITE_I2C_ARRAY 49
881 #define CFG_READ_I2C_ARRAY 50
882 #define CFG_PCLK_CHANGE 51
883 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
884 #define CFG_CONFIG_VREG_ARRAY 52
885 #define CFG_CONFIG_CLK_ARRAY 53
886 #define CFG_GPIO_OP 54
887 #define CFG_MAX 55
888 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
889 #define MOVE_NEAR 0
890 #define MOVE_FAR 1
891 #define SENSOR_PREVIEW_MODE 0
892 #define SENSOR_SNAPSHOT_MODE 1
893 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
894 #define SENSOR_RAW_SNAPSHOT_MODE 2
895 #define SENSOR_HFR_60FPS_MODE 3
896 #define SENSOR_HFR_90FPS_MODE 4
897 #define SENSOR_HFR_120FPS_MODE 5
898 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
899 #define SENSOR_QTR_SIZE 0
900 #define SENSOR_FULL_SIZE 1
901 #define SENSOR_QVGA_SIZE 2
902 #define SENSOR_INVALID_SIZE 3
903 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
904 #define CAMERA_EFFECT_OFF 0
905 #define CAMERA_EFFECT_MONO 1
906 #define CAMERA_EFFECT_NEGATIVE 2
907 #define CAMERA_EFFECT_SOLARIZE 3
908 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
909 #define CAMERA_EFFECT_SEPIA 4
910 #define CAMERA_EFFECT_POSTERIZE 5
911 #define CAMERA_EFFECT_WHITEBOARD 6
912 #define CAMERA_EFFECT_BLACKBOARD 7
913 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
914 #define CAMERA_EFFECT_AQUA 8
915 #define CAMERA_EFFECT_EMBOSS 9
916 #define CAMERA_EFFECT_SKETCH 10
917 #define CAMERA_EFFECT_NEON 11
918 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
919 #define CAMERA_EFFECT_FADED 12
920 #define CAMERA_EFFECT_VINTAGECOOL 13
921 #define CAMERA_EFFECT_VINTAGEWARM 14
922 #define CAMERA_EFFECT_ACCENT_BLUE 15
923 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
924 #define CAMERA_EFFECT_ACCENT_GREEN 16
925 #define CAMERA_EFFECT_ACCENT_ORANGE 17
926 #define CAMERA_EFFECT_MAX 18
927 #define CAMERA_EFFECT_BW 10
928 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
929 #define CAMERA_EFFECT_BLUISH 12
930 #define CAMERA_EFFECT_REDDISH 13
931 #define CAMERA_EFFECT_GREENISH 14
932 #define CAMERA_ANTIBANDING_OFF 0
933 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
934 #define CAMERA_ANTIBANDING_50HZ 2
935 #define CAMERA_ANTIBANDING_60HZ 1
936 #define CAMERA_ANTIBANDING_AUTO 3
937 #define CAMERA_CONTRAST_LV0 0
938 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
939 #define CAMERA_CONTRAST_LV1 1
940 #define CAMERA_CONTRAST_LV2 2
941 #define CAMERA_CONTRAST_LV3 3
942 #define CAMERA_CONTRAST_LV4 4
943 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
944 #define CAMERA_CONTRAST_LV5 5
945 #define CAMERA_CONTRAST_LV6 6
946 #define CAMERA_CONTRAST_LV7 7
947 #define CAMERA_CONTRAST_LV8 8
948 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
949 #define CAMERA_CONTRAST_LV9 9
950 #define CAMERA_BRIGHTNESS_LV0 0
951 #define CAMERA_BRIGHTNESS_LV1 1
952 #define CAMERA_BRIGHTNESS_LV2 2
953 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
954 #define CAMERA_BRIGHTNESS_LV3 3
955 #define CAMERA_BRIGHTNESS_LV4 4
956 #define CAMERA_BRIGHTNESS_LV5 5
957 #define CAMERA_BRIGHTNESS_LV6 6
958 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
959 #define CAMERA_BRIGHTNESS_LV7 7
960 #define CAMERA_BRIGHTNESS_LV8 8
961 #define CAMERA_SATURATION_LV0 0
962 #define CAMERA_SATURATION_LV1 1
963 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
964 #define CAMERA_SATURATION_LV2 2
965 #define CAMERA_SATURATION_LV3 3
966 #define CAMERA_SATURATION_LV4 4
967 #define CAMERA_SATURATION_LV5 5
968 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
969 #define CAMERA_SATURATION_LV6 6
970 #define CAMERA_SATURATION_LV7 7
971 #define CAMERA_SATURATION_LV8 8
972 #define CAMERA_SHARPNESS_LV0 0
973 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
974 #define CAMERA_SHARPNESS_LV1 3
975 #define CAMERA_SHARPNESS_LV2 6
976 #define CAMERA_SHARPNESS_LV3 9
977 #define CAMERA_SHARPNESS_LV4 12
978 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
979 #define CAMERA_SHARPNESS_LV5 15
980 #define CAMERA_SHARPNESS_LV6 18
981 #define CAMERA_SHARPNESS_LV7 21
982 #define CAMERA_SHARPNESS_LV8 24
983 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
984 #define CAMERA_SHARPNESS_LV9 27
985 #define CAMERA_SHARPNESS_LV10 30
986 #define CAMERA_SETAE_AVERAGE 0
987 #define CAMERA_SETAE_CENWEIGHT 1
988 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
989 #define CAMERA_WB_AUTO 1
990 #define CAMERA_WB_CUSTOM 2
991 #define CAMERA_WB_INCANDESCENT 3
992 #define CAMERA_WB_FLUORESCENT 4
993 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
994 #define CAMERA_WB_DAYLIGHT 5
995 #define CAMERA_WB_CLOUDY_DAYLIGHT 6
996 #define CAMERA_WB_TWILIGHT 7
997 #define CAMERA_WB_SHADE 8
998 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
999 #define CAMERA_EXPOSURE_COMPENSATION_LV0 12
1000 #define CAMERA_EXPOSURE_COMPENSATION_LV1 6
1001 #define CAMERA_EXPOSURE_COMPENSATION_LV2 0
1002 #define CAMERA_EXPOSURE_COMPENSATION_LV3 - 6
1003 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1004 #define CAMERA_EXPOSURE_COMPENSATION_LV4 - 12
1005 enum msm_v4l2_saturation_level {
1006   MSM_V4L2_SATURATION_L0,
1007   MSM_V4L2_SATURATION_L1,
1008 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1009   MSM_V4L2_SATURATION_L2,
1010   MSM_V4L2_SATURATION_L3,
1011   MSM_V4L2_SATURATION_L4,
1012   MSM_V4L2_SATURATION_L5,
1013 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1014   MSM_V4L2_SATURATION_L6,
1015   MSM_V4L2_SATURATION_L7,
1016   MSM_V4L2_SATURATION_L8,
1017   MSM_V4L2_SATURATION_L9,
1018 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1019   MSM_V4L2_SATURATION_L10,
1020 };
1021 enum msm_v4l2_contrast_level {
1022   MSM_V4L2_CONTRAST_L0,
1023 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1024   MSM_V4L2_CONTRAST_L1,
1025   MSM_V4L2_CONTRAST_L2,
1026   MSM_V4L2_CONTRAST_L3,
1027   MSM_V4L2_CONTRAST_L4,
1028 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1029   MSM_V4L2_CONTRAST_L5,
1030   MSM_V4L2_CONTRAST_L6,
1031   MSM_V4L2_CONTRAST_L7,
1032   MSM_V4L2_CONTRAST_L8,
1033 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1034   MSM_V4L2_CONTRAST_L9,
1035   MSM_V4L2_CONTRAST_L10,
1036 };
1037 enum msm_v4l2_exposure_level {
1038 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1039   MSM_V4L2_EXPOSURE_N2,
1040   MSM_V4L2_EXPOSURE_N1,
1041   MSM_V4L2_EXPOSURE_D,
1042   MSM_V4L2_EXPOSURE_P1,
1043 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1044   MSM_V4L2_EXPOSURE_P2,
1045 };
1046 enum msm_v4l2_sharpness_level {
1047   MSM_V4L2_SHARPNESS_L0,
1048 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1049   MSM_V4L2_SHARPNESS_L1,
1050   MSM_V4L2_SHARPNESS_L2,
1051   MSM_V4L2_SHARPNESS_L3,
1052   MSM_V4L2_SHARPNESS_L4,
1053 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1054   MSM_V4L2_SHARPNESS_L5,
1055   MSM_V4L2_SHARPNESS_L6,
1056 };
1057 enum msm_v4l2_expo_metering_mode {
1058 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1059   MSM_V4L2_EXP_FRAME_AVERAGE,
1060   MSM_V4L2_EXP_CENTER_WEIGHTED,
1061   MSM_V4L2_EXP_SPOT_METERING,
1062 };
1063 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1064 enum msm_v4l2_iso_mode {
1065   MSM_V4L2_ISO_AUTO = 0,
1066   MSM_V4L2_ISO_DEBLUR,
1067   MSM_V4L2_ISO_100,
1068 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1069   MSM_V4L2_ISO_200,
1070   MSM_V4L2_ISO_400,
1071   MSM_V4L2_ISO_800,
1072   MSM_V4L2_ISO_1600,
1073 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1074 };
1075 enum msm_v4l2_wb_mode {
1076   MSM_V4L2_WB_OFF,
1077   MSM_V4L2_WB_AUTO,
1078 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1079   MSM_V4L2_WB_CUSTOM,
1080   MSM_V4L2_WB_INCANDESCENT,
1081   MSM_V4L2_WB_FLUORESCENT,
1082   MSM_V4L2_WB_DAYLIGHT,
1083 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1084   MSM_V4L2_WB_CLOUDY_DAYLIGHT,
1085 };
1086 enum msm_v4l2_special_effect {
1087   MSM_V4L2_EFFECT_OFF,
1088 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1089   MSM_V4L2_EFFECT_MONO,
1090   MSM_V4L2_EFFECT_NEGATIVE,
1091   MSM_V4L2_EFFECT_SOLARIZE,
1092   MSM_V4L2_EFFECT_SEPIA,
1093 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1094   MSM_V4L2_EFFECT_POSTERAIZE,
1095   MSM_V4L2_EFFECT_WHITEBOARD,
1096   MSM_V4L2_EFFECT_BLACKBOARD,
1097   MSM_V4L2_EFFECT_AQUA,
1098 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1099   MSM_V4L2_EFFECT_EMBOSS,
1100   MSM_V4L2_EFFECT_SKETCH,
1101   MSM_V4L2_EFFECT_NEON,
1102   MSM_V4L2_EFFECT_MAX,
1103 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1104 };
1105 enum msm_v4l2_power_line_frequency {
1106   MSM_V4L2_POWER_LINE_OFF,
1107   MSM_V4L2_POWER_LINE_60HZ,
1108 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1109   MSM_V4L2_POWER_LINE_50HZ,
1110   MSM_V4L2_POWER_LINE_AUTO,
1111 };
1112 #define CAMERA_ISO_TYPE_AUTO 0
1113 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1114 #define CAMEAR_ISO_TYPE_HJR 1
1115 #define CAMEAR_ISO_TYPE_100 2
1116 #define CAMERA_ISO_TYPE_200 3
1117 #define CAMERA_ISO_TYPE_400 4
1118 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1119 #define CAMEAR_ISO_TYPE_800 5
1120 #define CAMERA_ISO_TYPE_1600 6
1121 struct sensor_pict_fps {
1122   uint16_t prevfps;
1123 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1124   uint16_t pictfps;
1125 };
1126 struct exp_gain_cfg {
1127   uint16_t gain;
1128 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1129   uint32_t line;
1130 };
1131 struct focus_cfg {
1132   int32_t steps;
1133 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1134   int dir;
1135 };
1136 struct fps_cfg {
1137   uint16_t f_mult;
1138 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1139   uint16_t fps_div;
1140   uint32_t pict_fps_div;
1141 };
1142 struct wb_info_cfg {
1143 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1144   uint16_t red_gain;
1145   uint16_t green_gain;
1146   uint16_t blue_gain;
1147 };
1148 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1149 struct sensor_3d_exp_cfg {
1150   uint16_t gain;
1151   uint32_t line;
1152   uint16_t r_gain;
1153 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1154   uint16_t b_gain;
1155   uint16_t gr_gain;
1156   uint16_t gb_gain;
1157   uint16_t gain_adjust;
1158 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1159 };
1160 struct sensor_3d_cali_data_t {
1161   unsigned char left_p_matrix[3][4][8];
1162   unsigned char right_p_matrix[3][4][8];
1163 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1164   unsigned char square_len[8];
1165   unsigned char focal_len[8];
1166   unsigned char pixel_pitch[8];
1167   uint16_t left_r;
1168 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1169   uint16_t left_b;
1170   uint16_t left_gb;
1171   uint16_t left_af_far;
1172   uint16_t left_af_mid;
1173 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1174   uint16_t left_af_short;
1175   uint16_t left_af_5um;
1176   uint16_t left_af_50up;
1177   uint16_t left_af_50down;
1178 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1179   uint16_t right_r;
1180   uint16_t right_b;
1181   uint16_t right_gb;
1182   uint16_t right_af_far;
1183 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1184   uint16_t right_af_mid;
1185   uint16_t right_af_short;
1186   uint16_t right_af_5um;
1187   uint16_t right_af_50up;
1188 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1189   uint16_t right_af_50down;
1190 };
1191 struct sensor_init_cfg {
1192   uint8_t prev_res;
1193 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1194   uint8_t pict_res;
1195 };
1196 struct sensor_calib_data {
1197   uint16_t r_over_g;
1198 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1199   uint16_t b_over_g;
1200   uint16_t gr_over_gb;
1201   uint16_t macro_2_inf;
1202   uint16_t inf_2_macro;
1203 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1204   uint16_t stroke_amt;
1205   uint16_t af_pos_1m;
1206   uint16_t af_pos_inf;
1207 };
1208 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1209 enum msm_sensor_resolution_t {
1210   MSM_SENSOR_RES_FULL,
1211   MSM_SENSOR_RES_QTR,
1212   MSM_SENSOR_RES_2,
1213 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1214   MSM_SENSOR_RES_3,
1215   MSM_SENSOR_RES_4,
1216   MSM_SENSOR_RES_5,
1217   MSM_SENSOR_RES_6,
1218 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1219   MSM_SENSOR_RES_7,
1220   MSM_SENSOR_INVALID_RES,
1221 };
1222 struct msm_sensor_output_info_t {
1223 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1224   uint16_t x_output;
1225   uint16_t y_output;
1226   uint16_t line_length_pclk;
1227   uint16_t frame_length_lines;
1228 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1229   uint32_t vt_pixel_clk;
1230   uint32_t op_pixel_clk;
1231   uint16_t binning_factor;
1232 };
1233 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1234 struct sensor_output_info_t {
1235   struct msm_sensor_output_info_t * output_info;
1236   uint16_t num_info;
1237 };
1238 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1239 struct msm_sensor_exp_gain_info_t {
1240   uint16_t coarse_int_time_addr;
1241   uint16_t global_gain_addr;
1242   uint16_t vert_offset;
1243 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1244 };
1245 struct msm_sensor_output_reg_addr_t {
1246   uint16_t x_output;
1247   uint16_t y_output;
1248 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1249   uint16_t line_length_pclk;
1250   uint16_t frame_length_lines;
1251 };
1252 struct sensor_driver_params_type {
1253 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1254   struct msm_camera_i2c_reg_setting * init_settings;
1255   uint16_t init_settings_size;
1256   struct msm_camera_i2c_reg_setting * mode_settings;
1257   uint16_t mode_settings_size;
1258 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1259   struct msm_sensor_output_reg_addr_t * sensor_output_reg_addr;
1260   struct msm_camera_i2c_reg_setting * start_settings;
1261   struct msm_camera_i2c_reg_setting * stop_settings;
1262   struct msm_camera_i2c_reg_setting * groupon_settings;
1263 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1264   struct msm_camera_i2c_reg_setting * groupoff_settings;
1265   struct msm_sensor_exp_gain_info_t * sensor_exp_gain_info;
1266   struct msm_sensor_output_info_t * output_info;
1267 };
1268 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1269 struct mirror_flip {
1270   int32_t x_mirror;
1271   int32_t y_flip;
1272 };
1273 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1274 struct cord {
1275   uint32_t x;
1276   uint32_t y;
1277 };
1278 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1279 struct msm_eeprom_data_t {
1280   void * eeprom_data;
1281   uint16_t index;
1282 };
1283 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1284 struct msm_camera_csid_vc_cfg {
1285   uint8_t cid;
1286   uint8_t dt;
1287   uint8_t decode_format;
1288 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1289 };
1290 struct csi_lane_params_t {
1291   uint16_t csi_lane_assign;
1292   uint8_t csi_lane_mask;
1293 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1294   uint8_t csi_if;
1295   uint8_t csid_core[2];
1296   uint8_t csi_phy_sel;
1297 };
1298 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1299 struct msm_camera_csid_lut_params {
1300   uint8_t num_cid;
1301   struct msm_camera_csid_vc_cfg * vc_cfg;
1302 };
1303 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1304 struct msm_camera_csid_params {
1305   uint8_t lane_cnt;
1306   uint16_t lane_assign;
1307   uint8_t phy_sel;
1308 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1309   struct msm_camera_csid_lut_params lut_params;
1310 };
1311 struct msm_camera_csiphy_params {
1312   uint8_t lane_cnt;
1313 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1314   uint8_t settle_cnt;
1315   uint16_t lane_mask;
1316   uint8_t combo_mode;
1317   uint8_t csid_core;
1318 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1319 };
1320 struct msm_camera_csi2_params {
1321   struct msm_camera_csid_params csid_params;
1322   struct msm_camera_csiphy_params csiphy_params;
1323 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1324 };
1325 enum msm_camera_csi_data_format {
1326   CSI_8BIT,
1327   CSI_10BIT,
1328 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1329   CSI_12BIT,
1330 };
1331 struct msm_camera_csi_params {
1332   enum msm_camera_csi_data_format data_format;
1333 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1334   uint8_t lane_cnt;
1335   uint8_t lane_assign;
1336   uint8_t settle_cnt;
1337   uint8_t dpcm_scheme;
1338 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1339 };
1340 enum csic_cfg_type_t {
1341   CSIC_INIT,
1342   CSIC_CFG,
1343 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1344 };
1345 struct csic_cfg_data {
1346   enum csic_cfg_type_t cfgtype;
1347   struct msm_camera_csi_params * csic_params;
1348 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1349 };
1350 enum csid_cfg_type_t {
1351   CSID_INIT,
1352   CSID_CFG,
1353 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1354 };
1355 struct csid_cfg_data {
1356   enum csid_cfg_type_t cfgtype;
1357   union {
1358 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1359     uint32_t csid_version;
1360     struct msm_camera_csid_params * csid_params;
1361   } cfg;
1362 };
1363 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1364 enum csiphy_cfg_type_t {
1365   CSIPHY_INIT,
1366   CSIPHY_CFG,
1367 };
1368 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1369 struct csiphy_cfg_data {
1370   enum csiphy_cfg_type_t cfgtype;
1371   struct msm_camera_csiphy_params * csiphy_params;
1372 };
1373 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1374 #define CSI_EMBED_DATA 0x12
1375 #define CSI_RESERVED_DATA_0 0x13
1376 #define CSI_YUV422_8 0x1E
1377 #define CSI_RAW8 0x2A
1378 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1379 #define CSI_RAW10 0x2B
1380 #define CSI_RAW12 0x2C
1381 #define CSI_DECODE_6BIT 0
1382 #define CSI_DECODE_8BIT 1
1383 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1384 #define CSI_DECODE_10BIT 2
1385 #define CSI_DECODE_DPCM_10_8_10 5
1386 #define ISPIF_STREAM(intf,action,vfe) (((intf) << ISPIF_S_STREAM_SHIFT) + (action) + ((vfe) << ISPIF_VFE_INTF_SHIFT))
1387 #define ISPIF_ON_FRAME_BOUNDARY (0x01 << 0)
1388 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1389 #define ISPIF_OFF_FRAME_BOUNDARY (0x01 << 1)
1390 #define ISPIF_OFF_IMMEDIATELY (0x01 << 2)
1391 #define ISPIF_S_STREAM_SHIFT 4
1392 #define ISPIF_VFE_INTF_SHIFT 12
1393 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1394 #define PIX_0 (0x01 << 0)
1395 #define RDI_0 (0x01 << 1)
1396 #define PIX_1 (0x01 << 2)
1397 #define RDI_1 (0x01 << 3)
1398 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1399 #define RDI_2 (0x01 << 4)
1400 enum msm_ispif_vfe_intf {
1401   VFE0,
1402   VFE1,
1403 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1404   VFE_MAX,
1405 };
1406 enum msm_ispif_intftype {
1407   PIX0,
1408 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1409   RDI0,
1410   PIX1,
1411   RDI1,
1412   RDI2,
1413 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1414   INTF_MAX,
1415 };
1416 enum msm_ispif_vc {
1417   VC0,
1418 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1419   VC1,
1420   VC2,
1421   VC3,
1422 };
1423 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1424 enum msm_ispif_cid {
1425   CID0,
1426   CID1,
1427   CID2,
1428 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1429   CID3,
1430   CID4,
1431   CID5,
1432   CID6,
1433 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1434   CID7,
1435   CID8,
1436   CID9,
1437   CID10,
1438 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1439   CID11,
1440   CID12,
1441   CID13,
1442   CID14,
1443 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1444   CID15,
1445 };
1446 struct msm_ispif_params {
1447   uint8_t intftype;
1448 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1449   uint16_t cid_mask;
1450   uint8_t csid;
1451   uint8_t vfe_intf;
1452 };
1453 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1454 struct msm_ispif_params_list {
1455   uint32_t len;
1456   struct msm_ispif_params params[4];
1457 };
1458 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1459 enum ispif_cfg_type_t {
1460   ISPIF_INIT,
1461   ISPIF_SET_CFG,
1462   ISPIF_SET_ON_FRAME_BOUNDARY,
1463 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1464   ISPIF_SET_OFF_FRAME_BOUNDARY,
1465   ISPIF_SET_OFF_IMMEDIATELY,
1466   ISPIF_RELEASE,
1467 };
1468 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1469 struct ispif_cfg_data {
1470   enum ispif_cfg_type_t cfgtype;
1471   union {
1472     uint32_t csid_version;
1473 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1474     int cmd;
1475     struct msm_ispif_params_list ispif_params;
1476   } cfg;
1477 };
1478 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1479 enum msm_camera_i2c_reg_addr_type {
1480   MSM_CAMERA_I2C_BYTE_ADDR = 1,
1481   MSM_CAMERA_I2C_WORD_ADDR,
1482   MSM_CAMERA_I2C_3B_ADDR,
1483 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1484 };
1485 struct msm_camera_i2c_reg_array {
1486   uint16_t reg_addr;
1487   uint16_t reg_data;
1488 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1489 };
1490 enum msm_camera_i2c_data_type {
1491   MSM_CAMERA_I2C_BYTE_DATA = 1,
1492   MSM_CAMERA_I2C_WORD_DATA,
1493 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1494   MSM_CAMERA_I2C_SET_BYTE_MASK,
1495   MSM_CAMERA_I2C_UNSET_BYTE_MASK,
1496   MSM_CAMERA_I2C_SET_WORD_MASK,
1497   MSM_CAMERA_I2C_UNSET_WORD_MASK,
1498 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1499   MSM_CAMERA_I2C_SET_BYTE_WRITE_MASK_DATA,
1500 };
1501 struct msm_camera_i2c_reg_setting {
1502   struct msm_camera_i2c_reg_array * reg_setting;
1503 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1504   uint16_t size;
1505   enum msm_camera_i2c_reg_addr_type addr_type;
1506   enum msm_camera_i2c_data_type data_type;
1507   uint16_t delay;
1508 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1509 };
1510 enum oem_setting_type {
1511   I2C_READ = 1,
1512   I2C_WRITE,
1513 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1514   GPIO_OP,
1515   EEPROM_READ,
1516   VREG_SET,
1517   CLK_SET,
1518 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1519 };
1520 struct sensor_oem_setting {
1521   enum oem_setting_type type;
1522   void * data;
1523 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1524 };
1525 enum camera_vreg_type {
1526   REG_LDO,
1527   REG_VS,
1528 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1529   REG_GPIO,
1530 };
1531 enum msm_camera_vreg_name_t {
1532   CAM_VDIG,
1533 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1534   CAM_VIO,
1535   CAM_VANA,
1536   CAM_VAF,
1537   CAM_VREG_MAX,
1538 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1539 };
1540 struct msm_camera_csi_lane_params {
1541   uint16_t csi_lane_assign;
1542   uint16_t csi_lane_mask;
1543 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1544 };
1545 struct camera_vreg_t {
1546   const char * reg_name;
1547   int min_voltage;
1548 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1549   int max_voltage;
1550   int op_mode;
1551   uint32_t delay;
1552 };
1553 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1554 struct msm_camera_vreg_setting {
1555   struct camera_vreg_t * cam_vreg;
1556   uint16_t num_vreg;
1557   uint8_t enable;
1558 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1559 };
1560 struct msm_cam_clk_info {
1561   const char * clk_name;
1562   long clk_rate;
1563 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1564   uint32_t delay;
1565 };
1566 struct msm_cam_clk_setting {
1567   struct msm_cam_clk_info * clk_info;
1568 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1569   uint16_t num_clk_info;
1570   uint8_t enable;
1571 };
1572 struct sensor_cfg_data {
1573 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1574   int cfgtype;
1575   int mode;
1576   int rs;
1577   uint8_t max_steps;
1578 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1579   union {
1580     int8_t effect;
1581     uint8_t lens_shading;
1582     uint16_t prevl_pf;
1583 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1584     uint16_t prevp_pl;
1585     uint16_t pictl_pf;
1586     uint16_t pictp_pl;
1587     uint32_t pict_max_exp_lc;
1588 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1589     uint16_t p_fps;
1590     uint8_t iso_type;
1591     struct sensor_init_cfg init_info;
1592     struct sensor_pict_fps gfps;
1593 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1594     struct exp_gain_cfg exp_gain;
1595     struct focus_cfg focus;
1596     struct fps_cfg fps;
1597     struct wb_info_cfg wb_info;
1598 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1599     struct sensor_3d_exp_cfg sensor_3d_exp;
1600     struct sensor_calib_data calib_info;
1601     struct sensor_output_info_t output_info;
1602     struct msm_eeprom_data_t eeprom_data;
1603 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1604     struct csi_lane_params_t csi_lane_params;
1605     uint16_t antibanding;
1606     uint8_t contrast;
1607     uint8_t saturation;
1608 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1609     uint8_t sharpness;
1610     int8_t brightness;
1611     int ae_mode;
1612     uint8_t wb_val;
1613 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1614     int8_t exp_compensation;
1615     uint32_t pclk;
1616     struct cord aec_cord;
1617     int is_autoflash;
1618 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1619     struct mirror_flip mirror_flip;
1620     void * setting;
1621   } cfg;
1622 };
1623 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1624 enum gpio_operation_type {
1625   GPIO_REQUEST,
1626   GPIO_FREE,
1627   GPIO_SET_DIRECTION_OUTPUT,
1628 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1629   GPIO_SET_DIRECTION_INPUT,
1630   GPIO_GET_VALUE,
1631   GPIO_SET_VALUE,
1632 };
1633 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1634 struct msm_cam_gpio_operation {
1635   enum gpio_operation_type op_type;
1636   unsigned address;
1637   int value;
1638 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1639   const char * tag;
1640 };
1641 struct damping_params_t {
1642   uint32_t damping_step;
1643 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1644   uint32_t damping_delay;
1645   uint32_t hw_params;
1646 };
1647 enum actuator_type {
1648 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1649   ACTUATOR_VCM,
1650   ACTUATOR_PIEZO,
1651   ACTUATOR_HVCM,
1652   ACTUATOR_BIVCM,
1653 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1654 };
1655 enum msm_actuator_data_type {
1656   MSM_ACTUATOR_BYTE_DATA = 1,
1657   MSM_ACTUATOR_WORD_DATA,
1658 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1659 };
1660 enum msm_actuator_addr_type {
1661   MSM_ACTUATOR_BYTE_ADDR = 1,
1662   MSM_ACTUATOR_WORD_ADDR,
1663 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1664 };
1665 enum msm_actuator_write_type {
1666   MSM_ACTUATOR_WRITE_HW_DAMP,
1667   MSM_ACTUATOR_WRITE_DAC,
1668 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1669   MSM_ACTUATOR_WRITE,
1670   MSM_ACTUATOR_WRITE_DIR_REG,
1671   MSM_ACTUATOR_POLL,
1672   MSM_ACTUATOR_READ_WRITE,
1673 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1674 };
1675 struct msm_actuator_reg_params_t {
1676   enum msm_actuator_write_type reg_write_type;
1677   uint32_t hw_mask;
1678 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1679   uint16_t reg_addr;
1680   uint16_t hw_shift;
1681   uint16_t data_type;
1682   uint16_t addr_type;
1683 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1684   uint16_t reg_data;
1685   uint16_t delay;
1686 };
1687 struct reg_settings_t {
1688 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1689   uint16_t reg_addr;
1690   uint16_t reg_data;
1691 };
1692 struct region_params_t {
1693 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1694   uint16_t step_bound[2];
1695   uint16_t code_per_step;
1696 };
1697 struct msm_actuator_move_params_t {
1698 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1699   int8_t dir;
1700   int8_t sign_dir;
1701   int16_t dest_step_pos;
1702   int32_t num_steps;
1703 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1704   struct damping_params_t * ringing_params;
1705 };
1706 struct msm_actuator_tuning_params_t {
1707   int16_t initial_code;
1708 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1709   uint16_t pwd_step;
1710   uint16_t region_size;
1711   uint32_t total_steps;
1712   struct region_params_t * region_params;
1713 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1714 };
1715 struct msm_actuator_params_t {
1716   enum actuator_type act_type;
1717   uint8_t reg_tbl_size;
1718 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1719   uint16_t data_size;
1720   uint16_t init_setting_size;
1721   uint32_t i2c_addr;
1722   enum msm_actuator_addr_type i2c_addr_type;
1723 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1724   enum msm_actuator_data_type i2c_data_type;
1725   struct msm_actuator_reg_params_t * reg_tbl_params;
1726   struct reg_settings_t * init_settings;
1727 };
1728 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1729 struct msm_actuator_set_info_t {
1730   struct msm_actuator_params_t actuator_params;
1731   struct msm_actuator_tuning_params_t af_tuning_params;
1732 };
1733 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1734 struct msm_actuator_get_info_t {
1735   uint32_t focal_length_num;
1736   uint32_t focal_length_den;
1737   uint32_t f_number_num;
1738 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1739   uint32_t f_number_den;
1740   uint32_t f_pix_num;
1741   uint32_t f_pix_den;
1742   uint32_t total_f_dist_num;
1743 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1744   uint32_t total_f_dist_den;
1745   uint32_t hor_view_angle_num;
1746   uint32_t hor_view_angle_den;
1747   uint32_t ver_view_angle_num;
1748 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1749   uint32_t ver_view_angle_den;
1750 };
1751 enum af_camera_name {
1752   ACTUATOR_MAIN_CAM_0,
1753 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1754   ACTUATOR_MAIN_CAM_1,
1755   ACTUATOR_MAIN_CAM_2,
1756   ACTUATOR_MAIN_CAM_3,
1757   ACTUATOR_MAIN_CAM_4,
1758 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1759   ACTUATOR_MAIN_CAM_5,
1760   ACTUATOR_WEB_CAM_0,
1761   ACTUATOR_WEB_CAM_1,
1762   ACTUATOR_WEB_CAM_2,
1763 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1764 };
1765 struct msm_actuator_cfg_data {
1766   int cfgtype;
1767   uint8_t is_af_supported;
1768 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1769   union {
1770     struct msm_actuator_move_params_t move;
1771     struct msm_actuator_set_info_t set_info;
1772     struct msm_actuator_get_info_t get_info;
1773 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1774     enum af_camera_name cam_name;
1775   } cfg;
1776 };
1777 struct msm_eeprom_support {
1778 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1779   uint16_t is_supported;
1780   uint16_t size;
1781   uint16_t index;
1782   uint16_t qvalue;
1783 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1784 };
1785 struct msm_calib_wb {
1786   uint16_t r_over_g;
1787   uint16_t b_over_g;
1788 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1789   uint16_t gr_over_gb;
1790 };
1791 struct msm_calib_af {
1792   uint16_t macro_dac;
1793 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1794   uint16_t inf_dac;
1795   uint16_t start_dac;
1796 };
1797 struct msm_calib_lsc {
1798 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1799   uint16_t r_gain[221];
1800   uint16_t b_gain[221];
1801   uint16_t gr_gain[221];
1802   uint16_t gb_gain[221];
1803 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1804 };
1805 struct pixel_t {
1806   int x;
1807   int y;
1808 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1809 };
1810 struct msm_calib_dpc {
1811   uint16_t validcount;
1812   struct pixel_t snapshot_coord[128];
1813 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1814   struct pixel_t preview_coord[128];
1815   struct pixel_t video_coord[128];
1816 };
1817 struct msm_calib_raw {
1818 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1819   uint8_t * data;
1820   uint32_t size;
1821 };
1822 struct msm_camera_eeprom_info_t {
1823 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1824   struct msm_eeprom_support af;
1825   struct msm_eeprom_support wb;
1826   struct msm_eeprom_support lsc;
1827   struct msm_eeprom_support dpc;
1828 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1829   struct msm_eeprom_support raw;
1830 };
1831 struct msm_eeprom_cfg_data {
1832   int cfgtype;
1833 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1834   uint8_t is_eeprom_supported;
1835   union {
1836     struct msm_eeprom_data_t get_data;
1837     struct msm_camera_eeprom_info_t get_info;
1838 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1839   } cfg;
1840 };
1841 struct sensor_large_data {
1842   int cfgtype;
1843 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1844   union {
1845     struct sensor_3d_cali_data_t sensor_3d_cali_data;
1846   } data;
1847 };
1848 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1849 enum sensor_type_t {
1850   BAYER,
1851   YUV,
1852   JPEG_SOC,
1853 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1854 };
1855 enum flash_type {
1856   LED_FLASH,
1857   STROBE_FLASH,
1858 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1859 };
1860 enum strobe_flash_ctrl_type {
1861   STROBE_FLASH_CTRL_INIT,
1862   STROBE_FLASH_CTRL_CHARGE,
1863 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1864   STROBE_FLASH_CTRL_RELEASE
1865 };
1866 struct strobe_flash_ctrl_data {
1867   enum strobe_flash_ctrl_type type;
1868 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1869   int charge_en;
1870 };
1871 struct msm_camera_info {
1872   int num_cameras;
1873 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1874   uint8_t has_3d_support[MSM_MAX_CAMERA_SENSORS];
1875   uint8_t is_internal_cam[MSM_MAX_CAMERA_SENSORS];
1876   uint32_t s_mount_angle[MSM_MAX_CAMERA_SENSORS];
1877   const char * video_dev_name[MSM_MAX_CAMERA_SENSORS];
1878 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1879   enum sensor_type_t sensor_type[MSM_MAX_CAMERA_SENSORS];
1880 };
1881 struct msm_cam_config_dev_info {
1882   int num_config_nodes;
1883 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1884   const char * config_dev_name[MSM_MAX_CAMERA_CONFIGS];
1885   int config_dev_id[MSM_MAX_CAMERA_CONFIGS];
1886 };
1887 struct msm_mctl_node_info {
1888 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1889   int num_mctl_nodes;
1890   const char * mctl_node_name[MSM_MAX_CAMERA_SENSORS];
1891 };
1892 struct flash_ctrl_data {
1893 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1894   int flashtype;
1895   union {
1896     int led_state;
1897     struct strobe_flash_ctrl_data strobe_ctrl;
1898 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1899   } ctrl_data;
1900 };
1901 #define GET_NAME 0
1902 #define GET_PREVIEW_LINE_PER_FRAME 1
1903 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1904 #define GET_PREVIEW_PIXELS_PER_LINE 2
1905 #define GET_SNAPSHOT_LINE_PER_FRAME 3
1906 #define GET_SNAPSHOT_PIXELS_PER_LINE 4
1907 #define GET_SNAPSHOT_FPS 5
1908 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1909 #define GET_SNAPSHOT_MAX_EP_LINE_CNT 6
1910 struct msm_camsensor_info {
1911   char name[MAX_SENSOR_NAME];
1912   uint8_t flash_enabled;
1913 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1914   uint8_t strobe_flash_enabled;
1915   uint8_t actuator_enabled;
1916   uint8_t ispif_supported;
1917   int8_t total_steps;
1918 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1919   uint8_t support_3d;
1920   enum flash_type flashtype;
1921   enum sensor_type_t sensor_type;
1922   uint32_t pxlcode;
1923 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1924   uint32_t camera_type;
1925   int mount_angle;
1926   uint32_t max_width;
1927   uint32_t max_height;
1928 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1929 };
1930 #define V4L2_SINGLE_PLANE 0
1931 #define V4L2_MULTI_PLANE_Y 0
1932 #define V4L2_MULTI_PLANE_CBCR 1
1933 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1934 #define V4L2_MULTI_PLANE_CB 1
1935 #define V4L2_MULTI_PLANE_CR 2
1936 struct plane_data {
1937   int plane_id;
1938 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1939   uint32_t offset;
1940   unsigned long size;
1941 };
1942 struct img_plane_info {
1943 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1944   uint32_t width;
1945   uint32_t height;
1946   uint32_t pixelformat;
1947   uint8_t buffer_type;
1948 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1949   uint8_t output_port;
1950   uint32_t ext_mode;
1951   uint8_t num_planes;
1952   struct plane_data plane[MAX_PLANES];
1953 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1954   uint32_t sp_y_offset;
1955   uint32_t inst_handle;
1956 };
1957 #define QCAMERA_NAME "qcamera"
1958 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1959 #define QCAMERA_SERVER_NAME "qcamera_server"
1960 #define QCAMERA_DEVICE_GROUP_ID 1
1961 #define QCAMERA_VNODE_GROUP_ID 2
1962 enum msm_cam_subdev_type {
1963 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1964   CSIPHY_DEV,
1965   CSID_DEV,
1966   CSIC_DEV,
1967   ISPIF_DEV,
1968 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1969   VFE_DEV,
1970   AXI_DEV,
1971   VPE_DEV,
1972   SENSOR_DEV,
1973 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1974   ACTUATOR_DEV,
1975   EEPROM_DEV,
1976   GESTURE_DEV,
1977   IRQ_ROUTER_DEV,
1978 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1979   CPP_DEV,
1980   CCI_DEV,
1981   FLASH_DEV,
1982 };
1983 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1984 struct msm_mctl_set_sdev_data {
1985   uint32_t revision;
1986   enum msm_cam_subdev_type sdev_type;
1987 };
1988 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1989 #define MSM_CAM_V4L2_IOCTL_GET_CAMERA_INFO _IOWR('V', BASE_VIDIOC_PRIVATE + 1, struct msm_camera_v4l2_ioctl_t)
1990 #define MSM_CAM_V4L2_IOCTL_GET_CONFIG_INFO _IOWR('V', BASE_VIDIOC_PRIVATE + 2, struct msm_camera_v4l2_ioctl_t)
1991 #define MSM_CAM_V4L2_IOCTL_GET_MCTL_INFO _IOWR('V', BASE_VIDIOC_PRIVATE + 3, struct msm_camera_v4l2_ioctl_t)
1992 #define MSM_CAM_V4L2_IOCTL_CTRL_CMD_DONE _IOWR('V', BASE_VIDIOC_PRIVATE + 4, struct msm_camera_v4l2_ioctl_t)
1993 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1994 #define MSM_CAM_V4L2_IOCTL_GET_EVENT_PAYLOAD _IOWR('V', BASE_VIDIOC_PRIVATE + 5, struct msm_camera_v4l2_ioctl_t)
1995 #define MSM_CAM_IOCTL_SEND_EVENT _IOWR('V', BASE_VIDIOC_PRIVATE + 6, struct v4l2_event)
1996 #define MSM_CAM_V4L2_IOCTL_CFG_VPE _IOWR('V', BASE_VIDIOC_PRIVATE + 7, struct msm_vpe_cfg_cmd)
1997 #define MSM_CAM_V4L2_IOCTL_PRIVATE_S_CTRL _IOWR('V', BASE_VIDIOC_PRIVATE + 8, struct msm_camera_v4l2_ioctl_t)
1998 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
1999 #define MSM_CAM_V4L2_IOCTL_PRIVATE_G_CTRL _IOWR('V', BASE_VIDIOC_PRIVATE + 9, struct msm_camera_v4l2_ioctl_t)
2000 #define MSM_CAM_V4L2_IOCTL_PRIVATE_GENERAL _IOW('V', BASE_VIDIOC_PRIVATE + 10, struct msm_camera_v4l2_ioctl_t)
2001 #define VIDIOC_MSM_VPE_INIT _IO('V', BASE_VIDIOC_PRIVATE + 15)
2002 #define VIDIOC_MSM_VPE_RELEASE _IO('V', BASE_VIDIOC_PRIVATE + 16)
2003 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2004 #define VIDIOC_MSM_VPE_CFG _IOWR('V', BASE_VIDIOC_PRIVATE + 17, struct msm_mctl_pp_params *)
2005 #define VIDIOC_MSM_AXI_INIT _IOWR('V', BASE_VIDIOC_PRIVATE + 18, uint8_t *)
2006 #define VIDIOC_MSM_AXI_RELEASE _IO('V', BASE_VIDIOC_PRIVATE + 19)
2007 #define VIDIOC_MSM_AXI_CFG _IOWR('V', BASE_VIDIOC_PRIVATE + 20, void *)
2008 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2009 #define VIDIOC_MSM_AXI_IRQ _IOWR('V', BASE_VIDIOC_PRIVATE + 21, void *)
2010 #define VIDIOC_MSM_AXI_BUF_CFG _IOWR('V', BASE_VIDIOC_PRIVATE + 22, void *)
2011 #define VIDIOC_MSM_AXI_RDI_COUNT_UPDATE _IOWR('V', BASE_VIDIOC_PRIVATE + 23, void *)
2012 #define VIDIOC_MSM_VFE_INIT _IO('V', BASE_VIDIOC_PRIVATE + 24)
2013 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2014 #define VIDIOC_MSM_VFE_RELEASE _IO('V', BASE_VIDIOC_PRIVATE + 25)
2015 struct msm_camera_v4l2_ioctl_t {
2016   uint32_t id;
2017   uint32_t len;
2018 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2019   uint32_t trans_code;
2020   void * ioctl_ptr;
2021 };
2022 struct msm_camera_vfe_params_t {
2023 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2024   uint32_t operation_mode;
2025   uint32_t capture_count;
2026   uint8_t skip_reset;
2027   uint8_t stop_immediately;
2028 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2029   uint16_t port_info;
2030   uint32_t inst_handle;
2031   uint16_t cmd_type;
2032 };
2033 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2034 enum msm_camss_irq_idx {
2035   CAMERA_SS_IRQ_0,
2036   CAMERA_SS_IRQ_1,
2037   CAMERA_SS_IRQ_2,
2038 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2039   CAMERA_SS_IRQ_3,
2040   CAMERA_SS_IRQ_4,
2041   CAMERA_SS_IRQ_5,
2042   CAMERA_SS_IRQ_6,
2043 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2044   CAMERA_SS_IRQ_7,
2045   CAMERA_SS_IRQ_8,
2046   CAMERA_SS_IRQ_9,
2047   CAMERA_SS_IRQ_10,
2048 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2049   CAMERA_SS_IRQ_11,
2050   CAMERA_SS_IRQ_12,
2051   CAMERA_SS_IRQ_MAX
2052 };
2053 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2054 enum msm_cam_hw_idx {
2055   MSM_CAM_HW_MICRO,
2056   MSM_CAM_HW_CCI,
2057   MSM_CAM_HW_CSI0,
2058 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2059   MSM_CAM_HW_CSI1,
2060   MSM_CAM_HW_CSI2,
2061   MSM_CAM_HW_CSI3,
2062   MSM_CAM_HW_ISPIF,
2063 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2064   MSM_CAM_HW_CPP,
2065   MSM_CAM_HW_VFE0,
2066   MSM_CAM_HW_VFE1,
2067   MSM_CAM_HW_JPEG0,
2068 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2069   MSM_CAM_HW_JPEG1,
2070   MSM_CAM_HW_JPEG2,
2071   MSM_CAM_HW_MAX
2072 };
2073 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2074 struct msm_camera_irq_cfg {
2075   uint32_t cam_hw_mask;
2076   uint8_t irq_idx;
2077   uint8_t num_hwcore;
2078 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2079 };
2080 #define MSM_IRQROUTER_CFG_COMPIRQ _IOWR('V', BASE_VIDIOC_PRIVATE, void *)
2081 #define MAX_NUM_CPP_STRIPS 8
2082 enum msm_cpp_frame_type {
2083 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2084   MSM_CPP_OFFLINE_FRAME,
2085   MSM_CPP_REALTIME_FRAME,
2086 };
2087 struct msm_cpp_frame_info_t {
2088 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2089   int32_t frame_id;
2090   uint32_t inst_id;
2091   uint32_t client_id;
2092   enum msm_cpp_frame_type frame_type;
2093 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2094   uint32_t num_strips;
2095 };
2096 struct msm_ver_num_info {
2097   uint32_t main;
2098 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2099   uint32_t minor;
2100   uint32_t rev;
2101 };
2102 #define VIDIOC_MSM_CPP_CFG _IOWR('V', BASE_VIDIOC_PRIVATE, struct msm_camera_v4l2_ioctl_t)
2103 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2104 #define VIDIOC_MSM_CPP_GET_EVENTPAYLOAD _IOWR('V', BASE_VIDIOC_PRIVATE + 1, struct msm_camera_v4l2_ioctl_t)
2105 #define VIDIOC_MSM_CPP_GET_INST_INFO _IOWR('V', BASE_VIDIOC_PRIVATE + 2, struct msm_camera_v4l2_ioctl_t)
2106 #define V4L2_EVENT_CPP_FRAME_DONE (V4L2_EVENT_PRIVATE_START + 0)
2107 #define CLR_DEVID_MODE(handle) (handle &= 0x00FFFFFF)
2108 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2109 #define SET_DEVID_MODE(handle,data) (handle |= ((0x1 << 31) | ((data & 0x7F) << 24)))
2110 #define GET_DEVID_MODE(handle) ((handle & 0x80000000) ? ((handle & 0x7F000000) >> 24) : 0xFF)
2111 #define CLR_IMG_MODE(handle) (handle &= 0xFF00FFFF)
2112 #define SET_IMG_MODE(handle,data) (handle |= ((0x1 << 23) | ((data & 0x7F) << 16)))
2113 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2114 #define GET_IMG_MODE(handle) ((handle & 0x800000) ? ((handle & 0x7F0000) >> 16) : 0xFF)
2115 #define CLR_MCTLPP_INST_IDX(handle) (handle &= 0xFFFF00FF)
2116 #define SET_MCTLPP_INST_IDX(handle,data) (handle |= ((0x1 << 15) | ((data & 0x7F) << 8)))
2117 #define GET_MCTLPP_INST_IDX(handle) ((handle & 0x8000) ? ((handle & 0x7F00) >> 8) : 0xFF)
2118 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2119 #define CLR_VIDEO_INST_IDX(handle) (handle &= 0xFFFFFF00)
2120 #define GET_VIDEO_INST_IDX(handle) ((handle & 0x80) ? (handle & 0x7F) : 0xFF)
2121 #define SET_VIDEO_INST_IDX(handle,data) (handle |= (0x1 << 7) | (data & 0x7F))
2122 #endif
2123 /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */
2124 
2125