From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE, SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5320EC4338F for ; Tue, 3 Aug 2021 14:45:06 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id CA58361053 for ; Tue, 3 Aug 2021 14:45:05 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org CA58361053 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id 6E77B8D0002; Tue, 3 Aug 2021 10:45:05 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 6BE758D0001; Tue, 3 Aug 2021 10:45:05 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 5D5878D0002; Tue, 3 Aug 2021 10:45:05 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0072.hostedemail.com [216.40.44.72]) by kanga.kvack.org (Postfix) with ESMTP id 431958D0001 for ; Tue, 3 Aug 2021 10:45:05 -0400 (EDT) Received: from smtpin19.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id EC606824999B for ; Tue, 3 Aug 2021 14:45:04 +0000 (UTC) X-FDA: 78434041728.19.5D9F78A Received: from szxga03-in.huawei.com (szxga03-in.huawei.com [45.249.212.189]) by imf30.hostedemail.com (Postfix) with ESMTP id 13049E014CC9 for ; Tue, 3 Aug 2021 14:45:03 +0000 (UTC) Received: from dggemv711-chm.china.huawei.com (unknown [172.30.72.53]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4GfHbD2QVmz81hq; Tue, 3 Aug 2021 22:40:08 +0800 (CST) Received: from dggpemm500001.china.huawei.com (7.185.36.107) by dggemv711-chm.china.huawei.com (10.1.198.66) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Tue, 3 Aug 2021 22:44:58 +0800 Received: from [10.174.177.243] (10.174.177.243) by dggpemm500001.china.huawei.com (7.185.36.107) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Tue, 3 Aug 2021 22:44:56 +0800 Subject: Re: [PATCH] slub: fix unreclaimable slab stat for bulk free To: Vlastimil Babka , Shakeel Butt CC: Christoph Lameter , Pekka Enberg , "David Rientjes" , Michal Hocko , "Roman Gushchin" , Wang Hai , Muchun Song , Andrew Morton , "Linux MM" , LKML References: <20210728155354.3440560-1-shakeelb@google.com> <8c14efe2-69dc-6eab-3cd5-c042576770e7@huawei.com> <35a0b75a-f348-d21c-4ff4-fadba0c4db02@huawei.com> <43cf4e71-4dd4-dc37-a70f-553fe5cba126@suse.cz> From: Kefeng Wang Message-ID: Date: Tue, 3 Aug 2021 22:44:56 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 MIME-Version: 1.0 In-Reply-To: <43cf4e71-4dd4-dc37-a70f-553fe5cba126@suse.cz> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US X-Originating-IP: [10.174.177.243] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To dggpemm500001.china.huawei.com (7.185.36.107) X-CFilter-Loop: Reflected Authentication-Results: imf30.hostedemail.com; dkim=none; spf=pass (imf30.hostedemail.com: domain of wangkefeng.wang@huawei.com designates 45.249.212.189 as permitted sender) smtp.mailfrom=wangkefeng.wang@huawei.com; dmarc=pass (policy=none) header.from=huawei.com X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: 13049E014CC9 X-Stat-Signature: n4cz8kj33ssmss5crdfxx9qx3ec1osr6 X-HE-Tag: 1628001903-691366 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On 2021/8/3 22:29, Vlastimil Babka wrote: > On 8/3/21 4:24 PM, Kefeng Wang wrote: >> On 2021/7/29 22:03, Shakeel Butt wrote: >>> On Wed, Jul 28, 2021 at 11:52 PM Kefeng Wang wrote: >>>> On 2021/7/28 23:53, Shakeel Butt wrote: >>> I don't have a strong opinion on this. Please send a patch with >>> reasoning if you want WARN_ON_ONCE here. >> Ok, we met a BUG_ON(!PageCompound(page)) in kfree() twice in lts4.4, we are >> still debugging it. >> >> It's different to analyses due to no vmcore, and can't be reproduced. >> >> WARN_ON() here could help us to notice the issue. >> >> Also is there any experience or known fix/way to debug this kinds of issue? >> memory corruption? > This would typically be a use-after-free/double-free - a problem of the slab > user, not slab itself. We enable KASAN to find whether or not there are some UAF/double free, no related log for now. > >> Any suggestion will be appreciated, thanks. > debug_pagealloc could help to catch a use-after-free earlier OK, will try this, thanks. > >>> . >>> > . >