Lines Matching +full:0 +full:x7c

21 #define OV08D10_REG_PAGE		0xfd
22 #define OV08D10_REG_GLOBAL_EFFECTIVE 0x01
23 #define OV08D10_REG_CHIP_ID_0 0x00
24 #define OV08D10_REG_CHIP_ID_1 0x01
25 #define OV08D10_ID_MASK GENMASK(15, 0)
26 #define OV08D10_CHIP_ID 0x5608
28 #define OV08D10_REG_MODE_SELECT 0xa0
29 #define OV08D10_MODE_STANDBY 0x00
30 #define OV08D10_MODE_STREAMING 0x01
33 #define OV08D10_REG_VTS_H 0x05
34 #define OV08D10_REG_VTS_L 0x06
35 #define OV08D10_VTS_MAX 0x7fff
38 #define OV08D10_REG_EXPOSURE_H 0x02
39 #define OV08D10_REG_EXPOSURE_M 0x03
40 #define OV08D10_REG_EXPOSURE_L 0x04
46 #define OV08D10_REG_ANALOG_GAIN 0x24
52 #define OV08D10_REG_MWB_DGAIN_C 0x21
53 #define OV08D10_REG_MWB_DGAIN_F 0x22
54 #define OV08D10_DGTL_GAIN_MIN 0
60 #define OV08D10_REG_TEST_PATTERN 0x12
61 #define OV08D10_TEST_PATTERN_ENABLE 0x01
62 #define OV08D10_TEST_PATTERN_DISABLE 0x00
65 #define OV08D10_REG_FLIP_OPT 0x32
66 #define OV08D10_REG_FLIP_MASK 0x3
112 {0xfd, 0x00},
113 {0x11, 0x2a},
114 {0x14, 0x43},
115 {0x1a, 0x04},
116 {0x1b, 0xe1},
117 {0x1e, 0x13},
118 {0xb7, 0x02}
123 {0xfd, 0x00},
124 {0x1a, 0x04},
125 {0x1b, 0xe1},
126 {0x1d, 0x00},
127 {0x1c, 0x19},
128 {0x11, 0x2a},
129 {0x14, 0x54},
130 {0x1e, 0x13},
131 {0xb7, 0x02}
136 {0xfd, 0x01},
137 {0x12, 0x00},
138 {0x03, 0x12},
139 {0x04, 0x58},
140 {0x07, 0x05},
141 {0x21, 0x02},
142 {0x24, 0x30},
143 {0x33, 0x03},
144 {0x01, 0x03},
145 {0x19, 0x10},
146 {0x42, 0x55},
147 {0x43, 0x00},
148 {0x47, 0x07},
149 {0x48, 0x08},
150 {0xb2, 0x7f},
151 {0xb3, 0x7b},
152 {0xbd, 0x08},
153 {0xd2, 0x57},
154 {0xd3, 0x10},
155 {0xd4, 0x08},
156 {0xd5, 0x08},
157 {0xd6, 0x06},
158 {0xb1, 0x00},
159 {0xb4, 0x00},
160 {0xb7, 0x0a},
161 {0xbc, 0x44},
162 {0xbf, 0x48},
163 {0xc1, 0x10},
164 {0xc3, 0x24},
165 {0xc8, 0x03},
166 {0xc9, 0xf8},
167 {0xe1, 0x33},
168 {0xe2, 0xbb},
169 {0x51, 0x0c},
170 {0x52, 0x0a},
171 {0x57, 0x8c},
172 {0x59, 0x09},
173 {0x5a, 0x08},
174 {0x5e, 0x10},
175 {0x60, 0x02},
176 {0x6d, 0x5c},
177 {0x76, 0x16},
178 {0x7c, 0x11},
179 {0x90, 0x28},
180 {0x91, 0x16},
181 {0x92, 0x1c},
182 {0x93, 0x24},
183 {0x95, 0x48},
184 {0x9c, 0x06},
185 {0xca, 0x0c},
186 {0xce, 0x0d},
187 {0xfd, 0x01},
188 {0xc0, 0x00},
189 {0xdd, 0x18},
190 {0xde, 0x19},
191 {0xdf, 0x32},
192 {0xe0, 0x70},
193 {0xfd, 0x01},
194 {0xc2, 0x05},
195 {0xd7, 0x88},
196 {0xd8, 0x77},
197 {0xd9, 0x00},
198 {0xfd, 0x07},
199 {0x00, 0xf8},
200 {0x01, 0x2b},
201 {0x05, 0x40},
202 {0x08, 0x06},
203 {0x09, 0x11},
204 {0x28, 0x6f},
205 {0x2a, 0x20},
206 {0x2b, 0x05},
207 {0x5e, 0x10},
208 {0x52, 0x00},
209 {0x53, 0x7c},
210 {0x54, 0x00},
211 {0x55, 0x7c},
212 {0x56, 0x00},
213 {0x57, 0x7c},
214 {0x58, 0x00},
215 {0x59, 0x7c},
216 {0xfd, 0x02},
217 {0x9a, 0x30},
218 {0xa8, 0x02},
219 {0xfd, 0x02},
220 {0xa1, 0x01},
221 {0xa2, 0x09},
222 {0xa3, 0x9c},
223 {0xa5, 0x00},
224 {0xa6, 0x0c},
225 {0xa7, 0xd0},
226 {0xfd, 0x00},
227 {0x24, 0x01},
228 {0xc0, 0x16},
229 {0xc1, 0x08},
230 {0xc2, 0x30},
231 {0x8e, 0x0c},
232 {0x8f, 0xd0},
233 {0x90, 0x09},
234 {0x91, 0x9c},
235 {0xfd, 0x05},
236 {0x04, 0x40},
237 {0x07, 0x00},
238 {0x0d, 0x01},
239 {0x0f, 0x01},
240 {0x10, 0x00},
241 {0x11, 0x00},
242 {0x12, 0x0c},
243 {0x13, 0xcf},
244 {0x14, 0x00},
245 {0x15, 0x00},
246 {0xfd, 0x00},
247 {0x20, 0x0f},
248 {0xe7, 0x03},
249 {0xe7, 0x00}
254 {0xfd, 0x01},
255 {0x12, 0x00},
256 {0x03, 0x12},
257 {0x04, 0x58},
258 {0x07, 0x05},
259 {0x21, 0x02},
260 {0x24, 0x30},
261 {0x33, 0x03},
262 {0x01, 0x03},
263 {0x19, 0x10},
264 {0x42, 0x55},
265 {0x43, 0x00},
266 {0x47, 0x07},
267 {0x48, 0x08},
268 {0xb2, 0x7f},
269 {0xb3, 0x7b},
270 {0xbd, 0x08},
271 {0xd2, 0x57},
272 {0xd3, 0x10},
273 {0xd4, 0x08},
274 {0xd5, 0x08},
275 {0xd6, 0x06},
276 {0xb1, 0x00},
277 {0xb4, 0x00},
278 {0xb7, 0x0a},
279 {0xbc, 0x44},
280 {0xbf, 0x48},
281 {0xc1, 0x10},
282 {0xc3, 0x24},
283 {0xc8, 0x03},
284 {0xc9, 0xf8},
285 {0xe1, 0x33},
286 {0xe2, 0xbb},
287 {0x51, 0x0c},
288 {0x52, 0x0a},
289 {0x57, 0x8c},
290 {0x59, 0x09},
291 {0x5a, 0x08},
292 {0x5e, 0x10},
293 {0x60, 0x02},
294 {0x6d, 0x5c},
295 {0x76, 0x16},
296 {0x7c, 0x11},
297 {0x90, 0x28},
298 {0x91, 0x16},
299 {0x92, 0x1c},
300 {0x93, 0x24},
301 {0x95, 0x48},
302 {0x9c, 0x06},
303 {0xca, 0x0c},
304 {0xce, 0x0d},
305 {0xfd, 0x01},
306 {0xc0, 0x00},
307 {0xdd, 0x18},
308 {0xde, 0x19},
309 {0xdf, 0x32},
310 {0xe0, 0x70},
311 {0xfd, 0x01},
312 {0xc2, 0x05},
313 {0xd7, 0x88},
314 {0xd8, 0x77},
315 {0xd9, 0x00},
316 {0xfd, 0x07},
317 {0x00, 0xf8},
318 {0x01, 0x2b},
319 {0x05, 0x40},
320 {0x08, 0x06},
321 {0x09, 0x11},
322 {0x28, 0x6f},
323 {0x2a, 0x20},
324 {0x2b, 0x05},
325 {0x5e, 0x10},
326 {0x52, 0x00},
327 {0x53, 0x7c},
328 {0x54, 0x00},
329 {0x55, 0x7c},
330 {0x56, 0x00},
331 {0x57, 0x7c},
332 {0x58, 0x00},
333 {0x59, 0x7c},
334 {0xfd, 0x02},
335 {0x9a, 0x30},
336 {0xa8, 0x02},
337 {0xfd, 0x02},
338 {0xa1, 0x09},
339 {0xa2, 0x09},
340 {0xa3, 0x90},
341 {0xa5, 0x08},
342 {0xa6, 0x0c},
343 {0xa7, 0xc0},
344 {0xfd, 0x00},
345 {0x24, 0x01},
346 {0xc0, 0x16},
347 {0xc1, 0x08},
348 {0xc2, 0x30},
349 {0x8e, 0x0c},
350 {0x8f, 0xc0},
351 {0x90, 0x09},
352 {0x91, 0x90},
353 {0xfd, 0x05},
354 {0x04, 0x40},
355 {0x07, 0x00},
356 {0x0d, 0x01},
357 {0x0f, 0x01},
358 {0x10, 0x00},
359 {0x11, 0x00},
360 {0x12, 0x0c},
361 {0x13, 0xcf},
362 {0x14, 0x00},
363 {0x15, 0x00},
364 {0xfd, 0x00},
365 {0x20, 0x0f},
366 {0xe7, 0x03},
367 {0xe7, 0x00}
372 {0xfd, 0x01},
373 {0x1a, 0x0a},
374 {0x1b, 0x08},
375 {0x2a, 0x01},
376 {0x2b, 0x9a},
377 {0xfd, 0x01},
378 {0x12, 0x00},
379 {0x03, 0x05},
380 {0x04, 0xe2},
381 {0x07, 0x05},
382 {0x21, 0x02},
383 {0x24, 0x30},
384 {0x33, 0x03},
385 {0x31, 0x06},
386 {0x33, 0x03},
387 {0x01, 0x03},
388 {0x19, 0x10},
389 {0x42, 0x55},
390 {0x43, 0x00},
391 {0x47, 0x07},
392 {0x48, 0x08},
393 {0xb2, 0x7f},
394 {0xb3, 0x7b},
395 {0xbd, 0x08},
396 {0xd2, 0x57},
397 {0xd3, 0x10},
398 {0xd4, 0x08},
399 {0xd5, 0x08},
400 {0xd6, 0x06},
401 {0xb1, 0x00},
402 {0xb4, 0x00},
403 {0xb7, 0x0a},
404 {0xbc, 0x44},
405 {0xbf, 0x48},
406 {0xc1, 0x10},
407 {0xc3, 0x24},
408 {0xc8, 0x03},
409 {0xc9, 0xf8},
410 {0xe1, 0x33},
411 {0xe2, 0xbb},
412 {0x51, 0x0c},
413 {0x52, 0x0a},
414 {0x57, 0x8c},
415 {0x59, 0x09},
416 {0x5a, 0x08},
417 {0x5e, 0x10},
418 {0x60, 0x02},
419 {0x6d, 0x5c},
420 {0x76, 0x16},
421 {0x7c, 0x1a},
422 {0x90, 0x28},
423 {0x91, 0x16},
424 {0x92, 0x1c},
425 {0x93, 0x24},
426 {0x95, 0x48},
427 {0x9c, 0x06},
428 {0xca, 0x0c},
429 {0xce, 0x0d},
430 {0xfd, 0x01},
431 {0xc0, 0x00},
432 {0xdd, 0x18},
433 {0xde, 0x19},
434 {0xdf, 0x32},
435 {0xe0, 0x70},
436 {0xfd, 0x01},
437 {0xc2, 0x05},
438 {0xd7, 0x88},
439 {0xd8, 0x77},
440 {0xd9, 0x00},
441 {0xfd, 0x07},
442 {0x00, 0xf8},
443 {0x01, 0x2b},
444 {0x05, 0x40},
445 {0x08, 0x03},
446 {0x09, 0x08},
447 {0x28, 0x6f},
448 {0x2a, 0x20},
449 {0x2b, 0x05},
450 {0x2c, 0x01},
451 {0x50, 0x02},
452 {0x51, 0x03},
453 {0x5e, 0x00},
454 {0x52, 0x00},
455 {0x53, 0x7c},
456 {0x54, 0x00},
457 {0x55, 0x7c},
458 {0x56, 0x00},
459 {0x57, 0x7c},
460 {0x58, 0x00},
461 {0x59, 0x7c},
462 {0xfd, 0x02},
463 {0x9a, 0x30},
464 {0xa8, 0x02},
465 {0xfd, 0x02},
466 {0xa9, 0x04},
467 {0xaa, 0xd0},
468 {0xab, 0x06},
469 {0xac, 0x68},
470 {0xa1, 0x09},
471 {0xa2, 0x04},
472 {0xa3, 0xc8},
473 {0xa5, 0x04},
474 {0xa6, 0x06},
475 {0xa7, 0x60},
476 {0xfd, 0x05},
477 {0x06, 0x80},
478 {0x18, 0x06},
479 {0x19, 0x68},
480 {0xfd, 0x00},
481 {0x24, 0x01},
482 {0xc0, 0x16},
483 {0xc1, 0x08},
484 {0xc2, 0x30},
485 {0x8e, 0x06},
486 {0x8f, 0x60},
487 {0x90, 0x04},
488 {0x91, 0xc8},
489 {0x93, 0x0e},
490 {0x94, 0x77},
491 {0x95, 0x77},
492 {0x96, 0x10},
493 {0x98, 0x88},
494 {0x9c, 0x1a},
495 {0xfd, 0x05},
496 {0x04, 0x40},
497 {0x07, 0x99},
498 {0x0d, 0x03},
499 {0x0f, 0x03},
500 {0x10, 0x00},
501 {0x11, 0x00},
502 {0x12, 0x0c},
503 {0x13, 0xcf},
504 {0x14, 0x00},
505 {0x15, 0x00},
506 {0xfd, 0x00},
507 {0x20, 0x0f},
508 {0xe7, 0x03},
509 {0xe7, 0x00},
584 .link_freq_index = 0,
597 .link_freq_index = 0,
627 unsigned int i, count = 0; in ov08d10_modes_num()
629 for (i = 0; i < ARRAY_SIZE(ov08d10->priv_lane->sp_modes); i++) { in ov08d10_modes_num()
630 if (ov08d10->priv_lane->sp_modes[i].width == 0) in ov08d10_modes_num()
665 for (i = 0; i < r_list->num_of_regs; i++) { in ov08d10_write_reg_list()
670 "failed to write reg 0x%2.2x. error = %d", in ov08d10_write_reg_list()
676 return 0; in ov08d10_write_reg_list()
685 val = ((a_gain >> 3) & 0xFF); in ov08d10_update_analog_gain()
687 ret = i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x01); in ov08d10_update_analog_gain()
688 if (ret < 0) in ov08d10_update_analog_gain()
693 if (ret < 0) in ov08d10_update_analog_gain()
697 OV08D10_REG_GLOBAL_EFFECTIVE, 0x01); in ov08d10_update_analog_gain()
708 ret = i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x01); in ov08d10_update_digital_gain()
709 if (ret < 0) in ov08d10_update_digital_gain()
712 val = ((d_gain >> 8) & 0x3F); in ov08d10_update_digital_gain()
715 if (ret < 0) in ov08d10_update_digital_gain()
718 val = d_gain & 0xFF; in ov08d10_update_digital_gain()
720 if (ret < 0) in ov08d10_update_digital_gain()
724 OV08D10_REG_GLOBAL_EFFECTIVE, 0x01); in ov08d10_update_digital_gain()
736 ret = i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x01); in ov08d10_set_exposure()
737 if (ret < 0) in ov08d10_set_exposure()
740 hts_h = i2c_smbus_read_byte_data(client, 0x37); in ov08d10_set_exposure()
741 hts_l = i2c_smbus_read_byte_data(client, 0x38); in ov08d10_set_exposure()
746 ret = i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x01); in ov08d10_set_exposure()
747 if (ret < 0) in ov08d10_set_exposure()
751 val = ((exposure >> 16) & 0xFF); in ov08d10_set_exposure()
753 if (ret < 0) in ov08d10_set_exposure()
756 val = ((exposure >> 8) & 0xFF); in ov08d10_set_exposure()
758 if (ret < 0) in ov08d10_set_exposure()
761 val = exposure & 0xFF; in ov08d10_set_exposure()
763 if (ret < 0) in ov08d10_set_exposure()
767 OV08D10_REG_GLOBAL_EFFECTIVE, 0x01); in ov08d10_set_exposure()
777 ret = i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x01); in ov08d10_set_vblank()
778 if (ret < 0) in ov08d10_set_vblank()
781 val = ((vblank >> 8) & 0xFF); in ov08d10_set_vblank()
784 if (ret < 0) in ov08d10_set_vblank()
787 val = vblank & 0xFF; in ov08d10_set_vblank()
789 if (ret < 0) in ov08d10_set_vblank()
793 OV08D10_REG_GLOBAL_EFFECTIVE, 0x01); in ov08d10_set_vblank()
808 ret = i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x01); in ov08d10_test_pattern()
809 if (ret < 0) in ov08d10_test_pattern()
814 if (ret < 0) in ov08d10_test_pattern()
818 OV08D10_REG_GLOBAL_EFFECTIVE, 0x01); in ov08d10_test_pattern()
828 ret = i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x01); in ov08d10_set_ctrl_flip()
829 if (ret < 0) in ov08d10_set_ctrl_flip()
833 if (ret < 0) in ov08d10_set_ctrl_flip()
838 ret = i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x01); in ov08d10_set_ctrl_flip()
839 if (ret < 0) in ov08d10_set_ctrl_flip()
844 if (ret < 0) in ov08d10_set_ctrl_flip()
848 OV08D10_REG_GLOBAL_EFFECTIVE, 0x01); in ov08d10_set_ctrl_flip()
872 return 0; in ov08d10_set_ctrl()
939 0, in ov08d10_init_controls()
944 pixel_rate_max = to_rate(ov08d10->priv_lane->link_freq_menu, 0, in ov08d10_init_controls()
948 V4L2_CID_PIXEL_RATE, 0, pixel_rate_max, 1, in ov08d10_init_controls()
989 0, 0, ov08d10_test_pattern_menu); in ov08d10_init_controls()
992 V4L2_CID_HFLIP, 0, 1, 1, 0); in ov08d10_init_controls()
994 V4L2_CID_VFLIP, 0, 1, 1, 0); in ov08d10_init_controls()
1000 return 0; in ov08d10_init_controls()
1024 ret = i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x00); in ov08d10_start_streaming()
1025 if (ret < 0) { in ov08d10_start_streaming()
1029 ret = i2c_smbus_write_byte_data(client, 0x20, 0x0e); in ov08d10_start_streaming()
1030 if (ret < 0) { in ov08d10_start_streaming()
1035 ret = i2c_smbus_write_byte_data(client, 0x20, 0x0b); in ov08d10_start_streaming()
1036 if (ret < 0) { in ov08d10_start_streaming()
1059 ret = i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x00); in ov08d10_start_streaming()
1060 if (ret < 0) in ov08d10_start_streaming()
1065 if (ret < 0) in ov08d10_start_streaming()
1068 return i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x01); in ov08d10_start_streaming()
1076 ret = i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x00); in ov08d10_stop_streaming()
1077 if (ret < 0) { in ov08d10_stop_streaming()
1083 if (ret < 0) { in ov08d10_stop_streaming()
1088 ret = i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x01); in ov08d10_stop_streaming()
1089 if (ret < 0) { in ov08d10_stop_streaming()
1099 int ret = 0; in ov08d10_set_stream()
1102 return 0; in ov08d10_set_stream()
1107 if (ret < 0) { in ov08d10_set_stream()
1114 enable = 0; in ov08d10_set_stream()
1146 return 0; in ov08d10_suspend()
1170 return 0; in ov08d10_resume()
1218 return 0; in ov08d10_set_format()
1238 return 0; in ov08d10_get_format()
1247 if (code->index > 0) in ov08d10_enum_mbus_code()
1254 return 0; in ov08d10_enum_mbus_code()
1278 return 0; in ov08d10_enum_frame_size()
1286 ov08d10_update_pad_format(ov08d10, &ov08d10->priv_lane->sp_modes[0], in ov08d10_open()
1287 v4l2_subdev_get_try_format(sd, fh->state, 0)); in ov08d10_open()
1290 return 0; in ov08d10_open()
1321 ret = i2c_smbus_write_byte_data(client, OV08D10_REG_PAGE, 0x00); in ov08d10_identify_module()
1322 if (ret < 0) in ov08d10_identify_module()
1327 if (ret < 0) in ov08d10_identify_module()
1333 if (ret < 0) in ov08d10_identify_module()
1339 dev_err(&client->dev, "unexpected sensor id(0x%04x)\n", in ov08d10_identify_module()
1344 return 0; in ov08d10_identify_module()
1397 for (i = 0; i < ARRAY_SIZE(ov08d10->priv_lane->link_freq_menu); i++) { in ov08d10_get_hwcfg()
1398 for (j = 0; j < bus_cfg.nr_of_link_frequencies; j++) { in ov08d10_get_hwcfg()
1455 ov08d10->cur_mode = &ov08d10->priv_lane->sp_modes[0]; in ov08d10_probe()
1473 if (ret < 0) { in ov08d10_probe()
1487 return 0; in ov08d10_probe()