summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/drm_internal.h
diff options
context:
space:
mode:
authorThomas Zimmermann <tzimmermann@suse.de>2025-05-26 15:25:20 +0200
committerThomas Zimmermann <tzimmermann@suse.de>2025-05-30 09:47:28 +0200
commitdf1c3093aee3daee4d56a5cb8cdba75c1ef6962f (patch)
tree530e5312d9dea78cd2986de2885be7f1e3ddcdfd /drivers/gpu/drm/drm_internal.h
parent3c89f2d85c39506772c65f44b3013b111d23dafc (diff)
drm/gem: Inline drm_gem_pin() into PRIME helpers
Inline drm_gem_pin() into its only caller drm_gem_map_attach() and update the documentation in the callback's purpose. Do the equivalent for drm_gem_unpin(). Also add stricter error checking on the involved locking. The pin operation in the GEM object functions is a helper for PRIME-exported buffer objects. Having drm_gem_pin() gives the impression of a general-purpose interface, which is not the case. Removing it makes the pin callback a bit harder to misuse. v2: - clarify comment on pin callback (Dmitry) Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Dmitry Osipenko <dmitry.osipenko@collabora.com> Link: https://lore.kernel.org/r/20250526132634.531789-5-tzimmermann@suse.de
Diffstat (limited to 'drivers/gpu/drm/drm_internal.h')
-rw-r--r--drivers/gpu/drm/drm_internal.h4
1 files changed, 0 insertions, 4 deletions
diff --git a/drivers/gpu/drm/drm_internal.h b/drivers/gpu/drm/drm_internal.h
index e44f28fd81d3..442eb31351dd 100644
--- a/drivers/gpu/drm/drm_internal.h
+++ b/drivers/gpu/drm/drm_internal.h
@@ -175,10 +175,6 @@ void drm_gem_release(struct drm_device *dev, struct drm_file *file_private);
void drm_gem_print_info(struct drm_printer *p, unsigned int indent,
const struct drm_gem_object *obj);
-int drm_gem_pin_locked(struct drm_gem_object *obj);
-void drm_gem_unpin_locked(struct drm_gem_object *obj);
-int drm_gem_pin(struct drm_gem_object *obj);
-void drm_gem_unpin(struct drm_gem_object *obj);
int drm_gem_vmap_locked(struct drm_gem_object *obj, struct iosys_map *map);
void drm_gem_vunmap_locked(struct drm_gem_object *obj, struct iosys_map *map);