Lines Matching defs:edid

119 	struct adv7511_state_edid edid;
548 struct adv7511_state_edid *edid = &state->edid;
577 edid->segments ? "found" : "no",
578 edid->blocks);
618 v4l2_info(sd, "i2c edid addr: 0x%x\n", state->i2c_edid_addr);
1170 static int adv7511_get_edid(struct v4l2_subdev *sd, struct v4l2_edid *edid)
1174 memset(edid->reserved, 0, sizeof(edid->reserved));
1176 if (edid->pad != 0)
1179 if (edid->start_block == 0 && edid->blocks == 0) {
1180 edid->blocks = state->edid.blocks;
1184 if (state->edid.blocks == 0)
1187 if (edid->start_block >= state->edid.blocks)
1190 if (edid->start_block + edid->blocks > state->edid.blocks)
1191 edid->blocks = state->edid.blocks - edid->start_block;
1193 memcpy(edid->edid, &state->edid.data[edid->start_block * 128],
1194 128 * edid->blocks);
1430 v4l2_dbg(lvl, debug, sd, "edid segment %d\n", segment);
1477 if (state->edid.read_retries) {
1478 state->edid.read_retries--;
1479 v4l2_dbg(1, debug, sd, "%s: edid read failed\n", __func__);
1490 v4l2_dbg(1, debug, sd, "%s: no edid found\n", __func__);
1561 if ((status & MASK_ADV7511_HPD_DETECT) && ((status & MASK_ADV7511_MSEN_DETECT) || state->edid.segments)) {
1562 v4l2_dbg(1, debug, sd, "%s: hotplug and (rx-sense or edid)\n", __func__);
1573 state->edid.read_retries = EDID_MAX_RETRIES;
1578 state->edid.read_retries = EDID_MAX_RETRIES;
1588 memset(&state->edid, 0, sizeof(struct adv7511_state_edid));
1606 u32 blocks = state->edid.blocks;
1607 u8 *data = state->edid.data;
1622 u8 *data = state->edid.data;
1634 v4l2_dbg(1, debug, sd, "%s: edid ready (retries: %d)\n",
1635 __func__, EDID_MAX_RETRIES - state->edid.read_retries);
1637 if (state->edid.complete)
1646 v4l2_err(sd, "edid segment number too big\n");
1650 err = adv7511_edid_rd(sd, 256, &state->edid.data[segment * 256]);
1652 adv7511_dbg_dump_edid(2, debug, sd, segment, &state->edid.data[segment * 256]);
1654 state->edid.blocks = state->edid.data[0x7e] + 1;
1656 __func__, state->edid.blocks);
1663 v4l2_err(sd, "%s: edid crc or header error\n", __func__);
1670 state->edid.segments = segment + 1;
1672 if (((state->edid.data[0x7e] >> 1) + 1) > state->edid.segments) {
1674 v4l2_dbg(1, debug, sd, "%s: request segment %d\n", __func__, state->edid.segments);
1676 adv7511_wr(sd, 0xc4, state->edid.segments);
1677 state->edid.read_retries = EDID_MAX_RETRIES;
1682 v4l2_dbg(1, debug, sd, "%s: edid complete with %d segment(s)\n", __func__, state->edid.segments);
1683 state->edid.complete = true;
1684 ed.phys_addr = cec_get_edid_phys_addr(state->edid.data,
1685 state->edid.segments * 256,
1730 struct adv7511_state_edid *edid = &state->edid;
1745 memset(edid, 0, sizeof(struct adv7511_state_edid));
1855 v4l2_err(sd, "failed to register edid i2c client\n");