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: 126d5adb11 ("radv: Use host memory pool for non-freeable descriptors.")

Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8840>
This commit is contained in:
Mike Blumenkrantz 2021-02-02 19:59:12 -05:00
parent 021bc4f868
commit 2f534c2e2e

View file

@ -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;
}