radeonsi: initialize scissor registers etc. without clear state
authorMarek Olšák <marek.olsak@amd.com>
Wed, 17 Jul 2019 03:17:38 +0000 (23:17 -0400)
committerMarek Olšák <marek.olsak@amd.com>
Sat, 20 Jul 2019 00:16:56 +0000 (20:16 -0400)
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Acked-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
src/gallium/drivers/radeonsi/si_state.c

index 1de54885ce7bdd9c6b1a99a7627c9aac9d38dc05..398dc83a924e688ed74d038da84dd7ad83595894 100644 (file)
@@ -5455,7 +5455,7 @@ static void si_init_config(struct si_context *sctx)
        /* CLEAR_STATE doesn't clear these correctly on certain generations.
         * I don't know why. Deduced by trial and error.
         */
-       if (sctx->chip_class <= GFX7) {
+       if (sctx->chip_class <= GFX7 || !has_clear_state) {
                si_pm4_set_reg(pm4, R_028B28_VGT_STRMOUT_DRAW_OPAQUE_OFFSET, 0);
                si_pm4_set_reg(pm4, R_028204_PA_SC_WINDOW_SCISSOR_TL, S_028204_WINDOW_OFFSET_DISABLE(1));
                si_pm4_set_reg(pm4, R_028240_PA_SC_GENERIC_SCISSOR_TL, S_028240_WINDOW_OFFSET_DISABLE(1));