x86/asm: add commas to BUILD_BUG_ON
PATCH 1/1 x86/asm: add commas to BUILD_BUG_ON
In light of recent observations with how macros are handled by gas, let's play by what we informally set for ourselves as a guideline: Use commas to separate parameters/arguments.
xen/arch/x86/include/asm/asm_defns.h +2 -2
@@ -82,13 +82,13 @@ register unsigned long current_stack_poi#ifdef __ASSEMBLY__ -.macro BUILD_BUG_ON condstr cond:vararg +.macro BUILD_BUG_ON condstr, cond:vararg .if \cond .error "Condition \"\condstr\" not satisfied" .endif .endm/* preprocessor macro to make error message more user friendly */ -#define BUILD_BUG_ON (cond) BUILD_BUG_ON #cond cond +#define BUILD_BUG_ON (cond) BUILD_BUG_ON #cond, cond#ifdef HAVE_AS_QUOTED_SYM #define SUBSECTION_LBL (tag) \
Quoted 5 lines · Jan Beulich
In light of recent observations with how macros are handled by gas, let's play by what we informally set for ourselves as a guideline: Use commas to separate parameters/arguments.
Signed-off-by Jan Beulich <[email protected]>
However, there are some other examples wanting the same treatment.
alternative-asm.h:14:.macro altinstruction_entry orig repl feature orig_len repl_len pad_len
asm-defns.h:32:.macro INDIRECT_BRANCH insn:req arg:req asm_defns.h:284:.macro RESTORE_ALL adj=0 compat=0 spec_ctrl_asm.h:107:.macro DO_OVERWRITE_RSB tmp=rax xu
Preferably, fix all of these in one go.
As for observations about the other architectures, PPC uses commas everywhere. RISC-V has no .macro's. ARM looks to be a 50/50 mix.