[Intel-gfx] [PATCH 1/3] drm/i915: Use standard form -EDEADLK check

Jani Nikula jani.nikula at linux.intel.com
Thu Sep 30 10:53:58 UTC 2021


On Thu, 30 Sep 2021, Ville Syrjala <ville.syrjala at linux.intel.com> wrote:
> From: Ville Syrjälä <ville.syrjala at linux.intel.com>
>
> Unify how we check for -EDEADLK vs. other errors from
> crtc vs. encoder compute_config() calls.

On the series,

Reviewed-by: Jani Nikula <jani.nikula at intel.com>


>
> Signed-off-by: Ville Syrjälä <ville.syrjala at linux.intel.com>
> ---
>  drivers/gpu/drm/i915/display/intel_display.c | 7 +++----
>  1 file changed, 3 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
> index a4453dd1bb51..4fa0b7cfa888 100644
> --- a/drivers/gpu/drm/i915/display/intel_display.c
> +++ b/drivers/gpu/drm/i915/display/intel_display.c
> @@ -7699,11 +7699,10 @@ intel_modeset_pipe_config(struct intel_atomic_state *state,
>  
>  		ret = encoder->compute_config(encoder, pipe_config,
>  					      connector_state);
> +		if (ret == -EDEADLK)
> +			return ret;
>  		if (ret < 0) {
> -			if (ret != -EDEADLK)
> -				drm_dbg_kms(&i915->drm,
> -					    "Encoder config failure: %d\n",
> -					    ret);
> +			drm_dbg_kms(&i915->drm, "Encoder config failure: %d\n", ret);
>  			return ret;
>  		}
>  	}

-- 
Jani Nikula, Intel Open Source Graphics Center


More information about the Intel-gfx mailing list