Module: Mesa
Branch: master
Commit: c65bc2e805a1fbcb72b9b77e0d9557ebce3a379a
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=c65bc2e805a1fbcb72b9b77e0d9557ebce3a379a

Author: Ilia Mirkin <[email protected]>
Date:   Sat Nov 21 10:28:45 2015 -0500

freedreno/a4xx: support 16384 texels in buffer texture

Looks like the width field's bitmask was off-by-one.

Signed-off-by: Ilia Mirkin <[email protected]>

---

 src/gallium/drivers/freedreno/a4xx/a4xx.xml.h    |    2 +-
 src/gallium/drivers/freedreno/freedreno_screen.c |    7 +++----
 2 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/src/gallium/drivers/freedreno/a4xx/a4xx.xml.h 
b/src/gallium/drivers/freedreno/a4xx/a4xx.xml.h
index df59438..5a53230 100644
--- a/src/gallium/drivers/freedreno/a4xx/a4xx.xml.h
+++ b/src/gallium/drivers/freedreno/a4xx/a4xx.xml.h
@@ -2864,7 +2864,7 @@ static inline uint32_t A4XX_TEX_CONST_1_HEIGHT(uint32_t 
val)
 {
        return ((val) << A4XX_TEX_CONST_1_HEIGHT__SHIFT) & 
A4XX_TEX_CONST_1_HEIGHT__MASK;
 }
-#define A4XX_TEX_CONST_1_WIDTH__MASK                           0x1fff8000
+#define A4XX_TEX_CONST_1_WIDTH__MASK                           0x3fff8000
 #define A4XX_TEX_CONST_1_WIDTH__SHIFT                          15
 static inline uint32_t A4XX_TEX_CONST_1_WIDTH(uint32_t val)
 {
diff --git a/src/gallium/drivers/freedreno/freedreno_screen.c 
b/src/gallium/drivers/freedreno/freedreno_screen.c
index 0c494d4..9e51c4e 100644
--- a/src/gallium/drivers/freedreno/freedreno_screen.c
+++ b/src/gallium/drivers/freedreno/freedreno_screen.c
@@ -187,12 +187,11 @@ fd_screen_get_param(struct pipe_screen *pscreen, enum 
pipe_cap param)
                if (is_a4xx(screen)) return 32;
                return 0;
        case PIPE_CAP_MAX_TEXTURE_BUFFER_SIZE:
-               /* I think 32k on a4xx.. and we could possibly emulate more
-                * by pretending 2d/rect textures and splitting high bits
-                * of index into 2nd dimension..
+               /* We could possibly emulate more by pretending 2d/rect 
textures and
+                * splitting high bits of index into 2nd dimension..
                 */
                if (is_a3xx(screen)) return 8192;
-               if (is_a4xx(screen)) return 16383;
+               if (is_a4xx(screen)) return 16384;
                return 0;
 
        case PIPE_CAP_TEXTURE_FLOAT_LINEAR:

_______________________________________________
mesa-commit mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to