Skip to content

Commit

Permalink
drm/nouveau/kms: Move drm_dp_cec_unset_edid() into nouveau_connector_…
Browse files Browse the repository at this point in the history
…detect()

For whatever reason we currently unset the EDID for DP CEC support when
responding to the connector being unplugged, instead of just doing it in
nouveau_connector_detect() where we set the CEC EDID. This isn't really
needed and could even potentially cause us to forget to unset the EDID
if the connector is removed without a corresponding hpd event, so let's
fix that.

Signed-off-by: Lyude Paul <lyude@redhat.com>
Reviewed-by: Ben Skeggs <bskeggs@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200826182456.322681-12-lyude@redhat.com
  • Loading branch information
Lyude Paul committed Aug 31, 2020
1 parent 8b75e83 commit 02bb7fe
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions drivers/gpu/drm/nouveau/nouveau_connector.c
Original file line number Diff line number Diff line change
Expand Up @@ -633,10 +633,11 @@ nouveau_connector_detect(struct drm_connector *connector, bool force)
conn_status = connector_status_connected;
goto out;
}

}

out:
if (!nv_connector->edid)
drm_dp_cec_unset_edid(&nv_connector->aux);

pm_runtime_mark_last_busy(dev->dev);
pm_runtime_put_autosuspend(dev->dev);
Expand Down Expand Up @@ -1174,8 +1175,6 @@ nouveau_connector_hotplug(struct nvif_notify *notify)
return NVIF_NOTIFY_DROP;
}

if (!plugged)
drm_dp_cec_unset_edid(&nv_connector->aux);
NV_DEBUG(drm, "%splugged %s\n", plugged ? "" : "un", name);

drm_helper_hpd_irq_event(connector->dev);
Expand Down

0 comments on commit 02bb7fe

Please sign in to comment.