Checkpatch miscomplaint about macro parentheses enclosure in traces
Hi,
I'm seeing:
ERROR: Macros with complex values should be enclosed in parentheses #61: FILE: include/trace/events/rxrpc.h:484:
+#define rxrpc_tq_traces \
+ EM(rxrpc_tq_alloc, "ALLOC") \
+ EM(rxrpc_tq_cleaned, "CLEAN") \
+ EM(rxrpc_tq_decant, "DCNT ") \
+ EM(rxrpc_tq_decant_advance, "DCNT>") \
+ EM(rxrpc_tq_queue, "QUEUE") \
+ EM(rxrpc_tq_queue_dup, "QUE!!") \
+ EM(rxrpc_tq_rotate, "ROT ") \
+ EM(rxrpc_tq_rotate_and_free, "ROT-F") \
+ EM(rxrpc_tq_rotate_and_keep, "ROT-K") \
+ EM(rxrpc_tq_transmit, "XMIT ") \
+ E_(rxrpc_tq_transmit_advance, "XMIT>")
in the trace headers. However, this cannot be parenthesised as one of the things it is being used for is to generate an enum, thereby reducing the number of times the list of symbols is given.
Can this be at least downgraded to a warning, if not waived altogether, if the file is in the include/trace/events/ directory? Possibly the "EM"/"E_"/"EMe" prefix could be checked for.
David