aboutsummaryrefslogtreecommitdiffstats
path: root/meta-amdfalconx86/recipes-kernel/linux/linux-yocto/0904-drm-amdgpu-set-snooped-flags-only-on-system-addresse.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta-amdfalconx86/recipes-kernel/linux/linux-yocto/0904-drm-amdgpu-set-snooped-flags-only-on-system-addresse.patch')
-rw-r--r--meta-amdfalconx86/recipes-kernel/linux/linux-yocto/0904-drm-amdgpu-set-snooped-flags-only-on-system-addresse.patch42
1 files changed, 42 insertions, 0 deletions
diff --git a/meta-amdfalconx86/recipes-kernel/linux/linux-yocto/0904-drm-amdgpu-set-snooped-flags-only-on-system-addresse.patch b/meta-amdfalconx86/recipes-kernel/linux/linux-yocto/0904-drm-amdgpu-set-snooped-flags-only-on-system-addresse.patch
new file mode 100644
index 00000000..18de313e
--- /dev/null
+++ b/meta-amdfalconx86/recipes-kernel/linux/linux-yocto/0904-drm-amdgpu-set-snooped-flags-only-on-system-addresse.patch
@@ -0,0 +1,42 @@
+From a874c86d5635addeb049911c544f775d8fd981ca Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Christian=20K=C3=B6nig?= <christian.koenig@amd.com>
+Date: Fri, 4 Dec 2015 13:32:55 +0100
+Subject: [PATCH 0904/1050] drm/amdgpu: set snooped flags only on system
+ addresses v2
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Not necessary for VRAM.
+
+v2: no need to check if ttm is NULL.
+
+Signed-off-by: Christian König <christian.koenig@amd.com>
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+---
+ drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 7 ++++---
+ 1 file changed, 4 insertions(+), 3 deletions(-)
+
+diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
+index 8051cb9..8a1752f 100644
+--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
++++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
+@@ -801,11 +801,12 @@ uint32_t amdgpu_ttm_tt_pte_flags(struct amdgpu_device *adev, struct ttm_tt *ttm,
+ if (mem && mem->mem_type != TTM_PL_SYSTEM)
+ flags |= AMDGPU_PTE_VALID;
+
+- if (mem && mem->mem_type == TTM_PL_TT)
++ if (mem && mem->mem_type == TTM_PL_TT) {
+ flags |= AMDGPU_PTE_SYSTEM;
+
+- if (!ttm || ttm->caching_state == tt_cached)
+- flags |= AMDGPU_PTE_SNOOPED;
++ if (ttm->caching_state == tt_cached)
++ flags |= AMDGPU_PTE_SNOOPED;
++ }
+
+ if (adev->asic_type >= CHIP_TOPAZ)
+ flags |= AMDGPU_PTE_EXECUTABLE;
+--
+1.9.1
+