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 X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id BD952C433B4 for ; Wed, 21 Apr 2021 09:07:00 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 1A231600D1 for ; Wed, 21 Apr 2021 09:07:00 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1A231600D1 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=bytedance.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 7EF576B006C; Wed, 21 Apr 2021 05:06:59 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 7C6476B006E; Wed, 21 Apr 2021 05:06:59 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 667926B0070; Wed, 21 Apr 2021 05:06:59 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0185.hostedemail.com [216.40.44.185]) by kanga.kvack.org (Postfix) with ESMTP id 4BECC6B006C for ; Wed, 21 Apr 2021 05:06:59 -0400 (EDT) Received: from smtpin20.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id 0E2F32C88 for ; Wed, 21 Apr 2021 09:06:59 +0000 (UTC) X-FDA: 78055794558.20.6E5A430 Received: from mail-pf1-f177.google.com (mail-pf1-f177.google.com [209.85.210.177]) by imf04.hostedemail.com (Postfix) with ESMTP id 3A94A3C2 for ; Wed, 21 Apr 2021 09:06:56 +0000 (UTC) Received: by mail-pf1-f177.google.com with SMTP id i190so28131764pfc.12 for ; Wed, 21 Apr 2021 02:06:58 -0700 (PDT) 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; bh=z+iHXh65iVvo4np4Gau+UG0A6fVjF6OF4qe3iW5dlBQ=; b=cKRTNiweZv1CB+TmPXTHEuk/D3q6KRWbOYv26a5/nnRcbXbBa4sRinHzaZqlDw8IPK V26zl43Ll4ob/dxArZPWyA4qOpnJxPJk8DjZuABCkaNyS8O8ZsjefM98zQ/WDfNoXHjw I9Y4Jb7szrqvY1AsKwIGCc+RpKJHRvfXrbtzOpClqU2kr3qEvAJAWqK7aiwM4w7pEYAc N9/GDBfvk/vlEZcV/aayCTXvn5DmtTALGlTwJ2lRrwaZkNLn5ePUmFlVzUMAmu4Dvv9t LOWZ6CH+NAODFuCCxob1MO+H9YWAbW1/x6xFI+jX3V8c4KE39RF6vvG/gEqKUp5c5WK6 f8vA== 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=z+iHXh65iVvo4np4Gau+UG0A6fVjF6OF4qe3iW5dlBQ=; b=hvsQhJJM+VCvdldkY5fuosEg+gCiv1Zh0Dn3FEWsi4EHOJfEvDj6+EHSwI0o5l798l s77DAVxsRK0qNAIzpO4maXxkX+wkFSkf4eQOJcrSvPSrT6nCblzkj2hlpYfy2fv00ym8 Zxqv3TMcLTa0/nodXU1f+8Bs9NszsMhj8cpULjPbWSdBQmPoQAN06eeTsGrPlwWTR70A 2oTewtRxbG2y2lsKcQylJlOjbclZhb8KdToXWt2XboplbDn5x2JgXr7hCrM0tDViWsMD XnRE5rtWXAu3aZeHu0MS/AbHm/YCBXnFBGYwXCqCThWXsRHibJa2A0kmSgP5bWoBhT4y 0C+g== X-Gm-Message-State: AOAM532xr+394BoJ+ZFG1/k3lpEXHpGbFIrfEF73Ps7BvDifNRWVh/Mq hG7/XucLz1yrnWqIXiK4WyaYlEXhjn/REx7l61sa5w== X-Google-Smtp-Source: ABdhPJzKNN7n6cCYVH22d3weYBRKCJ+tLw5cB/f+qRUy/RycEPUVGIGD6d0QfahjlqPmJZLfex7L+sVrp7mhdjHX1iA= X-Received: by 2002:a63:1665:: with SMTP id 37mr21367832pgw.31.1618996017511; Wed, 21 Apr 2021 02:06:57 -0700 (PDT) MIME-Version: 1.0 References: <20210415084005.25049-1-songmuchun@bytedance.com> <20210415084005.25049-9-songmuchun@bytedance.com> <20210421073346.GA22456@linux> In-Reply-To: <20210421073346.GA22456@linux> From: Muchun Song Date: Wed, 21 Apr 2021 17:06:20 +0800 Message-ID: Subject: Re: [External] Re: [PATCH v20 8/9] mm: memory_hotplug: disable memmap_on_memory when hugetlb_free_vmemmap enabled To: Oscar Salvador Cc: Jonathan Corbet , Mike Kravetz , Thomas Gleixner , Ingo Molnar , bp@alien8.de, X86 ML , hpa@zytor.com, dave.hansen@linux.intel.com, luto@kernel.org, Peter Zijlstra , Alexander Viro , Andrew Morton , paulmck@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 , Michal Hocko , "Song Bao Hua (Barry Song)" , David Hildenbrand , =?UTF-8?B?SE9SSUdVQ0hJIE5BT1lBKOWggOWPoyDnm7TkuZ8p?= , Joao Martins , Xiongchun duan , fam.zheng@bytedance.com, linux-doc@vger.kernel.org, LKML , Linux Memory Management List , linux-fsdevel Content-Type: text/plain; charset="UTF-8" X-Rspamd-Server: rspam01 X-Rspamd-Queue-Id: 3A94A3C2 X-Stat-Signature: wg6rkc3szo5q65d9dyny5d6aypwwhc9h Received-SPF: none (bytedance.com>: No applicable sender policy available) receiver=imf04; identity=mailfrom; envelope-from=""; helo=mail-pf1-f177.google.com; client-ip=209.85.210.177 X-HE-DKIM-Result: pass/pass X-HE-Tag: 1618996016-919561 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: On Wed, Apr 21, 2021 at 3:33 PM Oscar Salvador wrote: > > On Wed, Apr 21, 2021 at 11:41:24AM +0800, Muchun Song wrote: > > > Documentation/admin-guide/kernel-parameters.txt already provides an > > > explanation on memory_hotplug.memmap_on_memory parameter that states > > > that the feature cannot be enabled when using hugetlb-vmemmap > > > optimization. > > > > > > Users can always check whether the feature is enabled via > > > /sys/modules/memory_hotplug/parameters/memmap_on_memory. > > Heh, I realized this is not completely true. > Users can check whether the feature is __enabled__ by checking the sys fs, > but although it is enabled, it might not be effective. Right. I have done the test. > > This might be due to a different number of reasons, vmemmap does not fully > span a PMD, the size we want to add spans more than a single memory block, etc. Agree. Thanks for your explanations. > > That is what > > "Note that even when enabled, there are a few cases where the feature is not > effective." > > is supposed to mean. > > Anyway, I did not change my opionion on this. > > Thanks > > -- > Oscar Salvador > SUSE L3