diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2009-02-08 14:08:04 -0500 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2009-02-19 21:21:09 -0500 |
commit | 96dec61d563fb8dff2c8427fdf85327a95b65c74 (patch) | |
tree | b514a1367cfa36cc18dd38a4251aae633772cd1a /drivers/gpu | |
parent | d6873102fd36c577f88174d8bd50f1d51645fc51 (diff) |
drm/i915: refleak along pin() error path.
A missing unreference if the user calls pin() a second time on a pinned
buffer.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Dave Airlie <airlied@linux.ie>
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/i915/i915_gem.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c index b79ced8f3c61..55f4c060fa01 100644 --- a/drivers/gpu/drm/i915/i915_gem.c +++ b/drivers/gpu/drm/i915/i915_gem.c | |||
@@ -2755,6 +2755,7 @@ i915_gem_pin_ioctl(struct drm_device *dev, void *data, | |||
2755 | if (obj_priv->pin_filp != NULL && obj_priv->pin_filp != file_priv) { | 2755 | if (obj_priv->pin_filp != NULL && obj_priv->pin_filp != file_priv) { |
2756 | DRM_ERROR("Already pinned in i915_gem_pin_ioctl(): %d\n", | 2756 | DRM_ERROR("Already pinned in i915_gem_pin_ioctl(): %d\n", |
2757 | args->handle); | 2757 | args->handle); |
2758 | drm_gem_object_unreference(obj); | ||
2758 | mutex_unlock(&dev->struct_mutex); | 2759 | mutex_unlock(&dev->struct_mutex); |
2759 | return -EINVAL; | 2760 | return -EINVAL; |
2760 | } | 2761 | } |