Mesa (master): radv: null bo list pointer for null descriptors on update
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Sat Feb 6 02:12:25 UTC 2021
Module: Mesa
Branch: master
Commit: 2f534c2e2ee97b89c43f155c0e2f9efe5a3dffac
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=2f534c2e2ee97b89c43f155c0e2f9efe5a3dffac
Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date: Tue Feb 2 19:59:12 2021 -0500
radv: null bo list pointer for null descriptors on update
failing to unset any existing pointers here leads to stale bo entries in
the list and then the kernel rejecting the cmdbuf with ENOENT
Fixes: 126d5adb11e ("radv: Use host memory pool for non-freeable descriptors.")
Reviewed-by: Bas Nieuwenhuizen <bas at basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8840>
---
src/amd/vulkan/radv_descriptor_set.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/src/amd/vulkan/radv_descriptor_set.c b/src/amd/vulkan/radv_descriptor_set.c
index 2053b7fc82e..9e8794ab299 100644
--- a/src/amd/vulkan/radv_descriptor_set.c
+++ b/src/amd/vulkan/radv_descriptor_set.c
@@ -965,6 +965,8 @@ static void write_texel_buffer_descriptor(struct radv_device *device,
if (!buffer_view) {
memset(dst, 0, 4 * 4);
+ if (!cmd_buffer)
+ *buffer_list = NULL;
return;
}
@@ -986,6 +988,8 @@ static void write_buffer_descriptor(struct radv_device *device,
if (!buffer) {
memset(dst, 0, 4 * 4);
+ if (!cmd_buffer)
+ *buffer_list = NULL;
return;
}
@@ -1050,6 +1054,7 @@ static void write_dynamic_buffer_descriptor(struct radv_device *device,
if (!buffer) {
range->va = 0;
+ *buffer_list = NULL;
return;
}
@@ -1085,6 +1090,8 @@ write_image_descriptor(struct radv_device *device,
if (!iview) {
memset(dst, 0, size);
+ if (!cmd_buffer)
+ *buffer_list = NULL;
return;
}
More information about the mesa-commit
mailing list