nv50: Fix m2mf positions.
authorMarcin Koƛcielnicki <koriakin@0x04.net>
Mon, 14 Sep 2009 09:56:55 +0000 (09:56 +0000)
committerChristoph Bumiller <e0425955@student.tuwien.ac.at>
Mon, 14 Sep 2009 10:12:03 +0000 (12:12 +0200)
src/gallium/drivers/nv50/nv50_transfer.c

index e9c3562194b353e820df65d1ccd2e2a52277be2e..bb7731855cd4b4af0732f9419dbcf2d19e75bd6d 100644 (file)
@@ -89,14 +89,14 @@ nv50_transfer_rect_m2mf(struct pipe_screen *pscreen,
                if (src_bo->tile_flags) {
                        BEGIN_RING(chan, m2mf,
                                NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_IN, 1);
-                       OUT_RING  (chan, (sy << 16) | sx);
+                       OUT_RING  (chan, (sy << 16) | (sx * cpp));
                } else {
                        src_offset += (line_count * src_pitch);
                }
                if (dst_bo->tile_flags) {
                        BEGIN_RING(chan, m2mf,
                                NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_OUT, 1);
-                       OUT_RING  (chan, (dy << 16) | dx);
+                       OUT_RING  (chan, (dy << 16) | (dx * cpp));
                } else {
                        dst_offset += (line_count * dst_pitch);
                }