summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2013-10-08 14:23:22 +0200
committerMarek Olšák <[email protected]>2013-10-09 11:44:48 +0200
commit6b7c039dc2272bcba298c7c18bd7e278820b66f5 (patch)
tree6b1d713da56968434253313dcbbd8bd78e05a2ba /src/gallium/drivers
parentec922ef98797c0dcd33b5f88a3a6eafff79a0831 (diff)
radeonsi: fix occlusion queries for CIK
Reviewed-by: Michel Dänzer <[email protected]>
Diffstat (limited to 'src/gallium/drivers')
-rw-r--r--src/gallium/drivers/radeonsi/si_state_draw.c15
1 files changed, 12 insertions, 3 deletions
diff --git a/src/gallium/drivers/radeonsi/si_state_draw.c b/src/gallium/drivers/radeonsi/si_state_draw.c
index 626ba9533f4..d20658ebafd 100644
--- a/src/gallium/drivers/radeonsi/si_state_draw.c
+++ b/src/gallium/drivers/radeonsi/si_state_draw.c
@@ -570,9 +570,18 @@ static void si_state_draw(struct r600_context *rctx,
if (rctx->num_cs_dw_nontimer_queries_suspend) {
struct si_state_dsa *dsa = rctx->queued.named.dsa;
- si_pm4_set_reg(pm4, R_028004_DB_COUNT_CONTROL,
- S_028004_PERFECT_ZPASS_COUNTS(1) |
- S_028004_SAMPLE_RATE(rctx->fb_log_samples));
+ if (rctx->b.chip_class >= CIK) {
+ si_pm4_set_reg(pm4, R_028004_DB_COUNT_CONTROL,
+ S_028004_PERFECT_ZPASS_COUNTS(1) |
+ S_028004_SAMPLE_RATE(rctx->fb_log_samples) |
+ S_028004_ZPASS_ENABLE(1) |
+ S_028004_SLICE_EVEN_ENABLE(1) |
+ S_028004_SLICE_ODD_ENABLE(1));
+ } else {
+ si_pm4_set_reg(pm4, R_028004_DB_COUNT_CONTROL,
+ S_028004_PERFECT_ZPASS_COUNTS(1) |
+ S_028004_SAMPLE_RATE(rctx->fb_log_samples));
+ }
si_pm4_set_reg(pm4, R_02800C_DB_RENDER_OVERRIDE,
dsa->db_render_override |
S_02800C_NOOP_CULL_DISABLE(1));