From: Ander Conselvan de Oliveira Date: Fri, 27 Mar 2015 13:33:51 +0000 (+0200) Subject: drm/i915: Handle error to get connector state when staging config X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=9d918c157fc27716ca8d601745b4776a3145cc93;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git drm/i915: Handle error to get connector state when staging config The return value of one of the calls to drm_atomic_get_connector_state() in intel_modeset_stage_output_state() wasn't checked for errors. Reported-by: Dan Carpenter Signed-off-by: Ander Conselvan de Oliveira Signed-off-by: Daniel Vetter --- diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index 3852cbaf9163..75955fee6d24 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -11985,6 +11985,8 @@ intel_modeset_stage_output_state(struct drm_device *dev, for_each_intel_connector(dev, connector) { connector_state = drm_atomic_get_connector_state(state, &connector->base); + if (IS_ERR(connector_state)) + return PTR_ERR(connector_state); if (connector->new_encoder) { if (connector->new_encoder != connector->encoder)