Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp10225167imu; Wed, 5 Dec 2018 19:08:35 -0800 (PST) X-Google-Smtp-Source: AFSGD/UBGMd2tFMNQHo/vByEQXYDqU2o+aDdcv22xiBqcyyIlxNgZZZ7aPdffzFS27/vn12msOpw X-Received: by 2002:a62:18ce:: with SMTP id 197mr27981658pfy.88.1544065715244; Wed, 05 Dec 2018 19:08:35 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1544065715; cv=none; d=google.com; s=arc-20160816; b=b2LepWH2aVBTAUyZRGDk4sKsm3ZCJKg2AhlqQFydyRiIOdKqqp6Ncei6HcoTdNwu+e qJszw5g5KHYdZL16EzrcrnpRbhLSxR8kYQBHRa+K0HAzW4MWqjHt/Kjob9YdtZgFSquA Dtm5h1t2Q4EsRD7J6i1qkeilTfijSUSWLILcjWNI9+tbzk+Q05O4Wf38iCNBBsutkCze E3rahCqqblMDwlgWsZ8TnewPJyuOs8mIj07In0Z+Lax1V7jzjE+0B9Cmw4b9LdYJPgkr d0nRb5jhGeqRyskpVCwBN4HTEHiFq0NX+zgo3LJ3Oi7EfcJ5yoN4ywUDWA7xTz6KHATW GnuA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=duaU23knQ88/JeQ9XKeIbq22/brl1MX2UJZiXJq07To=; b=R3D5xld7Pms+zQXnDxbLG5Y0TWnaa9CYsmwux08kn7wwc7lXK4MYLlTfM7y5AsFxwX 8s60Ke8IRJiHjrfjzP0+OOykF0E8CzZInOWMXzU6JX5u7rz3c6mZKqy3GUEacvr1IQ/L 9fP72TvobRkakojgK4XsaQ1uBFUyHhXZMiasJXb0CF1PcNs1QBYPef1pJK+1N6TLeJKK LDAhrgWba+Q9HqC15aebMTEtNgP5QPhgy5bU/u0ZlUTKEsmnxadrJB5O4E+TE473MCKY hmb1986+KNQQL8fAnwC5R1BGzdfcnvlnycJEUC4nFnfbp0jxsv9jyz7Sf7RFuppmNtLK mD0g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=lLRu8TFV; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id cd2si24542308plb.39.2018.12.05.19.08.19; Wed, 05 Dec 2018 19:08:35 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=lLRu8TFV; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728546AbeLFDHr (ORCPT + 99 others); Wed, 5 Dec 2018 22:07:47 -0500 Received: from mail-ed1-f68.google.com ([209.85.208.68]:42778 "EHLO mail-ed1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727695AbeLFDHr (ORCPT ); Wed, 5 Dec 2018 22:07:47 -0500 Received: by mail-ed1-f68.google.com with SMTP id j6so18807397edp.9 for ; Wed, 05 Dec 2018 19:07:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=duaU23knQ88/JeQ9XKeIbq22/brl1MX2UJZiXJq07To=; b=lLRu8TFV6kzb4NkJw4tuddMmks1Ud4njuauTYV6b3Ihkr5QvSafjlHhioCw2iOQMEn tVOMCbyhyNXbx8WW1quvwwSi4omVAupOKjIMSGgZtlrgvFVRQqp3MphEV81Tl+xOsWju ZrGcIGv18s5IZAFF0Hp4KYMDrmkPtuywOebMGLI3+RpQ+MXEFWwPEZqd5ysts7L31E2d Z0fNbHG27lFawIBd+2X/6mGfSmn1uQHOe3yOJR1lGlVQuV8jJRgQkui3O6INscFbIRZn 8t2DEiyzDvY3OPEiYSXpnKwKBsYqjVXSKsWG+99lCZBUL9y9WOxISynne8awuvFsFwjS eUcQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=duaU23knQ88/JeQ9XKeIbq22/brl1MX2UJZiXJq07To=; b=J6IoTI6NEJg6L2aQcl0G0m9QpDL9IIC9ug6ApCGUX95JvEaSI0KxnCla9dlQBh/ZBB 0lpAaVOGqXX1MUHMtiQFg/juKp/02hqJ3REYYlIDGeGFPjXbDgTBogTSx8UowP4I39DG 509GBf2S4RzLMfIZDgV0e2o9UKRQDX0TAsNwGRrwgPheAz0l81DDijLBq/HbtFj/M/Ue jmVbs31y/7h3XqKLxHbPPOyjXH+hJUKW3GItrmJF0qRrmuvZA2+5k0fxkLG/aF+lXLUF QB3uugqCFntGdonGwpfKx+E9Ot7dmrM3jaW9BKCnLIXK96J3HzLzPHUIqtFwq4cjK0SG M0fQ== X-Gm-Message-State: AA+aEWY0+Ch1GjxvfmvAmSpSy+9gRtfDSj3S6zlnwx+tzp1jSGFtausZ LoIaqUtXQd/OE++Pefwy+QFDFxZTzyX0rFk62A== X-Received: by 2002:a17:906:2acf:: with SMTP id m15-v6mr20117364eje.180.1544065665329; Wed, 05 Dec 2018 19:07:45 -0800 (PST) MIME-Version: 1.0 References: <1543892757-4323-1-git-send-email-kernelfans@gmail.com> <20181204072251.GT31738@dhcp22.suse.cz> <20181204085601.GC1286@dhcp22.suse.cz> <20181205092148.GA1286@dhcp22.suse.cz> <186b1804-3b1e-340e-f73b-f3c7e69649f5@suse.cz> In-Reply-To: <186b1804-3b1e-340e-f73b-f3c7e69649f5@suse.cz> From: Pingfan Liu Date: Thu, 6 Dec 2018 11:07:33 +0800 Message-ID: Subject: Re: [PATCH] mm/alloc: fallback to first node if the wanted node offline To: Vlastimil Babka Cc: mhocko@kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Andrew Morton , Mike Rapoport , Bjorn Helgaas , Jonathan Cameron Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Dec 5, 2018 at 5:40 PM Vlastimil Babka wrote: > > On 12/5/18 10:29 AM, Pingfan Liu wrote: > >> [ 0.007418] Early memory node ranges > >> [ 0.007419] node 1: [mem 0x0000000000001000-0x000000000008efff] > >> [ 0.007420] node 1: [mem 0x0000000000090000-0x000000000009ffff] > >> [ 0.007422] node 1: [mem 0x0000000000100000-0x000000005c3d6fff] > >> [ 0.007422] node 1: [mem 0x00000000643df000-0x0000000068ff7fff] > >> [ 0.007423] node 1: [mem 0x000000006c528000-0x000000006fffffff] > >> [ 0.007424] node 1: [mem 0x0000000100000000-0x000000047fffffff] > >> [ 0.007425] node 5: [mem 0x0000000480000000-0x000000087effffff] > >> > >> There is clearly no node2. Where did the driver get the node2 from? > > I don't understand these tables too much, but it seems the other nodes > exist without them: > > [ 0.007393] SRAT: PXM 2 -> APIC 0x20 -> Node 2 > > Maybe the nodes are hotplugable or something? > I also not sure about it, and just have a hurry look at acpi spec. I will reply it on another email, and Cced some acpi guys about it > > Since using nr_cpus=4 , the node2 is not be instanced by x86 initalizing code. > > Indeed, nr_cpus seems to restrict what nodes we allocate and populate > zonelists for. Yes, in init_cpu_to_node(), since nr_cpus limits the possible cpu, which affects the loop for_each_possible_cpu(cpu) and skip the node2 in this case. Thanks, Pingfan