Re: [PATCH v2 2/2] x86/process: Silence KASAN warnings in get_wchan()

2015-10-13 Thread Ingo Molnar
* Dmitry Vyukov wrote: > > Hm, exactly how is the 'red zone' defined? Is this about the current task > > mostly, or when doing get_wchan() on other tasks? > > When code is compiled with AddressSanitizer, most variables on stack have > redzones around them, on entry function "poisons" these

Re: [PATCH v2 2/2] x86/process: Silence KASAN warnings in get_wchan()

2015-10-13 Thread Andrey Ryabinin
On 10/13/2015 04:57 PM, Dmitry Vyukov wrote: > On Tue, Oct 13, 2015 at 3:48 PM, Ingo Molnar wrote: >> >> * Andrey Ryabinin wrote: >> >>> get_wchan() is racy by design, it may access volatile stack >>> of running task, thus it may access redzone in a stack frame >>> and cause KASAN to warn

Re: [PATCH v2 2/2] x86/process: Silence KASAN warnings in get_wchan()

2015-10-13 Thread Andrey Ryabinin
On 10/13/2015 04:48 PM, Ingo Molnar wrote: > > * Andrey Ryabinin wrote: > >> get_wchan() is racy by design, it may access volatile stack >> of running task, thus it may access redzone in a stack frame >> and cause KASAN to warn about this. >> >> Use READ_ONCE_NOCHECK() to silence these

Re: [PATCH v2 2/2] x86/process: Silence KASAN warnings in get_wchan()

2015-10-13 Thread Dmitry Vyukov
On Tue, Oct 13, 2015 at 3:48 PM, Ingo Molnar wrote: > > * Andrey Ryabinin wrote: > >> get_wchan() is racy by design, it may access volatile stack >> of running task, thus it may access redzone in a stack frame >> and cause KASAN to warn about this. >> >> Use READ_ONCE_NOCHECK() to silence these

Re: [PATCH v2 2/2] x86/process: Silence KASAN warnings in get_wchan()

2015-10-13 Thread Ingo Molnar
* Andrey Ryabinin wrote: > get_wchan() is racy by design, it may access volatile stack > of running task, thus it may access redzone in a stack frame > and cause KASAN to warn about this. > > Use READ_ONCE_NOCHECK() to silence these warnings. > > Reported-by: Sasha Levin > Signed-off-by:

Re: [PATCH v2 2/2] x86/process: Silence KASAN warnings in get_wchan()

2015-10-13 Thread Andrey Ryabinin
On 10/13/2015 04:48 PM, Ingo Molnar wrote: > > * Andrey Ryabinin wrote: > >> get_wchan() is racy by design, it may access volatile stack >> of running task, thus it may access redzone in a stack frame >> and cause KASAN to warn about this. >> >> Use

Re: [PATCH v2 2/2] x86/process: Silence KASAN warnings in get_wchan()

2015-10-13 Thread Ingo Molnar
* Andrey Ryabinin wrote: > get_wchan() is racy by design, it may access volatile stack > of running task, thus it may access redzone in a stack frame > and cause KASAN to warn about this. > > Use READ_ONCE_NOCHECK() to silence these warnings. > > Reported-by: Sasha

Re: [PATCH v2 2/2] x86/process: Silence KASAN warnings in get_wchan()

2015-10-13 Thread Dmitry Vyukov
On Tue, Oct 13, 2015 at 3:48 PM, Ingo Molnar wrote: > > * Andrey Ryabinin wrote: > >> get_wchan() is racy by design, it may access volatile stack >> of running task, thus it may access redzone in a stack frame >> and cause KASAN to warn about this. >>

Re: [PATCH v2 2/2] x86/process: Silence KASAN warnings in get_wchan()

2015-10-13 Thread Ingo Molnar
* Dmitry Vyukov wrote: > > Hm, exactly how is the 'red zone' defined? Is this about the current task > > mostly, or when doing get_wchan() on other tasks? > > When code is compiled with AddressSanitizer, most variables on stack have > redzones around them, on entry

Re: [PATCH v2 2/2] x86/process: Silence KASAN warnings in get_wchan()

2015-10-13 Thread Andrey Ryabinin
On 10/13/2015 04:57 PM, Dmitry Vyukov wrote: > On Tue, Oct 13, 2015 at 3:48 PM, Ingo Molnar wrote: >> >> * Andrey Ryabinin wrote: >> >>> get_wchan() is racy by design, it may access volatile stack >>> of running task, thus it may access redzone in a