OSDN Git Service
(root)
/
uclinux-h8
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ef4c627
)
drm/gem: Use container_of in drm_gem_object_free
author
Daniel Vetter
<daniel.vetter@ffwll.ch>
Thu, 15 Oct 2015 07:36:26 +0000
(09:36 +0200)
committer
Daniel Vetter
<daniel.vetter@ffwll.ch>
Mon, 19 Oct 2015 09:00:43 +0000
(11:00 +0200)
Just a random thing I spotted while reading code - better safe than
sorry.
Link:
http://mid.gmane.org/1444894601-5200-11-git-send-email-daniel.vetter@ffwll.ch
Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
drivers/gpu/drm/drm_gem.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/drm_gem.c
b/drivers/gpu/drm/drm_gem.c
index
7dc4a8a
..
ab8ea42
100644
(file)
--- a/
drivers/gpu/drm/drm_gem.c
+++ b/
drivers/gpu/drm/drm_gem.c
@@
-763,7
+763,8
@@
EXPORT_SYMBOL(drm_gem_object_release);
void
drm_gem_object_free(struct kref *kref)
{
- struct drm_gem_object *obj = (struct drm_gem_object *) kref;
+ struct drm_gem_object *obj =
+ container_of(kref, struct drm_gem_object, refcount);
struct drm_device *dev = obj->dev;
WARN_ON(!mutex_is_locked(&dev->struct_mutex));