Re: [PATCH v2 3/3] scftorture: Use a lock-less list to free memory.
From: Sebastian Andrzej Siewior
Date: Fri Nov 08 2024 - 05:36:08 EST
On 2024-11-07 12:45:25 [-0800], Boqun Feng wrote:
> > @@ -538,6 +567,8 @@ static void scf_torture_cleanup(void)
> >
> > end:
> > torture_cleanup_end();
> > + for (i = 0; i < nthreads; i++)
>
> This needs to be:
>
> for (i = 0; i < nr_cpu_ids; i++)
>
> because nthreads can be larger than nr_cpu_ids, and it'll access a
> out-of-bound percpu section.
And I though I learned my lesson last time.
Thank you.
> Regards,
> Boqun
Sebastian