]> git.baikalelectronics.ru Git - kernel.git/commit
drm: Introduce drm_gem_object_{get,put}()
authorThierry Reding <treding@nvidia.com>
Tue, 28 Feb 2017 14:46:41 +0000 (15:46 +0100)
committerThierry Reding <treding@nvidia.com>
Tue, 28 Feb 2017 15:16:43 +0000 (16:16 +0100)
commitef7e3b7a007510682ba43d1474ceb536a95f671a
tree295fdcf6c17e379b393de020cd0c0848ba0a872b
parent624dfef065a5ecacf78ae55a9b9ba758a1c00bb0
drm: Introduce drm_gem_object_{get,put}()

For consistency with other reference counting APIs in the kernel, add
drm_gem_object_get() and drm_gem_object_put(), as well as an unlocked
variant of the latter, to reference count GEM buffer objects.

Compatibility aliases are added to keep existing code working. To help
speed up the transition, all the instances of the old functions in the
DRM core are already replaced in this commit.

The existing semantic patch for the DRM subsystem-wide conversion is
extended to account for these new helpers.

Reviewed-by: Sean Paul <seanpaul@chromium.org>
Acked-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20170228144643.5668-6-thierry.reding@gmail.com
Documentation/gpu/drm-mm.rst
drivers/gpu/drm/drm_fb_cma_helper.c
drivers/gpu/drm/drm_gem.c
drivers/gpu/drm/drm_gem_cma_helper.c
drivers/gpu/drm/drm_prime.c
include/drm/drm_gem.h
scripts/coccinelle/api/drm-get-put.cocci