aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/ttm
diff options
context:
space:
mode:
authorThomas Hellstrom <thellstrom@vmware.com>2014-01-24 02:49:45 -0500
committerThomas Hellstrom <thellstrom@vmware.com>2014-02-05 03:29:25 -0500
commitc66f854338253e603a4fb6817069ee23eacf0ae3 (patch)
tree4c6d5f2c2c02d8c582fb51b7e11f6445bcbfa928 /drivers/gpu/drm/ttm
parent76f4f415e502e4dfaf409edd0d4ed0dd3a0a0419 (diff)
drm/ttm: Fix TTM object open regression
Commit drm/ttm: ttm object security fixes for render nodes introduced a regression where, if a TTM object was opened multiple times from the same open file, the caller would spin uninterruptibly in the kernel. Fix this. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
Diffstat (limited to 'drivers/gpu/drm/ttm')
-rw-r--r--drivers/gpu/drm/ttm/ttm_object.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/ttm/ttm_object.c b/drivers/gpu/drm/ttm/ttm_object.c
index 37079859afc8..53b51c4e671a 100644
--- a/drivers/gpu/drm/ttm/ttm_object.c
+++ b/drivers/gpu/drm/ttm/ttm_object.c
@@ -292,7 +292,7 @@ int ttm_ref_object_add(struct ttm_object_file *tfile,
292 292
293 if (ret == 0) { 293 if (ret == 0) {
294 ref = drm_hash_entry(hash, struct ttm_ref_object, hash); 294 ref = drm_hash_entry(hash, struct ttm_ref_object, hash);
295 if (!kref_get_unless_zero(&ref->kref)) { 295 if (kref_get_unless_zero(&ref->kref)) {
296 rcu_read_unlock(); 296 rcu_read_unlock();
297 break; 297 break;
298 } 298 }