public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel@ffwll.ch>
To: Matt Roper <matthew.d.roper@intel.com>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH 2/2] drm/i915: Drop unnecessary NULL test
Date: Thu, 10 Dec 2015 15:15:21 +0100	[thread overview]
Message-ID: <20151210141521.GS20822@phenom.ffwll.local> (raw)
In-Reply-To: <1449614932-20258-2-git-send-email-matthew.d.roper@intel.com>

On Tue, Dec 08, 2015 at 02:48:52PM -0800, Matt Roper wrote:
> We can never be passed a NULL crtc_state (and if we could there are
> plenty of other places later in this function where we access it
> without testing for NULL).
> 
> Signed-off-by: Matt Roper <matthew.d.roper@intel.com>

Yup, atomic state structures better exist once we can do
atomic_check/commit().

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>

> ---
>  drivers/gpu/drm/i915/intel_display.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index 2e8d1a8..51980a9 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -11808,7 +11808,7 @@ int intel_plane_atomic_calc_changes(struct drm_crtc_state *crtc_state,
>  	bool turn_off, turn_on, visible, was_visible;
>  	struct drm_framebuffer *fb = plane_state->fb;
>  
> -	if (crtc_state && INTEL_INFO(dev)->gen >= 9 &&
> +	if (INTEL_INFO(dev)->gen >= 9 &&
>  	    plane->type != DRM_PLANE_TYPE_CURSOR) {
>  		ret = skl_update_scaler_plane(
>  			to_intel_crtc_state(crtc_state),
> -- 
> 2.1.4
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2015-12-10 14:15 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-08 22:48 [PATCH 1/2] drm/i915: Don't leak connector state on SDVO init failure Matt Roper
2015-12-08 22:48 ` [PATCH 2/2] drm/i915: Drop unnecessary NULL test Matt Roper
2015-12-10 14:15   ` Daniel Vetter [this message]
2015-12-10 14:14 ` [PATCH 1/2] drm/i915: Don't leak connector state on SDVO init failure Daniel Vetter
2015-12-11  1:57   ` Matt Roper
2015-12-11 17:28     ` Daniel Vetter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20151210141521.GS20822@phenom.ffwll.local \
    --to=daniel@ffwll.ch \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=matthew.d.roper@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox