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 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id B10AAC61DF7 for ; Fri, 24 Nov 2023 00:45:16 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 250BC6B045E; Thu, 23 Nov 2023 19:45:16 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 1FC236B046E; Thu, 23 Nov 2023 19:45:16 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 075C06B047F; Thu, 23 Nov 2023 19:45:15 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id E88896B045E for ; Thu, 23 Nov 2023 19:45:15 -0500 (EST) Received: from smtpin26.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id BB98CB6460 for ; Fri, 24 Nov 2023 00:45:15 +0000 (UTC) X-FDA: 81491003790.26.161BC07 Received: from mail-il1-f172.google.com (mail-il1-f172.google.com [209.85.166.172]) by imf13.hostedemail.com (Postfix) with ESMTP id 0C80920021 for ; Fri, 24 Nov 2023 00:45:13 +0000 (UTC) Authentication-Results: imf13.hostedemail.com; dkim=pass header.d=google.com header.s=20230601 header.b=h6lzMZ0P; dmarc=pass (policy=reject) header.from=google.com; spf=pass (imf13.hostedemail.com: domain of rientjes@google.com designates 209.85.166.172 as permitted sender) smtp.mailfrom=rientjes@google.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1700786714; 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: in-reply-to:in-reply-to:references:references:dkim-signature; bh=RjvlNJZCYVj3BK/c/qbMtW/UyhsFITEp4fF0Uz8Mao8=; b=ojdq2RnXLVRhoReJk9IBzB4BTy7/Q0lwDgWSMa6gRLNLJE5PGt3ZtQx42TM6kwJK+51NYz aNj1wmpBI0u+lTwylRfYOXuoo/IdmGNgeE4OxD+203QDufkC4VvBy/ef7+FpLZGusTD90X MdTe6Tq5rVDXHF0ODCOZqxqMaQWqntk= ARC-Authentication-Results: i=1; imf13.hostedemail.com; dkim=pass header.d=google.com header.s=20230601 header.b=h6lzMZ0P; dmarc=pass (policy=reject) header.from=google.com; spf=pass (imf13.hostedemail.com: domain of rientjes@google.com designates 209.85.166.172 as permitted sender) smtp.mailfrom=rientjes@google.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1700786714; a=rsa-sha256; cv=none; b=qHZtyRHZV6a18w/dIB1WnaNTTZmIhzp6aUsINNQCtWTyxsSlP/3DNjCmslisWmxRgrbVzH VaiOfoUpMZnWmi+Amfd82rbfw9vL9JzlmgMg4TzbwJ5OLQx7nRHtILj/D0OAINtWmGgyTr EPmmjxE0cyhVj1JJwXOvvprY+4GaiOc= Received: by mail-il1-f172.google.com with SMTP id e9e14a558f8ab-357d0d15b29so119735ab.1 for ; Thu, 23 Nov 2023 16:45:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1700786713; x=1701391513; darn=kvack.org; h=mime-version:references:message-id:in-reply-to:subject:cc:to:from :date:from:to:cc:subject:date:message-id:reply-to; bh=RjvlNJZCYVj3BK/c/qbMtW/UyhsFITEp4fF0Uz8Mao8=; b=h6lzMZ0PMpotgWxbTjOuOxd8q/OicIo3xjH+4Crd3a3+EKCHk/9ZgrLv35c4wW50Ji fKX0dzVWqMDrJWiCLG8DXBGyzzkWN1tBRyFBRcq2gN0YsTeOzXfJRKFyTUgLrOT8sr6p 6EQJXTq9vFRSLiRVBDY1SBbH3/P6iW+uGQUw3RnedrSXCZ9d8BhoLm/P8R+f+vx+AdJq em7p4742zYJEbFurLSwbgdCYkTBhs4fhiUmpyb/4jrJrlJ/RMTFRcs5RIfNhEggFeGkx saa+ViC9AalUZbOv23KJ8R+eYb1FIh4lhqYdfwS5XPyCXOy8QEuc9f4AzobhjQkNib4C VvcQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700786713; x=1701391513; h=mime-version:references:message-id:in-reply-to:subject:cc:to:from :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=RjvlNJZCYVj3BK/c/qbMtW/UyhsFITEp4fF0Uz8Mao8=; b=ofA3chYPTvuaIVPomReOzL8qZH3ckqnOwLpyNegDZYKlwVpQAAewt4J4fBv27X+Y3Z vlrp25iEwjudqSP5JsijMC7ckSoZV0W53W1/7fKifRhd4BSvsoD+MOhsRe0WDbrA3M++ cHH4WSM+p1NfxFOmYuziQu/HNvmQ4v6g6unLh/p8FgYbN92kZAXImf829kzjUETzBAAQ ZwtLZ10g6hf5Q+1TjmZWIxwINLqUhBlGldsXO1yVF9R3pWYSxpW/3rHO9CvfPW1xJ2D9 p6DwEk24S6wogi0MvKxVtgw/RIg+tPfSG3ptuKEnvrxF38k3zlpa7ZVtVnjS1F9APZDW Jegg== X-Gm-Message-State: AOJu0Yz/g0yTxDfVAawlNWB0EmvpTU/qTtEg8+fmo5DF60cISWohTGDl +IDr5NbtLpRzPDfyQz1iBGLILQ== X-Google-Smtp-Source: AGHT+IFp5Vt0r4dxgxouGwH8qybG/NW6TxiUxTw6TyLOqXsKdt6ktNcxwvwHx0LVMlBIFEYNytErDQ== X-Received: by 2002:a05:6e02:1687:b0:357:4335:77fe with SMTP id f7-20020a056e02168700b00357433577femr452960ila.27.1700786713087; Thu, 23 Nov 2023 16:45:13 -0800 (PST) Received: from [2620:0:1008:15:ab09:50a5:ec6d:7b5c] ([2620:0:1008:15:ab09:50a5:ec6d:7b5c]) by smtp.gmail.com with ESMTPSA id q4-20020a631f44000000b005acd5d7e11bsm1919194pgm.35.2023.11.23.16.45.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Nov 2023 16:45:11 -0800 (PST) Date: Thu, 23 Nov 2023 16:45:06 -0800 (PST) From: David Rientjes To: Vlastimil Babka cc: Christoph Lameter , Pekka Enberg , Joonsoo Kim , Andrew Morton , Hyeonggon Yoo <42.hyeyoo@gmail.com>, Roman Gushchin , Andrey Ryabinin , Alexander Potapenko , Andrey Konovalov , Dmitry Vyukov , Vincenzo Frascino , Marco Elver , Johannes Weiner , Michal Hocko , Shakeel Butt , Muchun Song , Kees Cook , linux-mm@kvack.org, linux-kernel@vger.kernel.org, kasan-dev@googlegroups.com, cgroups@vger.kernel.org, linux-hardening@vger.kernel.org, Michal Hocko Subject: Re: [PATCH v2 00/21] remove the SLAB allocator In-Reply-To: <20231120-slab-remove-slab-v2-0-9c9c70177183@suse.cz> Message-ID: References: <20231120-slab-remove-slab-v2-0-9c9c70177183@suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Rspam-User: X-Rspamd-Server: rspam12 X-Rspamd-Queue-Id: 0C80920021 X-Stat-Signature: 3z8kcdn7qdb3t99gnamidkwrgrqwz93k X-HE-Tag: 1700786713-179166 X-HE-Meta: U2FsdGVkX1/qAssc1spX0YQh59F0HgC7nJxzt+J+1QteUAph4UrzCI446RrD4JsO1pO8yjGUjjeLdfjDGpk/+l8VvCjNzCXshJLOEPpYjikvSYY7m2NNa4lB4+VMVsLRAoXivSd9drJzu2F/gy3iLB+WsKOsN7seODkOVbs2GdEQPLg96W0w8xLYLo2Zw/R1JfVc/hHy751SZwjBM5MWnJRb+M8wm0McOmL2X/daMNKJvjbCjpAkuhr9cyfogONbvWNmdTLfujOL3vMcuh8+KAO5foQB+0+w2tEon0EiFewevlWc5L8rZ9daI9tzlQ+CvM7osRZm0sif2XNYTnCjj2hzzOpSY3pwuwv1q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tdVOO6h6lF6TJVUqJAClLcQir4ch5qQ3N4uPEYvfckUCh9Zs/xlNT/kRxO7TI42jrVmvbkMPZHU4U= 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: On Mon, 20 Nov 2023, Vlastimil Babka wrote: > Changes from v1: > - Added new Patch 01 to fix up kernel docs build (thanks Marco Elver) > - Additional changes to Kconfig user visible texts in Patch 02 (thanks Kees > Cook) > - Whitespace fixes and other fixups (thanks Kees) > > The SLAB allocator has been deprecated since 6.5 and nobody has objected > so far. As we agreed at LSF/MM, we should wait with the removal until > the next LTS kernel is released. This is now determined to be 6.6, and > we just missed 6.7, so now we can aim for 6.8 and start exposing the > removal to linux-next during the 6.7 cycle. If nothing substantial pops > up, will start including this in slab-next later this week. > I agree with the decision to remove the SLAB allocator, same as at LSF/MM. Thanks for doing this, Vlastimil! And thanks for deferring this until the next LTS kernel, it will give any last minute hold outs a full year to raise any issues in their switch to SLUB if they only only upgrade to LTS kernels at which point we'll have done our due diligence to make people aware of SLAB's deprecation in 6.6. I've completed testing on v1 of the series, so feel free to add Acked-by: David Rientjes Tested-by: David Rientjes to each patch so I don't spam the list unnecessarily. I'll respond to individual changes that were not in v1. Thanks again! > To keep the series reasonably sized and not pull in people from other > subsystems than mm and closely related ones, I didn't attempt to remove > every trace of unnecessary reference to dead config options in external > areas, nor in the defconfigs. Such cleanups can be sent to and handled > by respective maintainers after this is merged. > > Instead I have added some patches aimed to reap some immediate benefits > of the removal, mainly by not having to split some fastpath code between > slab_common.c and slub.c anymore. But that is also not an exhaustive > effort and I expect more cleanups and optimizations will follow later. > > Patch 09 updates CREDITS for the removed mm/slab.c. Please point out if > I missed someone not yet credited. > > Git version: https://git.kernel.org/vbabka/l/slab-remove-slab-v2r1 > > --- > Vlastimil Babka (21): > mm/slab, docs: switch mm-api docs generation from slab.c to slub.c > mm/slab: remove CONFIG_SLAB from all Kconfig and Makefile > KASAN: remove code paths guarded by CONFIG_SLAB > KFENCE: cleanup kfence_guarded_alloc() after CONFIG_SLAB removal > mm/memcontrol: remove CONFIG_SLAB #ifdef guards > cpu/hotplug: remove CPUHP_SLAB_PREPARE hooks > mm/slab: remove CONFIG_SLAB code from slab common code > mm/mempool/dmapool: remove CONFIG_DEBUG_SLAB ifdefs > mm/slab: remove mm/slab.c and slab_def.h > mm/slab: move struct kmem_cache_cpu declaration to slub.c > mm/slab: move the rest of slub_def.h to mm/slab.h > mm/slab: consolidate includes in the internal mm/slab.h > mm/slab: move pre/post-alloc hooks from slab.h to slub.c > mm/slab: move memcg related functions from slab.h to slub.c > mm/slab: move struct kmem_cache_node from slab.h to slub.c > mm/slab: move kfree() from slab_common.c to slub.c > mm/slab: move kmalloc_slab() to mm/slab.h > mm/slab: move kmalloc() functions from slab_common.c to slub.c > mm/slub: remove slab_alloc() and __kmem_cache_alloc_lru() wrappers > mm/slub: optimize alloc fastpath code layout > mm/slub: optimize free fast path code layout > > CREDITS | 12 +- > Documentation/core-api/mm-api.rst | 2 +- > arch/arm64/Kconfig | 2 +- > arch/s390/Kconfig | 2 +- > arch/x86/Kconfig | 2 +- > include/linux/cpuhotplug.h | 1 - > include/linux/slab.h | 22 +- > include/linux/slab_def.h | 124 -- > include/linux/slub_def.h | 204 -- > kernel/cpu.c | 5 - > lib/Kconfig.debug | 1 - > lib/Kconfig.kasan | 11 +- > lib/Kconfig.kfence | 2 +- > lib/Kconfig.kmsan | 2 +- > mm/Kconfig | 68 +- > mm/Kconfig.debug | 16 +- > mm/Makefile | 6 +- > mm/dmapool.c | 2 +- > mm/kasan/common.c | 13 +- > mm/kasan/kasan.h | 3 +- > mm/kasan/quarantine.c | 7 - > mm/kasan/report.c | 1 + > mm/kfence/core.c | 4 - > mm/memcontrol.c | 6 +- > mm/mempool.c | 6 +- > mm/slab.c | 4026 ------------------------------------- > mm/slab.h | 551 ++--- > mm/slab_common.c | 231 +-- > mm/slub.c | 617 +++++- > 29 files changed, 815 insertions(+), 5134 deletions(-) > --- > base-commit: b85ea95d086471afb4ad062012a4d73cd328fa86 > change-id: 20231120-slab-remove-slab-a76ec668d8c6 > > Best regards, > -- > Vlastimil Babka > >