Re: [PATCH] slub: Introduce CONFIG_SLUB_RCU_DEBUG

2023-09-16 Thread Andrey Konovalov
On Mon, Aug 28, 2023 at 4:40 PM Jann Horn wrote: > > > Can't we unpoision this rcu_head right before call_rcu() and repoison > > after receiving the callback? > > Yeah, I think that should work. It looks like currently > kasan_unpoison() is exposed in include/linux/kasan.h but > kasan_poison() is

Re: [PATCH] slub: Introduce CONFIG_SLUB_RCU_DEBUG

2023-09-11 Thread Dmitry Vyukov
On Mon, 28 Aug 2023 at 16:40, Jann Horn wrote: > > On Sat, Aug 26, 2023 at 5:32 AM Dmitry Vyukov wrote: > > On Fri, 25 Aug 2023 at 23:15, Jann Horn wrote: > > > Currently, KASAN is unable to catch use-after-free in SLAB_TYPESAFE_BY_RCU > > > slabs because use-after-free is allowed within the RCU

Re: [PATCH] slub: Introduce CONFIG_SLUB_RCU_DEBUG

2023-09-11 Thread Marco Elver
On Fri, 25 Aug 2023 at 23:15, 'Jann Horn' via kasan-dev wrote: > > Currently, KASAN is unable to catch use-after-free in SLAB_TYPESAFE_BY_RCU > slabs because use-after-free is allowed within the RCU grace period by > design. > > Add a SLUB debugging feature which RCU-delays every individual > kmem