diff options
author | Thierry Reding <treding@nvidia.com> | 2017-02-28 15:46:42 +0100 |
---|---|---|
committer | Thierry Reding <treding@nvidia.com> | 2017-02-28 16:16:46 +0100 |
commit | 6472e5090be7c78749a3c279b4faae87ab835c40 (patch) | |
tree | 3447583297ce95fe76ef1525abad2078cf4961a3 /scripts | |
parent | e6b62714e87c8811d5564b6a0738dcde63a51774 (diff) | |
download | linux-stable-6472e5090be7c78749a3c279b4faae87ab835c40.tar.gz linux-stable-6472e5090be7c78749a3c279b4faae87ab835c40.tar.bz2 linux-stable-6472e5090be7c78749a3c279b4faae87ab835c40.zip |
drm: Introduce drm_property_blob_{get,put}()
For consistency with other reference counting APIs in the kernel, add
drm_property_blob_get() and drm_property_blob_put() to reference count
DRM blob properties.
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.
A semantic patch is provided that can be used to convert all drivers to
the 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-7-thierry.reding@gmail.com
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/coccinelle/api/drm-get-put.cocci | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/scripts/coccinelle/api/drm-get-put.cocci b/scripts/coccinelle/api/drm-get-put.cocci index 24882547b4d1..0c7a9265c07e 100644 --- a/scripts/coccinelle/api/drm-get-put.cocci +++ b/scripts/coccinelle/api/drm-get-put.cocci @@ -44,6 +44,12 @@ expression object; | - drm_gem_object_unreference_unlocked(object) + drm_gem_object_put_unlocked(object) +| +- drm_property_reference_blob(object) ++ drm_property_blob_get(object) +| +- drm_property_unreference_blob(object) ++ drm_property_blob_put(object) ) @r depends on report@ @@ -71,6 +77,10 @@ drm_gem_object_reference@p(object) __drm_gem_object_unreference(object) | drm_gem_object_unreference_unlocked(object) +| +drm_property_unreference_blob@p(object) +| +drm_property_reference_blob@p(object) ) @script:python depends on report@ |