[Intel-gfx] [PATCH 2/3] drm/i915: Don't update staged config during force restore modesets

Matt Roper matthew.d.roper at intel.com
Mon Jun 15 19:00:51 PDT 2015


On Fri, Jun 12, 2015 at 10:19:41AM +0300, Ander Conselvan de Oliveira wrote:
> The force restore path relies on the staged config to preserve the
> configuration used before a suspend/resume cycle. The update done to it
> in intel_modeset_fixup_state() would cause that information to be lost
> after the first modeset, making it impossible to restore the modes for
> pipes B and C.
> 
> References: https://bugs.freedesktop.org/show_bug.cgi?id=90468
> Signed-off-by: Ander Conselvan de Oliveira <ander.conselvan.de.oliveira at intel.com>

Reviewed-by: Matt Roper <matthew.d.roper at intel.com>

> ---
>  drivers/gpu/drm/i915/intel_display.c | 8 +++-----
>  1 file changed, 3 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index 6ef57e6..49c6698 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -11386,10 +11386,6 @@ static void intel_modeset_fixup_state(struct drm_atomic_state *state)
>  		crtc->base.enabled = crtc->base.state->enable;
>  		crtc->config = to_intel_crtc_state(crtc->base.state);
>  	}
> -
> -	/* Copy the new configuration to the staged state, to keep the few
> -	 * pieces of code that haven't been converted yet happy */
> -	intel_modeset_update_staged_output_state(state->dev);
>  }
>  
>  static void
> @@ -12654,8 +12650,10 @@ static int intel_set_mode_with_config(struct drm_crtc *crtc,
>  
>  	ret = __intel_set_mode(crtc, pipe_config);
>  
> -	if (ret == 0 && check)
> +	if (ret == 0 && check) {
> +		intel_modeset_update_staged_output_state(crtc->dev);
>  		intel_modeset_check_state(crtc->dev);
> +	}
>  
>  	return ret;
>  }
> -- 
> 2.1.0
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Matt Roper
Graphics Software Engineer
IoTG Platform Enabling & Development
Intel Corporation
(916) 356-2795


More information about the Intel-gfx mailing list