Re: [PATCH] drm/radeon/kms: r600 CS parser fixes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Alex Deucher wrote:

Does reverting this part of the patch fix it?

@@ -1055,10 +1055,10 @@ static void r600_texture_size(unsigned nfaces,
unsigned blevel, unsigned nlevels
        }
        *l0_size = ALIGN((w0 * bpe), pitch_align) * h0 * d0;
        *mipmap_size = offset;
-       if (!blevel)
-               *mipmap_size -= *l0_size;
        if (!nlevels)
                *mipmap_size = *l0_size;
+       if (!blevel)
+               *mipmap_size -= *l0_size;
  }

No, it does make the nunbers bigger, though -

radeon 0000:01:00.0: mipmap bo too small (512 512 4 0 0 1048576 -> 1048576 have 1409024)

Just as a double check this is my diff against current d-r-t for this test.

diff --git a/drivers/gpu/drm/radeon/r600_cs.c b/drivers/gpu/drm/radeon/r600_cs.c
index d886494..f6580ca 100644
--- a/drivers/gpu/drm/radeon/r600_cs.c
+++ b/drivers/gpu/drm/radeon/r600_cs.c
@@ -1051,10 +1051,10 @@ static void r600_texture_size(unsigned nfaces, unsigned blevel, unsigned nlevels
        }
        *l0_size = ALIGN((w0 * bpe), pitch_align) * h0 * d0;
        *mipmap_size = offset;
-       if (!nlevels)
-               *mipmap_size = *l0_size;
        if (!blevel)
                *mipmap_size -= *l0_size;
+       if (!nlevels)
+               *mipmap_size = *l0_size;
 }

 /**


_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/dri-devel


[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux