Re: [PATCH] kasan: Remove kasan_record_aux_stack_noalloc().

2024-11-22 Thread Sebastian Andrzej Siewior
On 2024-11-22 16:01:29 [+0100], Marco Elver wrote: > > Do we need to update the comment saying that it must not be used from > > NMI or do we make it jump over the locked section in the NMI case? > > Good point. It was meant to also be usable from NMI, because it's very > likely to succeed, and sh

Re: [PATCH] kasan: Remove kasan_record_aux_stack_noalloc().

2024-11-22 Thread Marco Elver
On Fri, Nov 22, 2024 at 12:32PM +0100, Sebastian Andrzej Siewior wrote: > On 2024-11-19 20:36:56 [+0100], Andrey Konovalov wrote: > > > diff --git a/mm/kasan/generic.c b/mm/kasan/generic.c > > > index 6310a180278b6..b18b5944997f8 100644 > > > --- a/mm/kasan/generic.c > > > +++ b/mm/kasan/generic.c

Re: [PATCH] kasan: Remove kasan_record_aux_stack_noalloc().

2024-11-22 Thread Sebastian Andrzej Siewior
On 2024-11-19 20:36:56 [+0100], Andrey Konovalov wrote: > > diff --git a/mm/kasan/generic.c b/mm/kasan/generic.c > > index 6310a180278b6..b18b5944997f8 100644 > > --- a/mm/kasan/generic.c > > +++ b/mm/kasan/generic.c > > @@ -521,7 +521,7 @@ size_t kasan_metadata_size(struct kmem_cache *cache, > >

Re: [PATCH] kasan: Remove kasan_record_aux_stack_noalloc().

2024-11-19 Thread Waiman Long
On 11/19/24 10:57 AM, Sebastian Andrzej Siewior wrote: From: Peter Zijlstra kasan_record_aux_stack_noalloc() was introduced to record a stack trace without allocating memory in the process. It has been added to callers which were invoked while a raw_spinlock_t was held. More and more callers we

Re: [PATCH] kasan: Remove kasan_record_aux_stack_noalloc().

2024-11-19 Thread Andrey Konovalov
On Tue, Nov 19, 2024 at 4:57 PM Sebastian Andrzej Siewior wrote: > > From: Peter Zijlstra > > kasan_record_aux_stack_noalloc() was introduced to record a stack trace > without allocating memory in the process. It has been added to callers > which were invoked while a raw_spinlock_t was held. > Mo

Re: [PATCH] kasan: Remove kasan_record_aux_stack_noalloc().

2024-11-19 Thread Marco Elver
On Tue, 19 Nov 2024 at 16:57, Sebastian Andrzej Siewior wrote: > > From: Peter Zijlstra The patch title is misleading - it might suggest the opposite of what it's doing. I think this might be clearer: "kasan: Make kasan_record_aux_stack_noalloc() the default behaviour" Which is also more or le