[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <7e9395e1de1c9a34d16ea40a522057f05bbee400.1694613528.git.geert@linux-m68k.org>
Date: Wed, 13 Sep 2023 16:08:07 +0200
From: Geert Uytterhoeven <geert@...ux-m68k.org>
To: linux-m68k@...ts.linux-m68k.org
Cc: Arnd Bergmann <arnd@...db.de>, Finn Thain <fthain@...ux-m68k.org>,
Michael Schmitz <schmitzmic@...il.com>,
Philip Blundell <philb@....org>,
Greg Ungerer <gerg@...ux-m68k.org>,
Joshua Thompson <funaho@...ai.org>,
Sam Creasey <sammy@...my.net>,
Laurent Vivier <laurent@...ier.eu>,
linux-kernel@...r.kernel.org,
Geert Uytterhoeven <geert@...ux-m68k.org>
Subject: [PATCH v2 17/52] m68k: amiga: Add and use "amiga.h"
When building with W=1:
arch/m68k/amiga/amisound.c:48:13: warning: no previous prototype for ‘amiga_init_sound’ [-Wmissing-prototypes]
48 | void __init amiga_init_sound(void)
| ^~~~~~~~~~~~~~~~
arch/m68k/amiga/amisound.c:71:6: warning: no previous prototype for ‘amiga_mksound’ [-Wmissing-prototypes]
71 | void amiga_mksound( unsigned int hz, unsigned int ticks )
| ^~~~~~~~~~~~~
Fix this by introducing a new header file "amiga.h" for holding the
prototypes of functions implemented in arch/m68k/amiga/.
Signed-off-by: Geert Uytterhoeven <geert@...ux-m68k.org>
Acked-by: Arnd Bergmann <arnd@...db.de>
---
v2:
- Add Acked-by.
---
arch/m68k/amiga/amiga.h | 5 +++++
arch/m68k/amiga/amisound.c | 2 ++
arch/m68k/amiga/config.c | 4 ++--
3 files changed, 9 insertions(+), 2 deletions(-)
create mode 100644 arch/m68k/amiga/amiga.h
diff --git a/arch/m68k/amiga/amiga.h b/arch/m68k/amiga/amiga.h
new file mode 100644
index 0000000000000000..00392781442cb91a
--- /dev/null
+++ b/arch/m68k/amiga/amiga.h
@@ -0,0 +1,5 @@
+/* SPDX-License-Identifier: GPL-2.0-only */
+
+/* amisound.c */
+void amiga_init_sound(void);
+void amiga_mksound(unsigned int hz, unsigned int ticks);
diff --git a/arch/m68k/amiga/amisound.c b/arch/m68k/amiga/amisound.c
index 442bdeee6bd7920c..714fe8ec6afa3364 100644
--- a/arch/m68k/amiga/amisound.c
+++ b/arch/m68k/amiga/amisound.c
@@ -16,6 +16,8 @@
#include <asm/amigahw.h>
+#include "amiga.h"
+
static unsigned short *snd_data;
static const signed char sine_data[] = {
0, 39, 75, 103, 121, 127, 121, 103, 75, 39,
diff --git a/arch/m68k/amiga/config.c b/arch/m68k/amiga/config.c
index 3137b45750dfcea7..7791673e547bf795 100644
--- a/arch/m68k/amiga/config.c
+++ b/arch/m68k/amiga/config.c
@@ -39,6 +39,8 @@
#include <asm/io.h>
#include <asm/config.h>
+#include "amiga.h"
+
static unsigned long amiga_model;
unsigned long amiga_eclock;
@@ -96,9 +98,7 @@ static char amiga_model_name[13] = "Amiga ";
static void amiga_sched_init(void);
static void amiga_get_model(char *model);
static void amiga_get_hardware_list(struct seq_file *m);
-extern void amiga_mksound(unsigned int count, unsigned int ticks);
static void amiga_reset(void);
-extern void amiga_init_sound(void);
static void amiga_mem_console_write(struct console *co, const char *b,
unsigned int count);
#ifdef CONFIG_HEARTBEAT
--
2.34.1
Powered by blists - more mailing lists