1 // SPDX-License-Identifier: GPL-2.0
3 /// Use drm_*_get() and drm_*_put() helpers instead of drm_*_reference() and
4 /// drm_*_unreference() helpers.
7 // Copyright: (C) 2017 NVIDIA Corporation
8 // Options: --no-includes --include-headers
19 - drm_mode_object_reference(object)
20 + drm_mode_object_get(object)
22 - drm_mode_object_unreference(object)
23 + drm_mode_object_put(object)
25 - drm_connector_reference(object)
26 + drm_connector_get(object)
28 - drm_connector_unreference(object)
29 + drm_connector_put(object)
31 - drm_framebuffer_reference(object)
32 + drm_framebuffer_get(object)
34 - drm_framebuffer_unreference(object)
35 + drm_framebuffer_put(object)
37 - drm_gem_object_reference(object)
38 + drm_gem_object_get(object)
40 - drm_gem_object_unreference(object)
41 + drm_gem_object_put(object)
43 - __drm_gem_object_unreference(object)
44 + __drm_gem_object_put(object)
46 - drm_gem_object_unreference_unlocked(object)
47 + drm_gem_object_put_unlocked(object)
49 - drm_property_reference_blob(object)
50 + drm_property_blob_get(object)
52 - drm_property_unreference_blob(object)
53 + drm_property_blob_put(object)
55 - drm_dev_unref(object)
65 drm_mode_object_unreference@p(object)
67 drm_mode_object_reference@p(object)
69 drm_connector_unreference@p(object)
71 drm_connector_reference@p(object)
73 drm_framebuffer_unreference@p(object)
75 drm_framebuffer_reference@p(object)
77 drm_gem_object_unreference@p(object)
79 drm_gem_object_reference@p(object)
81 __drm_gem_object_unreference(object)
83 drm_gem_object_unreference_unlocked(object)
85 drm_property_unreference_blob@p(object)
87 drm_property_reference_blob@p(object)
89 drm_dev_unref@p(object)
92 @script:python depends on report@
97 msg="WARNING: use get/put helpers to reference and dereference %s" % (object)
98 coccilib.report.print_report(p[0], msg)