Lines Matching refs:bt

214 static void ths8200_setup(struct v4l2_subdev *sd, struct v4l2_bt_timings *bt)
217 uint16_t line_start_active_video = (bt->vsync + bt->vbackporch);
218 uint16_t line_start_front_porch = (vtotal(bt) - bt->vfrontporch);
225 ths8200_write(sd, THS8200_DTG1_SPEC_A, bt->hsync);
226 ths8200_write(sd, THS8200_DTG1_SPEC_B, bt->hfrontporch);
229 if (!bt->interlaced)
236 (bt->hbackporch + bt->hsync) & 0xff);
244 ((bt->hbackporch + bt->hsync) & 0x100) >> 1);
247 ths8200_write(sd, THS8200_DTG1_SPEC_K_LSB, (bt->hfrontporch) & 0xff);
249 ((bt->hfrontporch) & 0x700) >> 8);
252 ths8200_write(sd, THS8200_DTG1_SPEC_G_LSB, (htotal(bt)/2) & 0xff);
254 ((htotal(bt)/2) >> 8) & 0x0f);
257 ths8200_write(sd, THS8200_DTG1_TOT_PIXELS_MSB, htotal(bt) >> 8);
258 ths8200_write(sd, THS8200_DTG1_TOT_PIXELS_LSB, htotal(bt) & 0xff);
265 ((vtotal(bt) >> 4) & 0xf0) + 0x7);
266 ths8200_write(sd, THS8200_DTG1_FRAME_SZ_LSB, vtotal(bt) & 0xff);
271 if (!bt->interlaced)
292 ths8200_write(sd, THS8200_DTG2_BP3_4_MSB, ((vtotal(bt)) >> 4) & 0x70);
295 ths8200_write(sd, THS8200_DTG2_BP3_LSB, (vtotal(bt)) & 0xff);
302 ths8200_write(sd, THS8200_DTG2_HLENGTH_LSB, bt->hsync & 0xff);
304 (bt->hsync >> 2) & 0xc0);
308 (htotal(bt) >> 8) & 0x1f);
309 ths8200_write(sd, THS8200_DTG2_HLENGTH_HDLY_LSB, htotal(bt));
312 ths8200_write(sd, THS8200_DTG2_VLENGTH1_LSB, (bt->vsync + 1) & 0xff);
314 ((bt->vsync + 1) >> 2) & 0xc0);
318 ((vtotal(bt) + 1) >> 8) & 0x7);
319 ths8200_write(sd, THS8200_DTG2_VDLY1_LSB, vtotal(bt) + 1);
336 if (bt->polarities & V4L2_DV_HSYNC_POS_POL) {
340 if (bt->polarities & V4L2_DV_VSYNC_POS_POL) {
356 "vertical: sync %d\n", __func__, htotal(bt), vtotal(bt),
357 polarity, bt->hfrontporch, bt->hbackporch,
358 bt->hsync, bt->vsync);
378 timings->bt.flags &= ~V4L2_DV_FL_REDUCED_FPS;
383 ths8200_setup(sd, &timings->bt);