drm/nv50/gr: fix overlap while zeroing zcull regions
authorPierre Moreau <pierre.morrow@free.fr>
Fri, 13 Jun 2014 00:34:29 +0000 (02:34 +0200)
committerBen Skeggs <bskeggs@redhat.com>
Tue, 17 Jun 2014 04:41:40 +0000 (14:41 +1000)
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>
drivers/gpu/drm/nouveau/core/engine/graph/nv50.c

index 1a2d56493cf6a5ce00612430d6b7aa5429c7bdf1..5f34bd0df02f7c62de725e2a759e35cd0c412bdd 100644 (file)
@@ -991,10 +991,10 @@ nv50_graph_init(struct nouveau_object *object)
 
        /* zero out zcull regions */
        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;
 }