On Thu, May 13, 2021 at 1:03 PM David Gow <davidgow@xxxxxxxxxx> wrote: > > Some KUnit functions use variable arguments to implement a printf-like > format string. Use the __printf() attribute to let the compiler warn if > invalid format strings are passed in. > > If the kernel is build with W=1, it complained about the lack of these > specifiers, e.g.: > ../lib/kunit/test.c:72:2: warning: function ‘kunit_log_append’ might be a candidate for ‘gnu_printf’ format attribute [-Wsuggest-attribute=format] > > Signed-off-by: David Gow <davidgow@xxxxxxxxxx> Acked-by: Brendan Higgins <brendanhiggins@xxxxxxxxxx>