Lines Matching refs:stdi
1362 struct stdi_readback *stdi,
1366 u32 hfreq = (ADV76XX_FSC * 8) / stdi->bl;
1377 if (vtotal(bt) != stdi->lcf + 1)
1379 if (bt->vsync != stdi->lcvs)
1391 if (v4l2_detect_cvt(stdi->lcf + 1, hfreq, stdi->lcvs, 0,
1392 (stdi->hs_pol == '+' ? V4L2_DV_HSYNC_POS_POL : 0) |
1393 (stdi->vs_pol == '+' ? V4L2_DV_VSYNC_POS_POL : 0),
1396 if (v4l2_detect_gtf(stdi->lcf + 1, hfreq, stdi->lcvs,
1397 (stdi->hs_pol == '+' ? V4L2_DV_HSYNC_POS_POL : 0) |
1398 (stdi->vs_pol == '+' ? V4L2_DV_VSYNC_POS_POL : 0),
1404 __func__, stdi->lcvs, stdi->lcf, stdi->bl,
1405 stdi->hs_pol, stdi->vs_pol);
1410 static int read_stdi(struct v4l2_subdev *sd, struct stdi_readback *stdi)
1422 stdi->bl = cp_read16(sd, 0xb1, 0x3fff);
1423 stdi->lcf = cp_read16(sd, info->lcf_reg, 0x7ff);
1424 stdi->lcvs = cp_read(sd, 0xb3) >> 3;
1425 stdi->interlaced = io_read(sd, 0x12) & 0x10;
1431 stdi->hs_pol = polarity & 0x10
1433 stdi->vs_pol = polarity & 0x40
1436 stdi->hs_pol = 'x';
1437 stdi->vs_pol = 'x';
1441 stdi->hs_pol = polarity & 0x20 ? '+' : '-';
1442 stdi->vs_pol = polarity & 0x10 ? '+' : '-';
1451 if (stdi->lcf < 239 || stdi->bl < 8 || stdi->bl == 0x3fff) {
1453 memset(stdi, 0, sizeof(struct stdi_readback));
1459 __func__, stdi->lcf, stdi->bl, stdi->lcvs,
1460 stdi->hs_pol, stdi->vs_pol,
1461 stdi->interlaced ? "interlaced" : "progressive");
1552 struct stdi_readback stdi;
1566 if (read_stdi(sd, &stdi)) {
1570 bt->interlaced = stdi.interlaced ?
1619 if (!stdi2dv_timings(sd, &stdi, timings))
1621 stdi.lcvs += 1;
1622 v4l2_dbg(1, debug, sd, "%s: lcvs + 1 = %d\n", __func__, stdi.lcvs);
1623 if (!stdi2dv_timings(sd, &stdi, timings))
1625 stdi.lcvs -= 2;
1626 v4l2_dbg(1, debug, sd, "%s: lcvs - 1 = %d\n", __func__, stdi.lcvs);
1627 if (stdi2dv_timings(sd, &stdi, timings)) {
2489 struct stdi_readback stdi;
2571 if (read_stdi(sd, &stdi))
2575 stdi.lcf, stdi.bl, stdi.lcvs,
2576 stdi.interlaced ? "interlaced" : "progressive",
2577 stdi.hs_pol, stdi.vs_pol);