aboutsummaryrefslogtreecommitdiffstats
path: root/common/recipes-kernel/linux/files/0729-drm-amd-dal-Make-use-of-amdgpu_crtc-cursor_addr.patch
diff options
context:
space:
mode:
Diffstat (limited to 'common/recipes-kernel/linux/files/0729-drm-amd-dal-Make-use-of-amdgpu_crtc-cursor_addr.patch')
-rw-r--r--common/recipes-kernel/linux/files/0729-drm-amd-dal-Make-use-of-amdgpu_crtc-cursor_addr.patch99
1 files changed, 0 insertions, 99 deletions
diff --git a/common/recipes-kernel/linux/files/0729-drm-amd-dal-Make-use-of-amdgpu_crtc-cursor_addr.patch b/common/recipes-kernel/linux/files/0729-drm-amd-dal-Make-use-of-amdgpu_crtc-cursor_addr.patch
deleted file mode 100644
index 8e88181a..00000000
--- a/common/recipes-kernel/linux/files/0729-drm-amd-dal-Make-use-of-amdgpu_crtc-cursor_addr.patch
+++ /dev/null
@@ -1,99 +0,0 @@
-From 299511579bbef4d7e67360cb382ac58f4d37a828 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Michel=20D=C3=A4nzer?= <michel.daenzer@amd.com>
-Date: Tue, 19 Jan 2016 16:37:18 +0900
-Subject: [PATCH 0729/1110] drm/amd/dal: Make use of amdgpu_crtc->cursor_addr
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
-Acked-by: Harry Wentland <harry.wentland@amd.com>
----
- .../gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_types.c | 22 ++++++++++++----------
- 1 file changed, 12 insertions(+), 10 deletions(-)
-
-diff --git a/drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_types.c b/drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_types.c
-index f2b25cd..c472530 100644
---- a/drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_types.c
-+++ b/drivers/gpu/drm/amd/dal/amdgpu_dm/amdgpu_dm_types.c
-@@ -139,8 +139,7 @@ static int dm_crtc_pin_cursor_bo_new(
- struct drm_crtc *crtc,
- struct drm_file *file_priv,
- uint32_t handle,
-- struct amdgpu_bo **ret_obj,
-- uint64_t *gpu_addr)
-+ struct amdgpu_bo **ret_obj)
- {
- struct amdgpu_crtc *amdgpu_crtc;
- struct amdgpu_bo *robj;
-@@ -148,6 +147,10 @@ static int dm_crtc_pin_cursor_bo_new(
- int ret = EINVAL;
-
- if (NULL != crtc) {
-+ struct drm_device *dev = crtc->dev;
-+ struct amdgpu_device *adev = dev->dev_private;
-+ uint64_t gpu_addr;
-+
- amdgpu_crtc = to_amdgpu_crtc(crtc);
-
- obj = drm_gem_object_lookup(crtc->dev, file_priv, handle);
-@@ -170,10 +173,12 @@ static int dm_crtc_pin_cursor_bo_new(
- goto release;
- }
-
-- ret = amdgpu_bo_pin(robj, AMDGPU_GEM_DOMAIN_VRAM, NULL);
-+ ret = amdgpu_bo_pin_restricted(robj, AMDGPU_GEM_DOMAIN_VRAM, 0,
-+ adev->mc.visible_vram_size,
-+ &gpu_addr);
-
- if (ret == 0) {
-- *gpu_addr = amdgpu_bo_gpu_offset(robj);
-+ amdgpu_crtc->cursor_addr = gpu_addr;
- *ret_obj = robj;
- }
- amdgpu_bo_unreserve(robj);
-@@ -194,7 +199,6 @@ static int dm_crtc_cursor_set(
- uint32_t height)
- {
- struct amdgpu_bo *new_cursor_bo;
-- uint64_t gpu_addr;
- struct dc_cursor_position position;
-
- int ret;
-@@ -203,7 +207,6 @@ static int dm_crtc_cursor_set(
-
- ret = EINVAL;
- new_cursor_bo = NULL;
-- gpu_addr = 0;
-
- DRM_DEBUG_KMS(
- "%s: crtc_id=%d with handle %d and size %d to %d, bo_object %p\n",
-@@ -243,14 +246,13 @@ static int dm_crtc_cursor_set(
- goto release;
- }
- /*try to pin new cursor bo*/
-- ret = dm_crtc_pin_cursor_bo_new(crtc, file_priv, handle,
-- &new_cursor_bo, &gpu_addr);
-+ ret = dm_crtc_pin_cursor_bo_new(crtc, file_priv, handle, &new_cursor_bo);
- /*if map not successful then return an error*/
- if (ret)
- goto release;
-
- /*program new cursor bo to hardware*/
-- dm_set_cursor(amdgpu_crtc, gpu_addr, width, height);
-+ dm_set_cursor(amdgpu_crtc, amdgpu_crtc->cursor_addr, width, height);
-
- /*un map old, not used anymore cursor bo ,
- * return memory and mapping back */
-@@ -336,7 +338,7 @@ static void dm_crtc_cursor_reset(struct drm_crtc *crtc)
- if (amdgpu_crtc->cursor_bo && amdgpu_crtc->target) {
- dm_set_cursor(
- amdgpu_crtc,
-- amdgpu_bo_gpu_offset(gem_to_amdgpu_bo(amdgpu_crtc->cursor_bo)),
-+ amdgpu_crtc->cursor_addr,
- amdgpu_crtc->cursor_width,
- amdgpu_crtc->cursor_height);
- }
---
-2.7.4
-