From patchwork Thu Sep 5 07:56:44 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Brauner X-Patchwork-Id: 13791881 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id AF1C6CD4F59 for ; Thu, 5 Sep 2024 07:57:11 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 407D86B009B; Thu, 5 Sep 2024 03:57:11 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 390846B00E7; Thu, 5 Sep 2024 03:57:11 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 20ADA6B00B5; Thu, 5 Sep 2024 03:57:11 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0011.hostedemail.com [216.40.44.11]) by kanga.kvack.org (Postfix) with ESMTP id F34E58D0001 for ; Thu, 5 Sep 2024 03:57:10 -0400 (EDT) Received: from smtpin03.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay02.hostedemail.com (Postfix) with ESMTP id 97F8A1219C1 for ; Thu, 5 Sep 2024 07:57:10 +0000 (UTC) X-FDA: 82529929020.03.A80B5DE Received: from nyc.source.kernel.org (nyc.source.kernel.org [147.75.193.91]) by imf16.hostedemail.com (Postfix) with ESMTP id D3BA618000C for ; Thu, 5 Sep 2024 07:57:08 +0000 (UTC) Authentication-Results: imf16.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=PV7TCy+x; spf=pass (imf16.hostedemail.com: domain of brauner@kernel.org designates 147.75.193.91 as permitted sender) smtp.mailfrom=brauner@kernel.org; dmarc=pass (policy=quarantine) header.from=kernel.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1725522952; h=from:from:sender: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:dkim-signature; bh=GDW+dC6B32MFmyBg3N0T+Mv1KEQyjD1yi60gLpagBxc=; b=JZ1o4gAMzMH9Crdhs/kPiMTSp/PZ90gUf9xTQixbaTZ9shCNgboCaY/H168Q8BotsCzLsG 3GANWEsFTT6ahxqyJDOFmsCElJg7tgal4vu2QigA+NHv5r9q0zti7FBsDC/2HGR1u1mTsx pNy27LVgsb5CykuCV88jKF2ahXIbBrI= ARC-Authentication-Results: i=1; imf16.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=PV7TCy+x; spf=pass (imf16.hostedemail.com: domain of brauner@kernel.org designates 147.75.193.91 as permitted sender) smtp.mailfrom=brauner@kernel.org; dmarc=pass (policy=quarantine) header.from=kernel.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1725522952; a=rsa-sha256; cv=none; b=f3mNPrecJnbdegRul3xF3Ru4F5GCphd7HL4MsDuQA+mn0gk2UghszIL/xhpJJ8Z4QrXKlR ZvFUJkmi8OYD6xgyprq5pczEyJO98gOAJ4EFnKkVBh75ELXCh8bDVLSEi2cb/6EGmykz/c D+6Q4gT2DzBsjGpFyqY84SX4us/W/OI= Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by nyc.source.kernel.org (Postfix) with ESMTP id DF5E1A4437B; Thu, 5 Sep 2024 07:57:00 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 62592C4CEC4; Thu, 5 Sep 2024 07:57:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1725523027; bh=rY6kC2WiEYeQ/Zth3l+6kLSSBQxvb1BV7zU7+V4xp9g=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=PV7TCy+xlc5pai2T6OdADRXzqDCI7RS8Bew/YoEZlFm+l72tOIN19MbKrPF6i5xBM gOSOOQaJQe465NMdIBUFo+hbYDaRhYpDBiPbcDjqtRlv4DoS2DtOzj+tQv6cfdWBNb q0/i6dtuVk/rAoczLEeDpKbjTKcXRRWRLJDQAjn70rnQxzBUnrBpk0NSHVvzdefNjO RB4FHrnCps+DNwlrGxUABHRx3MBhNmetxyiNvz5dkhcGbVTYjn3mTBI+qXz7EvI+WC Y5xY+PYXXi78sd/hs7aUOS4++QZ8sdSPHGUlCFu1/5fer/b2UN8aXI5F+OehXTDhhW fKT+xPJB0wmuQ== From: Christian Brauner Date: Thu, 05 Sep 2024 09:56:44 +0200 Subject: [PATCH v4 01/17] slab: s/__kmem_cache_create/do_kmem_cache_create/g MIME-Version: 1.0 Message-Id: <20240905-work-kmem_cache_args-v4-1-ed45d5380679@kernel.org> References: <20240905-work-kmem_cache_args-v4-0-ed45d5380679@kernel.org> In-Reply-To: <20240905-work-kmem_cache_args-v4-0-ed45d5380679@kernel.org> To: Vlastimil Babka , Jens Axboe , Jann Horn , Linus Torvalds , Mike Rapoport Cc: Kees Cook , Christoph Lameter , Pekka Enberg , David Rientjes , Joonsoo Kim , Andrew Morton , Roman Gushchin , Hyeonggon Yoo <42.hyeyoo@gmail.com>, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, Christian Brauner X-Mailer: b4 0.15-dev-37811 X-Developer-Signature: v=1; a=openpgp-sha256; l=2107; i=brauner@kernel.org; h=from:subject:message-id; bh=rY6kC2WiEYeQ/Zth3l+6kLSSBQxvb1BV7zU7+V4xp9g=; b=owGbwMvMwCU28Zj0gdSKO4sYT6slMaTdTPEK4X7zku9Z8Eq+IAvWO5pVE032Bs03YHF2aUuIm s81MSG5o5SFQYyLQVZMkcWh3SRcbjlPxWajTA2YOaxMIEMYuDgFYCKFpxn+yoRdZjFudkjftsb2 yvpJ/zeGidzekMn8YGWqmMvE35bsexn+mTQ0TNHW08p6kHv/WRij7csO74MdNnfOrmJ8xKLl3sr MAwA= X-Developer-Key: i=brauner@kernel.org; a=openpgp; fpr=4880B8C9BD0E5106FC070F4F7B3C391EFEA93624 X-Stat-Signature: a4tcmzft14hj9eoh6yx4s71n6eefywu6 X-Rspam-User: X-Rspamd-Queue-Id: D3BA618000C X-Rspamd-Server: rspam02 X-HE-Tag: 1725523028-269437 X-HE-Meta: U2FsdGVkX1+AB2KYQhxzBUB0HJafF40hlnLCZZMF+ySZKq3OqBW71ORqOCRre+0m7v4beAp2GKkbUa7Zc6juiPdDRmRjXVaKt/snx4+Cm86gHsiqAbixBN8fPmvJS2WqzKvREx7JGyK90cPBF+WYQbdEnCaULt2BTnTzl8h8wLgB8l038R4G1dFO7O2EJ5wU5fBMgi2cod9cl38XhzTEZDywEWl9PNdLdhGJs0DwqwOHYM4mBdRsWWyJilMQY7qWSiLVJJTfCnwSTPs8np+ba0f5FY44Csvohs18sWmUu/vw2yP1VHuZAAF87fJr/KZneyA+7H3HJk5zyEQFZgESvKmvJfW1AyxmTeqLciuRUo/sRqLNvRe00m9ulP8jP5aUuMeXEwSV2jBclfDjC8nuXt19ZSQDYtyQiJDbWzDuyQTbqeDuiziTBK88S8+zEqYlL0cVt+a2lsiAP3AUpszrciKMalHl1cAWMsVqP6ze/BZwpLQKVSZFXoE1SMLIF0sO2gNkXBYbfgGA9Uzu5tRQH5JEn+T0yXq3+bhz0ZxSppKFjZcmcXN2/9fTk/GObHgreNqBot3XtkD+opmf5zvdqlYPjV3EiSXRKpILGT0DcA9J+NlMzruw58h+OOA9uehNV1x+p8pATh+7nbKt52vkXd7Mh9KxuBaXF0qQyaGtPDZZ0On5E8t+HLByPLwLWNuHGoHClt7iZYLt1edsAfQuwJrQXQzFIbFhECw5JOLz0lsy5FwMCCWgLc3nyG0NzQ49fiZTCya2kNPCUisnY0k0XWTgBSR+1UNsE9Xy9IOfm5H5Izyv9/6MZz7qN892pK9nqBagUcgkyg/zK8glcCi5Tv12dMVZ2O1jUOIHWkDA7+rz0h32oOFp4ylfxwIjv3BIDBQUuZEQVhCB6u8Zw84/7dIyXSA2fAdlZxkIpSWSS4yQWSm/u8oQgfPJIH/vSwvVUKtnutM0lHKs6DtcWK0 kIEv5jIJ g6FiRry7lITHlUbPx4/Lf3+5kEHwnoa0rJ027VYC5xd8VGW8rUUwYJS2CQSFORhroclslXTR9DMbw13BmvRRKy4wW3KggM9qBGJVfQuERAU2tJPVl9mSkkOzEuvGbH+KL0N+PEuu4RxETCC8lAL97poNpVWYjmikzeZQrW0cMfYDW361hxs1IuW6BL0NaiI4L22X04bpvhg0cT1Tggi8WEs2oBwye1WLF9MctoIB6ylT83BxgE8ANhX6Z6h3wV3rH7dTzNpIEsTEFFjJJb3CXUFoXy1F06t6xAIPQCsV+579+ewg5EdvmdiPllgoTxODww0AR/b9ChR4Dc+5m3NNUs74sPVcR2gAblQAtQBQpNuHpYAeFAcV8QWybXk1LbsCqYpNI47hlUnXZ0XEBH/K1AqRToryRlsh9XTHgsACP5VYr4Ng8IbRxXmdLndqqTYItD39c 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: List-Subscribe: List-Unsubscribe: Free up reusing the double-underscore variant for follow-up patches. Reviewed-by: Kees Cook Reviewed-by: Jens Axboe Reviewed-by: Mike Rapoport (Microsoft) Reviewed-by: Vlastimil Babka Signed-off-by: Christian Brauner Reviewed-by: Roman Gushchin --- mm/slab.h | 2 +- mm/slab_common.c | 4 ++-- mm/slub.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/mm/slab.h b/mm/slab.h index a6051385186e..684bb48c4f39 100644 --- a/mm/slab.h +++ b/mm/slab.h @@ -424,7 +424,7 @@ kmalloc_slab(size_t size, kmem_buckets *b, gfp_t flags, unsigned long caller) gfp_t kmalloc_fix_flags(gfp_t flags); /* Functions provided by the slab allocators */ -int __kmem_cache_create(struct kmem_cache *, slab_flags_t flags); +int do_kmem_cache_create(struct kmem_cache *, slab_flags_t flags); void __init kmem_cache_init(void); extern void create_boot_cache(struct kmem_cache *, const char *name, diff --git a/mm/slab_common.c b/mm/slab_common.c index 95db3702f8d6..91e0e36e4379 100644 --- a/mm/slab_common.c +++ b/mm/slab_common.c @@ -234,7 +234,7 @@ static struct kmem_cache *create_cache(const char *name, s->useroffset = useroffset; s->usersize = usersize; #endif - err = __kmem_cache_create(s, flags); + err = do_kmem_cache_create(s, flags); if (err) goto out_free_cache; @@ -778,7 +778,7 @@ void __init create_boot_cache(struct kmem_cache *s, const char *name, s->usersize = usersize; #endif - err = __kmem_cache_create(s, flags); + err = do_kmem_cache_create(s, flags); if (err) panic("Creation of kmalloc slab %s size=%u failed. Reason %d\n", diff --git a/mm/slub.c b/mm/slub.c index 9aa5da1e8e27..23d9d783ff26 100644 --- a/mm/slub.c +++ b/mm/slub.c @@ -5902,7 +5902,7 @@ __kmem_cache_alias(const char *name, unsigned int size, unsigned int align, return s; } -int __kmem_cache_create(struct kmem_cache *s, slab_flags_t flags) +int do_kmem_cache_create(struct kmem_cache *s, slab_flags_t flags) { int err;