rusticl/mem: can only map staging textures directly

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19213>
This commit is contained in:
Karol Herbst
2022-10-16 23:02:01 +02:00
committed by Marge Bot
parent 0a0c35dd24
commit 8be9171fcb
+2 -2
View File
@@ -527,8 +527,8 @@ impl Mem {
let r = self.get_res()?.get(&q.device).unwrap();
let ctx = q.device.helper_ctx();
// don't bother mapping directly if it's not UMA
let tx = if q.device.unified_memory() || bit_check(self.flags, CL_MEM_ALLOC_HOST_PTR) {
// don't bother mapping directly if it's not staging
let tx = if bit_check(self.flags, CL_MEM_ALLOC_HOST_PTR) {
ctx.texture_map_directly(r, bx, rw)
} else {
None