Received: by 2002:a05:6602:18e:0:0:0:0 with SMTP id m14csp2391683ioo; Sat, 28 May 2022 12:10:45 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx7a74ViTiJ7NRG6yuUBVTzdV8UI3y5+MMd4dRM7vNX62wmlzd+0dgXTKfIUI56yNvUjyma X-Received: by 2002:a17:90b:4d05:b0:1e0:b53:f4a3 with SMTP id mw5-20020a17090b4d0500b001e00b53f4a3mr2914550pjb.3.1653765045350; Sat, 28 May 2022 12:10:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1653765045; cv=none; d=google.com; s=arc-20160816; b=CYwbOpvhqYof2hfFRRunHtL2MluBIEvANkO2gh2KY/PXK/K4qbXIHYIj08j13i0Sj/ T/CbhCs2QAFQuONWVwIBPLNJOCNTcRmde0ytka07jZxzxUfMHZTtBRI0cSCAhR7DxuQo cMuoN5OSFkU4D3zn3JnvdDq1fMDNWuoJnf539N7aoCtXBoUkQ4KM/YYTc2A+PODZmEN9 pVqR4kj5TKeM6Y8/WyHTLhnhV3Aqn7uqgJLrwip34jYNpQYMQSePeNK/P8nyK6wULz7Q FFiy9u19xmy4utPoVscUbV67m4/jTmIss+wg2EMZ/bQ3RBB8bs8I7k9LBKkwzMSSlQF4 IoeA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=Z1Aq17dHELJ872l+t8fXkD03dN9Wq38KxjIxdkA2X6s=; b=Ve7FFFlJX2h995bG+ueBnhe9ut8kCvLiAXyC7bzQAw5QuKOYWaGvKX2OQuQ2rP6uwA 78+xTIxiPQ38jCtNkpePDnkbuHynvJDj+IM9I5IaKFl3U93zYwBtsO4kfF0sHUuhe+Oo hRhPLH8wVOWQpYj/dSQFPD5Ek3H1ja6/vT7KgN1PIyVceYO92gNi7szxKnPmHAPSFP8Q SrV9H26xHq9UMXWkrPaPyCuffmFOs0elXqOQ8EcTqobbQPbl8eLtM+/3JsI7iw0aFc+3 xbUKIJtH9Qc/QB8phNJUIiGwiE54fo9cmwW5koyRvCEJgrSvnNeBmqdl4W56xtyMXkF8 kBtg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bytedance-com.20210112.gappssmtp.com header.s=20210112 header.b=uEnODR0k; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 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 lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id 38-20020a631566000000b003c6445e2aa0si10328768pgv.173.2022.05.28.12.10.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 28 May 2022 12:10:45 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@bytedance-com.20210112.gappssmtp.com header.s=20210112 header.b=uEnODR0k; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=bytedance.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 6211B41302; Sat, 28 May 2022 11:47:59 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242173AbiE0IUL (ORCPT + 99 others); Fri, 27 May 2022 04:20:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40096 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1349284AbiE0IUI (ORCPT ); Fri, 27 May 2022 04:20:08 -0400 Received: from mail-pf1-x42b.google.com (mail-pf1-x42b.google.com [IPv6:2607:f8b0:4864:20::42b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5AF77102771 for ; Fri, 27 May 2022 01:20:07 -0700 (PDT) Received: by mail-pf1-x42b.google.com with SMTP id c65so3186105pfb.1 for ; Fri, 27 May 2022 01:20:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bytedance-com.20210112.gappssmtp.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Z1Aq17dHELJ872l+t8fXkD03dN9Wq38KxjIxdkA2X6s=; b=uEnODR0keCyU9dqcQdNE62D84XuwSxmZfz1vsz4MRUBXf8TYXzJc9D+ZOj4mikUGqn 58dpLjjrv6LfusGiQslMj3pLvzW6F+86n9BafXIEu4OqEj8VstNSI61ovuvpYSEZ1Qea 4dEAohjprmCxAwHtIuHdaapmh364Y8EFuTDRB128YVVsObUxJoiyIZk5bTjDpUcdKAvt O8p0H5474Dk7iHftFZEirHMO6aztQecenOUpMrhA862vBILtQ8d5zx8Da9nFEsFUGPtL 7QJ5GFkarhFfZu+bYytYx/67rJ//Ef4Wh5C4qn4qD4ysRt1vDQ/TzZthTRGl0AHY9GSB rDCw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=Z1Aq17dHELJ872l+t8fXkD03dN9Wq38KxjIxdkA2X6s=; b=vTsC3HYjifke8pcB/+kCLunsJZYlbut0USyLz953zsKTQtTha2YDsNEUm5liMjYKYd 7fCz6tLc/6oaWn6UxGjEBpb5voWBBSe03Zsu/VXpXHF7Zf1XZEkZP6mxnAfpYwFfurl8 siyV/X+fhRW5zHY4ixhvCBQhgzLGTWBwq2xcS3ZQNtLNhzZA3O+116wAn/baDf0CJS4u CJDYLY/z/F1WXrWbrPGnCbguGRReEdCbZdBeugUenZ80OmtRpZXpl5OtUSugObAlPNQ3 L76c7b+nVLbxdC/D382ANXi1mxKOzp055pi6q3DRpYNneBz67ABCl3lKwlzEeOM8njwH eAkQ== X-Gm-Message-State: AOAM531pIUQPWdup2ILOVnXvNhc2ogsPFXlyckRKVG+x4zM9llhjQs0D MdPFRpxYNFrSbGuS/G9kBx0iiA== X-Received: by 2002:a63:5fcf:0:b0:3f6:298d:e2ea with SMTP id t198-20020a635fcf000000b003f6298de2eamr37127841pgb.561.1653639606843; Fri, 27 May 2022 01:20:06 -0700 (PDT) Received: from FVFYT0MHHV2J.bytedance.net ([139.177.225.238]) by smtp.gmail.com with ESMTPSA id y139-20020a626491000000b0051844a64d3dsm2865931pfb.25.2022.05.27.01.20.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 27 May 2022 01:20:06 -0700 (PDT) From: Muchun Song To: akpm@linux-foundation.org, mike.kravetz@oracle.com Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Muchun Song , Vlastimil Babka Subject: [PATCH] mm: hugetlb_vmemmap: fix CONFIG_HUGETLB_PAGE_FREE_VMEMMAP_DEFAULT_ON Date: Fri, 27 May 2022 16:19:48 +0800 Message-Id: <20220527081948.68832-1-songmuchun@bytedance.com> X-Mailer: git-send-email 2.32.1 (Apple Git-133) MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The following: commit 47010c040dec ("mm: hugetlb_vmemmap: cleanup CONFIG_HUGETLB_PAGE_FREE_VMEMMAP*") forgot to update CONFIG_HUGETLB_PAGE_FREE_VMEMMAP_DEFAULT_ON used in vmemmap_optimize_mode to CONFIG_HUGETLB_PAGE_OPTIMIZE_VMEMMAP_DEFAULT_ON. The result is we cannot enable hugetlb_optimize_vmemmap at boot time when we configure CONFIG_HUGETLB_PAGE_OPTIMIZE_VMEMMAP_DEFAULT_ON. Fix it. Reported-by: Vlastimil Babka Fixes: 47010c040dec ("mm: hugetlb_vmemmap: cleanup CONFIG_HUGETLB_PAGE_FREE_VMEMMAP*") Signed-off-by: Muchun Song --- mm/hugetlb_vmemmap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/hugetlb_vmemmap.c b/mm/hugetlb_vmemmap.c index fcd9f7872064..1089ea8a9c98 100644 --- a/mm/hugetlb_vmemmap.c +++ b/mm/hugetlb_vmemmap.c @@ -33,7 +33,7 @@ DEFINE_STATIC_KEY_MAYBE(CONFIG_HUGETLB_PAGE_OPTIMIZE_VMEMMAP_DEFAULT_ON, EXPORT_SYMBOL(hugetlb_optimize_vmemmap_key); static enum vmemmap_optimize_mode vmemmap_optimize_mode = - IS_ENABLED(CONFIG_HUGETLB_PAGE_FREE_VMEMMAP_DEFAULT_ON); + IS_ENABLED(CONFIG_HUGETLB_PAGE_OPTIMIZE_VMEMMAP_DEFAULT_ON); static void vmemmap_optimize_mode_switch(enum vmemmap_optimize_mode to) { -- 2.11.0