Re: [PATCH] [v2] kasan: avoid -Wmaybe-uninitialized warning

2017-07-25 Thread Arnd Bergmann
On Tue, Jul 25, 2017 at 2:06 PM, Andrey Ryabinin wrote: > On 07/25/2017 10:17 AM, Arnd Bergmann wrote: >> On Mon, Jul 24, 2017 at 1:35 PM, Alexander Potapenko >> wrote: >>> On Fri, Jul 21, 2017 at 11:02 PM, Arnd Bergmann wrote: >> diff --git a/mm/kasan/report.c b/mm/kasan/report.c ind

Re: [PATCH] [v2] kasan: avoid -Wmaybe-uninitialized warning

2017-07-25 Thread Andrey Ryabinin
On 07/25/2017 10:17 AM, Arnd Bergmann wrote: > On Mon, Jul 24, 2017 at 1:35 PM, Alexander Potapenko > wrote: >> On Fri, Jul 21, 2017 at 11:02 PM, Arnd Bergmann wrote: > >>> diff --git a/mm/kasan/report.c b/mm/kasan/report.c >>> index 04bb1d3eb9ec..28fb222ab149 100644 >>> --- a/mm/kasan/report.c

Re: [PATCH] [v2] kasan: avoid -Wmaybe-uninitialized warning

2017-07-25 Thread Arnd Bergmann
On Mon, Jul 24, 2017 at 1:35 PM, Alexander Potapenko wrote: > On Fri, Jul 21, 2017 at 11:02 PM, Arnd Bergmann wrote: >> diff --git a/mm/kasan/report.c b/mm/kasan/report.c >> index 04bb1d3eb9ec..28fb222ab149 100644 >> --- a/mm/kasan/report.c >> +++ b/mm/kasan/report.c >> @@ -111,6 +111,9 @@ stati

Re: [PATCH] [v2] kasan: avoid -Wmaybe-uninitialized warning

2017-07-24 Thread Alexander Potapenko
On Fri, Jul 21, 2017 at 11:02 PM, Arnd Bergmann wrote: > gcc-7 produces this warning: > > mm/kasan/report.c: In function 'kasan_report': > mm/kasan/report.c:351:3: error: 'info.first_bad_addr' may be used > uninitialized in this function [-Werror=maybe-uninitialized] >print_shadow_for_address

[PATCH] [v2] kasan: avoid -Wmaybe-uninitialized warning

2017-07-21 Thread Arnd Bergmann
gcc-7 produces this warning: mm/kasan/report.c: In function 'kasan_report': mm/kasan/report.c:351:3: error: 'info.first_bad_addr' may be used uninitialized in this function [-Werror=maybe-uninitialized] print_shadow_for_address(info->first_bad_addr); ^~~~