From 693435d846b1208bb962eaf830f10649e56af2bc Mon Sep 17 00:00:00 2001 From: =?utf8?q?Nicolai=20H=C3=A4hnle?= Date: Mon, 31 Oct 2016 21:07:53 +0100 Subject: [PATCH] radeonsi: si_vgt_gs_mode only depends on the selector MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Reviewed-by: Marek Olšák --- src/gallium/drivers/radeonsi/si_state_shaders.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/gallium/drivers/radeonsi/si_state_shaders.c b/src/gallium/drivers/radeonsi/si_state_shaders.c index 9976085cd01..69711587c15 100644 --- a/src/gallium/drivers/radeonsi/si_state_shaders.c +++ b/src/gallium/drivers/radeonsi/si_state_shaders.c @@ -444,9 +444,9 @@ static void si_shader_es(struct si_screen *sscreen, struct si_shader *shader) * Calculate the appropriate setting of VGT_GS_MODE when \p shader is a * geometry shader. */ -static uint32_t si_vgt_gs_mode(struct si_shader *shader) +static uint32_t si_vgt_gs_mode(struct si_shader_selector *sel) { - unsigned gs_max_vert_out = shader->selector->gs_max_out_vertices; + unsigned gs_max_vert_out = sel->gs_max_out_vertices; unsigned cut_mode; if (gs_max_vert_out <= 128) { @@ -482,7 +482,7 @@ static void si_shader_gs(struct si_shader *shader) if (!pm4) return; - si_pm4_set_reg(pm4, R_028A40_VGT_GS_MODE, si_vgt_gs_mode(shader)); + si_pm4_set_reg(pm4, R_028A40_VGT_GS_MODE, si_vgt_gs_mode(shader->selector)); si_pm4_set_reg(pm4, R_028A60_VGT_GSVS_RING_OFFSET_1, gsvs_itemsize); si_pm4_set_reg(pm4, R_028A64_VGT_GSVS_RING_OFFSET_2, gsvs_itemsize * ((max_stream >= 2) ? 2 : 1)); -- 2.30.2