diff options
author | Alex Deucher <[email protected]> | 2013-06-07 14:07:10 -0400 |
---|---|---|
committer | Alex Deucher <[email protected]> | 2013-06-28 15:16:53 -0400 |
commit | 234d81e6b26457a94aae37633c1adc89498bdb4e (patch) | |
tree | 07982889f73a8044685a67cab4cfe8395de6fe69 /src/gallium/drivers/radeonsi | |
parent | 9d8ad222c69d70201d6b62eda454e08333e836ad (diff) |
radeonsi: emit PA_SC_RASTER_CONFIG[_1] on cik
Use the golden values for each asic.
Todo: update Kabini and Kaveri.
Signed-off-by: Alex Deucher <[email protected]>
Diffstat (limited to 'src/gallium/drivers/radeonsi')
-rw-r--r-- | src/gallium/drivers/radeonsi/si_state.c | 51 |
1 files changed, 34 insertions, 17 deletions
diff --git a/src/gallium/drivers/radeonsi/si_state.c b/src/gallium/drivers/radeonsi/si_state.c index 4ef73ec4b37..58e5a569399 100644 --- a/src/gallium/drivers/radeonsi/si_state.c +++ b/src/gallium/drivers/radeonsi/si_state.c @@ -2937,23 +2937,40 @@ void si_init_config(struct r600_context *rctx) si_pm4_set_reg(pm4, R_02882C_PA_SU_PRIM_FILTER_CNTL, 0); - switch (rctx->screen->family) { - case CHIP_TAHITI: - case CHIP_PITCAIRN: - si_pm4_set_reg(pm4, R_028350_PA_SC_RASTER_CONFIG, 0x2a00126a); - break; - case CHIP_VERDE: - si_pm4_set_reg(pm4, R_028350_PA_SC_RASTER_CONFIG, 0x0000124a); - break; - case CHIP_OLAND: - si_pm4_set_reg(pm4, R_028350_PA_SC_RASTER_CONFIG, 0x00000082); - break; - case CHIP_HAINAN: - si_pm4_set_reg(pm4, R_028350_PA_SC_RASTER_CONFIG, 0x00000000); - break; - default: - si_pm4_set_reg(pm4, R_028350_PA_SC_RASTER_CONFIG, 0x00000000); - break; + if (rctx->chip_class >= CIK) { + switch (rctx->screen->family) { + case CHIP_BONAIRE: + si_pm4_set_reg(pm4, R_028350_PA_SC_RASTER_CONFIG, 0x16000012); + si_pm4_set_reg(pm4, R_028354_PA_SC_RASTER_CONFIG_1, 0x00000000); + break; + case CHIP_KAVERI: + /* XXX todo */ + case CHIP_KABINI: + /* XXX todo */ + default: + si_pm4_set_reg(pm4, R_028350_PA_SC_RASTER_CONFIG, 0x00000000); + si_pm4_set_reg(pm4, R_028354_PA_SC_RASTER_CONFIG_1, 0x00000000); + break; + } + } else { + switch (rctx->screen->family) { + case CHIP_TAHITI: + case CHIP_PITCAIRN: + si_pm4_set_reg(pm4, R_028350_PA_SC_RASTER_CONFIG, 0x2a00126a); + break; + case CHIP_VERDE: + si_pm4_set_reg(pm4, R_028350_PA_SC_RASTER_CONFIG, 0x0000124a); + break; + case CHIP_OLAND: + si_pm4_set_reg(pm4, R_028350_PA_SC_RASTER_CONFIG, 0x00000082); + break; + case CHIP_HAINAN: + si_pm4_set_reg(pm4, R_028350_PA_SC_RASTER_CONFIG, 0x00000000); + break; + default: + si_pm4_set_reg(pm4, R_028350_PA_SC_RASTER_CONFIG, 0x00000000); + break; + } } si_pm4_set_state(rctx, init, pm4); |