summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/ast
diff options
context:
space:
mode:
authorThomas Zimmermann <tzimmermann@suse.de>2020-12-09 15:25:20 +0100
committerThomas Zimmermann <tzimmermann@suse.de>2020-12-11 12:35:25 +0100
commitabe54e54ddef85006d58495e6f2311ce82b4f015 (patch)
treea427b41128b9192cdb34cef7b0a9d35a56750109 /drivers/gpu/drm/ast
parentc365d304d69ab2a38e1431323d17a216b7930e32 (diff)
downloadlinux-abe54e54ddef85006d58495e6f2311ce82b4f015.tar.bz2
drm/ast: Don't pin cursor source BO explicitly during update
Vmapping the cursor source BO contains an implicit pin operation, so there's no need to do this manually. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: https://patchwork.freedesktop.org/patch/msgid/20201209142527.26415-2-tzimmermann@suse.de
Diffstat (limited to 'drivers/gpu/drm/ast')
-rw-r--r--drivers/gpu/drm/ast/ast_cursor.c10
1 files changed, 1 insertions, 9 deletions
diff --git a/drivers/gpu/drm/ast/ast_cursor.c b/drivers/gpu/drm/ast/ast_cursor.c
index 742d43a7edf4..68bf3d33f1ed 100644
--- a/drivers/gpu/drm/ast/ast_cursor.c
+++ b/drivers/gpu/drm/ast/ast_cursor.c
@@ -180,12 +180,9 @@ int ast_cursor_blit(struct ast_private *ast, struct drm_framebuffer *fb)
gbo = drm_gem_vram_of_gem(fb->obj[0]);
- ret = drm_gem_vram_pin(gbo, 0);
- if (ret)
- return ret;
ret = drm_gem_vram_vmap(gbo, &map);
if (ret)
- goto err_drm_gem_vram_unpin;
+ return ret;
src = map.vaddr; /* TODO: Use mapping abstraction properly */
dst = ast->cursor.map[ast->cursor.next_index].vaddr_iomem;
@@ -194,13 +191,8 @@ int ast_cursor_blit(struct ast_private *ast, struct drm_framebuffer *fb)
update_cursor_image(dst, src, fb->width, fb->height);
drm_gem_vram_vunmap(gbo, &map);
- drm_gem_vram_unpin(gbo);
return 0;
-
-err_drm_gem_vram_unpin:
- drm_gem_vram_unpin(gbo);
- return ret;
}
static void ast_cursor_set_base(struct ast_private *ast, u64 address)