just do what the comment says
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
}
if (!(usage & PIPE_HANDLE_USAGE_EXPLICIT_FLUSH) &&
- rtex->cmask.size) {
+ (rtex->cmask.size || rtex->dcc_offset)) {
/* Eliminate fast clear (both CMASK and DCC) */
r600_eliminate_fast_color_clear(rctx, rtex);
/* Disable CMASK if flush_resource isn't going
* to be called.
*/
- r600_texture_discard_cmask(rscreen, rtex);
+ if (rtex->cmask.size)
+ r600_texture_discard_cmask(rscreen, rtex);
}
/* Set metadata. */