mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Chen Gang <gang.chen@asianux.com>
To: "vgupta@synopsys.com" <vgupta@synopsys.com>,
	Arnd Bergmann <arnd@arndb.de>,
	Paul Gortmaker <paul.gortmaker@windriver.com>,
	pierrick.hascoet@abilis.com, christian.ruppert@abilis.com,
	noamc@ezchip.com
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: [PATCH] arc: kernel: remove '__init' for get_hw_config_num_irq()
Date: Wed, 23 Oct 2013 11:02:51 +0800	[thread overview]
Message-ID: <52673C5B.4090703@asianux.com> (raw)

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>
---
 arch/arc/include/asm/irq.h |    2 +-
 arch/arc/kernel/irq.c      |    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 548207f..291a70d 100644
--- a/arch/arc/include/asm/irq.h
+++ b/arch/arc/include/asm/irq.h
@@ -19,7 +19,7 @@
 #include <asm-generic/irq.h>
 
 extern void arc_init_IRQ(void);
-extern int __init get_hw_config_num_irq(void);
+extern int get_hw_config_num_irq(void);
 
 void arc_local_timer_setup(unsigned int cpu);
 
diff --git a/arch/arc/kernel/irq.c b/arch/arc/kernel/irq.c
index 5fc9245..e2bdfe5 100644
--- a/arch/arc/kernel/irq.c
+++ b/arch/arc/kernel/irq.c
@@ -146,7 +146,7 @@ void arch_do_IRQ(unsigned int irq, struct pt_regs *regs)
 	set_irq_regs(old_regs);
 }
 
-int __init get_hw_config_num_irq(void)
+int get_hw_config_num_irq(void)
 {
 	uint32_t val = read_aux_reg(ARC_REG_VECBASE_BCR);
 
-- 
1.7.7.6

                 reply	other threads:[~2013-10-23  3:03 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=52673C5B.4090703@asianux.com \
    --to=gang.chen@asianux.com \
    --cc=arnd@arndb.de \
    --cc=christian.ruppert@abilis.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=noamc@ezchip.com \
    --cc=paul.gortmaker@windriver.com \
    --cc=pierrick.hascoet@abilis.com \
    --cc=vgupta@synopsys.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome