aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/nouveau
diff options
context:
space:
mode:
authorBen Skeggs <bskeggs@redhat.com>2012-06-25 04:04:27 -0400
committerBen Skeggs <bskeggs@redhat.com>2012-07-25 20:28:14 -0400
commit5086f69eb960ff5984a2fdac9d238c76edfe57bc (patch)
treee27cdee43eb5bedcc1dd54a83b61aa3f3e468113 /drivers/gpu/drm/nouveau
parent887cd78804fb4179211d221c023455c33f13206a (diff)
drm/nouveau/gem: fix object reference leak in a failure path
Reported-by: Maarten Lankhorst <maarten.lankhorst@canonical.com> Signed-off-by: Ben Skeggs <bskeggs@redhat.com> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau')
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_gem.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_gem.c b/drivers/gpu/drm/nouveau/nouveau_gem.c
index 30f542316944..34d0bc596213 100644
--- a/drivers/gpu/drm/nouveau/nouveau_gem.c
+++ b/drivers/gpu/drm/nouveau/nouveau_gem.c
@@ -342,6 +342,7 @@ retry:
342 if (nvbo->reserved_by && nvbo->reserved_by == file_priv) { 342 if (nvbo->reserved_by && nvbo->reserved_by == file_priv) {
343 NV_ERROR(dev, "multiple instances of buffer %d on " 343 NV_ERROR(dev, "multiple instances of buffer %d on "
344 "validation list\n", b->handle); 344 "validation list\n", b->handle);
345 drm_gem_object_unreference_unlocked(gem);
345 validate_fini(op, NULL); 346 validate_fini(op, NULL);
346 return -EINVAL; 347 return -EINVAL;
347 } 348 }