From 45f38cb3b80311ade3c87000f7d7a8f6ebd60a43 Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Wed, 13 May 2015 14:09:25 -0300 Subject: [media] saa7134: avoid complex macro warnings The debug macros are not properly defined, as they generate warnings like: ERROR: Macros with complex values should be enclosed in parentheses +#define core_dbg(fmt, arg...) if (core_debug) \ + printk(KERN_DEBUG pr_fmt("core: " fmt), ## arg) Use do { } while (0) for those macros. Signed-off-by: Mauro Carvalho Chehab --- drivers/media/pci/saa7134/saa7134-tvaudio.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'drivers/media/pci/saa7134/saa7134-tvaudio.c') diff --git a/drivers/media/pci/saa7134/saa7134-tvaudio.c b/drivers/media/pci/saa7134/saa7134-tvaudio.c index 6320b64d3528..1a960a1b07b5 100644 --- a/drivers/media/pci/saa7134/saa7134-tvaudio.c +++ b/drivers/media/pci/saa7134/saa7134-tvaudio.c @@ -49,8 +49,10 @@ static int audio_clock_tweak; module_param(audio_clock_tweak, int, 0644); MODULE_PARM_DESC(audio_clock_tweak, "Audio clock tick fine tuning for cards with audio crystal that's slightly off (range [-1024 .. 1024])"); -#define audio_dbg(level, fmt, arg...) if (audio_debug >= level) \ - printk(KERN_DEBUG pr_fmt("audio: " fmt), ## arg) +#define audio_dbg(level, fmt, arg...) do { \ + if (audio_debug >= level) \ + printk(KERN_DEBUG pr_fmt("audio: " fmt), ## arg); \ + } while (0) /* msecs */ #define SCAN_INITIAL_DELAY 1000 -- cgit v1.2.3