diff options
author | gareth <gareth> | 2001-01-30 03:22:46 +0000 |
---|---|---|
committer | gareth <gareth> | 2001-01-30 03:22:46 +0000 |
commit | 6e7d60e05c04ac84aca2a103c3c9d6c57be5364d (patch) | |
tree | fc78dd433533402209a9c50cd5ca312a06ba4fff | |
parent | 3aa8ae2cbd65869f8abd54b48e2275b58eccbb7d (diff) |
These PPC people think they're pretty tough, don't they? ;-)
-rw-r--r-- | xc/lib/GL/mesa/src/drv/r128/r128_tris.c | 26 | ||||
-rw-r--r-- | xc/programs/Xserver/hw/xfree86/os-support/linux/drm/kernel/r128_drv.h | 2 |
2 files changed, 11 insertions, 17 deletions
diff --git a/xc/lib/GL/mesa/src/drv/r128/r128_tris.c b/xc/lib/GL/mesa/src/drv/r128/r128_tris.c index 2f1625e23..83180fde1 100644 --- a/xc/lib/GL/mesa/src/drv/r128/r128_tris.c +++ b/xc/lib/GL/mesa/src/drv/r128/r128_tris.c @@ -50,20 +50,7 @@ static struct { quad_func quad; } rast_tab[R128_MAX_TRIFUNC]; -#include <endian.h> - -#if __BYTE_ORDER == __BIG_ENDIAN - -#define R128_COLOR(to, from) \ -do { \ - (to)[0] = (from)[3]; \ - (to)[1] = (from)[0]; \ - (to)[2] = (from)[1]; \ - (to)[3] = (from)[2]; \ -} while (0) - -#else /* little endian */ - +#if __BYTE_ORDER == __LITTLE_ENDIAN #define R128_COLOR( to, from ) \ do { \ (to)[0] = (from)[2]; \ @@ -71,8 +58,15 @@ do { \ (to)[2] = (from)[0]; \ (to)[3] = (from)[3]; \ } while (0) - -#endif /* __BYTE_ORDER */ +#else +#define R128_COLOR( to, from ) \ +do { \ + (to)[0] = (from)[3]; \ + (to)[1] = (from)[0]; \ + (to)[2] = (from)[1]; \ + (to)[3] = (from)[2]; \ +} while (0) +#endif static void r128_null_quad( GLcontext *ctx, GLuint v0, diff --git a/xc/programs/Xserver/hw/xfree86/os-support/linux/drm/kernel/r128_drv.h b/xc/programs/Xserver/hw/xfree86/os-support/linux/drm/kernel/r128_drv.h index 48d91a1f8..8f5aea15e 100644 --- a/xc/programs/Xserver/hw/xfree86/os-support/linux/drm/kernel/r128_drv.h +++ b/xc/programs/Xserver/hw/xfree86/os-support/linux/drm/kernel/r128_drv.h @@ -463,7 +463,7 @@ do { \ drm_r128_ring_buffer_t *ring = &dev_priv->ring; int i; \ if ( ring->space < ring->high_mark ) { \ for ( i = 0 ; i < dev_priv->usec_timeout ; i++ ) { \ - ring->space = GET_RING_HEAD( ring ) - ring->tail; \ + ring->space = GET_RING_HEAD( ring ) - ring->tail;\ if ( ring->space <= 0 ) \ ring->space += ring->size; \ if ( ring->space >= ring->high_mark ) \ |