From nobody Mon Dec 29 00:36:53 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id AA970C4167B for ; Mon, 4 Dec 2023 11:59:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343900AbjLDL7A (ORCPT ); Mon, 4 Dec 2023 06:59:00 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47596 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343803AbjLDL6T (ORCPT ); Mon, 4 Dec 2023 06:58:19 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B98281BC0 for ; Mon, 4 Dec 2023 03:57:41 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 726FFC43395; Mon, 4 Dec 2023 11:57:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1701691061; bh=TN+helZA3bPv2YjKOOvsbQc10ej/I0xDQI0yWDQmgfs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=O0qjci0KWVyXGoGetwLAdxCbm3vMP8PwEkoyqEAI4sdba9umtQj+C0CjCz/+VCNHt 78dAPC0khV3FBaDdebhE5AVNwQldlJnkXvD8wa2BZ9TAkf+aHEpe9k7WZaU7z+Frsx 9ROjnLRKResu/hhZ8yh3uMJ1CexSrTKe+5vA6wbLE3SEG9eQgtfqTDfP0l5OVDLKOM bvQwa5x1yXV5P03JcUcfXAoi8Lmrc8ufouFNwfD9IY7hc104mQdi0pYkv0fRESsPLg R/REziphpRYuQNQ+t20SI/gYNxs0m/qKxr/a9mU0wGDJmMAKIeoDRF32GwZmHTNnqf w3cn2BNnu8jLQ== From: Arnd Bergmann To: linux-mips@vger.kernel.org Cc: Arnd Bergmann , "Andrew Morton" , "Stephen Rothwell" , "Linux Kernel Mailing List" , "Thomas Bogendoerfer" Subject: [PATCH 11/20] mips: fix tlb_init() prototype Date: Mon, 4 Dec 2023 12:57:01 +0100 Message-Id: <20231204115710.2247097-12-arnd@kernel.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231204115710.2247097-1-arnd@kernel.org> References: <20231204115710.2247097-1-arnd@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Arnd Bergmann There are two definitions for tlb_init(), but no global declaration: arch/mips/mm/tlb-r4k.c:552:6: error: no previous prototype for 'tlb_init' [= -Werror=3Dmissing-prototypes] arch/mips/mm/tlb-r3k.c:244:6: error: no previous prototype for 'tlb_init' [= -Werror=3Dmissing-prototypes] Move the declaration to asm/setup.h and included it as needed. Signed-off-by: Arnd Bergmann --- arch/mips/include/asm/setup.h | 1 + arch/mips/kernel/traps.c | 2 -- arch/mips/mm/tlb-r3k.c | 1 + arch/mips/mm/tlb-r4k.c | 1 + 4 files changed, 3 insertions(+), 2 deletions(-) diff --git a/arch/mips/include/asm/setup.h b/arch/mips/include/asm/setup.h index 8c56b862fd9c..4dce41138bad 100644 --- a/arch/mips/include/asm/setup.h +++ b/arch/mips/include/asm/setup.h @@ -27,5 +27,6 @@ extern unsigned long ebase; extern unsigned int hwrena; extern void per_cpu_trap_init(bool); extern void cpu_cache_init(void); +extern void tlb_init(void); =20 #endif /* __SETUP_H */ diff --git a/arch/mips/kernel/traps.c b/arch/mips/kernel/traps.c index 246c6a6b0261..c58c0c3c5b40 100644 --- a/arch/mips/kernel/traps.c +++ b/arch/mips/kernel/traps.c @@ -2157,8 +2157,6 @@ void *set_vi_handler(int n, vi_handler_t addr) return set_vi_srs_handler(n, addr, 0); } =20 -extern void tlb_init(void); - /* * Timer interrupt */ diff --git a/arch/mips/mm/tlb-r3k.c b/arch/mips/mm/tlb-r3k.c index 1fb2cf8c8bfa..f6db65410c65 100644 --- a/arch/mips/mm/tlb-r3k.c +++ b/arch/mips/mm/tlb-r3k.c @@ -23,6 +23,7 @@ #include #include #include +#include #include =20 #undef DEBUG_TLB diff --git a/arch/mips/mm/tlb-r4k.c b/arch/mips/mm/tlb-r4k.c index a542b255019a..44411b20c7ec 100644 --- a/arch/mips/mm/tlb-r4k.c +++ b/arch/mips/mm/tlb-r4k.c @@ -24,6 +24,7 @@ #include #include #include +#include =20 /* * LOONGSON-2 has a 4 entry itlb which is a subset of jtlb, LOONGSON-3 has --=20 2.39.2