From: Anirudha Sarangi <anirudha.sarangi@xilinx.com>
To: Marc Zyngier <maz@kernel.org>
Cc: Thomas Gleixner <tglx@linutronix.de>,
Michal Simek <michal.simek@xilinx.com>,
Valentin Schneider <valentin.schneider@arm.com>,
Douglas Anderson <dianders@chromium.org>,
Hans de Goede <hdegoede@redhat.com>,
Maulik Shah <mkshah@codeaurora.org>,
Zhen Lei <thunder.leizhen@huawei.com>,
<linux-kernel@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>,
Rob Herring <robh+dt@kernel.org>,
Frank Rowand <frowand.list@gmail.com>,
<devicetree@vger.kernel.org>, <git@xilinx.com>,
Anirudha Sarangi <anirudha.sarangi@xilinx.com>
Subject: [PATCH 1/3] irqchip: xilinx: Avoid __init macro usage for xilinx_intc_of_init
Date: Tue, 27 Apr 2021 17:01:34 +0530 [thread overview]
Message-ID: <20210427113136.12469-2-anirudha.sarangi@xilinx.com> (raw)
In-Reply-To: <20210427113136.12469-1-anirudha.sarangi@xilinx.com>
This patch ensures that xilinx_intc_of_init API is not allocated into
the .init.text section. Since this API calls the API set_handle_irq
which uses __init macro to be put into .init.text section, this patch
makes changes to ensure that set_handle_irq also does not stay in
.init.text section.
This patch is in preparation for the patch through which the xilinx
intc driver will be loaded and unloaded as a module.
Signed-off-by: Anirudha Sarangi <anirudha.sarangi@xilinx.com>
---
drivers/irqchip/irq-xilinx-intc.c | 4 ++--
include/linux/irq.h | 2 +-
kernel/irq/handle.c | 2 +-
3 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/irqchip/irq-xilinx-intc.c b/drivers/irqchip/irq-xilinx-intc.c
index 1d3d273309bd..642733a6cbdf 100644
--- a/drivers/irqchip/irq-xilinx-intc.c
+++ b/drivers/irqchip/irq-xilinx-intc.c
@@ -177,8 +177,8 @@ static void xil_intc_irq_handler(struct irq_desc *desc)
chained_irq_exit(chip, desc);
}
-static int __init xilinx_intc_of_init(struct device_node *intc,
- struct device_node *parent)
+static int xilinx_intc_of_init(struct device_node *intc,
+ struct device_node *parent)
{
struct xintc_irq_chip *irqc;
int ret, irq;
diff --git a/include/linux/irq.h b/include/linux/irq.h
index 2efde6a79b7e..252fab8074de 100644
--- a/include/linux/irq.h
+++ b/include/linux/irq.h
@@ -1250,7 +1250,7 @@ int ipi_send_mask(unsigned int virq, const struct cpumask *dest);
* Returns 0 on success, or -EBUSY if an IRQ handler has already been
* registered.
*/
-int __init set_handle_irq(void (*handle_irq)(struct pt_regs *));
+int set_handle_irq(void (*handle_irq)(struct pt_regs *));
/*
* Allows interrupt handlers to find the irqchip that's been registered as the
diff --git a/kernel/irq/handle.c b/kernel/irq/handle.c
index 762a928e18f9..a0b18e8f5af0 100644
--- a/kernel/irq/handle.c
+++ b/kernel/irq/handle.c
@@ -218,7 +218,7 @@ irqreturn_t handle_irq_event(struct irq_desc *desc)
}
#ifdef CONFIG_GENERIC_IRQ_MULTI_HANDLER
-int __init set_handle_irq(void (*handle_irq)(struct pt_regs *))
+int set_handle_irq(void (*handle_irq)(struct pt_regs *))
{
if (handle_arch_irq)
return -EBUSY;
--
2.17.1
next prev parent reply other threads:[~2021-04-27 11:32 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-27 11:31 [PATCH 0/3] Updates in irqchip framework to remove irqchip Anirudha Sarangi
2021-04-27 11:31 ` Anirudha Sarangi [this message]
2021-04-27 12:17 ` [PATCH 1/3] irqchip: xilinx: Avoid __init macro usage for xilinx_intc_of_init Marc Zyngier
2021-04-27 11:31 ` [PATCH 2/3] irqchip: Add support to remove irqchip driver modules Anirudha Sarangi
2021-04-27 12:35 ` Marc Zyngier
2021-04-27 11:31 ` [PATCH 3/3] irqchip: xilinx: Add support to remove the Xilinx INTC driver module Anirudha Sarangi
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=20210427113136.12469-2-anirudha.sarangi@xilinx.com \
--to=anirudha.sarangi@xilinx.com \
--cc=devicetree@vger.kernel.org \
--cc=dianders@chromium.org \
--cc=frowand.list@gmail.com \
--cc=git@xilinx.com \
--cc=hdegoede@redhat.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=maz@kernel.org \
--cc=michal.simek@xilinx.com \
--cc=mkshah@codeaurora.org \
--cc=robh+dt@kernel.org \
--cc=tglx@linutronix.de \
--cc=thunder.leizhen@huawei.com \
--cc=valentin.schneider@arm.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;
as well as URLs for NNTP newsgroup(s).