drm/amd/display: Move drm_get_vblank from legacy code
authorLeo (Sunpeng) Li <sunpeng.li@amd.com>
Tue, 25 Jul 2017 22:00:44 +0000 (18:00 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 26 Sep 2017 22:08:19 +0000 (18:08 -0400)
commite29088b2932a11db6155212ca19c75029bc137aa
tree86c371cae4437657aec2f3a05769ba7f45f7575b
parent061d34994597284b4228b7468762772fbdbcfa4c
drm/amd/display: Move drm_get_vblank from legacy code

Previously, we assumed that allow_modeset=false => page flip. This
assumption breaks when an atomic commit is submitted with allow_modeset
set to false, since the legacy flip code is never called (the legacy
code grabs the vblank reference).

Fix: Move drm_vblank_get() from amdgpu_atomic_helper_page_flip() to
amdgpu_dm_commit_surfaces().

Signed-off-by: Leo (Sunpeng) Li <sunpeng.li@amd.com>
Reviewed-by: Andrey Grodzovsky <Andrey.Grodzovsky@amd.com>
Acked-by: Harry Wentland <Harry.Wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_types.c