m68k: kernel: Add and use "ints.h"
authorGeert Uytterhoeven <geert@linux-m68k.org>
Wed, 13 Sep 2023 14:07:55 +0000 (16:07 +0200)
committerGeert Uytterhoeven <geert@linux-m68k.org>
Fri, 6 Oct 2023 08:03:01 +0000 (10:03 +0200)
When building with W=1:

    arch/m68k/kernel/ints.c:165:17: warning: no previous prototype for â€˜handle_badint’ [-Wmissing-prototypes]
      165 | asmlinkage void handle_badint(struct pt_regs *regs)
  |                 ^~~~~~~~~~~~~

Fix this by introducing a new header file "ints.h" for holding the
prototypes of functions implemented in arch/m68k/kernel/ints.c.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Link: https://lore.kernel.org/r/dc65d01ca4c7de94ce814e5b5e1f726fff97566b.1694613528.git.geert@linux-m68k.org
arch/m68k/kernel/ints.c
arch/m68k/kernel/ints.h [new file with mode: 0644]

index 5b8d66fbf3832a2c70d95d7841f4c5e38e9171cf..cf2b13488476c8c62986bcb29a2ebb46add2eb03 100644 (file)
@@ -26,6 +26,8 @@
 #include <asm/q40ints.h>
 #endif
 
+#include "ints.h"
+
 extern u32 auto_irqhandler_fixup[];
 extern u16 user_irqvec_fixup[];
 
diff --git a/arch/m68k/kernel/ints.h b/arch/m68k/kernel/ints.h
new file mode 100644 (file)
index 0000000..ecac601
--- /dev/null
@@ -0,0 +1,7 @@
+/* SPDX-License-Identifier: GPL-2.0-only */
+
+#include <linux/linkage.h>
+
+struct pt_regs;
+
+asmlinkage void handle_badint(struct pt_regs *regs);