aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2019-05-28 19:58:18 -0400
committerBen Skeggs <bskeggs@redhat.com>2019-07-19 02:26:50 -0400
commitd1084184789d677df4e9c110f38cb3f3d709195d (patch)
treefdb43ec0d11b0ea98953e39480bf3fd8164a4143
parent533f4752407543f488a9118d817b8c504352b6fb (diff)
drm/nouveau/kms: disallow dual-link harder if hdmi connection detected
The fallthrough cases (pre-Fermi) would accidentally allow dual-link pixel clocks even where they shouldn't be. This leads to a high resolution HDMI displays, connected via a DVI->HDMI adapter, to fail on the original NV50. Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_connector.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_connector.c b/drivers/gpu/drm/nouveau/nouveau_connector.c
index 4116ee62adaf..caa8c7595889 100644
--- a/drivers/gpu/drm/nouveau/nouveau_connector.c
+++ b/drivers/gpu/drm/nouveau/nouveau_connector.c
@@ -978,11 +978,13 @@ get_tmds_link_bandwidth(struct drm_connector *connector)
978 struct nouveau_drm *drm = nouveau_drm(connector->dev); 978 struct nouveau_drm *drm = nouveau_drm(connector->dev);
979 struct dcb_output *dcb = nv_connector->detected_encoder->dcb; 979 struct dcb_output *dcb = nv_connector->detected_encoder->dcb;
980 struct drm_display_info *info = NULL; 980 struct drm_display_info *info = NULL;
981 const unsigned duallink_scale = 981 unsigned duallink_scale =
982 nouveau_duallink && nv_encoder->dcb->duallink_possible ? 2 : 1; 982 nouveau_duallink && nv_encoder->dcb->duallink_possible ? 2 : 1;
983 983
984 if (drm_detect_hdmi_monitor(nv_connector->edid)) 984 if (drm_detect_hdmi_monitor(nv_connector->edid)) {
985 info = &nv_connector->base.display_info; 985 info = &nv_connector->base.display_info;
986 duallink_scale = 1;
987 }
986 988
987 if (info) { 989 if (info) {
988 if (nouveau_hdmimhz > 0) 990 if (nouveau_hdmimhz > 0)
@@ -1003,6 +1005,7 @@ get_tmds_link_bandwidth(struct drm_connector *connector)
1003 if (drm->client.device.info.family >= NV_DEVICE_INFO_V0_FERMI) 1005 if (drm->client.device.info.family >= NV_DEVICE_INFO_V0_FERMI)
1004 return 225000; 1006 return 225000;
1005 } 1007 }
1008
1006 if (dcb->location != DCB_LOC_ON_CHIP || 1009 if (dcb->location != DCB_LOC_ON_CHIP ||
1007 drm->client.device.info.chipset >= 0x46) 1010 drm->client.device.info.chipset >= 0x46)
1008 return 165000 * duallink_scale; 1011 return 165000 * duallink_scale;