Re: [BUG] Shudown-time lockdep splat in next-20210514

From: Paul E. McKenney
Date: Sat May 15 2021 - 19:52:29 EST


On Sat, May 15, 2021 at 11:09:13PM +0200, Vlastimil Babka wrote:
> On 5/15/21 10:46 PM, Paul E. McKenney wrote:
> > Hello!
> >
> > I am seeing the following lockdep splat in next-20210514. It happens
> > at shutdown time in all rcutorture scenarios that enable lockdep. It
> > happens consistently on 2-hour runs, and I am trying it on shorter runs.
> > If it reproduces nicely, I will try bisection.
> >
> > In the meantime, does this ring a bell for anyone?
>
> Hm, I think it will be
> ad36bafb3bcdf mm/slub: use stackdepot to save stack trace in objects
>
> can you try this please?
>
> diff --git a/mm/slub.c b/mm/slub.c
> index 6b896b8c36f0..04824dae2e32 100644
> --- a/mm/slub.c
> +++ b/mm/slub.c
> @@ -623,7 +623,7 @@ static void set_track(struct kmem_cache *s, void *object,
>
> if (addr) {
> #ifdef CONFIG_STACKDEPOT
> - p->handle = save_stack_depot_trace(GFP_KERNEL);
> + p->handle = save_stack_depot_trace(GFP_NOWAIT);
> #endif
> p->addr = addr;
> p->cpu = smp_processor_id();

Works like a charm!

Tested-by: Paul E. McKenney <paulmck@xxxxxxxxxx>

Thanx, Paul