[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ad258412-2f8f-8e15-fbd0-c0933aeb1a6d@suse.cz>
Date: Tue, 19 Jul 2022 16:21:32 +0200
From: Vlastimil Babka <vbabka@...e.cz>
To: Rongwei Wang <rongwei.wang@...ux.alibaba.com>,
akpm@...ux-foundation.org, roman.gushchin@...ux.dev,
iamjoonsoo.kim@....com, rientjes@...gle.com, penberg@...nel.org,
cl@...ux.com
Cc: linux-mm@...ck.org, linux-kernel@...r.kernel.org,
Hyeonggon Yoo <42.hyeyoo@...il.com>
Subject: Re: [PATCH 1/3] mm/slub: fix the race between validate_slab and
slab_free
On 7/19/22 16:15, Rongwei Wang wrote:
>
...
>> +
>> + slab_unlock(slab, &flags2);
>> + spin_unlock_irqrestore(&n->list_lock, flags);
>> + if (!ret)
>> + slab_fix(s, "Object at 0x%p not freed", object);
>> + if (slab_to_discard) {
>> + stat(s, FREE_SLAB);
>> + discard_slab(s, slab);
>> + }
>> +
>> + return ret;
>> +}
> I had test this patch, and it indeed deal with the bug that I described.
Thanks.
> Though I am also has prepared this part of code, your code is ok to me.
Aha, feel free to post your version, maybe it's simpler? We can compare.
Powered by blists - more mailing lists