[Intel-gfx] [PATCH 3/5] xvmc: Silence gcc, add parentheses around arithmetic.

Cyril Brulebois kibi at debian.org
Mon Jan 31 06:22:37 CET 2011


Get rid of those accordingly with CFLAGS="-Wall -Werror":
|   CC     i915_xvmc.lo
| cc1: warnings being treated as errors
| i915_xvmc.c: In function ‘i915_mc_one_time_state_emit’:
| i915_xvmc.c:369: error: suggest parentheses around arithmetic in operand of ‘|’
| i915_xvmc.c:374: error: suggest parentheses around arithmetic in operand of ‘|’
| i915_xvmc.c:379: error: suggest parentheses around arithmetic in operand of ‘|’
| i915_xvmc.c: In function ‘i915_mc_load_indirect_render_emit’:
| i915_xvmc.c:708: error: suggest parentheses around arithmetic in operand of ‘|’
| i915_xvmc.c:713: error: suggest parentheses around arithmetic in operand of ‘|’

Signed-off-by: Cyril Brulebois <kibi at debian.org>
---
 src/xvmc/i915_xvmc.c |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/src/xvmc/i915_xvmc.c b/src/xvmc/i915_xvmc.c
index fbd4555..dc3b593 100644
--- a/src/xvmc/i915_xvmc.c
+++ b/src/xvmc/i915_xvmc.c
@@ -367,17 +367,17 @@ static void i915_mc_one_time_state_emit(XvMCContext * context)
 
 	/* Sample state buffer */
 	OUT_RELOC(pI915XvMC->ssb_bo, I915_GEM_DOMAIN_INSTRUCTION, 0,
-			STATE_VALID | STATE_FORCE);
+			(STATE_VALID | STATE_FORCE));
 	OUT_BATCH(7);	/* 8 - 1 */
 
 	/* Pixel shader program buffer */
 	OUT_RELOC(pI915XvMC->psp_bo, I915_GEM_DOMAIN_INSTRUCTION, 0,
-			STATE_VALID | STATE_FORCE);
+			(STATE_VALID | STATE_FORCE));
 	OUT_BATCH(66);	/* 4 + 16 + 16 + 31 - 1 */
 
 	/* Pixel shader constant buffer */
 	OUT_RELOC(pI915XvMC->psc_bo, I915_GEM_DOMAIN_INSTRUCTION, 0,
-			STATE_VALID | STATE_FORCE);
+			(STATE_VALID | STATE_FORCE));
 	OUT_BATCH(5);	/* 6 - 1 */
 	ADVANCE_BATCH();
 }
@@ -705,12 +705,12 @@ static void i915_mc_load_indirect_render_emit(XvMCContext * context)
 
 	/* Static Indirect state buffer (dest buffer info) */
 	OUT_RELOC(pI915XvMC->sis_bo, I915_GEM_DOMAIN_INSTRUCTION, 0,
-			STATE_VALID | STATE_FORCE);
+			(STATE_VALID | STATE_FORCE));
 	OUT_BATCH(16);	/* 4 * 3 + 2 + 3 - 1 */
 
 	/* Map state buffer (reference buffer info) */
 	OUT_RELOC(pI915XvMC->msb_bo, I915_GEM_DOMAIN_INSTRUCTION, 0,
-			STATE_VALID | STATE_FORCE);
+			(STATE_VALID | STATE_FORCE));
 	OUT_BATCH(23);	/* 3 * 8 - 1 */
 	ADVANCE_BATCH();
 }
-- 
1.7.2.3




More information about the Intel-gfx mailing list