aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPierre-Eric Pelloux-Prayer <[email protected]>2020-02-28 11:54:41 +0100
committerPierre-Eric Pelloux-Prayer <[email protected]>2020-05-11 10:25:53 +0200
commit92e64f4b41ed0ab0b9291d1de0b285733fd92307 (patch)
tree850ddeca21ee8a2eb37928661582178506629732
parent2c2ab36f5346a07b14ee85703316f323a77c2530 (diff)
amdgpu: use AMDGPU_IB_FLAGS_SECURE when requested
Reviewed-by: Marek Olšák <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4401>
-rw-r--r--src/gallium/winsys/amdgpu/drm/amdgpu_cs.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gallium/winsys/amdgpu/drm/amdgpu_cs.c b/src/gallium/winsys/amdgpu/drm/amdgpu_cs.c
index ea2e372ceb8..fa74aad394a 100644
--- a/src/gallium/winsys/amdgpu/drm/amdgpu_cs.c
+++ b/src/gallium/winsys/amdgpu/drm/amdgpu_cs.c
@@ -1594,6 +1594,11 @@ void amdgpu_cs_submit_ib(void *job, int thread_index)
chunks[num_chunks].chunk_data = (uintptr_t)&cs->ib[IB_MAIN];
num_chunks++;
+ if (ws->secure && cs->secure)
+ cs->ib[IB_MAIN].flags |= AMDGPU_IB_FLAGS_SECURE;
+ else
+ cs->ib[IB_MAIN].flags &= ~AMDGPU_IB_FLAGS_SECURE;
+
assert(num_chunks <= ARRAY_SIZE(chunks));
r = amdgpu_cs_submit_raw2(ws->dev, acs->ctx->ctx, bo_list,