]> git.karo-electronics.de Git - karo-tx-linux.git/commit
bug.h: Prevent double evaulation of in BUILD_BUG_ON
authorDaniel Santos <daniel.santos@pobox.com>
Wed, 20 Feb 2013 02:13:30 +0000 (13:13 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Wed, 20 Feb 2013 05:52:00 +0000 (16:52 +1100)
commit3a27efbe278b4a0e54e9c2a6f1f7c27c1e1327af
tree9c82566621576a711be72f97170f4db442b3d99f
parent06e79baa4613b4688c11e07ef7702e6db13ca87f
bug.h: Prevent double evaulation of in BUILD_BUG_ON

When calling BUILD_BUG_ON in an optimized build using gcc 4.3 and later,
the condition will be evaulated twice, possibily with side-effects.  This
patch eliminates that error.

Signed-off-by: Daniel Santos <daniel.santos@pobox.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Borislav Petkov <bp@alien8.de>
Cc: David Rientjes <rientjes@google.com>
Cc: Joe Perches <joe@perches.com>
Cc: Josh Triplett <josh@joshtriplett.org>
Cc: Paul Gortmaker <paul.gortmaker@windriver.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
include/linux/bug.h