diff --git a/drivers/gpu/drm/nouveau/nouveau_connector.c b/drivers/gpu/drm/nouveau/nouveau_connector.c index 1e40ef0..2ead5ef 100644 --- a/drivers/gpu/drm/nouveau/nouveau_connector.c +++ b/drivers/gpu/drm/nouveau/nouveau_connector.c @@ -632,7 +632,7 @@ nouveau_connector_create_lvds(struct drm_device *dev, struct drm_nouveau_private *dev_priv = dev->dev_private; struct nouveau_i2c_chan *i2c = NULL; struct nouveau_encoder *nv_encoder; - struct drm_display_mode native, *mode, *temp; + struct drm_display_mode *mode, *temp; bool dummy, if_is_24bit = false; int ret, flags; @@ -663,9 +663,12 @@ nouveau_connector_create_lvds(struct drm_device *dev, * modeline is avalilable for the panel, set it as the panel's * native mode and exit. */ - if (!nv_connector->edid && - nv_encoder->dcb->lvdsconf.use_straps_for_mode && - nouveau_bios_fp_mode(dev, &native)) { + if (!nv_connector->edid && nouveau_bios_fp_mode(dev, NULL) && + (nv_encoder->dcb->lvdsconf.use_straps_for_mode || + dev_priv->VBIOS.pub.fp_no_ddc)) { + struct drm_display_mode native; + + nouveau_bios_fp_mode(dev, &native); nv_connector->native_mode = drm_mode_duplicate(dev, &native); goto out; }