Module: Mesa
Branch: staging/22.2
Commit: 797a781ffe0889fc00deb2cfebb9dde846a9c437
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=797a781ffe0889fc00deb2cfebb9dde846a9c437

Author: Pierre-Eric Pelloux-Prayer <[email protected]>
Date:   Fri Jun 25 17:35:12 2021 +0200

amdgpu/bo: update uses_secure_bos when importing buffers

Fixes: 90b98c06493 ("amd/tmz: move uses_secure_bos to radeon_winsys")
Reviewed-by: Marek Olšák <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11449>
(cherry picked from commit a693fbf64b84ed6364984c45dc3255b71063c6dc)

---

 .pick_status.json                         | 2 +-
 src/gallium/winsys/amdgpu/drm/amdgpu_bo.c | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/.pick_status.json b/.pick_status.json
index 544bcf9bce8..39dbed95863 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -58,7 +58,7 @@
         "description": "amdgpu/bo: update uses_secure_bos when importing 
buffers",
         "nominated": true,
         "nomination_type": 1,
-        "resolution": 0,
+        "resolution": 1,
         "main_sha": null,
         "because_sha": "90b98c06493f8a9759e5496d5ec91fb60edf7b92"
     },
diff --git a/src/gallium/winsys/amdgpu/drm/amdgpu_bo.c 
b/src/gallium/winsys/amdgpu/drm/amdgpu_bo.c
index d9d3dac67d7..b8825ac53bc 100644
--- a/src/gallium/winsys/amdgpu/drm/amdgpu_bo.c
+++ b/src/gallium/winsys/amdgpu/drm/amdgpu_bo.c
@@ -1544,6 +1544,7 @@ static struct pb_buffer *amdgpu_bo_from_handle(struct 
radeon_winsys *rws,
        * if it can be used for scanout.
        */
       flags |= RADEON_FLAG_ENCRYPTED;
+      *((bool*)&rws->uses_secure_bos) = true;
    }
 
    /* Initialize the structure. */

Reply via email to