[Mesa-dev] [PATCH 03/20] intel: Silence many "intel_batchbuffer.h:97:39: warning: comparison between signed and unsigned integer expressions"
Ian Romanick
idr at freedesktop.org
Mon Aug 29 14:58:53 PDT 2011
From: Ian Romanick <ian.d.romanick at intel.com>
---
src/mesa/drivers/dri/intel/intel_batchbuffer.h | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/src/mesa/drivers/dri/intel/intel_batchbuffer.h b/src/mesa/drivers/dri/intel/intel_batchbuffer.h
index fb4134d..90dc0ed 100644
--- a/src/mesa/drivers/dri/intel/intel_batchbuffer.h
+++ b/src/mesa/drivers/dri/intel/intel_batchbuffer.h
@@ -57,9 +57,11 @@ static INLINE uint32_t float_as_int(float f)
* be passed as structs rather than dwords, but that's a little bit of
* work...
*/
-static INLINE GLint
+static INLINE unsigned
intel_batchbuffer_space(struct intel_context *intel)
{
+ assert((intel->batch.state_batch_offset - intel->batch.reserved_space)
+ >= intel->batch.used*4);
return (intel->batch.state_batch_offset - intel->batch.reserved_space) - intel->batch.used*4;
}
--
1.7.4.4
More information about the mesa-dev
mailing list