From 82ff2fb5d184e95c7877c58359cef4f5d43df9c1 Mon Sep 17 00:00:00 2001 From: Thomas Zimmermann Date: Thu, 16 May 2019 18:27:45 +0200 Subject: drm: Add drm_gem_vram_{pin/unpin}_reserved() and convert mgag200 The new interfaces drm_gem_vram_{pin/unpin}_reserved() are variants of the GEM VRAM pin/unpin functions that do not reserve the BO during validation. The mgag200 driver requires this behavior for its cursor handling. The patch also converts the driver to use the new interfaces. Signed-off-by: Thomas Zimmermann Link: http://patchwork.freedesktop.org/patch/msgid/20190516162746.11636-2-tzimmermann@suse.de Signed-off-by: Gerd Hoffmann --- include/drm/drm_gem_vram_helper.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include/drm') diff --git a/include/drm/drm_gem_vram_helper.h b/include/drm/drm_gem_vram_helper.h index b056f189ba62..ff1a81761543 100644 --- a/include/drm/drm_gem_vram_helper.h +++ b/include/drm/drm_gem_vram_helper.h @@ -82,7 +82,10 @@ void drm_gem_vram_unreserve(struct drm_gem_vram_object *gbo); u64 drm_gem_vram_mmap_offset(struct drm_gem_vram_object *gbo); s64 drm_gem_vram_offset(struct drm_gem_vram_object *gbo); int drm_gem_vram_pin(struct drm_gem_vram_object *gbo, unsigned long pl_flag); +int drm_gem_vram_pin_reserved(struct drm_gem_vram_object *gbo, + unsigned long pl_flag); int drm_gem_vram_unpin(struct drm_gem_vram_object *gbo); +int drm_gem_vram_unpin_reserved(struct drm_gem_vram_object *gbo); int drm_gem_vram_push_to_system(struct drm_gem_vram_object *gbo); void *drm_gem_vram_kmap_at(struct drm_gem_vram_object *gbo, bool map, bool *is_iomem, struct ttm_bo_kmap_obj *kmap); -- cgit v1.2.3