MIPS: Alchemy: Fix missing prototypes
authorFlorian Fainelli <f.fainelli@gmail.com>
Wed, 17 Jan 2024 23:49:44 +0000 (15:49 -0800)
committerThomas Bogendoerfer <tsbogend@alpha.franken.de>
Mon, 22 Jan 2024 09:32:36 +0000 (10:32 +0100)
We have a number of missing prototypes warnings for board_setup(),
alchemy_set_lpj() and prom_init_cmdline(), prom_getenv() and
prom_get_ethernet_addr(). Fix those by providing definitions for the
first two functions in au1000.h which is included everywhere relevant,
and including prom.h for the last three.

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
arch/mips/alchemy/common/prom.c
arch/mips/alchemy/common/setup.c
arch/mips/include/asm/mach-au1x00/au1000.h

index b13d8ad..20d30f6 100644 (file)
@@ -40,6 +40,7 @@
 #include <linux/string.h>
 
 #include <asm/bootinfo.h>
+#include <prom.h>
 
 int prom_argc;
 char **prom_argv;
index 2388d68..a7a6d31 100644 (file)
 #include <linux/mm.h>
 #include <linux/dma-map-ops.h> /* for dma_default_coherent */
 
+#include <asm/bootinfo.h>
 #include <asm/mipsregs.h>
 
 #include <au1000.h>
 
-extern void __init board_setup(void);
-extern void __init alchemy_set_lpj(void);
-
 static bool alchemy_dma_coherent(void)
 {
        switch (alchemy_get_cputype()) {
index a7eec33..4154677 100644 (file)
 
 #include <asm/cpu.h>
 
+void alchemy_set_lpj(void);
+void board_setup(void);
+
 /* helpers to access the SYS_* registers */
 static inline unsigned long alchemy_rdsys(int regofs)
 {