Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

arc: remove '__init' for get_hw_config_num_irq()

get_hw_config_num_irq() may be called by normal iss_model_init_smp()
which is a function pointer for 'init_smp' which may be called by
first_lines_of_secondary() which also need be normal too.

The related warning (with allmodconfig):

MODPOST vmlinux.o
WARNING: vmlinux.o(.text+0x5814): Section mismatch in reference from the function iss_model_init_smp() to the function .init.text:get_hw_config_num_irq()
The function iss_model_init_smp() references
the function __init get_hw_config_num_irq().
This is often because iss_model_init_smp lacks a __init
annotation or the annotation of get_hw_config_num_irq is wrong.

Signed-off-by: Chen Gang <gang.chen@asianux.com>

authored by

Chen Gang and committed by
Vineet Gupta
4782f7f9 8f5d221b

+2 -2
+1 -1
arch/arc/include/asm/irq.h
··· 19 19 #include <asm-generic/irq.h> 20 20 21 21 extern void arc_init_IRQ(void); 22 - extern int __init get_hw_config_num_irq(void); 22 + extern int get_hw_config_num_irq(void); 23 23 24 24 void arc_local_timer_setup(unsigned int cpu); 25 25
+1 -1
arch/arc/kernel/irq.c
··· 150 150 set_irq_regs(old_regs); 151 151 } 152 152 153 - int __init get_hw_config_num_irq(void) 153 + int get_hw_config_num_irq(void) 154 154 { 155 155 uint32_t val = read_aux_reg(ARC_REG_VECBASE_BCR); 156 156