From 449ac258d1b1d14fbb003b0140d4e4692777b05e Mon Sep 17 00:00:00 2001 From: =?utf8?q?Nicolai=20H=C3=A4hnle?= Date: Tue, 26 Sep 2017 17:24:19 +0200 Subject: [PATCH] radeonsi: remove si_apply_scissor_bug_workaround MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit It only affects pre-SI chips. Reviewed-by: Marek Olšák --- src/gallium/drivers/radeon/r600_pipe_common.h | 2 -- .../drivers/radeonsi/si_state_viewport.c | 17 ----------------- 2 files changed, 19 deletions(-) diff --git a/src/gallium/drivers/radeon/r600_pipe_common.h b/src/gallium/drivers/radeon/r600_pipe_common.h index f6ded92dc5b..4508a768768 100644 --- a/src/gallium/drivers/radeon/r600_pipe_common.h +++ b/src/gallium/drivers/radeon/r600_pipe_common.h @@ -880,8 +880,6 @@ void si_init_screen_texture_functions(struct r600_common_screen *rscreen); void si_init_context_texture_functions(struct r600_common_context *rctx); /* r600_viewport.c */ -void si_apply_scissor_bug_workaround(struct r600_common_context *rctx, - struct pipe_scissor_state *scissor); void si_viewport_set_rast_deps(struct r600_common_context *rctx, bool scissor_enable, bool clip_halfz); void si_update_vs_writes_viewport_index(struct r600_common_context *rctx, diff --git a/src/gallium/drivers/radeonsi/si_state_viewport.c b/src/gallium/drivers/radeonsi/si_state_viewport.c index 00fa4c0d026..54f31c4694d 100644 --- a/src/gallium/drivers/radeonsi/si_state_viewport.c +++ b/src/gallium/drivers/radeonsi/si_state_viewport.c @@ -115,21 +115,6 @@ static void r600_scissor_make_union(struct r600_signed_scissor *out, out->maxy = MAX2(out->maxy, in->maxy); } -void si_apply_scissor_bug_workaround(struct r600_common_context *rctx, - struct pipe_scissor_state *scissor) -{ - if (rctx->chip_class == EVERGREEN || rctx->chip_class == CAYMAN) { - if (scissor->maxx == 0) - scissor->minx = 1; - if (scissor->maxy == 0) - scissor->miny = 1; - - if (rctx->chip_class == CAYMAN && - scissor->maxx == 1 && scissor->maxy == 1) - scissor->maxx = 2; - } -} - static void r600_emit_one_scissor(struct r600_common_context *rctx, struct radeon_winsys_cs *cs, struct r600_signed_scissor *vp_scissor, @@ -147,8 +132,6 @@ static void r600_emit_one_scissor(struct r600_common_context *rctx, if (scissor) r600_clip_scissor(&final, scissor); - si_apply_scissor_bug_workaround(rctx, &final); - radeon_emit(cs, S_028250_TL_X(final.minx) | S_028250_TL_Y(final.miny) | S_028250_WINDOW_OFFSET_DISABLE(1)); -- 2.30.2