Skip to contentSkip to conversation

sparc32: fix sparse warning in init_32.c

PATCH In review Sam Ravnborg 1 participant 1 message Apr 21, 2014 SPARC + UltraSPARC (sparc/sparc64)

lore
Share & tools
lore
#0 lore raw

PATCH 3/29 sparc32: fix sparse warning in init_32.c

Fix following warning:
init_32.c:112:22: warning: symbol 'bootmem_init' was not declared. Should it be static?

Fix by adding a proper prototype in pgtable_32.h and drop the local prototype in srmmu.c

---
 arch/sparc/include/asm/pgtable_32.h | 1 +
 arch/sparc/mm/srmmu.c               | 2 --
 2 files changed, 1 insertion(+), 2 deletions(-)
arch/sparc/include/asm/pgtable_32.h +1 -0
index 502f632..16629e7 100644
@@ -27,6 +27,7 @@ struct page;
 
 extern void load_mmu(void);
 extern unsigned long calc_highpages(void);
+unsigned long __init bootmem_init(unsigned long *pages_avail);
 
 #define pte_ERROR(e)   __builtin_trap()
 #define pmd_ERROR(e)   __builtin_trap()
arch/sparc/mm/srmmu.c +0 -2
index ed0b0b6a..54e834c 100644
@@ -865,8 +865,6 @@ static void __init map_kernel(void)
 
 void (*poke_srmmu)(void) = NULL;
 
-extern unsigned long bootmem_init(unsigned long *pages_avail);
-
 void __init srmmu_paging_init(void)
 {
 	int i;
Signature · 1 line
1.8.3.1