Received: by 2002:a05:7208:9594:b0:7e:5202:c8b4 with SMTP id gs20csp1100228rbb; Sun, 25 Feb 2024 20:30:29 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWeva2a3o1XN8HGz95It5u82V97fFwOBPaF4LqOTeQB3vWs34EGV8JB9hbawBgA+P+RqtuVFI/en2sq6M15sjSOiw41baD227qhMPZo9w== X-Google-Smtp-Source: AGHT+IF4lVkjYx50kzE8pHF5G16QkyCF79ZNltTDwUIWoBglizBb9HU0TPursYk5DmN/giUkmnx0 X-Received: by 2002:a05:622a:1993:b0:42e:8bb0:8103 with SMTP id u19-20020a05622a199300b0042e8bb08103mr423870qtc.33.1708921829638; Sun, 25 Feb 2024 20:30:29 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708921829; cv=pass; d=google.com; s=arc-20160816; b=Mrwr0I5XI2350RDzlCTNPR5ysmw4tudOJBAR7sUWuDHoQmyoeO1XBAPEX95FWNzgh7 XJx2nJf2YERHs0V62srMrUopCVg/0Fdya2QYGVBPHEcYcWFxBbVQclsyjn5A5SblZw4X +ALg7LVXatLLcDSn+0zV7NVlz3EqIl1BCdh0XoWsE/h30TZygdupVdbuVmCvbCRK7Jlo N5/2KsN487ZqjD1FTk6TwIlLnWUmNt7a56OKL04LWsYDfYxR5ne0L22D8o+YADrEpLzX iafVNxsqRfIqoujqjzGlR+tuLOMNmUiLc9B4q5WERlNJorGw/OXQ9KBDNd11enNGfkPg 47fw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:dkim-signature:message-id; bh=RgfeyY+29BFgB7d+7DJ1UYGNHFedjbusiVsI4MvBh/g=; fh=2D/KWe5yccGOY++3IXmIAyw8EllLqCbvPL3lDYrrMS0=; b=pvqp7RriOGZXDuK1dfU2b9B561zukGRpgnSAWT7v2CkoAitqb7Y5xXxOYH5iLiDY9l NQaRwChXbCY2puVil2bRIThebrjrWCwP1mfV7UnpShhovgwIuL68eXivomEKoS+Bda6M /k0cqsJjRsN5+RtMBg9s79fyKdLhZ76pkIOR3amZuld/MtKJ0KCsLC4ixbX8l3DtMU5q 7TaK8m2vSPZspF998/KVMYtNBB53S1ILPyC3IosogCQ+/DCOCdJcseAqR8DKeHW8TyJP rY60iIvfm3zq+fFg6IPbdEuHKYnJ0tmd//Zk+t/uf+YcZ6zuQ5tdRA6BfnU8xIC5MC7h GVHg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=pwhGE8rU; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-80551-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-80551-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id h21-20020ac87155000000b0042db67c4eddsi4256866qtp.655.2024.02.25.20.30.29 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 25 Feb 2024 20:30:29 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-80551-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=pwhGE8rU; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-80551-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-80551-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 1E8F51C21386 for ; Mon, 26 Feb 2024 04:30:29 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 10D361B7FB; Mon, 26 Feb 2024 04:30:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="pwhGE8rU" Received: from out-184.mta1.migadu.com (out-184.mta1.migadu.com [95.215.58.184]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id F34749440 for ; Mon, 26 Feb 2024 04:30:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=95.215.58.184 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708921820; cv=none; b=ZyokTic5FlCbUB1/yuzHBiNJaY/D7QQG0tMLmD77k/0ZwYnVah4vwXg8iJPcT6A9vDo6wvkclV5LEj1sBzxJHmovmQVsBE+tusd3FttDyanV+xWJdKGUWlcRWqCfCvFgOxO+x71CPmiVV1Ls7rem5kgkVTgrMj05tzyePVXjltI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708921820; c=relaxed/simple; bh=q8N4ZcUXLQWjQ9n2yT19kgIHaSLe4XIYihAb9YnZAWQ=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=kIhzoHoRMrvPxVBlcJdeA/VY/Gn2SNZ68A5bJjea+pqaeijJMcNH/a5rWDDCP9NeFjni4PE0l9oJUnqhfZYvn+lOKVqUmq1G803mxXOKs1X+tD+hq9sKRzuNRzEQe0wdSzjtiDK3c92WoU1nGEZuEz7Uo7kW3tiOub41bX2ea+8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=pwhGE8rU; arc=none smtp.client-ip=95.215.58.184 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Message-ID: <82c2553f-822e-40c2-9bf8-433689b3669d@linux.dev> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1708921815; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=RgfeyY+29BFgB7d+7DJ1UYGNHFedjbusiVsI4MvBh/g=; b=pwhGE8rUZfqrhbBaHVTdxP6R0+Qbotfl/KmyO6S9f2kLDLjp97gOJagXfppJ2vf0gvzt1m nfQjI5hqwaISbFLPsJzciGTNHQ/Jycs/iM33wT2vH4KNGBCuvNx1cbETqqjFDlv+aFQuR6 YjkJu18a/oY5TOrE7qcr/lc2Sdn2K+4= Date: Mon, 26 Feb 2024 12:30:01 +0800 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Subject: Re: [PATCH] ceph: remove SLAB_MEM_SPREAD flag usage Content-Language: en-US To: Xiubo Li , idryomov@gmail.com, jlayton@kernel.org Cc: ceph-devel@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, vbabka@suse.cz, roman.gushchin@linux.dev, Xiongwei.Song@windriver.com, Chengming Zhou References: <20240224134715.829225-1-chengming.zhou@linux.dev> <35df81f5-feac-4373-87a3-d3a27ba9c9d4@redhat.com> X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Chengming Zhou In-Reply-To: <35df81f5-feac-4373-87a3-d3a27ba9c9d4@redhat.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT On 2024/2/26 12:23, Xiubo Li wrote: > > On 2/26/24 10:42, Chengming Zhou wrote: >> On 2024/2/26 09:43, Xiubo Li wrote: >>> Hi Chengming, >>> >>> Thanks for your patch. >>> >>> BTW, could you share the link of the relevant patches to mark this a no-op ? >> Update changelog to make it clearer: >> >> The SLAB_MEM_SPREAD flag used to be implemented in SLAB, which was >> removed as of v6.8-rc1, so it became a dead flag. And the series[1] >> went on to mark it obsolete to avoid confusion for users. Here we >> can just remove all its users, which has no functional change. >> >> [1] https://lore.kernel.org/all/20240223-slab-cleanup-flags-v2-1-02f1753e8303@suse.cz/ > > Thanks for your quick feedback. > > BTW, I couldn't find this change in Linus' tree in the master and even the v6.8-rc1 tag, please see https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/tree/include/linux/slab.h?h=master. > > Did I miss something ? Or has this patch been merged ? You're right, this patch hasn't been merged. But it's already a dead flag as of v6.8-rc1. Update changelog to make it clearer: The SLAB_MEM_SPREAD flag used to be implemented in SLAB, which was removed as of v6.8-rc1, so it became a dead flag since the commit 16a1d968358a ("mm/slab: remove mm/slab.c and slab_def.h"). And the series[1] went on to mark it obsolete to avoid confusion for users. Here we can just remove all its users, which has no functional change. [1] https://lore.kernel.org/all/20240223-slab-cleanup-flags-v2-1-02f1753e8303@suse.cz/ Does this look clearer to you? I can improve it if there is still confusion. Thanks! > > - Xiubo > >> Thanks! >> >>> Thanks >>> >>> - Xiubo >>> >>> On 2/24/24 21:47, chengming.zhou@linux.dev wrote: >>>> From: Chengming Zhou >>>> >>>> The SLAB_MEM_SPREAD flag is already a no-op as of 6.8-rc1, remove >>>> its usage so we can delete it from slab. No functional change. >>>> >>>> Signed-off-by: Chengming Zhou >>>> --- >>>>    fs/ceph/super.c | 18 +++++++++--------- >>>>    1 file changed, 9 insertions(+), 9 deletions(-) >>>> >>>> diff --git a/fs/ceph/super.c b/fs/ceph/super.c >>>> index 5ec102f6b1ac..4dcbbaa297f6 100644 >>>> --- a/fs/ceph/super.c >>>> +++ b/fs/ceph/super.c >>>> @@ -928,36 +928,36 @@ static int __init init_caches(void) >>>>        ceph_inode_cachep = kmem_cache_create("ceph_inode_info", >>>>                          sizeof(struct ceph_inode_info), >>>>                          __alignof__(struct ceph_inode_info), >>>> -                      SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD| >>>> -                      SLAB_ACCOUNT, ceph_inode_init_once); >>>> +                      SLAB_RECLAIM_ACCOUNT|SLAB_ACCOUNT, >>>> +                      ceph_inode_init_once); >>>>        if (!ceph_inode_cachep) >>>>            return -ENOMEM; >>>>    -    ceph_cap_cachep = KMEM_CACHE(ceph_cap, SLAB_MEM_SPREAD); >>>> +    ceph_cap_cachep = KMEM_CACHE(ceph_cap, 0); >>>>        if (!ceph_cap_cachep) >>>>            goto bad_cap; >>>> -    ceph_cap_snap_cachep = KMEM_CACHE(ceph_cap_snap, SLAB_MEM_SPREAD); >>>> +    ceph_cap_snap_cachep = KMEM_CACHE(ceph_cap_snap, 0); >>>>        if (!ceph_cap_snap_cachep) >>>>            goto bad_cap_snap; >>>>        ceph_cap_flush_cachep = KMEM_CACHE(ceph_cap_flush, >>>> -                       SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD); >>>> +                       SLAB_RECLAIM_ACCOUNT); >>>>        if (!ceph_cap_flush_cachep) >>>>            goto bad_cap_flush; >>>>          ceph_dentry_cachep = KMEM_CACHE(ceph_dentry_info, >>>> -                    SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD); >>>> +                    SLAB_RECLAIM_ACCOUNT); >>>>        if (!ceph_dentry_cachep) >>>>            goto bad_dentry; >>>>    -    ceph_file_cachep = KMEM_CACHE(ceph_file_info, SLAB_MEM_SPREAD); >>>> +    ceph_file_cachep = KMEM_CACHE(ceph_file_info, 0); >>>>        if (!ceph_file_cachep) >>>>            goto bad_file; >>>>    -    ceph_dir_file_cachep = KMEM_CACHE(ceph_dir_file_info, SLAB_MEM_SPREAD); >>>> +    ceph_dir_file_cachep = KMEM_CACHE(ceph_dir_file_info, 0); >>>>        if (!ceph_dir_file_cachep) >>>>            goto bad_dir_file; >>>>    -    ceph_mds_request_cachep = KMEM_CACHE(ceph_mds_request, SLAB_MEM_SPREAD); >>>> +    ceph_mds_request_cachep = KMEM_CACHE(ceph_mds_request, 0); >>>>        if (!ceph_mds_request_cachep) >>>>            goto bad_mds_req; >>>>    >