Home Home > GIT Browse
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichal Kubecek <mkubecek@suse.cz>2019-10-02 07:33:57 +0200
committerMichal Kubecek <mkubecek@suse.cz>2019-10-02 07:33:57 +0200
commit662604bb5e7fecdc5af9897998abffa23d7a7aa9 (patch)
tree8dd0cbb5d71bcd0561d6a1034dc1779797003bd1
parentbaa15cafd0d2ef875fe8be1d11b14ff039a8e6b2 (diff)
parenta57ad9e08234a320901349c0b487cd9b60aa822a (diff)
Merge branch 'users/tzimmermann/SLE15-SP2/for-next' into SLE15-SP2
Pull DRM fixes from Thomas Zimmermann. suse-commit: 035ce9b6a8a7d73a71cbd228c0e3911fc461c704
-rw-r--r--drivers/gpu/drm/mgag200/mgag200_cursor.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/gpu/drm/mgag200/mgag200_cursor.c b/drivers/gpu/drm/mgag200/mgag200_cursor.c
index f0c61a92351c..29ef932b9fb6 100644
--- a/drivers/gpu/drm/mgag200/mgag200_cursor.c
+++ b/drivers/gpu/drm/mgag200/mgag200_cursor.c
@@ -98,11 +98,12 @@ int mga_crtc_cursor_set(struct drm_crtc *crtc,
}
/* Pin and map up-coming buffer to write colour indices */
- ret = drm_gem_vram_pin(pixels_next, 0);
- if (ret)
+ ret = drm_gem_vram_pin(pixels_next, DRM_GEM_VRAM_PL_FLAG_VRAM);
+ if (ret) {
dev_err(&dev->pdev->dev,
"failed to pin cursor buffer: %d\n", ret);
goto err_drm_gem_vram_kunmap_src;
+ }
dst = drm_gem_vram_kmap(pixels_next, true, NULL);
if (IS_ERR(dst)) {
ret = PTR_ERR(dst);
@@ -110,7 +111,7 @@ int mga_crtc_cursor_set(struct drm_crtc *crtc,
"failed to kmap cursor updates: %d\n", ret);
goto err_drm_gem_vram_unpin_dst;
}
- gpu_addr = drm_gem_vram_offset(pixels_2);
+ gpu_addr = drm_gem_vram_offset(pixels_next);
if (gpu_addr < 0) {
ret = (int)gpu_addr;
dev_err(&dev->pdev->dev,
@@ -211,7 +212,6 @@ int mga_crtc_cursor_set(struct drm_crtc *crtc,
mdev->cursor.pixels_current = pixels_next;
drm_gem_vram_kunmap(pixels_next);
- drm_gem_vram_unpin(pixels_next);
drm_gem_vram_kunmap(gbo);
drm_gem_vram_unpin(gbo);
drm_gem_object_put_unlocked(obj);