Skip to content

Commit

Permalink
drm/ttm: fix refcounting in ttm global code.
Browse files Browse the repository at this point in the history
the global refcount wasn't being increased after the first reference.
this caused an oops on unload on a multi-gpu card.

Signed-off-by: Dave Airlie <airlied@redhat.com>
  • Loading branch information
Dave Airlie authored and Dave Airlie committed Oct 6, 2009
1 parent b8c00ac commit df748b0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/gpu/drm/ttm/ttm_global.c
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,8 @@ int ttm_global_item_ref(struct ttm_global_reference *ref)
if (unlikely(ret != 0))
goto out_err;

++item->refcount;
}
++item->refcount;
ref->object = item->object;
object = item->object;
mutex_unlock(&item->mutex);
Expand Down

0 comments on commit df748b0

Please sign in to comment.