summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJakob Bornecrantz <[email protected]>2008-11-16 12:33:58 +0100
committerJakob Bornecrantz <[email protected]>2008-11-16 13:15:14 +0100
commit96ad8a36003a21180ad6b61aa0b7d7c9452b3449 (patch)
tree1ae7620c6a2b140529529dd8da3ea9eb95b287a4 /src
parent7468765b18be202a64d58b83f6267b6973ea4897 (diff)
i915: Silence warnings
Diffstat (limited to 'src')
-rw-r--r--src/gallium/drivers/i915simple/i915_debug.c5
-rw-r--r--src/gallium/drivers/i915simple/i915_fpc_translate.c2
-rw-r--r--src/gallium/drivers/i915simple/i915_texture.c5
3 files changed, 8 insertions, 4 deletions
diff --git a/src/gallium/drivers/i915simple/i915_debug.c b/src/gallium/drivers/i915simple/i915_debug.c
index 5e26d1b9057..7a4e7051d20 100644
--- a/src/gallium/drivers/i915simple/i915_debug.c
+++ b/src/gallium/drivers/i915simple/i915_debug.c
@@ -210,6 +210,7 @@ BITS(
PRINTF(stream, ": 0x%x\n", ((dw) & himask) >> (lo));
}
+#ifdef DEBUG
#define MBZ( dw, hi, lo) do { \
unsigned x = (dw) >> (lo); \
unsigned lomask = (1 << (lo)) - 1; \
@@ -217,6 +218,10 @@ BITS(
himask = (1UL << (hi)) - 1; \
assert ((x & himask & ~lomask) == 0); \
} while (0)
+#else
+#define MBZ( dw, hi, lo) do { \
+} while (0)
+#endif
static void
FLAG(
diff --git a/src/gallium/drivers/i915simple/i915_fpc_translate.c b/src/gallium/drivers/i915simple/i915_fpc_translate.c
index 34b4a846c11..43d62c51765 100644
--- a/src/gallium/drivers/i915simple/i915_fpc_translate.c
+++ b/src/gallium/drivers/i915simple/i915_fpc_translate.c
@@ -144,7 +144,7 @@ src_vector(struct i915_fp_compile *p,
const struct tgsi_full_src_register *source)
{
uint index = source->SrcRegister.Index;
- uint src, sem_name, sem_ind;
+ uint src = 0, sem_name, sem_ind;
switch (source->SrcRegister.File) {
case TGSI_FILE_TEMPORARY:
diff --git a/src/gallium/drivers/i915simple/i915_texture.c b/src/gallium/drivers/i915simple/i915_texture.c
index bd87217063c..c65c0642319 100644
--- a/src/gallium/drivers/i915simple/i915_texture.c
+++ b/src/gallium/drivers/i915simple/i915_texture.c
@@ -206,11 +206,10 @@ i945_miptree_layout_2d( struct i915_texture *tex )
unsigned nblocksx = pt->nblocksx[0];
unsigned nblocksy = pt->nblocksy[0];
-#if 0 /* used for tiled display targets */
- if (pt->last_level == 0 && pt->block.size == 4)
+ /* used for tiled display targets */
+ if (0)
if (i915_displaytarget_layout(tex))
return;
-#endif
tex->stride = round_up(pt->nblocksx[0] * pt->block.size, 4);