diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2013-11-26 12:33:36 +1000 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2013-12-03 23:28:57 +1000 |
commit | 13cd1a5511eb44a54187d91d4929a6592787a48b (patch) | |
tree | 85aa59aeb0c673f0f2fe20d7085a6a305b9c10ff /drivers/gpu | |
parent | 2fd04c81dc652689b104ab16eba26146dde5c43f (diff) |
drm/nouveau/sw: fix oops if gpu has its display block disabled
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/nouveau/core/engine/software/nv50.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/core/engine/software/nv50.c b/drivers/gpu/drm/nouveau/core/engine/software/nv50.c index b574dd4bb82..5ce686ee729 100644 --- a/drivers/gpu/drm/nouveau/core/engine/software/nv50.c +++ b/drivers/gpu/drm/nouveau/core/engine/software/nv50.c @@ -176,7 +176,7 @@ nv50_software_context_ctor(struct nouveau_object *parent, if (ret) return ret; - chan->vblank.nr_event = pdisp->vblank->index_nr; + chan->vblank.nr_event = pdisp ? pdisp->vblank->index_nr : 0; chan->vblank.event = kzalloc(chan->vblank.nr_event * sizeof(*chan->vblank.event), GFP_KERNEL); if (!chan->vblank.event) |