/linux/drivers/media/i2c/adv748x/ |
H A D | adv748x-hdmi.c | 470 static int adv748x_hdmi_get_edid(struct v4l2_subdev *sd, struct v4l2_edid *edid) in adv748x_hdmi_get_edid() argument 474 memset(edid->reserved, 0, sizeof(edid->reserved)); in adv748x_hdmi_get_edid() 476 if (!hdmi->edid.present) in adv748x_hdmi_get_edid() 479 if (edid->start_block == 0 && edid->blocks == 0) { in adv748x_hdmi_get_edid() 480 edid->blocks = hdmi->edid.blocks; in adv748x_hdmi_get_edid() 484 if (edid->start_block >= hdmi->edid.blocks) in adv748x_hdmi_get_edid() 487 if (edid->start_block + edid->blocks > hdmi->edid.blocks) in adv748x_hdmi_get_edid() 488 edid->blocks = hdmi->edid.blocks - edid->start_block; in adv748x_hdmi_get_edid() 490 memcpy(edid->edid, hdmi->edid.edid + edid->start_block * 128, in adv748x_hdmi_get_edid() 491 edid->blocks * 128); in adv748x_hdmi_get_edid() [all …]
|
/linux/include/drm/ |
H A D | drm_edid.h | 284 struct edid { struct 346 int drm_edid_to_sad(const struct edid *edid, struct cea_sad **sads); argument 347 int drm_edid_to_speaker_allocation(const struct edid *edid, u8 **sadb); 426 struct edid *drm_get_edid(struct drm_connector *connector, 428 struct edid *drm_get_edid_switcheroo(struct drm_connector *connector, 430 struct edid *drm_edid_duplicate(const struct edid *edid); 431 int drm_add_edid_modes(struct drm_connector *connector, struct edid *edid); 435 bool drm_detect_hdmi_monitor(const struct edid *edid); 436 bool drm_detect_monitor_audio(const struct edid *edid); 442 int drm_edid_header_is_valid(const void *edid); [all …]
|
/linux/drivers/gpu/drm/ |
H A D | drm_edid.c | 1595 const struct edid *edid; member 1598 static int edid_hfeeodb_extension_block_count(const struct edid *edid); 1600 static int edid_hfeeodb_block_count(const struct edid *edid) in edid_hfeeodb_block_count() argument 1602 int eeodb = edid_hfeeodb_extension_block_count(edid); in edid_hfeeodb_block_count() 1607 static int edid_extension_block_count(const struct edid *edid) in edid_extension_block_count() argument 1609 return edid->extensions; in edid_extension_block_count() 1612 static int edid_block_count(const struct edid *edid) in edid_block_count() argument 1614 return edid_extension_block_count(edid) + 1; in edid_block_count() 1622 static int edid_size(const struct edid *edid) in edid_size() argument 1624 return edid_size_by_blocks(edid_block_count(edid)); in edid_size() [all …]
|
/linux/drivers/video/fbdev/core/ |
H A D | fbmon.c | 145 static int check_edid(unsigned char *edid) in check_edid() argument 147 unsigned char *block = edid + ID_MANUFACTURER_NAME, manufacturer[4]; in check_edid() 170 if (edid[i] != edid_v1_header[i]) { in check_edid() 177 b = edid + EDID_STRUCT_DISPLAY; in check_edid() 184 b = edid + DETAILED_TIMING_DESCRIPTIONS_START; in check_edid() 207 static void fix_edid(unsigned char *edid, int fix) in fix_edid() argument 215 memcpy(edid, edid_v1_header, 8); in fix_edid() 219 b = edid + EDID_STRUCT_DISPLAY; in fix_edid() 221 edid[127] += 0x80; in fix_edid() 225 b = edid + DETAILED_TIMING_DESCRIPTIONS_START; in fix_edid() [all …]
|
H A D | fb_ddc.c | 57 unsigned char *edid = NULL; in fb_ddc_read() local 90 edid = fb_do_probe_ddc_edid(adapter); in fb_ddc_read() 110 if (edid) in fb_ddc_read() 119 return edid; in fb_ddc_read()
|
/linux/include/media/ |
H A D | cec.h | 362 struct edid; 377 const struct edid *edid); 461 u16 cec_get_edid_phys_addr(const u8 *edid, unsigned int size, 489 const struct edid *edid) in cec_s_phys_addr_from_edid() argument 493 static inline u16 cec_get_edid_phys_addr(const u8 *edid, unsigned int size, in cec_get_edid_phys_addr() argument 544 static inline unsigned int cec_get_edid_spa_location(const u8 *edid, in cec_get_edid_spa_location() argument 562 if (edid[0x7e] + 1 < blocks) in cec_get_edid_spa_location() 563 blocks = edid[0x7e] + 1; in cec_get_edid_spa_location() 569 if (edid[offset] != 0x02 || edid[offset + 1] != 0x03) in cec_get_edid_spa_location() 573 d = edid[offset + 2] & 0x7f; in cec_get_edid_spa_location() [all …]
|
H A D | cec-notifier.h | 16 struct edid; 97 const struct edid *edid); 142 const struct edid *edid) in cec_notifier_set_phys_addr_from_edid() argument
|
/linux/drivers/gpu/drm/gma500/ |
H A D | psb_intel_modes.c | 55 struct edid *edid; in psb_intel_ddc_get_modes() local 58 edid = drm_get_edid(connector, adapter); in psb_intel_ddc_get_modes() 59 if (edid) { in psb_intel_ddc_get_modes() 60 drm_connector_update_edid_property(connector, edid); in psb_intel_ddc_get_modes() 61 ret = drm_add_edid_modes(connector, edid); in psb_intel_ddc_get_modes() 62 kfree(edid); in psb_intel_ddc_get_modes()
|
H A D | cdv_intel_hdmi.c | 131 struct edid *edid = NULL; in cdv_hdmi_detect() local 134 edid = drm_get_edid(connector, connector->ddc); in cdv_hdmi_detect() 138 if (edid) { in cdv_hdmi_detect() 139 if (edid->input & DRM_EDID_INPUT_DIGITAL) { in cdv_hdmi_detect() 142 drm_detect_hdmi_monitor(edid); in cdv_hdmi_detect() 144 drm_detect_monitor_audio(edid); in cdv_hdmi_detect() 146 kfree(edid); in cdv_hdmi_detect() 212 struct edid *edid = NULL; in cdv_hdmi_get_modes() local 215 edid = drm_get_edid(connector, connector->ddc); in cdv_hdmi_get_modes() 216 if (edid) { in cdv_hdmi_get_modes() [all …]
|
H A D | oaktrail_lvds.c | 299 struct edid *edid; in oaktrail_lvds_init() local 359 edid = NULL; in oaktrail_lvds_init() 364 edid = drm_get_edid(connector, i2c_adap); in oaktrail_lvds_init() 366 if (edid == NULL && dev_priv->lpc_gpio_base) { in oaktrail_lvds_init() 370 edid = drm_get_edid(connector, i2c_adap); in oaktrail_lvds_init() 385 if (edid) { in oaktrail_lvds_init() 386 drm_connector_update_edid_property(connector, edid); in oaktrail_lvds_init() 387 drm_add_edid_modes(connector, edid); in oaktrail_lvds_init() 388 kfree(edid); in oaktrail_lvds_init()
|
H A D | psb_intel_sdvo.c | 1231 static struct edid * 1239 static struct edid * 1253 struct edid *edid; in psb_intel_sdvo_hdmi_sink_detect() local 1255 edid = psb_intel_sdvo_get_edid(connector); in psb_intel_sdvo_hdmi_sink_detect() 1257 if (edid == NULL && psb_intel_sdvo_multifunc_encoder(psb_intel_sdvo)) { in psb_intel_sdvo_hdmi_sink_detect() 1266 edid = psb_intel_sdvo_get_edid(connector); in psb_intel_sdvo_hdmi_sink_detect() 1267 if (edid) in psb_intel_sdvo_hdmi_sink_detect() 1274 if (edid == NULL) in psb_intel_sdvo_hdmi_sink_detect() 1282 if (edid == NULL) in psb_intel_sdvo_hdmi_sink_detect() 1283 edid = psb_intel_sdvo_get_analog_edid(connector); in psb_intel_sdvo_hdmi_sink_detect() [all …]
|
/linux/drivers/media/test-drivers/vivid/ |
H A D | vivid-vid-common.c | 1077 struct v4l2_edid *edid) in vidioc_g_edid() argument 1085 memset(edid->reserved, 0, sizeof(edid->reserved)); in vidioc_g_edid() 1087 if (edid->pad >= dev->num_inputs) in vidioc_g_edid() 1089 if (dev->input_type[edid->pad] != HDMI) in vidioc_g_edid() 1093 if (edid->pad >= dev->num_outputs) in vidioc_g_edid() 1095 if (dev->output_type[edid->pad] != HDMI) in vidioc_g_edid() 1097 dev_rx = dev->output_to_input_instance[edid->pad]; in vidioc_g_edid() 1101 unsigned int hdmi_output = dev->output_to_iface_index[edid->pad]; in vidioc_g_edid() 1105 if (edid->start_block == 0 && edid->blocks == 0) { in vidioc_g_edid() 1106 edid->blocks = dev_rx->edid_blocks; in vidioc_g_edid() [all …]
|
/linux/drivers/media/cec/usb/extron-da-hd-4k-plus/ |
H A D | extron-da-hd-4k-plus.c | 252 const u8 *edid = port->edid; in extron_parse_edid() local 261 port->est_i = edid[0x23]; in extron_parse_edid() 262 port->est_ii = edid[0x24]; in extron_parse_edid() 266 const u8 *dtd = edid + 0x36 + i * 18; in extron_parse_edid() 292 edid += 128; in extron_parse_edid() 295 if (edid[0] != 0x02 || edid[1] != 0x03) in extron_parse_edid() 299 d = edid[2] & 0x7f; in extron_parse_edid() 308 u8 tag = edid[i] >> 5; in extron_parse_edid() 309 u8 len = edid[i] & 0x1f; in extron_parse_edid() 318 if (memchr(edid + i + 1, 97, len)) in extron_parse_edid() [all …]
|
/linux/drivers/gpu/drm/i915/gvt/ |
H A D | edid.c | 56 struct intel_vgpu_i2c_edid *edid = &vgpu->display.i2c_edid; in edid_get_byte() local 59 if (edid->state == I2C_NOT_SPECIFIED || !edid->target_selected) { in edid_get_byte() 63 if (edid->current_edid_read >= EDID_SIZE) { in edid_get_byte() 68 if (!edid->edid_available) { in edid_get_byte() 73 if (intel_vgpu_has_monitor_on_port(vgpu, edid->port)) { in edid_get_byte() 75 intel_vgpu_port(vgpu, edid->port)->edid; in edid_get_byte() 77 chr = edid_data->edid_block[edid->current_edid_read]; in edid_get_byte() 78 edid->current_edid_read++; in edid_get_byte() 571 struct intel_vgpu_i2c_edid *edid = &vgpu->display.i2c_edid; in intel_vgpu_init_i2c_edid() local 573 edid->state = I2C_NOT_SPECIFIED; in intel_vgpu_init_i2c_edid() [all …]
|
/linux/drivers/media/i2c/ |
H A D | adv7511-v4l2.c | 114 struct adv7511_state_edid edid; member 561 struct adv7511_state_edid *edid = &state->edid; in adv7511_log_status() local 590 edid->segments ? "found" : "no", in adv7511_log_status() 591 edid->blocks); in adv7511_log_status() 1183 static int adv7511_get_edid(struct v4l2_subdev *sd, struct v4l2_edid *edid) in adv7511_get_edid() argument 1187 memset(edid->reserved, 0, sizeof(edid->reserved)); in adv7511_get_edid() 1189 if (edid->pad != 0) in adv7511_get_edid() 1192 if (edid->start_block == 0 && edid->blocks == 0) { in adv7511_get_edid() 1193 edid->blocks = state->edid.blocks; in adv7511_get_edid() 1197 if (state->edid.blocks == 0) in adv7511_get_edid() [all …]
|
H A D | tda1997x.c | 273 u8 edid[256]; member 276 } edid; member 572 state->edid.present = 1; in tda1997x_delayed_work_enable_hpd() 1841 static int tda1997x_get_edid(struct v4l2_subdev *sd, struct v4l2_edid *edid) in tda1997x_get_edid() argument 1845 v4l_dbg(1, debug, state->client, "%s pad=%d\n", __func__, edid->pad); in tda1997x_get_edid() 1846 memset(edid->reserved, 0, sizeof(edid->reserved)); in tda1997x_get_edid() 1848 if (edid->start_block == 0 && edid->blocks == 0) { in tda1997x_get_edid() 1849 edid->blocks = state->edid.blocks; in tda1997x_get_edid() 1853 if (!state->edid.present) in tda1997x_get_edid() 1856 if (edid->start_block >= state->edid.blocks) in tda1997x_get_edid() [all …]
|
H A D | tc358743.c | 1762 struct v4l2_subdev_edid *edid) in tc358743_g_edid() argument 1766 memset(edid->reserved, 0, sizeof(edid->reserved)); in tc358743_g_edid() 1768 if (edid->pad != 0) in tc358743_g_edid() 1771 if (edid->start_block == 0 && edid->blocks == 0) { in tc358743_g_edid() 1772 edid->blocks = state->edid_blocks_written; in tc358743_g_edid() 1779 if (edid->start_block >= state->edid_blocks_written || in tc358743_g_edid() 1780 edid->blocks == 0) in tc358743_g_edid() 1783 if (edid->start_block + edid->blocks > state->edid_blocks_written) in tc358743_g_edid() 1784 edid->blocks = state->edid_blocks_written - edid->start_block; in tc358743_g_edid() 1786 i2c_rd(sd, EDID_RAM + (edid->start_block * EDID_BLOCK_SIZE), edid->edid, in tc358743_g_edid() [all …]
|
/linux/drivers/video/fbdev/nvidia/ |
H A D | nv_i2c.c | 155 u8 *edid = NULL; in nvidia_probe_i2c_connector() local 158 edid = fb_ddc_read(&par->chan[conn - 1].adapter); in nvidia_probe_i2c_connector() 160 if (!edid && conn == 1) { in nvidia_probe_i2c_connector() 165 edid = kmemdup(e, EDID_LENGTH, GFP_KERNEL); in nvidia_probe_i2c_connector() 168 *out_edid = edid; in nvidia_probe_i2c_connector() 170 return (edid) ? 0 : 1; in nvidia_probe_i2c_connector()
|
/linux/drivers/video/fbdev/savage/ |
H A D | savagefb-i2c.c | 221 u8 *edid; in savagefb_probe_i2c_connector() local 224 edid = fb_ddc_read(&par->chan.adapter); in savagefb_probe_i2c_connector() 226 edid = NULL; in savagefb_probe_i2c_connector() 228 if (!edid) { in savagefb_probe_i2c_connector() 233 edid = kmemdup(e, EDID_LENGTH, GFP_KERNEL); in savagefb_probe_i2c_connector() 236 *out_edid = edid; in savagefb_probe_i2c_connector() 238 return (edid) ? 0 : 1; in savagefb_probe_i2c_connector()
|
/linux/drivers/media/cec/core/ |
H A D | cec-notifier.c | 205 const struct edid *edid) in cec_notifier_set_phys_addr_from_edid() argument 212 if (edid && edid->extensions) in cec_notifier_set_phys_addr_from_edid() 213 pa = cec_get_edid_phys_addr((const u8 *)edid, in cec_notifier_set_phys_addr_from_edid() 214 EDID_LENGTH * (edid->extensions + 1), NULL); in cec_notifier_set_phys_addr_from_edid()
|
/linux/drivers/video/fbdev/aty/ |
H A D | radeon_i2c.c | 144 u8 *edid; in radeon_probe_i2c_connector() local 146 edid = fb_ddc_read(&rinfo->i2c[conn-1].adapter); in radeon_probe_i2c_connector() 149 *out_edid = edid; in radeon_probe_i2c_connector() 150 if (!edid) { in radeon_probe_i2c_connector() 154 if (edid[0x14] & 0x80) { in radeon_probe_i2c_connector()
|
/linux/drivers/gpu/drm/vboxvideo/ |
H A D | vbox_mode.c | 645 unsigned char edid[EDID_SIZE] = { in vbox_set_edid() local 690 edid[12] = width & 0xff; in vbox_set_edid() 691 edid[13] = width >> 8; in vbox_set_edid() 692 edid[14] = height & 0xff; in vbox_set_edid() 693 edid[15] = height >> 8; in vbox_set_edid() 694 edid[54] = clock & 0xff; in vbox_set_edid() 695 edid[55] = clock >> 8; in vbox_set_edid() 696 edid[56] = width & 0xff; in vbox_set_edid() 697 edid[58] = (width >> 4) & 0xf0; in vbox_set_edid() 698 edid[59] = height & 0xff; in vbox_set_edid() [all …]
|
/linux/drivers/video/fbdev/i810/ |
H A D | i810-i2c.c | 158 u8 *edid = NULL; in i810_probe_i2c_connector() local 162 edid = fb_ddc_read(&par->chan[conn].adapter); in i810_probe_i2c_connector() 168 edid = kmemdup(e, EDID_LENGTH, GFP_KERNEL); in i810_probe_i2c_connector() 172 *out_edid = edid; in i810_probe_i2c_connector() 174 return (edid) ? 0 : 1; in i810_probe_i2c_connector()
|
/linux/drivers/gpu/drm/msm/dp/ |
H A D | dp_panel.c | 212 static u8 msm_dp_panel_get_edid_checksum(const struct edid *edid) in msm_dp_panel_get_edid_checksum() argument 214 edid += edid->extensions; in msm_dp_panel_get_edid_checksum() 216 return edid->checksum; in msm_dp_panel_get_edid_checksum() 232 const struct edid *edid = drm_edid_raw(msm_dp_panel->drm_edid); in msm_dp_panel_handle_sink_request() local 235 if (edid) in msm_dp_panel_handle_sink_request() 236 checksum = msm_dp_panel_get_edid_checksum(edid); in msm_dp_panel_handle_sink_request()
|
/linux/drivers/gpu/drm/bridge/ |
H A D | nxp-ptn3460.c | 163 u8 *edid; in ptn3460_edid_read() local 169 edid = kmalloc(EDID_LENGTH, GFP_KERNEL); in ptn3460_edid_read() 170 if (!edid) { in ptn3460_edid_read() 175 ret = ptn3460_read_bytes(ptn_bridge, PTN3460_EDID_ADDR, edid, in ptn3460_edid_read() 178 kfree(edid); in ptn3460_edid_read() 182 drm_edid = drm_edid_alloc(edid, EDID_LENGTH); in ptn3460_edid_read()
|