Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp4735254iob; Sun, 8 May 2022 23:42:14 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx1A441zCcF/FK5tGZXIJZVZ/f4EvII8V9iuER+4BjKdM7giXcjyPaDExSSJnuIDtAlBflL X-Received: by 2002:a17:90b:1d03:b0:1dc:db97:942c with SMTP id on3-20020a17090b1d0300b001dcdb97942cmr15708448pjb.238.1652078534456; Sun, 08 May 2022 23:42:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652078534; cv=none; d=google.com; s=arc-20160816; b=Q1i3MYTo5M7hJ/EfhCY+0huF4ECDGpLFG4gcNO8GPQAnw+nlllKjjWxo5dRqQQ8b12 ZH/rKUsWR2AXoPr/+778USIZXX+gE7SohYJd4So2cNtIsBshTPH2i7nE1O0s9qNz2VJw VSMqWzpTpZ2wmHZKm2kaGRAzg0r26lWMWDPt6JNwbPBJJgmgSCwREzLZaYJ7Gp4MUrbR Ppp+prc5ngj5TcrycFQ08GOQ80Vl5M7+MOdOQRVbmnNj4KPMAdHi6XOGan5lYaYYP4yy X0lbJ7n/WsWU/nYlKcgXSAlcZOHsmZgDLQWu5N75EJWvsrZ5I61ftER6Hgs6AJXagnhj hwCg== 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 :dkim-signature; bh=mUybj7H/UOKVedWyWATy5/DDOeXg+iw2T9QAXkaf4Ko=; b=OxMGzc7RM2OIeIaxizuMBhrzERFaIYL/abewmM+EKbVgROBm3Ftf7hFljKJX/0zDti cQRK+S178j9HH0SXbgUzGjXjvzEGEBkXd1x8KAmiL0Rr686SlK9lUdDQlZsA1O5wivnu kvLQbTCQYwjv1RtIpsZ6j7bhfdM9y5Oyaz5TpjcRhyAxrpnu8xoPpvGv3ssMEHk8ayB3 JxpDguLkU2ifF/NnXtNYrcHM8svGA2Xv0IaF2ODCRsNzJHV7ywn+tlbbYZsRm46zTWpE WP3pE0UfzscLh3g18uzIKcyvAXKWwqFDl3ldf6QyjyPKCcBshstVNAYS6kbGrygqciNQ 3QfA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=mdPAo0t5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id v22-20020a636116000000b003ab243f2064si13037000pgb.556.2022.05.08.23.42.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 08 May 2022 23:42:14 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=mdPAo0t5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 8A3D7191E43; Sun, 8 May 2022 23:40:04 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235508AbiEHQU0 (ORCPT + 99 others); Sun, 8 May 2022 12:20:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38996 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235510AbiEHQUY (ORCPT ); Sun, 8 May 2022 12:20:24 -0400 Received: from sin.source.kernel.org (sin.source.kernel.org [145.40.73.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0B393B1C2 for ; Sun, 8 May 2022 09:16:33 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sin.source.kernel.org (Postfix) with ESMTPS id 6D059CE0F0B for ; Sun, 8 May 2022 16:16:31 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id BCB75C385A4; Sun, 8 May 2022 16:16:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1652026589; bh=cai4u5JKDr1cLjhdt9yaycCa4Y3iBnxfkpZjmnNWcVw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=mdPAo0t5mrvr4GmAHEi7fUpzOr52OdPOdTfvMG2GDQeOpWO4nWnz+BT8ei8S8bldv KGF56HqI6nCm50Jia/awUHAqUlXLc5KirY9OTAv+cDqV+3VHJOJNG66cS9GlDqP5wP l4+sOr1tt2o3b7/L6ifGSp7h0MxMkLSy9wfI8RXXzx5TJtIaSd8MK8o9VM+DXOt7xy Po0SUd/H6NhU4PshiM8nAIBCnU85lUhGkdQXtmz5iY5gMnEkGC3VQTcQBPLoRKq/D9 bESc0bsVD7erCPt7hJGlgaoO0YbJUdtISbpRRey/rCYsW+7jIV+hrrQTGz/IPqvvYI biSZhsinVL0Rg== From: Jisheng Zhang To: Paul Walmsley , Palmer Dabbelt , Albert Ou , Andrey Ryabinin , Alexander Potapenko , Andrey Konovalov , Dmitry Vyukov , Vincenzo Frascino , Alexandre Ghiti Cc: linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, kasan-dev@googlegroups.com Subject: [PATCH v2 1/4] riscv: mm: init: make pt_ops_set_[early|late|fixmap] static Date: Mon, 9 May 2022 00:07:46 +0800 Message-Id: <20220508160749.984-2-jszhang@kernel.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220508160749.984-1-jszhang@kernel.org> References: <20220508160749.984-1-jszhang@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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 These three functions are only used in init.c, so make them static. Fix W=1 warnings like below: arch/riscv/mm/init.c:721:13: warning: no previous prototype for function 'pt_ops_set_early' [-Wmissing-prototypes] void __init pt_ops_set_early(void) ^ Signed-off-by: Jisheng Zhang --- arch/riscv/mm/init.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/riscv/mm/init.c b/arch/riscv/mm/init.c index 05ed641a1134..5f3f26dd9f21 100644 --- a/arch/riscv/mm/init.c +++ b/arch/riscv/mm/init.c @@ -849,7 +849,7 @@ static void __init create_fdt_early_page_table(pgd_t *pgdir, uintptr_t dtb_pa) * MMU is not enabled, the page tables are allocated directly using * early_pmd/pud/p4d and the address returned is the physical one. */ -void __init pt_ops_set_early(void) +static void __init pt_ops_set_early(void) { pt_ops.alloc_pte = alloc_pte_early; pt_ops.get_pte_virt = get_pte_virt_early; @@ -871,7 +871,7 @@ void __init pt_ops_set_early(void) * Note that this is called with MMU disabled, hence kernel_mapping_pa_to_va, * but it will be used as described above. */ -void __init pt_ops_set_fixmap(void) +static void __init pt_ops_set_fixmap(void) { pt_ops.alloc_pte = kernel_mapping_pa_to_va((uintptr_t)alloc_pte_fixmap); pt_ops.get_pte_virt = kernel_mapping_pa_to_va((uintptr_t)get_pte_virt_fixmap); @@ -889,7 +889,7 @@ void __init pt_ops_set_fixmap(void) * MMU is enabled and page table setup is complete, so from now, we can use * generic page allocation functions to setup page table. */ -void __init pt_ops_set_late(void) +static void __init pt_ops_set_late(void) { pt_ops.alloc_pte = alloc_pte_late; pt_ops.get_pte_virt = get_pte_virt_late; -- 2.34.1