From: Jakob Bornecrantz Date: Thu, 3 Nov 2011 20:03:07 +0000 (+0100) Subject: vmwgfx: Move the prefered mode first in the list X-Git-Tag: firefly_0821_release~3680^2~4155^2~1 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=d41025c0d6a7b3d80d68f07f943b72962d66ac74;p=firefly-linux-kernel-4.4.55.git vmwgfx: Move the prefered mode first in the list Signed-off-by: Jakob Bornecrantz Signed-off-by: Thomas Hellstrom Signed-off-by: Dave Airlie --- diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c b/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c index 66e92acb3c5b..8de24836edb1 100644 --- a/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c @@ -1747,6 +1747,10 @@ int vmw_du_connector_fill_modes(struct drm_connector *connector, drm_mode_probed_add(connector, mode); } + /* Move the prefered mode first, help apps pick the right mode. */ + if (du->pref_mode) + list_move(&du->pref_mode->head, &connector->probed_modes); + drm_mode_connector_list_update(connector); return 1;