[PATCH 4/4] drm/dp_mst: Use DP_MST_LOGICAL_PORT_0 instead of magic number
Imre Deak
imre.deak at intel.com
Mon Feb 1 12:01:45 UTC 2021
Use the macro defined for the first logical port instead of the
corresponding magic number.
Cc: Lyude Paul <lyude at redhat.com>
Signed-off-by: Imre Deak <imre.deak at intel.com>
---
drivers/gpu/drm/drm_dp_mst_topology.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/drm_dp_mst_topology.c b/drivers/gpu/drm/drm_dp_mst_topology.c
index 43a40660136c..0a54506c2773 100644
--- a/drivers/gpu/drm/drm_dp_mst_topology.c
+++ b/drivers/gpu/drm/drm_dp_mst_topology.c
@@ -4232,9 +4232,8 @@ drm_dp_mst_detect_port(struct drm_connector *connector,
case DP_PEER_DEVICE_SST_SINK:
ret = connector_status_connected;
/* for logical ports - cache the EDID */
- if (port->port_num >= 8 && !port->cached_edid) {
+ if (port->port_num >= DP_MST_LOGICAL_PORT_0 && !port->cached_edid)
port->cached_edid = drm_get_edid(connector, &port->aux.ddc);
- }
break;
case DP_PEER_DEVICE_DP_LEGACY_CONV:
if (port->ldps)
--
2.25.1
More information about the dri-devel
mailing list