aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/vmwgfx
diff options
context:
space:
mode:
authorJakob Bornecrantz <jakob@vmware.com>2010-05-28 05:21:58 -0400
committerDave Airlie <airlied@redhat.com>2010-05-31 19:37:21 -0400
commit1ae1ddd5e99bbc067414ff571ac18d4312b4c8cf (patch)
treed43d71a888202a7a3e38ed11c6bfdd0f4e7d4214 /drivers/gpu/drm/vmwgfx
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/drm/vmwgfx')
-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 e1b3cf539b4..fefef9012c4 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)
456 encoder = &ldu->base.encoder; 456 encoder = &ldu->base.encoder;
457 connector = &ldu->base.connector; 457 connector = &ldu->base.connector;
458 458
459 INIT_LIST_HEAD(&ldu->active);
460
459 drm_connector_init(dev, connector, &vmw_legacy_connector_funcs, 461 drm_connector_init(dev, connector, &vmw_legacy_connector_funcs,
460 DRM_MODE_CONNECTOR_LVDS); 462 DRM_MODE_CONNECTOR_LVDS);
461 /* Initial status */ 463 connector->status = vmw_ldu_connector_detect(connector);
462 if (unit == 0)
463 connector->status = connector_status_connected;
464 else
465 connector->status = connector_status_disconnected;
466 464
467 drm_encoder_init(dev, encoder, &vmw_legacy_encoder_funcs, 465 drm_encoder_init(dev, encoder, &vmw_legacy_encoder_funcs,
468 DRM_MODE_ENCODER_LVDS); 466 DRM_MODE_ENCODER_LVDS);
@@ -470,8 +468,6 @@ static int vmw_ldu_init(struct vmw_private *dev_priv, unsigned unit)
470 encoder->possible_crtcs = (1 << unit); 468 encoder->possible_crtcs = (1 << unit);
471 encoder->possible_clones = 0; 469 encoder->possible_clones = 0;
472 470
473 INIT_LIST_HEAD(&ldu->active);
474
475 drm_crtc_init(dev, crtc, &vmw_legacy_crtc_funcs); 471 drm_crtc_init(dev, crtc, &vmw_legacy_crtc_funcs);
476 472
477 drm_connector_attach_property(connector, 473 drm_connector_attach_property(connector,