[PATCH] drm/amd/display: check if modeset is required before adding plane
Deucher, Alexander
Alexander.Deucher at amd.com
Fri Oct 27 13:36:12 UTC 2017
> -----Original Message-----
> From: S, Shirish
> Sent: Thursday, October 26, 2017 11:26 PM
> To: amd-gfx at lists.freedesktop.org; Wentland, Harry; Deucher, Alexander
> Subject: [PATCH] drm/amd/display: check if modeset is required before
> adding plane
>
>
> From: Shirish S <shirish.s at amd.com>
>
> Adding affected planes without checking if modeset is requested from the
> user space causes performance regression in video p/b scenarios when full
> screen p/b is not composited.
>
> Hence add a check before adding a plane as affected.
>
> bug: https://bugs.freedesktop.org/show_bug.cgi?id=103408
>
> Signed-off-by: Shirish S <shirish.s at amd.com>
Acked-by: Alex Deucher <alexander.deucher at amd.com>
> ---
> drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> index f0b50d9..e6ec130 100644
> --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> @@ -4727,6 +4727,9 @@ static int amdgpu_dm_atomic_check(struct
> drm_device *dev,
> }
> } else {
> for_each_oldnew_crtc_in_state(state, crtc, old_crtc_state,
> new_crtc_state, i) {
> + if
> (!drm_atomic_crtc_needs_modeset(new_crtc_state))
> + continue;
> +
> if (!new_crtc_state->enable)
> continue;
>
> --
> 2.7.4
More information about the amd-gfx
mailing list