aboutsummaryrefslogtreecommitdiffstats
path: root/common/recipes-kernel/linux/files/1072-drm-amdgpu-hdp-flush-inval-should-always-do.patch
blob: 534c89817aad194220df8ff594d0fb9dc9d13cda (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
From 339c80958dc2ab9e6cfc3b1c4744500f4099be81 Mon Sep 17 00:00:00 2001
From: Monk Liu <Monk.Liu@amd.com>
Date: Wed, 4 May 2016 16:27:41 +0800
Subject: [PATCH 1072/1110] drm/amdgpu:hdp flush&inval should always do
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

This fixes Tonga vm-fault issue when running disaster
(a multiple context GL heavy tests),
We should always flush & invalidate hdp no matter vm
used or not.

Change-Id: Idc18cf413bfe21ec02d92c92598693c27060502a
Signed-off-by: Monk Liu <Monk.Liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Chunming Zhou <David1.Zhou@amd.com>
Signed-off-by: Kalyan Alle <kalyan.alle@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c
index f879ffb..21f717a 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c
@@ -175,10 +175,9 @@ int amdgpu_ib_schedule(struct amdgpu_ring *ring, unsigned num_ibs,
                 amdgpu_ring_emit_ib(ring, ib, (i == 0 && old != fence_context));
 	}
 
-	if (vm) {
-		if (ring->funcs->emit_hdp_invalidate)
-			amdgpu_ring_emit_hdp_invalidate(ring);
-	}
+        if (ring->funcs->emit_hdp_invalidate)
+                amdgpu_ring_emit_hdp_invalidate(ring);
+
         ring->last_fence_context = fence_context;
 
 	r = amdgpu_fence_emit(ring, &hwf);
-- 
2.7.4