diff options
author | Marek Olšák <[email protected]> | 2016-11-03 19:16:51 +0100 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2016-11-04 11:30:47 +0100 |
commit | 00baaa4752ab7e721218a2840cf0952d8c7c6eca (patch) | |
tree | 06b419b93f804dcd7ebc956a0fb831fd151c240b /src/gallium/drivers/radeonsi/si_blit.c | |
parent | 64c2593a5c33a98d880d141793360b44d07d1366 (diff) |
radeonsi: fix an assertion failure in si_decompress_sampler_color_textures
This fixes a crash in Deus Ex: Mankind Divided. Release builds were
unaffected, so it's not too serious.
Cc: 11.2 12.0 13.0 <[email protected]>
Reviewed-by: Bas Nieuwenhuizen <[email protected]>
Reviewed-by: Nicolai Hähnle <[email protected]>
Diffstat (limited to 'src/gallium/drivers/radeonsi/si_blit.c')
-rw-r--r-- | src/gallium/drivers/radeonsi/si_blit.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gallium/drivers/radeonsi/si_blit.c b/src/gallium/drivers/radeonsi/si_blit.c index e086ed87fbe..075d76a2730 100644 --- a/src/gallium/drivers/radeonsi/si_blit.c +++ b/src/gallium/drivers/radeonsi/si_blit.c @@ -486,7 +486,9 @@ si_decompress_sampler_color_textures(struct si_context *sctx, assert(view); tex = (struct r600_texture *)view->texture; - assert(tex->cmask.size || tex->fmask.size || tex->dcc_offset); + /* CMASK or DCC can be discarded and we can still end up here. */ + if (!tex->cmask.size && !tex->fmask.size && !tex->dcc_offset) + continue; si_blit_decompress_color(&sctx->b.b, tex, view->u.tex.first_level, view->u.tex.last_level, |