diff options
author | Thomas Hellstrom <thellstrom@vmware.com> | 2015-06-29 12:59:58 -0700 |
---|---|---|
committer | Thomas Hellstrom <thellstrom@vmware.com> | 2015-08-05 14:01:11 +0200 |
commit | f6b05004538ab0933c7527f10a2a6ed88c620f99 (patch) | |
tree | 1d6af79077b60f5d0768be44b449772f077b1333 /drivers/gpu/drm/vmwgfx/vmwgfx_kms.c | |
parent | 352b20dc51488b264abe6b9755395c63c90e807b (diff) | |
download | op-kernel-dev-f6b05004538ab0933c7527f10a2a6ed88c620f99.zip op-kernel-dev-f6b05004538ab0933c7527f10a2a6ed88c620f99.tar.gz |
drm/vmwgfx: Fix kms preferred mode sorting
The preferred mode typically didn't end up first, since the function
drm_mode_connector_list_update() reordered the modes.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Reviewed-by: Sinclair Yeh <syeh@vmware.com>
Diffstat (limited to 'drivers/gpu/drm/vmwgfx/vmwgfx_kms.c')
-rw-r--r-- | drivers/gpu/drm/vmwgfx/vmwgfx_kms.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c b/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c index ae87e7e..ef605b6 100644 --- a/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_kms.c @@ -1554,11 +1554,9 @@ 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, true); + /* Move the prefered mode first, help apps pick the right mode. */ + drm_mode_sort(&connector->modes); return 1; } |