Re: [PATCH] mm/sparsemem: fix race in accessing memory_section->usage

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 17 Oct 2023 19:40:15 +0530 Charan Teja Kalla <quic_charante@xxxxxxxxxxx> wrote:

> >>  		 * was allocated during boot.
> >>  		 */
> >>  		if (!PageReserved(virt_to_page(ms->usage))) {
> >> +			synchronize_rcu();
> >>  			kfree(ms->usage);
> >>  			ms->usage = NULL;
> >>  		}
> > If we add NULL checks around ms->usage, this becomes
> > 
> > tmp = rcu_replace_pointer(ms->usage, NULL, hotplug_locked());
> > syncrhonize_rcu();
> > kfree(tmp);
> Per David input, I am working on using kfree_rcu().

How's it coming along?

Given that we're at 6.6-rc7 and given that this issue is causing
daily crashes in your device farm, I'm thinking that we use the current
version of your patch for 6.6 and for -stable.  We can look at the
kfree_rcu() optimization for later kernel releases?




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux