#define ext4_debug(f, a...) \
do { \
printk(KERN_DEBUG "EXT4-fs DEBUG (%s, %d): %s:", \
__FILE__, __LINE__, __func__); \
printk(KERN_DEBUG f, ## a); \
} while (0)
what I dont understand is this
printk(KERN_DEBUG f, ## a);
Could anybody help me to understand what is ## in this line?
thank you
It is there to make the variadic macro (macro which can take multiple arguments) work if you pass in 0 arguments.
From the Variadic Macros section in the GCC manual:
If you did not use this, then that would expand to
frpintf(stderr, "success!\n",), which is a syntax error.