Browse Source

drm/nv50/gr: fix overlap while zeroing zcull regions

The specified stride was not correct, resulting in erases overlapping
and part of the zcull regions being not erased at all.

Signed-off-by: Pierre Moreau <pierre.morrow@free.fr>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Pierre Moreau 11 years ago
parent
commit
c03d082488
1 changed files with 4 additions and 4 deletions
  1. 4 4
      drivers/gpu/drm/nouveau/core/engine/graph/nv50.c

+ 4 - 4
drivers/gpu/drm/nouveau/core/engine/graph/nv50.c

@@ -991,10 +991,10 @@ nv50_graph_init(struct nouveau_object *object)
 
 
 	/* zero out zcull regions */
 	/* zero out zcull regions */
 	for (i = 0; i < 8; i++) {
 	for (i = 0; i < 8; i++) {
-		nv_wr32(priv, 0x402c20 + (i * 8), 0x00000000);
-		nv_wr32(priv, 0x402c24 + (i * 8), 0x00000000);
-		nv_wr32(priv, 0x402c28 + (i * 8), 0x00000000);
-		nv_wr32(priv, 0x402c2c + (i * 8), 0x00000000);
+		nv_wr32(priv, 0x402c20 + (i * 0x10), 0x00000000);
+		nv_wr32(priv, 0x402c24 + (i * 0x10), 0x00000000);
+		nv_wr32(priv, 0x402c28 + (i * 0x10), 0x00000000);
+		nv_wr32(priv, 0x402c2c + (i * 0x10), 0x00000000);
 	}
 	}
 	return 0;
 	return 0;
 }
 }