radeonsi: silence Coverity warning

Coverity's analysis is too weak to understand that
r600_init_flushed_depth(_, _, NULL) only returns true when
flushed_depth_texture was assigned a non-NULL value.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
This commit is contained in:
Nicolai Hähnle 2016-07-10 16:13:28 +02:00
parent a2bd7334ed
commit 65d48fcf8c
2 changed files with 4 additions and 0 deletions

View File

@ -342,6 +342,8 @@ si_flush_depth_texture(struct si_context *sctx,
unsigned fully_copied_levels;
unsigned levels = 0;
assert(tex->flushed_depth_texture);
if (util_format_is_depth_and_stencil(dst->resource.b.b.format))
copy_planes = PIPE_MASK_Z | PIPE_MASK_S;

View File

@ -3001,6 +3001,8 @@ si_create_sampler_view_custom(struct pipe_context *ctx,
return NULL;
}
assert(tmp->flushed_depth_texture);
/* Override format for the case where the flushed texture
* contains only Z or only S.
*/