fix some signed vs unsigned warnings
authorDave Airlie <airliedfreedesktop.org>
Mon, 14 Feb 2005 09:27:38 +0000 (09:27 +0000)
committerDave Airlie <airliedfreedesktop.org>
Mon, 14 Feb 2005 09:27:38 +0000 (09:27 +0000)
src/mesa/drivers/dri/common/depthtmp.h
src/mesa/drivers/dri/common/dri_util.c
src/mesa/drivers/dri/common/dri_util.h
src/mesa/drivers/dri/common/spantmp.h
src/mesa/drivers/dri/common/stenciltmp.h
src/mesa/drivers/dri/common/texmem.c
src/mesa/drivers/dri/i810/i810context.c
src/mesa/drivers/dri/i810/i810ioctl.c
src/mesa/drivers/dri/i810/i810tris.c

index ec79aca30f72cc2a024580d74522367d36cc9cd9..ad26e6b8914ff648aebcaa059c299812d2f1f582 100644 (file)
@@ -111,7 +111,7 @@ static void TAG(WriteDepthPixels)( GLcontext *ctx,
 {
    HW_WRITE_LOCK()
       {
-        GLint i;
+        GLuint i;
         LOCAL_DEPTH_VARS;
 
         if ( DBG ) fprintf( stderr, "WriteDepthPixels\n" );
@@ -178,7 +178,7 @@ static void TAG(ReadDepthPixels)( GLcontext *ctx, GLuint n,
 {
    HW_READ_LOCK()
       {
-        GLint i;
+        GLuint i;
         LOCAL_DEPTH_VARS;
 
         if ( DBG ) fprintf( stderr, "ReadDepthPixels\n" );
index a4de0b6496a574e8ab45e16521d1bdf35d25eb7f..302994e0c23a9417fe0d48dace5177c0ecfc47b5 100644 (file)
@@ -1573,7 +1573,7 @@ __driUtilCreateScreen(Display *dpy, int scrn, __DRIscreen *psc,
  *
  * \sa __glXGetInternalVersion().
  */
-int driCompareGLXAPIVersion( GLuint required_version )
+int driCompareGLXAPIVersion( GLint required_version )
 {
    if ( api_ver > required_version ) {
       return 1;
index 001313c4c8a8303d7ebeb00822c843529f8d0c7b..6ef1b114f9c684bc361ef93f685d00ba592f6909 100644 (file)
@@ -561,7 +561,7 @@ __driUtilCreateScreen(Display *dpy, int scrn, __DRIscreen *psc,
 
 /* Test the version of the internal GLX API.  Returns a value like strcmp. */
 extern int
-driCompareGLXAPIVersion( GLuint required_version );
+driCompareGLXAPIVersion( GLint required_version );
 
 extern float
 driCalculateSwapUsage( __DRIdrawablePrivate *dPriv,
index 94126ecbaf318075acd53ba304e1032d015430f4..96f26333fcb15bdda8e03d6bfeb6ca99b79a9b3c 100644 (file)
@@ -145,7 +145,7 @@ static void TAG(WriteRGBAPixels)( const GLcontext *ctx,
 {
    HW_WRITE_LOCK()
       {
-        GLint i;
+        GLuint i;
         LOCAL_VARS;
 
         if (DBG) fprintf(stderr, "WriteRGBAPixels\n");
@@ -229,7 +229,7 @@ static void TAG(WriteMonoRGBAPixels)( const GLcontext *ctx,
 {
    HW_WRITE_LOCK()
       {
-        GLint i;
+        GLuint i;
         LOCAL_VARS;
         INIT_MONO_PIXEL(p, color);
 
@@ -293,7 +293,7 @@ static void TAG(ReadRGBAPixels)( const GLcontext *ctx,
 {
    HW_READ_LOCK()
       {
-        GLint i;
+        GLuint i;
         LOCAL_VARS;
 
         if (DBG) fprintf(stderr, "ReadRGBAPixels\n");
index 285d8e5291731d1fedd3850839fbc15d520efb97..dfbe665407dbbcc215640d90507c8c318cd6ed5a 100644 (file)
@@ -66,7 +66,7 @@ static void TAG(WriteStencilPixels)( GLcontext *ctx,
 {
    HW_WRITE_LOCK()
       {
-        GLint i;
+        GLuint i;
         LOCAL_STENCIL_VARS;
 
         if (DBG) fprintf(stderr, "WriteStencilPixels\n");
@@ -121,7 +121,7 @@ static void TAG(ReadStencilPixels)( GLcontext *ctx, GLuint n,
 {
    HW_READ_LOCK()
       {
-        GLint i;
+        GLuint i;
         LOCAL_STENCIL_VARS;
 
         if (DBG) fprintf(stderr, "ReadStencilPixels\n");
index 192b7870491e245788c25436866a08d54a9ee887..acefce0f5971302e793e36881bc479e575fe751b 100644 (file)
@@ -188,7 +188,7 @@ static void printLocalLRU( driTexHeap * heap, const char *callername  )
 static void printGlobalLRU( driTexHeap * heap, const char *callername )
 {
    drmTextureRegionPtr list = heap->global_regions;
-   int i, j;
+   unsigned int i, j;
 
    fprintf( stderr, "%s in %s:\nGlobal LRU, heap %d list %p:\n", 
            __FUNCTION__, callername, heap->heapId, (void *)list );
index bbdd5e17867eda426d7085255b88c35b4c9dc06f..bf1b2fc93c681370d2ce7d744becf96d5f0d141f 100644 (file)
@@ -331,7 +331,7 @@ i810DestroyContext(__DRIcontextPrivate *driContextPriv)
         /* This share group is about to go away, free our private
           * texture object data.
           */
-         int i;
+        unsigned int i;
 
          for ( i = 0 ; i < imesa->nr_heaps ; i++ ) {
            driDestroyTextureHeap( imesa->texture_heaps[ i ] );
index c62e58178997c2e2b73a1f7306ffbaad70e51f74..50ddd0976f2acb54122b5b986c2f5707ec2b9370 100644 (file)
@@ -55,7 +55,7 @@ static void i810Clear( GLcontext *ctx, GLbitfield mask, GLboolean all,
    __DRIdrawablePrivate *dPriv = imesa->driDrawable;
    const GLuint colorMask = *((GLuint *) &ctx->Color.ColorMask);
    drmI810Clear clear;
-   int i;
+   unsigned int i;
 
    clear.flags = 0;
    clear.clear_color = imesa->ClearColor;
@@ -63,12 +63,12 @@ static void i810Clear( GLcontext *ctx, GLbitfield mask, GLboolean all,
 
    I810_FIREVERTICES( imesa );
        
-   if ((mask & DD_FRONT_LEFT_BIT) && colorMask == ~0) {
+   if ((mask & DD_FRONT_LEFT_BIT) && colorMask == ~0U) {
       clear.flags |= I810_FRONT;
       mask &= ~DD_FRONT_LEFT_BIT;
    }
 
-   if ((mask & DD_BACK_LEFT_BIT) && colorMask == ~0) {
+   if ((mask & DD_BACK_LEFT_BIT) && colorMask == ~0U) {
       clear.flags |= I810_BACK;
       mask &= ~DD_BACK_LEFT_BIT;
    }
@@ -89,7 +89,7 @@ static void i810Clear( GLcontext *ctx, GLbitfield mask, GLboolean all,
 
       for (i = 0 ; i < imesa->numClipRects ; ) 
       {         
-        int nr = MIN2(i + I810_NR_SAREA_CLIPRECTS, imesa->numClipRects);
+        unsigned int nr = MIN2(i + I810_NR_SAREA_CLIPRECTS, imesa->numClipRects);
         drm_clip_rect_t *box = imesa->pClipRects;       
         drm_clip_rect_t *b = (drm_clip_rect_t *)imesa->sarea->boxes;
         int n = 0;
index 5b2ea018e1ed4adad5616074f1f8d96860ec379b..3e09427bb94f631c1fa6efcdf2ac55744a143de2 100644 (file)
@@ -75,7 +75,7 @@ do {                                                                  \
 } while (0)
 #endif
 
-static void __inline__ i810_draw_triangle( i810ContextPtr imesa,
+static __inline__ void i810_draw_triangle( i810ContextPtr imesa,
                                           i810VertexPtr v0,
                                           i810VertexPtr v1,
                                           i810VertexPtr v2 )
@@ -90,7 +90,7 @@ static void __inline__ i810_draw_triangle( i810ContextPtr imesa,
 }
 
 
-static void __inline__ i810_draw_quad( i810ContextPtr imesa,
+static __inline__ void i810_draw_quad( i810ContextPtr imesa,
                                       i810VertexPtr v0,
                                       i810VertexPtr v1,
                                       i810VertexPtr v2,