Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 359337
b: refs/heads/master
c: ff51235
h: refs/heads/master
i:
  359335: fb38a63
v: v3
  • Loading branch information
Tejun Heo authored and Linus Torvalds committed Feb 28, 2013
1 parent a968e18 commit 783427a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c8c470afe316002d5d5259a134984ed03f40e249
refs/heads/master: ff512357fe1bf7f901bd0ea19fc718025dff6b07
13 changes: 3 additions & 10 deletions trunk/drivers/gpu/drm/sis/sis_mm.c
Original file line number Diff line number Diff line change
Expand Up @@ -128,17 +128,10 @@ static int sis_drm_alloc(struct drm_device *dev, struct drm_file *file,
if (retval)
goto fail_alloc;

again:
if (idr_pre_get(&dev_priv->object_idr, GFP_KERNEL) == 0) {
retval = -ENOMEM;
goto fail_idr;
}

retval = idr_get_new_above(&dev_priv->object_idr, item, 1, &user_key);
if (retval == -EAGAIN)
goto again;
if (retval)
retval = idr_alloc(&dev_priv->object_idr, item, 1, 0, GFP_KERNEL);
if (retval < 0)
goto fail_idr;
user_key = retval;

list_add(&item->owner_list, &file_priv->obj_list);
mutex_unlock(&dev->struct_mutex);
Expand Down

0 comments on commit 783427a

Please sign in to comment.