From c0f4063703265fc4009e6cadc2de79f553f99b1c Mon Sep 17 00:00:00 2001 From: Pauli Nieminen Date: Sat, 22 Aug 2009 02:43:00 +0300 Subject: radeon/r300: Code clean up and logic fix. --- src/mesa/drivers/dri/r300/r300_draw.c | 2 +- src/mesa/drivers/dri/radeon/radeon_cmdbuf.h | 2 +- src/mesa/drivers/dri/radeon/radeon_common.c | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/mesa/drivers/dri/r300/r300_draw.c b/src/mesa/drivers/dri/r300/r300_draw.c index b3d19a90c30..2784808dda9 100644 --- a/src/mesa/drivers/dri/r300/r300_draw.c +++ b/src/mesa/drivers/dri/r300/r300_draw.c @@ -572,7 +572,7 @@ static GLuint r300PredictTryDrawPrimsSize(GLcontext *ctx, GLuint nr_prims) { struct r300_context *r300 = R300_CONTEXT(ctx); struct r300_vertex_buffer *vbuf = &r300->vbuf; - int flushed; + GLboolean flushed; GLuint dwords; GLuint state_size; diff --git a/src/mesa/drivers/dri/radeon/radeon_cmdbuf.h b/src/mesa/drivers/dri/radeon/radeon_cmdbuf.h index da748515add..410df4d665c 100644 --- a/src/mesa/drivers/dri/radeon/radeon_cmdbuf.h +++ b/src/mesa/drivers/dri/radeon/radeon_cmdbuf.h @@ -3,7 +3,7 @@ #include "radeon_bocs_wrapper.h" -int rcommonEnsureCmdBufSpace(radeonContextPtr rmesa, int dwords, const char *caller); +GLboolean rcommonEnsureCmdBufSpace(radeonContextPtr rmesa, int dwords, const char *caller); int rcommonFlushCmdBuf(radeonContextPtr rmesa, const char *caller); int rcommonFlushCmdBufLocked(radeonContextPtr rmesa, const char *caller); void rcommonInitCmdBuf(radeonContextPtr rmesa); diff --git a/src/mesa/drivers/dri/radeon/radeon_common.c b/src/mesa/drivers/dri/radeon/radeon_common.c index 30d24574edd..9f901d2c0af 100644 --- a/src/mesa/drivers/dri/radeon/radeon_common.c +++ b/src/mesa/drivers/dri/radeon/radeon_common.c @@ -928,7 +928,7 @@ static void radeon_print_state_atom(radeonContextPtr radeon, struct radeon_state int i, j, reg, count; int dwords; uint32_t packet0; - if (! (DEBUG_CMDBUF || RADEON_DEBUG & DEBUG_STATE)) + if (! (DEBUG_CMDBUF && RADEON_DEBUG & DEBUG_STATE) ) return; if (!radeon->radeonScreen->kernel_mm) { @@ -1212,7 +1212,7 @@ int rcommonFlushCmdBuf(radeonContextPtr rmesa, const char *caller) * * \param dwords The number of dwords we need to be free on the command buffer */ -int rcommonEnsureCmdBufSpace(radeonContextPtr rmesa, int dwords, const char *caller) +GLboolean rcommonEnsureCmdBufSpace(radeonContextPtr rmesa, int dwords, const char *caller) { if ((rmesa->cmdbuf.cs->cdw + dwords + 128) > rmesa->cmdbuf.size || radeon_cs_need_flush(rmesa->cmdbuf.cs)) { -- cgit v1.2.3