OSDN Git Service

ASoC: rsnd: adg: supply __printf(x, y) formatting for dbg_msg()
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Tue, 1 Jun 2021 23:43:28 +0000 (08:43 +0900)
committerMark Brown <broonie@kernel.org>
Thu, 3 Jun 2021 12:56:38 +0000 (13:56 +0100)
Fixes the following W=1 kernel build warning(s):

sound/soc/sh/rcar/adg.c: In function 'dbg_msg':
sound/soc/sh/rcar/adg.c:594:2: warning: function 'dbg_msg' might \
 be a candidate for 'gnu_printf' format attribute\
 [-Wsuggest-attribute=format]

Fixes: 1f9c82b5ab83 ("ASoC: rsnd: add debugfs support")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/87tumhi21r.wl-kuninori.morimoto.gx@renesas.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/sh/rcar/adg.c

index 7891633..390d5e2 100644 (file)
@@ -584,6 +584,7 @@ rsnd_adg_get_clkout_end:
 }
 
 #if defined(DEBUG) || defined(CONFIG_DEBUG_FS)
+__printf(3, 4)
 static void dbg_msg(struct device *dev, struct seq_file *m,
                                   const char *fmt, ...)
 {