Skip to contentSkip to conversation

irqchip/mmp: fix missing extern init code

PATCH Superseded Ben Dooks 3 participants 4 messages Jul 21, 2022 – Jul 22, 2022

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Ben Dooks

author
#0 lore raw

PATCH 1/1 irqchip/mmp: fix missing extern init code

The functions icu_init_irq and mmp2_init_icu are exported from this code, so declare them in the header file to avoid the following sparse warnings:

drivers/irqchip/irq-mmp.c:248:13: warning: symbol 'icu_init_irq' was not declared. Should it be static? drivers/irqchip/irq-mmp.c:271:13: warning: symbol 'mmp2_init_icu' was not declared. Should it be static?

---
 include/linux/irqchip/mmp.h | 3 +++
 1 file changed, 3 insertions(+)
include/linux/irqchip/mmp.h +3 -0
index cb8455c87c8a..aa1813749a4f 100644
@@ -4,4 +4,7 @@
 
 extern struct irq_chip icu_irq_chip;
 
+extern void icu_init_irq(void);
+extern void mmp2_init_icu(void);
+
 #endif	/* __IRQCHIP_MMP_H */
Signature · 1 line
2.35.1
#1 lore raw
Quoted 29 lines · Ben Dooks

The functions icu_init_irq and mmp2_init_icu are exported from this code, so declare them in the header file to avoid the following sparse warnings:

drivers/irqchip/irq-mmp.c:248:13: warning: symbol 'icu_init_irq' was not declared. Should it be static? drivers/irqchip/irq-mmp.c:271:13: warning: symbol 'mmp2_init_icu' was not declared. Should it be static?

---
 include/linux/irqchip/mmp.h | 3 +++
 1 file changed, 3 insertions(+)
include/linux/irqchip/mmp.h +3 -0
index cb8455c87c8a..aa1813749a4f 100644
@@ -4,4 +4,7 @@
 
 extern struct irq_chip icu_irq_chip;
 
+extern void icu_init_irq(void);
+extern void mmp2_init_icu(void);
+
 #endif	/* __IRQCHIP_MMP_H */
Signature · 1 line
2.35.1
$ git grep -E "icu_init_irq|mmp2_init_icu"
arch/arm/mach-mmp/mmp2.c:       mmp2_init_icu();
arch/arm/mach-mmp/mmp2.h:extern void __init mmp2_init_icu(void);
arch/arm/mach-mmp/pxa168.c:     icu_init_irq();
arch/arm/mach-mmp/pxa168.h:extern void __init icu_init_irq(void);
arch/arm/mach-mmp/pxa910.c:     icu_init_irq();
arch/arm/mach-mmp/pxa910.h:extern void __init icu_init_irq(void);
drivers/irqchip/irq-mmp.c:void __init icu_init_irq(void)
drivers/irqchip/irq-mmp.c:void __init mmp2_init_icu(void)

If you are going to fix this, please fix it sensibly.

Thanks,

	M.
Signature · 1 line
Without deviation from the norm, progress is not possible.
#2 lore raw
Quoted 17 lines · Marc Zyngier
Quoted 4 lines · Ben Dooks

The functions icu_init_irq and mmp2_init_icu are exported from this code, so declare them in the header file to avoid the following sparse warnings:

$ git grep -E "icu_init_irq|mmp2_init_icu"
arch/arm/mach-mmp/mmp2.c:       mmp2_init_icu();
arch/arm/mach-mmp/mmp2.h:extern void __init mmp2_init_icu(void);
arch/arm/mach-mmp/pxa168.c:     icu_init_irq();
arch/arm/mach-mmp/pxa168.h:extern void __init icu_init_irq(void);
arch/arm/mach-mmp/pxa910.c:     icu_init_irq();
arch/arm/mach-mmp/pxa910.h:extern void __init icu_init_irq(void);
drivers/irqchip/irq-mmp.c:void __init icu_init_irq(void)
drivers/irqchip/irq-mmp.c:void __init mmp2_init_icu(void)
Quoted 1 line

If you are going to fix this, please fix it sensibly.

Ok, didn't realise these where not being built my the v7_multi defconfig. Should this all go into one patch or do the arch/arm bits need to go via some arm tree?

Signature · 3 lines
Ben Dooks, [email protected], http://www.fluff.org/ben/

Large Hadron Colada: A large Pina Colada that makes the universe disappear.
#3 lore raw
Quoted 19 lines · Ben Dooks
Quoted 17 lines · Marc Zyngier
Quoted 4 lines · Ben Dooks

The functions icu_init_irq and mmp2_init_icu are exported from this code, so declare them in the header file to avoid the following sparse warnings:

$ git grep -E "icu_init_irq|mmp2_init_icu"
arch/arm/mach-mmp/mmp2.c:       mmp2_init_icu();
arch/arm/mach-mmp/mmp2.h:extern void __init mmp2_init_icu(void);
arch/arm/mach-mmp/pxa168.c:     icu_init_irq();
arch/arm/mach-mmp/pxa168.h:extern void __init icu_init_irq(void);
arch/arm/mach-mmp/pxa910.c:     icu_init_irq();
arch/arm/mach-mmp/pxa910.h:extern void __init icu_init_irq(void);
drivers/irqchip/irq-mmp.c:void __init icu_init_irq(void)
drivers/irqchip/irq-mmp.c:void __init mmp2_init_icu(void)
Quoted 5 lines
Quoted 1 line

If you are going to fix this, please fix it sensibly.

Ok, didn't realise these where not being built my the v7_multi defconfig. Should this all go into one patch or do the arch/arm bits need to go via some arm tree?

One single patch please, which I'll queue directly.

	M.
Signature · 1 line
Without deviation from the norm, progress is not possible.