summaryrefslogtreecommitdiff
path: root/drivers/gpu
diff options
context:
space:
mode:
authorJakob Bornecrantz <jakob@vmware.com>2010-05-28 11:21:58 +0200
committerDave Airlie <airlied@redhat.com>2010-06-01 09:37:21 +1000
commit1ae1ddd5e99bbc067414ff571ac18d4312b4c8cf (patch)
treed43d71a888202a7a3e38ed11c6bfdd0f4e7d4214 /drivers/gpu
parent1925d4565888eb313cc923372da6a08bbfb3a859 (diff)
drm/vmwgfx: Get connector status from detection function.
Also make sure the ldu::active member is properly initialized. Part of fix by Michel Daenzer <daenzer@vmware.com>. Signed-off-by: Jakob Bornecrantz <jakob@vmware.com> Signed-off-by: Michel Daenzer <daenzer@vmware.com> Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/vmwgfx/vmwgfx_ldu.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_ldu.c b/drivers/gpu/drm/vmwgfx/vmwgfx_ldu.c
index e1b3cf539b4a..fefef9012c4b 100644
--- a/drivers/gpu/drm/vmwgfx/vmwgfx_ldu.c
+++ b/drivers/gpu/drm/vmwgfx/vmwgfx_ldu.c
@@ -456,13 +456,11 @@ static int vmw_ldu_init(struct vmw_private *dev_priv, unsigned unit)
encoder = &ldu->base.encoder;
connector = &ldu->base.connector;
+ INIT_LIST_HEAD(&ldu->active);
+
drm_connector_init(dev, connector, &vmw_legacy_connector_funcs,
DRM_MODE_CONNECTOR_LVDS);
- /* Initial status */
- if (unit == 0)
- connector->status = connector_status_connected;
- else
- connector->status = connector_status_disconnected;
+ connector->status = vmw_ldu_connector_detect(connector);
drm_encoder_init(dev, encoder, &vmw_legacy_encoder_funcs,
DRM_MODE_ENCODER_LVDS);
@@ -470,8 +468,6 @@ static int vmw_ldu_init(struct vmw_private *dev_priv, unsigned unit)
encoder->possible_crtcs = (1 << unit);
encoder->possible_clones = 0;
- INIT_LIST_HEAD(&ldu->active);
-
drm_crtc_init(dev, crtc, &vmw_legacy_crtc_funcs);
drm_connector_attach_property(connector,