summaryrefslogtreecommitdiff
path: root/linux-core
diff options
context:
space:
mode:
authorThomas Hellstrom <thomas-at-tungstengraphics-dot-com>2006-08-23 13:49:13 +0200
committerThomas Hellstrom <thomas-at-tungstengraphics-dot-com>2006-08-23 13:49:13 +0200
commitea5709997329a6c425261dcc454cf7dd97a81167 (patch)
tree89842bdcc74332a72eb6165b555e7e2c4ad1b1c8 /linux-core
parent459b234d79daaa8a003da9ea48775a5587d5ba2a (diff)
Fix previous commit: Only fall back to hashed handles
when there is a duplicate handle error. Not for other errors.
Diffstat (limited to 'linux-core')
-rw-r--r--linux-core/drm_bufs.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/linux-core/drm_bufs.c b/linux-core/drm_bufs.c
index 13b0b174..1d9c0386 100644
--- a/linux-core/drm_bufs.c
+++ b/linux-core/drm_bufs.c
@@ -82,8 +82,8 @@ int drm_map_handle(drm_device_t *dev, drm_hash_item_t *hash,
int ret;
hash->key = user_token;
ret = drm_ht_insert_item(&dev->map_hash, hash);
- if (!ret)
- return 0;
+ if (ret != -EINVAL)
+ return ret;
}
return drm_ht_just_insert_please(&dev->map_hash, hash,
user_token, 32 - PAGE_SHIFT - 3,