Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp3949074rwr; Sun, 7 May 2023 23:59:11 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4upQDOeM2cJdhkUBE0A4rThiwWHZvig1PEdN12R7qWsr2isr2f2vgWpGyGQwfoFlMqbugK X-Received: by 2002:a05:6a00:a21:b0:62a:d752:acc5 with SMTP id p33-20020a056a000a2100b0062ad752acc5mr12592844pfh.32.1683529151130; Sun, 07 May 2023 23:59:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683529151; cv=none; d=google.com; s=arc-20160816; b=bhFmpgx3lsAEORvOjNdTz2+KtMaizg9NlZAUhZhQ5+2NJw9vtq7GtNF0n/HwYCOiX1 Tu3+9bitCP+6CCyQr4W11rhijEPX03HtpbKcGWghgiCNaYMhzQYIIsvy4pwtUYhX++LH GJFY0U2Gpdx2aNua3MZerkLbTAhdw086Uw0LhJA5HSwt3migHUSAveo/u3wjLRUEY2gl A2B/w3KnqNXcsGqKe6OrKgkoOpq47VVsiUjqkybdziLT7kR+YSQ0cs2JA456A3yN0w6h 9AgsA6LOHiq9+u961o9fOXtoG+GnK74ghneBs/4jXY3O35bV1HR2ookPARt7nK/JM8Vk Tbmw== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=rcVR99SxxrcTRKdzQe8S81O5MJzdlt01YSkJ0mja9MQ=; b=iUFTEWKdlILlWJp5iARwVDqdACsM4ta8ox2Gr6CH5fRU+JrdNUWklY7bZ8esOIcBZ3 KY+uDvzmTTXOkU3i0Wnnvk+RYv97nJGMZbG0xNb7qLq300a6I0wnGN4bhJUoJ0UEV4Q1 cpNS0OKxfpTBw7qdg6gUGQWdpjFdY3oWHnOo4bLrog6tU6OvJ4rPvLL2RN518z9FmzRF gyZnGc5aBhiWcBq0txk9Xsby9xkOHOQiJJbrJhNPkkd6SKrGVao2k4g7pDWe/JBlF8aa E9x1/Kg+OQEEF/44AZwv0I3qdw7uFmJRPOvyjLeP3Tpyqc82ezKwp+3LnkaBZ9/DJTlQ Z/Qg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k64-20020a628443000000b0064387bc87cesi8167508pfd.22.2023.05.07.23.58.59; Sun, 07 May 2023 23:59:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232957AbjEHGyw (ORCPT + 99 others); Mon, 8 May 2023 02:54:52 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37116 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229577AbjEHGyt (ORCPT ); Mon, 8 May 2023 02:54:49 -0400 Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 96983A5DE; Sun, 7 May 2023 23:54:48 -0700 (PDT) Received: from dggpemm500001.china.huawei.com (unknown [172.30.72.55]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4QFBkj5rRmzpSyw; Mon, 8 May 2023 14:50:37 +0800 (CST) Received: from localhost.localdomain.localdomain (10.175.113.25) by dggpemm500001.china.huawei.com (7.185.36.107) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23; Mon, 8 May 2023 14:54:45 +0800 From: Kefeng Wang To: Andrew Morton , Mike Rapoport , CC: David Hildenbrand , Oscar Salvador , "Rafael J. Wysocki" , Pavel Machek , Len Brown , Luis Chamberlain , Kees Cook , Iurii Zaikin , , , , Kefeng Wang Subject: [PATCH 01/12] mm: page_alloc: move mirrored_kernelcore into mm_init.c Date: Mon, 8 May 2023 15:11:49 +0800 Message-ID: <20230508071200.123962-2-wangkefeng.wang@huawei.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20230508071200.123962-1-wangkefeng.wang@huawei.com> References: <20230508071200.123962-1-wangkefeng.wang@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.175.113.25] X-ClientProxiedBy: dggems704-chm.china.huawei.com (10.3.19.181) To dggpemm500001.china.huawei.com (7.185.36.107) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham 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 Since commit 9420f89db2dd ("mm: move most of core MM initialization to mm/mm_init.c"), mirrored_kernelcore should be moved into mm_init.c, as most related codes are already there. Signed-off-by: Kefeng Wang --- mm/mm_init.c | 2 ++ mm/page_alloc.c | 3 --- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/mm/mm_init.c b/mm/mm_init.c index 7f7f9c677854..da162b7a044c 100644 --- a/mm/mm_init.c +++ b/mm/mm_init.c @@ -259,6 +259,8 @@ static int __init cmdline_parse_core(char *p, unsigned long *core, return 0; } +bool mirrored_kernelcore __initdata_memblock; + /* * kernelcore=size sets the amount of memory for use for allocations that * cannot be reclaimed or migrated. diff --git a/mm/page_alloc.c b/mm/page_alloc.c index af9c995d3c1e..d1086aeca8f2 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c @@ -23,7 +23,6 @@ #include #include #include -#include #include #include #include @@ -374,8 +373,6 @@ int user_min_free_kbytes = -1; int watermark_boost_factor __read_mostly = 15000; int watermark_scale_factor = 10; -bool mirrored_kernelcore __initdata_memblock; - /* movable_zone is the "real" zone pages in ZONE_MOVABLE are taken from */ int movable_zone; EXPORT_SYMBOL(movable_zone); -- 2.35.3