Skip to content

Commit

Permalink
drm/amd/display: update plane params before validation
Browse files Browse the repository at this point in the history
This patch updates the dc's plane state with the parameters set by the
user side.
This is needed to validate the plane capabilities with the parameters
user space wants to set.

Signed-off-by: Shirish S <shirish.s@amd.com>
Reviewed-by: Harry Wentland <Harry.Wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
  • Loading branch information
Shirish S authored and Alex Deucher committed Mar 7, 2018
1 parent 10eee2e commit 5449e07
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
Original file line number Diff line number Diff line change
Expand Up @@ -3064,6 +3064,9 @@ static int dm_plane_atomic_check(struct drm_plane *plane,
if (!dm_plane_state->dc_state)
return 0;

if (!fill_rects_from_plane_state(state, dm_plane_state->dc_state))
return -EINVAL;

if (dc_validate_plane(dc, dm_plane_state->dc_state) == DC_OK)
return 0;

Expand Down

0 comments on commit 5449e07

Please sign in to comment.