Re: [PATCH 1/2] lib/test_printf.c: Add ip6 tests

From: Sergey Senozhatsky
Date: Mon Aug 29 2022 - 21:47:33 EST


On (22/08/29 20:31), Kent Overstreet wrote:
> diff --git a/lib/test_printf.c b/lib/test_printf.c
> index 4bd15a593f..6a56dbf076 100644
> --- a/lib/test_printf.c
> +++ b/lib/test_printf.c
> @@ -18,6 +18,7 @@
> #include <linux/dcache.h>
> #include <linux/socket.h>
> #include <linux/in.h>
> +#include <linux/in6.h>
>
> #include <linux/gfp.h>
> #include <linux/mm.h>
> @@ -61,6 +62,9 @@ do_test(int bufsize, const char *expect, int elen,
> pr_warn("vsnprintf(buf, %d, \"%s\", ...) returned %d, expected %d\n",
> bufsize, fmt, ret, elen);
> return 1;
> + pr_warn("vsnprintf(buf, %d, \"%s\", ...) returned %d, expected %d (%s != %s)\n",
> + bufsize, fmt, ret, elen, test_buffer, expect);
> + return 1;
> }

I assume you intended to replace first pr_warn() with the second one?