[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20231204115710.2247097-9-arnd@kernel.org>
Date: Mon, 4 Dec 2023 12:56:58 +0100
From: Arnd Bergmann <arnd@...nel.org>
To: linux-mips@...r.kernel.org
Cc: Arnd Bergmann <arnd@...db.de>,
"Andrew Morton" <akpm@...ux-foundation.org>,
"Stephen Rothwell" <sfr@...hwell.id.au>,
"Linux Kernel Mailing List" <linux-kernel@...r.kernel.org>,
"Thomas Bogendoerfer" <tsbogend@...ha.franken.de>
Subject: [PATCH 08/20] mips: move jump_label_apply_nops() declaration to header
From: Arnd Bergmann <arnd@...db.de>
Instead of an extern declaration in the C file with the caller, move it
to an appropriate header, avoiding
arch/mips/kernel/jump_label.c:93:6: error: no previous prototype for 'jump_label_apply_nops' [-Werror=missing-prototypes]
Signed-off-by: Arnd Bergmann <arnd@...db.de>
---
arch/mips/include/asm/jump_label.h | 3 +++
arch/mips/kernel/module.c | 3 +--
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/arch/mips/include/asm/jump_label.h b/arch/mips/include/asm/jump_label.h
index c5c6864e64bc..081be98c71ef 100644
--- a/arch/mips/include/asm/jump_label.h
+++ b/arch/mips/include/asm/jump_label.h
@@ -15,6 +15,9 @@
#include <linux/types.h>
#include <asm/isa-rev.h>
+struct module;
+extern void jump_label_apply_nops(struct module *mod);
+
#define JUMP_LABEL_NOP_SIZE 4
#ifdef CONFIG_64BIT
diff --git a/arch/mips/kernel/module.c b/arch/mips/kernel/module.c
index 0c936cbf20c5..7b2fbaa9cac5 100644
--- a/arch/mips/kernel/module.c
+++ b/arch/mips/kernel/module.c
@@ -20,8 +20,7 @@
#include <linux/kernel.h>
#include <linux/spinlock.h>
#include <linux/jump_label.h>
-
-extern void jump_label_apply_nops(struct module *mod);
+#include <asm/jump_label.h>
struct mips_hi16 {
struct mips_hi16 *next;
--
2.39.2
Powered by blists - more mailing lists