diff options
author | Gustavo A. R. Silva <garsilva@embeddedor.com> | 2017-05-22 21:12:37 +0200 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2017-06-06 06:04:03 +0200 |
commit | 86276921a17ee3090749c9f38f57dcfb73733bd4 (patch) | |
tree | d2c195892b6a0b8357f19790d972b7add759c447 /drivers/gpu | |
parent | Merge tag 'topic/dp-quirks-2017-05-31' of git://anongit.freedesktop.org/git/d... (diff) | |
download | linux-86276921a17ee3090749c9f38f57dcfb73733bd4.tar.xz linux-86276921a17ee3090749c9f38f57dcfb73733bd4.zip |
drm/nouveau/kms/nv50: add null check before pointer dereference
Add null check before dereferencing pointer asyc
Addresses-Coverity-ID: 1397932
Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/nouveau/nv50_display.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nv50_display.c b/drivers/gpu/drm/nouveau/nv50_display.c index a7663249b3ba..06e564a9ccb2 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; } |