Skip to content

Commit

Permalink
branch tracer, intel-iommu: fix build with CONFIG_BRANCH_TRACER=y
Browse files Browse the repository at this point in the history
Fix the branch tracer barfing on comma statements within if ()
statements.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
  • Loading branch information
Linus Torvalds authored and Ingo Molnar committed Apr 7, 2009
1 parent d9ad8bc commit ab3c9c6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion include/linux/compiler.h
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,9 @@ void ftrace_likely_update(struct ftrace_branch_data *f, int val, int expect);
* "Define 'is'", Bill Clinton
* "Define 'if'", Steven Rostedt
*/
#define if(cond) if (__builtin_constant_p((cond)) ? !!(cond) : \
#define if(cond, ...) __trace_if( (cond , ## __VA_ARGS__) )
#define __trace_if(cond) \
if (__builtin_constant_p((cond)) ? !!(cond) : \
({ \
int ______r; \
static struct ftrace_branch_data \
Expand Down

0 comments on commit ab3c9c6

Please sign in to comment.