Received: by 2002:a05:7412:d1aa:b0:fc:a2b0:25d7 with SMTP id ba42csp1948034rdb; Wed, 31 Jan 2024 14:23:43 -0800 (PST) X-Google-Smtp-Source: AGHT+IFXR2FxGR69fnkiVS9tb9HWvShKpTLsEAsrKqYUaM7kM27nYq69hKsQ6HZrJYjGE0FJpcGe X-Received: by 2002:a05:620a:4d3:b0:784:5e49:e15 with SMTP id 19-20020a05620a04d300b007845e490e15mr826968qks.19.1706739822932; Wed, 31 Jan 2024 14:23:42 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706739822; cv=pass; d=google.com; s=arc-20160816; b=pSmol+YfsaSP0hb4rw06J6oCHpiAk2dDleOjY1Hq/ZLREr3DD51e21r6Wp4Btq+3gS BCoIuBJKxEm5/jAur4w7jgLhbp2mUseKMdalrKfUE6J66O0Z341d1iY3HsggXv3h7MXF zzbnMXcV4BYGS1q6BRkQU1AVrNZlxje0oyx0Y38KfexTxI3E2Apsp6c09CJ5iF/l/VHH MkZ3LUGgz7YnUry4R9q/szsL//EkYaU9ELrUXBQY5v+9NnQZBfj9C1ueqB7mVVevM0AR nEKfdfMK0igYg8V+KhbrJqjl5ROLOKE9fmS2JEHWn/VdhDW5XHAe6mQoo5ALZE7SCIlR iP8g== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:subject:cc:to:from :date; bh=viLlGxnrYUyhaQ0+sXTRxpeLd/pY6fSXf0otFTMjiEE=; fh=khGtIrGCJU64KhA7tVleQz2Vb02Sj7dBuPm/nxBh09I=; b=VQ+oWUIWyBDp7XrhCL1DKpfyMjLeo20guGsweK0DmGmevSbbAU6jq8S1BXpTn1u8yg WH005i2BEsTh5AjMxOZLdaQASO0vzTPkNmwr2vLbScHEJA1hxyahk5TCfU7sO6xFmnQJ iFmsOiNDd+rXQ1vqwd+kGTd6zwkJf72ugoFCEnfAVeE/1Ic6AgHQk48KM/N4pJo40EqN YZQuFCr91kemUqn8j1I6zK2HMLmfifv16xBSOpXK8cfw8ilfYPX2CH7CNgCEIdDeBzj0 a/aLGh0XcMuLtx2fJDKG+L6Y5YmJ1LyZjuvUVOguU0RJrNDeu+ziqFOqjXx80OTYN8t1 ZaYg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-47253-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-47253-linux.lists.archive=gmail.com@vger.kernel.org" X-Forwarded-Encrypted: i=1; AJvYcCWrUcsQXdH9KpuwPwXyfGpjsWYxmr4Xjx/m7QO3OWZ1EzLkVwxsRGncNIkhFjgnQx4jynw6uPLwdi4VYOAIvMsQPr2sVLtjepRRhRnvPg== Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id w5-20020a05620a444500b0078543d7f975si386164qkp.396.2024.01.31.14.23.42 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 31 Jan 2024 14:23:42 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-47253-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; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-47253-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-47253-linux.lists.archive=gmail.com@vger.kernel.org" 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 B0DDB1C228B6 for ; Wed, 31 Jan 2024 22:23:42 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 24D6F40BF5; Wed, 31 Jan 2024 22:20:15 +0000 (UTC) Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 971B83FE52 for ; Wed, 31 Jan 2024 22:20:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706739614; cv=none; b=pSE35VDVTIUSmn7ENZRi+amTE4QHgbsIBy4P3udJoJyRab4qENkseFyRHbFXImAg38XKcfCYm0OHw1Bukl47IxQMrSSG4KU/y+V24LrduVJ4HPhYaCCjycgi8x0THOV+8KYNdopZNta3hJjNZIaeIRpEaoIkGmhMUflmLQtUMwQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706739614; c=relaxed/simple; bh=xMysF+OwUF/L9YYOOy5X8GMzZdutOpCBkbPg9wLFhqg=; h=Date:From:To:Cc:Subject:Message-ID:MIME-Version:Content-Type; b=oefxPR/GbMXlux3dEMrBrJziNs3g49+yvfOZfn2DYball1/Pkn8W2yNY1HeeIuG/hb/x+BvJMiMn41xo8WnsvsWrlXNpz6mE+1SwY3OwhO6B6MxbGfF8W4+DQQlJnsEnVhzM8sEGKP2IrjHDSwnph969v7nIv72bER2VEDOuS+Y= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 134EFC43390; Wed, 31 Jan 2024 22:20:12 +0000 (UTC) Date: Wed, 31 Jan 2024 17:20:27 -0500 From: Steven Rostedt To: LKML , linux-mm@kvack.org Cc: Andrew Morton , Linus Torvalds , Vlastimil Babka , Kees Cook , Christoph Lameter , David Rientjes , Hyeonggon Yoo <42.hyeyoo@gmail.com> Subject: Do we still need SLAB_MEM_SPREAD (and possibly others)? Message-ID: <20240131172027.10f64405@gandalf.local.home> X-Mailer: Claws Mail 3.19.1 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit I was looking into moving eventfs_inode into a slab, and after cutting and pasting the tracefs allocator: tracefs_inode_cachep = kmem_cache_create("tracefs_inode_cache", sizeof(struct tracefs_inode), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD| SLAB_ACCOUNT), init_once); I figured I should know what those slab flags mean. I also looked at what others in fs use for their slabs. The above is rather common (which I probably just copied from another file system), but I wanted to know what they are for. When I got to SLAB_MEM_SPREAD, I found that it's a common flag and there's a lot of caches that just set that and nothing else. But I couldn't find how it was used. Then I found this commit: 16a1d968358a ("mm/slab: remove mm/slab.c and slab_def.h") Which I think removed the only use case of SLAB_MEM_SPREAD. $ git grep SLAB_MEM_SPREAD mm mm/slab.h: SLAB_MEM_SPREAD | \ That's all I find in the mm directory. Is it obsolete now? Can we delete it? Maybe there's other SLAB_* flags that are no longer used. I don't know, I haven't audited them. -- Steve