From a1378639ab19682a818ee627745db7f67485d406 Mon Sep 17 00:00:00 2001 From: Marek Olšák Date: Thu, 7 Feb 2019 00:01:13 -0500 Subject: radeonsi: always use compute rings for clover on CI and newer (v2) initialize all non-compute context functions to NULL. v2: fix SI --- src/gallium/drivers/radeonsi/si_blit.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'src/gallium/drivers/radeonsi/si_blit.c') diff --git a/src/gallium/drivers/radeonsi/si_blit.c b/src/gallium/drivers/radeonsi/si_blit.c index bb8d1cbd12d..f39cb5d143f 100644 --- a/src/gallium/drivers/radeonsi/si_blit.c +++ b/src/gallium/drivers/radeonsi/si_blit.c @@ -1352,7 +1352,10 @@ static void si_flush_resource(struct pipe_context *ctx, void si_decompress_dcc(struct si_context *sctx, struct si_texture *tex) { - if (!tex->dcc_offset) + /* If graphics is disabled, we can't decompress DCC, but it shouldn't + * be compressed either. The caller should simply discard it. + */ + if (!tex->dcc_offset || !sctx->has_graphics) return; si_blit_decompress_color(sctx, tex, 0, tex->buffer.b.b.last_level, @@ -1363,7 +1366,10 @@ void si_decompress_dcc(struct si_context *sctx, struct si_texture *tex) void si_init_blit_functions(struct si_context *sctx) { sctx->b.resource_copy_region = si_resource_copy_region; - sctx->b.blit = si_blit; - sctx->b.flush_resource = si_flush_resource; - sctx->b.generate_mipmap = si_generate_mipmap; + + if (sctx->has_graphics) { + sctx->b.blit = si_blit; + sctx->b.flush_resource = si_flush_resource; + sctx->b.generate_mipmap = si_generate_mipmap; + } } -- cgit v1.2.3