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 19589C6FD1D for ; Thu, 23 Mar 2023 08:25:55 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 641D26B0072; Thu, 23 Mar 2023 04:25:55 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 5F0136B0074; Thu, 23 Mar 2023 04:25:55 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4917D6B0075; Thu, 23 Mar 2023 04:25:55 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id 359A76B0072 for ; Thu, 23 Mar 2023 04:25:55 -0400 (EDT) Received: from smtpin12.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay01.hostedemail.com (Postfix) with ESMTP id 0AB231C54A4 for ; Thu, 23 Mar 2023 08:25:55 +0000 (UTC) X-FDA: 80599479870.12.720F164 Received: from mail-qt1-f169.google.com (mail-qt1-f169.google.com [209.85.160.169]) by imf08.hostedemail.com (Postfix) with ESMTP id 190ED16000D for ; Thu, 23 Mar 2023 08:25:52 +0000 (UTC) Authentication-Results: imf08.hostedemail.com; dkim=none; dmarc=none; spf=pass (imf08.hostedemail.com: domain of geert.uytterhoeven@gmail.com designates 209.85.160.169 as permitted sender) smtp.mailfrom=geert.uytterhoeven@gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1679559953; 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; bh=YLwa8WskLyA8HRsaKD+rmyXpE99G5zG0nLdln1xHQs8=; b=svo4N45QX29kVJmNv4brW/dtb8oQWX1TvJm+9Mq2IAz8rti/euodmceBQU3wiBEivVRu+T mJqgqkItTN6QrEtpUH8vDXkIdaV3+Szdwop0hQYDX3Zd65HSDFvQGeWZg9wDP3wrr582Vc BZ3KreWWrtfJkhR23YtfbxE0h4IoUw4= ARC-Authentication-Results: i=1; imf08.hostedemail.com; dkim=none; dmarc=none; spf=pass (imf08.hostedemail.com: domain of geert.uytterhoeven@gmail.com designates 209.85.160.169 as permitted sender) smtp.mailfrom=geert.uytterhoeven@gmail.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1679559953; a=rsa-sha256; cv=none; b=o9rABETOAkzuzBtOlt0LGomqHbEkAGj+vIiIvvb/nxmElgUVzb3gDBrvxEq5gb8oTDiGw4 PiuVSlFm/2OeWTXuU0aXNmeH7g84ojEhgY83NpVOWMfJW+daG4PKopa6YxaegRu/1MxPkk LuJiZ95ihbhqf5+rZZsPrmWw0tYO4M4= Received: by mail-qt1-f169.google.com with SMTP id c10so14487914qtj.10 for ; Thu, 23 Mar 2023 01:25:52 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679559952; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=YLwa8WskLyA8HRsaKD+rmyXpE99G5zG0nLdln1xHQs8=; b=6UlDYM7okTc4/0hMq1ZWH2MGe/nyL9etwH+yI+mDmoQVCnGkt7WUeZ2IqUXwfwm6do 4BYc7nCIy48Mnbr4d7CImoCiOITxmnQHcrHEXU5uKkDJaMSfHItc6tQ35jaxrHmn0iyG 34eP5uXV4wHBMMtfDWEsSr+JtPrJJZKBYnKAtnX7ryDfX1WIAbh4VMN9Xt4CrXqnHUVT BRVJln44BHl+wJ4Qzi5LVH4gQa8h263oD1JvZfnGF722j+vTtnRwLvA59NrvZ/2Bzd+k W29h8OaONw+mRcG8YyURFI4LWB3nf1NRHxRo99Ue2HOkX91nH2anOFpv7zc8Yf4vkthr 7pnA== X-Gm-Message-State: AO0yUKUeAkzxrXUV55cEEKmrY89hEP0JsXL/g5G2BwO/A2B/c8UqArLf B0G+jnblzh00dHe4A1CptDNZnSu5coNxvA== X-Google-Smtp-Source: AK7set84snUu2IAJPREdmhJvXGBIpyG3xDq/Jc4jWo5k3GV9tnO3nnJNb6y4fjyRqYMV16zeRfrjag== X-Received: by 2002:ac8:5bc1:0:b0:3d4:205e:be4e with SMTP id b1-20020ac85bc1000000b003d4205ebe4emr8513231qtb.13.1679559951829; Thu, 23 Mar 2023 01:25:51 -0700 (PDT) Received: from mail-yw1-f182.google.com (mail-yw1-f182.google.com. [209.85.128.182]) by smtp.gmail.com with ESMTPSA id 66-20020a370b45000000b0071eddd3bebbsm4540604qkl.81.2023.03.23.01.25.50 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 23 Mar 2023 01:25:50 -0700 (PDT) Received: by mail-yw1-f182.google.com with SMTP id 00721157ae682-544787916d9so382339687b3.13 for ; Thu, 23 Mar 2023 01:25:50 -0700 (PDT) X-Received: by 2002:a81:4424:0:b0:52f:184a:da09 with SMTP id r36-20020a814424000000b0052f184ada09mr1197947ywa.2.1679559949876; Thu, 23 Mar 2023 01:25:49 -0700 (PDT) MIME-Version: 1.0 References: <67261c513706241d479b8b4cf46eb4e6fb0417ba.1679387262.git.geert+renesas@glider.be> <6320abf6-0898-361b-d5f6-bcc58306f55c@intel.com> In-Reply-To: From: Geert Uytterhoeven Date: Thu, 23 Mar 2023 09:25:37 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] mm/slab: Fix undefined init_cache_node_node() for NUMA and !SMP To: Matthew Wilcox Cc: Dave Hansen , Dave Hansen , Arnd Bergmann , Christoph Lameter , Pekka Enberg , David Rientjes , Joonsoo Kim , Andrew Morton , Vlastimil Babka , Roman Gushchin , Hyeonggon Yoo <42.hyeyoo@gmail.com>, John Paul Adrian Glaubitz , linux-mm@kvack.org, linux-sh@vger.kernel.org, linux-kernel@vger.kernel.org, Randy Dunlap Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Rspam-User: X-Rspamd-Server: rspam04 X-Rspamd-Queue-Id: 190ED16000D X-Stat-Signature: x7ykz1rcdn5rofutmtzupei878mk4dqt X-HE-Tag: 1679559952-27768 X-HE-Meta: U2FsdGVkX19hsAo7BtGzoC6Ueav1p8pQR772+ajQlEJIxA9jfde4xwNK4HalwqUSGlsrlI7xWCy5D4+0xtYMJ+W2PhOIOocBK3aWWZNqxDOelbb9JwDYYtL7Z3HLi/vdlsYnNhghDzQh9CvbxiDuV98tJId9bhZo3GC5zcALD3HZq7VliOYBLITfJlA+gvSnPaefCv/KE6WX7t3K3CVojvYtihZQntuIxmMnpSXnwQeC6cgXHsgZWiyQ5mpEYrnijEcRTdMLk8bofqI6iFU8vDt4YdzDWsXl4vo6TZ2AMdYosFJ0GKpakWnqT/6YxSQL6xlbfRL7OZcwqFi2voieTxBch/Mjl1T5cDpcXPzMth42Oc5ylZ+zBM5bYtzRTiRVCrotIy0qoapyDcLTNqFrFlKXDFuSJP/5VlhKXFNGvE2pPy03mfDB+O0OTsxBEnp3yS1jcvmIslMl2p5dbvzxFrZLiP06TB7ohSk72kRzWwJ6a2+Nj8hnw8aDe3Tzmc+jtEtpisHxnskDjGefXj6GER1DCh4OY5RUyy+5HWHVlb3K82xmrJ1t3TJjIc/plwKNQVVEsEDTtGo4BqW9DAR5xXUJck+DIVB7p2aDQ4tDX5EsfhzySCKIdhvryMDxQOBZAPz6Vwmscln+B4fS8YSvHUOqi6bi5aXhpAWRe1TPRHfTADjHf6jkGus6cFKTEWavRbwI47dUapAtVOVPgJjL8HYmJVfFq//Nglv57/c1Hw2Hi68qKlRsUMkHqoRwJFuTUvbMHvtA0OJ+NZe8vJHBIFXdMjklkZqX+aGrfS6Pa+vAWfaAc77olILCOc+ipZWd4vKtUwhWGtTEo+vwED2h6NLE8BsW0vawXeodx3jibMN0C8/9xlglt7TWc083JBJ13s6WPxeyK1mDZ8xWbYoiL8G4Vv3ZnoYBw01LX8gtzqfOSbmvqQiYdaAD+Irvw0NsqMTEUuBo6MKrOP64owd vnvLkrWZ 4Mi4IfCfmbMGvq7vTiHXfYyBcitN+vNKEUeDe6GoTDhFEh8/nFnnCQzgvTJz/Zknj/0qCVSbcVyLqE7ydNwTzWX2p8BRQHn96Ijpa0qJioOoZWjb1fBTjzEgcsDWHZNPdcSFz5NOQpqdhAhXRLOKTu2sEVkrmYmfy/abx1hd8zlFziKlY+Nw2stkUxVnEtiT82niJtx7V5TR+fyzMe62I8206A8SnyhN7VpcE7eUb9lujF3h96l4o+DDSjtK1UB5a0WhOVYioP/oF/ntRLazqR0JkQsrOWK1xmV9Dj1RjfD98PanK2saOQ+YjHXStRkmHWo7P+UtuC4iOvYufRRF/zDhurtiZcBy6zEQLtdTzTP3axOXvZHtF4rDBwk0WoEoMEhK2/e9wC8jVP0S2arHyKuFYz5gA76xq4E5Pkhf2B0YEHNs89fW3LGWIwCbVU7LeowvwaoatDJabGNCGcAppnhHlWRJf63DvybZdRJpHA76d3827eYUb/povCikt0tTtabYuUZR75WQhyp5c6aluWiJIDsAT8YLnsSCU3gnkZppHq1Bbwu0nizJK71+6sbeLoggYuCo92AB/pOGAeEl88qDNfhOdu/VdyS6CRkbwNGC6R1i0ihYJ5TflpF6m3a037LEj4OlllsS1b22zDKTgtJ5YK4f6jYJOtEsxE+KABxi8x52HOWCJKHR5itumDp6n9jhg 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: Hi Matthew, On Wed, Mar 22, 2023 at 5:47=E2=80=AFPM Matthew Wilcox wrote: > On Wed, Mar 22, 2023 at 09:16:55AM -0700, Dave Hansen wrote: > > On 3/21/23 09:40, Matthew Wilcox wrote: > > > On Tue, Mar 21, 2023 at 09:30:59AM +0100, Geert Uytterhoeven wrote: > > >> -#if (defined(CONFIG_NUMA) && defined(CONFIG_MEMORY_HOTPLUG)) || def= ined(CONFIG_SMP) > > >> +#if defined(CONFIG_NUMA) || defined(CONFIG_SMP) > > > I'm amused by the thought of CONFIG_NUMA without CONFIG_SMP. > > > Is it possible to have one node with memory and a single CPU, then > > > another node with memory and no CPU? > > > > It's _possible_ for sure, just unlikely. The most likely place these > > days is probably a teensy tiny VM that just happens to have some > > performance-differentiated memory exposed to it for some reason. Maybe > > it's got a slice of slow PMEM or fast High-Bandwidth memory for whateve= r > > reason. > > Right, you can construct such a system, but do we support the CONFIG > options of NUMA enabled and SMP disabled? It seems so niche that we > shouldn't be spending time testing that combination. SH has been using this for a long time. It's supported. Dave just forgot to update the #ifdef around the definition of init_cache_node_node() when updating an #ifdef around a code block that contains one of the callers. P.S. To me, this discussion reminds me of the old discussion about discontigmem without NUMA. Yes, not all systems are PCs with contiguous memory on a single fast bus ;-) Gr{oetje,eeting}s, Geert --=20 Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k= .org In personal conversations with technical people, I call myself a hacker. Bu= t when I'm talking to journalists I just say "programmer" or something like t= hat. -- Linus Torvalds