Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp5551547pxb; Tue, 16 Feb 2021 01:07:56 -0800 (PST) X-Google-Smtp-Source: ABdhPJxN/sG/A7we8ydpggJ27GVG3PCVRtloIV6iytEo8vVOWire66jKHmMyM2RY6tGOlVKq18q+ X-Received: by 2002:a17:906:380b:: with SMTP id v11mr7887638ejc.183.1613466475908; Tue, 16 Feb 2021 01:07:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1613466475; cv=none; d=google.com; s=arc-20160816; b=lH3UicU4CF8P0ORIDfjOA60GhCpzbqDnVFDH+DBbvpUkVSrxx24xBXQOnWznzGYrts esdFA97DRJC4Vwd6IrPblg1vPaRPc1uiL1wIEKlEgOcVaHXjZEbXXfa/riOhJtNR70Qm w21hd3eFUUQiUtOFkyz9tLKhLZuFiAANcdPugJ1qUY5eF2zdns0ndFXnD2CwCqSEE7uh IvWmbyz10ic5xdpEZikTXu74ZPpN7PdCDBtyy1r3C8nnLU7s8T2KA0Ud1lEP2paI8tTh vCwCvPioW6jjhIs2hAr3aZXNLB5ivj9UKuQHkbpUWqfU4sKI2AHNF8QAgugdTkd/GmZp HjTg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=Hix40Xj1oUuEJXyWgpErtznzZizVsi/XpFAKnYjHmQY=; b=R2JT92vPOC5/2mxgld98OvqwA8LPTLefZBDORs8pKuRDiB8DRJoXgNA1wK1z/gl7k1 LBaoGqo8jqPvQRWAM5FTVrIv5YIQ3mxFr4aapOSgTVnr1Eif5jThnK+8134UIAeB7F25 ctYFZk9kPwZbbiUyOWyLVtqlX0GkMa7DxMJIzBPCnpFGbwvFID621fDqfRqYUdE1YiWx MDMsQVe33tVLgJNcs1x1JR+hu1BGe5yuDXqGQEGaCIIVuwXX6g/uf+gnWURzCTnTOkyy R7anjBiZvrQsXfSCO21kBSxRUsm9uymScHTX0ku1CwFghgva+R6wgKc2qqjjaGxrm06O MkHQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bytedance-com.20150623.gappssmtp.com header.s=20150623 header.b=eCXmzNSb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=bytedance.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id l6si11943355ejd.115.2021.02.16.01.07.33; Tue, 16 Feb 2021 01:07:55 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@bytedance-com.20150623.gappssmtp.com header.s=20150623 header.b=eCXmzNSb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=bytedance.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229988AbhBPJGD (ORCPT + 99 others); Tue, 16 Feb 2021 04:06:03 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38736 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229754AbhBPJGA (ORCPT ); Tue, 16 Feb 2021 04:06:00 -0500 Received: from mail-pl1-x62e.google.com (mail-pl1-x62e.google.com [IPv6:2607:f8b0:4864:20::62e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 54774C06178B for ; Tue, 16 Feb 2021 01:04:19 -0800 (PST) Received: by mail-pl1-x62e.google.com with SMTP id z7so5141279plk.7 for ; Tue, 16 Feb 2021 01:04:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bytedance-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=Hix40Xj1oUuEJXyWgpErtznzZizVsi/XpFAKnYjHmQY=; b=eCXmzNSbiTk7i4WkXniq28m9G37QrlWzW+DY39V8ZNK5WTP7spj9JBNl/75AUeXslS pJixcJGyqDLo4/gX0Lkr+1LUgrtreYH6pDPPHtbPLnLkeQx/1x9tDVzu0zNv77WPe+uF QM23Y4vse2SXdXjhaYvzlAGwnbVJnKqbsBbszex9XCw8oV+SmfE5m6RQXxoFgr5eVZn/ qINrIHGW1sADmAiL0WIfXKeZ8p6SxtIV13mV/bwjr35huaocQRV4X7kDW1oPkdZE79ZV Nbja5Hzu2TLV6H4VkmcjRP+LCxUc2OcC22SZjbz8IJ8OdTlvir4xzCcY9KhtszgDIiwM fSOg== 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:content-transfer-encoding; bh=Hix40Xj1oUuEJXyWgpErtznzZizVsi/XpFAKnYjHmQY=; b=JG1jXtjjy6Ynn/pJ4KXTT++kZE7PcpvzHKS2+MlybVavxHZx2hJZ5dPbQRW1a7IHgB yEeB38o97dsHnJ0Riv0DviINmBgHc/VNiG73X1JNreo8/QiYZ7fobginHqPk1VEB+N3k Z/r7+j1ASW6IpdwksyY82Z/f612DO7TczJ+wqwWx9bgsLgF6mQg3G5ThsnzCOesjLPqy XOFYAIxO9R+OtdvWE83E7rElr4ofIl+vQC5d8bhQuotO9JpmzM3ifjWRg5hupOeIHXw5 1fSPI+226SMFgjS7ceFB/U/eOss2Xdhe7qFkeLaVnDJ7RWJaRbGMu+ln4mwNdMgNKDEx p7wQ== X-Gm-Message-State: AOAM533i23qqLUTrirCY5DIsAiyXhO3ityjpA4km1RyXg4Q8chc+PHcz Lar17cUTihapRu8ljpOXjv6+KAVKIN7pgI9BQJakmA== X-Received: by 2002:a17:90b:286:: with SMTP id az6mr1469474pjb.147.1613466258888; Tue, 16 Feb 2021 01:04:18 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Muchun Song Date: Tue, 16 Feb 2021 17:03:42 +0800 Message-ID: Subject: Re: [External] Re: [PATCH v15 4/8] mm: hugetlb: alloc the vmemmap pages associated with each HugeTLB page To: Michal Hocko Cc: Jonathan Corbet , Mike Kravetz , Thomas Gleixner , mingo@redhat.com, bp@alien8.de, x86@kernel.org, hpa@zytor.com, dave.hansen@linux.intel.com, luto@kernel.org, Peter Zijlstra , viro@zeniv.linux.org.uk, Andrew Morton , paulmck@kernel.org, mchehab+huawei@kernel.org, pawan.kumar.gupta@linux.intel.com, Randy Dunlap , oneukum@suse.com, anshuman.khandual@arm.com, jroedel@suse.de, Mina Almasry , David Rientjes , Matthew Wilcox , Oscar Salvador , "Song Bao Hua (Barry Song)" , David Hildenbrand , =?UTF-8?B?SE9SSUdVQ0hJIE5BT1lBKOWggOWPoyDnm7TkuZ8p?= , Joao Martins , Xiongchun duan , linux-doc@vger.kernel.org, LKML , Linux Memory Management List , linux-fsdevel Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Feb 16, 2021 at 4:15 PM Michal Hocko wrote: > > On Tue 16-02-21 12:34:41, Muchun Song wrote: > > On Tue, Feb 16, 2021 at 3:39 AM Michal Hocko wrote: > [...] > > > > Using GFP_KERNEL will also use the current task cpuset to allocate > > > > memory. Do we have an interface to ignore current task cpuset=EF=BC= =9FIf not, > > > > WQ may be the only option and it also will not limit the context of > > > > put_page. Right? > > > > > > Well, GFP_KERNEL is constrained to the task cpuset only if the said > > > cpuset is hardwalled IIRC. But I do not see why this is a problem. > > > > I mean that if there are more than one node in the system, > > but the current task cpuset only allows one node. > > How would that cpuset get a huge pages from a node which is not part of > the cpuset? Well, that would be possible if the cpuset was dynamic but I > am not sure that such a configuration would be very sensible along with > hardwall setup. Got it. I didn't realize this before. Thanks. > > > If current > > node has no memory and other nodes have enough memory. > > We can fail to allocate vmemmap pages. But actually it is > > suitable to allocate vmemmap pages from other nodes. > > Right? > > Falling back to a different node would be very suboptimal because then > you would have vmemmap back by remote pages. We do not want that. > -- > Michal Hocko > SUSE Labs