summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2013-08-14 22:02:38 (GMT)
committerInki Dae <inki.dae@samsung.com>2014-10-15 11:05:12 (GMT)
commitee9df58ac556833a11b6a55278da7ee13927380d (patch)
treeee14e1ca558e86047d1e2c9481472e7697913fd5
parent047410bc3e963b36e13061683a16301ac864a78d (diff)
downloadlinux-3.10-ee9df58ac556833a11b6a55278da7ee13927380d.zip
linux-3.10-ee9df58ac556833a11b6a55278da7ee13927380d.tar.gz
linux-3.10-ee9df58ac556833a11b6a55278da7ee13927380d.tar.bz2
drm/prime: fix error path in drm_gem_prime_fd_to_handle
handle_unreference only clears up the obj->name and the reference, but would leave a dangling handle in the idr. The right thing to do is to call handle_delete. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com>
-rw-r--r--drivers/gpu/drm/drm_prime.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/drm_prime.c b/drivers/gpu/drm/drm_prime.c
index d39fe52..372711a 100644
--- a/drivers/gpu/drm/drm_prime.c
+++ b/drivers/gpu/drm/drm_prime.c
@@ -476,7 +476,7 @@ fail:
/* hmm, if driver attached, we are relying on the free-object path
* to detach.. which seems ok..
*/
- drm_gem_object_handle_unreference_unlocked(obj);
+ drm_gem_handle_delete(file_priv, *handle);
out_put:
dma_buf_put(dma_buf);
mutex_unlock(&file_priv->prime.lock);