summaryrefslogtreecommitdiffstats
path: root/src/amd/vulkan/radv_meta.c
diff options
context:
space:
mode:
authorSamuel Pitoiset <[email protected]>2018-07-10 16:13:40 +0200
committerSamuel Pitoiset <[email protected]>2018-07-12 11:08:45 +0200
commit6bfbc7b38b581e1a634b07bb5f3b3870c0a57317 (patch)
treea4b2b264aa9681c3f7042907ef1a2e7992bc54f3 /src/amd/vulkan/radv_meta.c
parent5b32926f7effda7990d9c9804e09149f414101e2 (diff)
radv/meta: do not restore a NULL descriptor
Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
Diffstat (limited to 'src/amd/vulkan/radv_meta.c')
-rw-r--r--src/amd/vulkan/radv_meta.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/amd/vulkan/radv_meta.c b/src/amd/vulkan/radv_meta.c
index 00a20d155e7..a59f38fb21d 100644
--- a/src/amd/vulkan/radv_meta.c
+++ b/src/amd/vulkan/radv_meta.c
@@ -80,10 +80,9 @@ radv_meta_save(struct radv_meta_saved_state *state,
}
if (state->flags & RADV_META_SAVE_DESCRIPTORS) {
- if (descriptors_state->valid & (1 << 0))
- state->old_descriptor_set0 = descriptors_state->sets[0];
- else
- state->old_descriptor_set0 = NULL;
+ state->old_descriptor_set0 = descriptors_state->sets[0];
+ if (!state->old_descriptor_set0)
+ state->flags &= ~RADV_META_SAVE_DESCRIPTORS;
}
if (state->flags & RADV_META_SAVE_CONSTANTS) {