linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] arc: include: asm: remove '__init' for setup_processor() and arc_init_IRQ()
@ 2013-10-23  2:12 Chen Gang
  2013-10-28 13:56 ` Vineet Gupta
  0 siblings, 1 reply; 3+ messages in thread
From: Chen Gang @ 2013-10-23  2:12 UTC (permalink / raw)
  To: vgupta, Arnd Bergmann, Paul Gortmaker, pierrick.hascoet,
	christian.ruppert
  Cc: linux-kernel

They haven't '__init' in definition, but has '__init' in declaration.
And normal function start_kernel_secondary() may call setup_processor()
which will call arc_init_IRQ().

So need remove '__init' for both of them. The related warning (with
allmodconfig):

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


Signed-off-by: Chen Gang <gang.chen@asianux.com>
---
 arch/arc/include/asm/irq.h   |    2 +-
 arch/arc/include/asm/setup.h |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arc/include/asm/irq.h b/arch/arc/include/asm/irq.h
index c0a7210..548207f 100644
--- a/arch/arc/include/asm/irq.h
+++ b/arch/arc/include/asm/irq.h
@@ -18,7 +18,7 @@
 
 #include <asm-generic/irq.h>
 
-extern void __init arc_init_IRQ(void);
+extern void arc_init_IRQ(void);
 extern int __init get_hw_config_num_irq(void);
 
 void arc_local_timer_setup(unsigned int cpu);
diff --git a/arch/arc/include/asm/setup.h b/arch/arc/include/asm/setup.h
index 229e506..e10f8ce 100644
--- a/arch/arc/include/asm/setup.h
+++ b/arch/arc/include/asm/setup.h
@@ -31,7 +31,7 @@ struct cpuinfo_data {
 extern int root_mountflags, end_mem;
 extern int running_on_hw;
 
-void __init setup_processor(void);
+void setup_processor(void);
 void __init setup_arch_memory(void);
 
 #endif /* __ASMARC_SETUP_H */
-- 
1.7.7.6

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] arc: include: asm: remove '__init' for setup_processor() and arc_init_IRQ()
  2013-10-23  2:12 [PATCH] arc: include: asm: remove '__init' for setup_processor() and arc_init_IRQ() Chen Gang
@ 2013-10-28 13:56 ` Vineet Gupta
  2013-10-29  1:11   ` Chen Gang
  0 siblings, 1 reply; 3+ messages in thread
From: Vineet Gupta @ 2013-10-28 13:56 UTC (permalink / raw)
  To: Chen Gang, Arnd Bergmann, Paul Gortmaker, pierrick.hascoet,
	christian.ruppert
  Cc: linux-kernel

On 10/23/2013 07:42 AM, Chen Gang wrote:
> They haven't '__init' in definition, but has '__init' in declaration.
> And normal function start_kernel_secondary() may call setup_processor()
> which will call arc_init_IRQ().
> 
> So need remove '__init' for both of them. The related warning (with
> allmodconfig):
> 
>     MODPOST vmlinux.o
>   WARNING: vmlinux.o(.text+0x3084): Section mismatch in reference from the function start_kernel_secondary() to the function .init.text:setup_processor()
>   The function start_kernel_secondary() references
>   the function __init setup_processor().
>   This is often because start_kernel_secondary lacks a __init
>   annotation or the annotation of setup_processor is wrong.
> 
> 
> Signed-off-by: Chen Gang <gang.chen@asianux.com>

Applied for 3.13

-Vineet

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] arc: include: asm: remove '__init' for setup_processor() and arc_init_IRQ()
  2013-10-28 13:56 ` Vineet Gupta
@ 2013-10-29  1:11   ` Chen Gang
  0 siblings, 0 replies; 3+ messages in thread
From: Chen Gang @ 2013-10-29  1:11 UTC (permalink / raw)
  To: Vineet Gupta
  Cc: Arnd Bergmann, Paul Gortmaker, pierrick.hascoet,
	christian.ruppert, linux-kernel

On 10/28/2013 09:56 PM, Vineet Gupta wrote:
> On 10/23/2013 07:42 AM, Chen Gang wrote:
>> They haven't '__init' in definition, but has '__init' in declaration.
>> And normal function start_kernel_secondary() may call setup_processor()
>> which will call arc_init_IRQ().
>>
>> So need remove '__init' for both of them. The related warning (with
>> allmodconfig):
>>
>>     MODPOST vmlinux.o
>>   WARNING: vmlinux.o(.text+0x3084): Section mismatch in reference from the function start_kernel_secondary() to the function .init.text:setup_processor()
>>   The function start_kernel_secondary() references
>>   the function __init setup_processor().
>>   This is often because start_kernel_secondary lacks a __init
>>   annotation or the annotation of setup_processor is wrong.
>>
>>
>> Signed-off-by: Chen Gang <gang.chen@asianux.com>
> 
> Applied for 3.13
> 

Thanks.
-- 
Chen Gang

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-10-29  1:12 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-23  2:12 [PATCH] arc: include: asm: remove '__init' for setup_processor() and arc_init_IRQ() Chen Gang
2013-10-28 13:56 ` Vineet Gupta
2013-10-29  1:11   ` Chen Gang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).