mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Ben Skeggs <bskeggs@redhat.com>
To: "Gustavo A. R. Silva" <garsilva@embeddedor.com>,
	David Airlie <airlied@linux.ie>
Cc: dri-devel@lists.freedesktop.org, nouveau@lists.freedesktop.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] gpu: drm: nouveau: add null check before pointer dereference
Date: Tue, 23 May 2017 08:24:26 +1000	[thread overview]
Message-ID: <52f5e84e-7072-4814-275e-1f5a1dba60d2@redhat.com> (raw)
In-Reply-To: <20170522191237.GA6240@embeddedgus>

On 05/23/2017 05:12 AM, Gustavo A. R. Silva wrote:
> Add null check before dereferencing pointer asyc
I've taken the patch into my tree, thanks!

Ben.

> 
> Addresses-Coverity-ID: 1397932
> Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
> ---
>   drivers/gpu/drm/nouveau/nv50_display.c | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/nouveau/nv50_display.c b/drivers/gpu/drm/nouveau/nv50_display.c
> index a766324..052a60a 100644
> --- a/drivers/gpu/drm/nouveau/nv50_display.c
> +++ b/drivers/gpu/drm/nouveau/nv50_display.c
> @@ -2107,7 +2107,8 @@ nv50_head_atomic_check(struct drm_crtc *crtc, struct drm_crtc_state *state)
>   					asyc->set.dither = true;
>   			}
>   		} else {
> -			asyc->set.mask = ~0;
> +			if (asyc)
> +				asyc->set.mask = ~0;
>   			asyh->set.mask = ~0;
>   		}
>   
> 

      reply	other threads:[~2017-05-22 22:24 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-22 19:12 Gustavo A. R. Silva
2017-05-22 22:24 ` Ben Skeggs [this message]

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=52f5e84e-7072-4814-275e-1f5a1dba60d2@redhat.com \
    --to=bskeggs@redhat.com \
    --cc=airlied@linux.ie \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=garsilva@embeddedor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nouveau@lists.freedesktop.org \
    /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

all inboxes | Powered by JetHome®