From: Marc Zyngier <marc.zyngier@arm.com>
To: Qiang Zhao <qiang.zhao@nxp.com>
Cc: "tglx@linutronix.de" <tglx@linutronix.de>,
"jason@lakedaemon.net" <jason@lakedaemon.net>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [patch v14 2/4] irqchip/qeic: merge qeic init code from platforms to a common function
Date: Mon, 25 Mar 2019 09:20:29 +0000 [thread overview]
Message-ID: <865zs7s42q.wl-marc.zyngier@arm.com> (raw)
In-Reply-To: <20190325035418.19065-3-qiang.zhao@nxp.com>
On Mon, 25 Mar 2019 03:53:37 +0000,
Qiang Zhao <qiang.zhao@nxp.com> wrote:
>
> The codes of qe_ic init from a variety of platforms are redundant,
> merge them to a common function and put it to irqchip/irq-qeic.c
>
> For non-p1021_mds mpc85xx_mds boards, use "qe_ic_init(np, 0,
> qe_ic_cascade_low_mpic, qe_ic_cascade_high_mpic);" instead of
> "qe_ic_init(np, 0, qe_ic_cascade_muxed_mpic, NULL);".
>
> qe_ic_cascade_muxed_mpic was used for boards has the same interrupt
> number for low interrupt and high interrupt, qe_ic_init has checked
> if "low interrupt == high interrupt"
>
> Signed-off-by: Zhao Qiang <qiang.zhao@nxp.com>
> ---
> arch/powerpc/platforms/83xx/misc.c | 15 ---------------
> arch/powerpc/platforms/85xx/corenet_generic.c | 9 ---------
> arch/powerpc/platforms/85xx/mpc85xx_mds.c | 14 --------------
> arch/powerpc/platforms/85xx/mpc85xx_rdb.c | 16 ----------------
> arch/powerpc/platforms/85xx/twr_p102x.c | 14 --------------
> drivers/irqchip/irq-qeic.c | 13 +++++++++++++
> 6 files changed, 13 insertions(+), 68 deletions(-)
>
> diff --git a/arch/powerpc/platforms/83xx/misc.c b/arch/powerpc/platforms/83xx/misc.c
> index 2b6589f..4150b56 100644
[...]
> diff --git a/drivers/irqchip/irq-qeic.c b/drivers/irqchip/irq-qeic.c
> index aba7135..673afb4 100644
> --- a/drivers/irqchip/irq-qeic.c
> +++ b/drivers/irqchip/irq-qeic.c
> @@ -18,6 +18,7 @@
> #include <linux/of_address.h>
> #include <linux/kernel.h>
> #include <linux/init.h>
> +#include <linux/irqchip.h>
> #include <linux/errno.h>
> #include <linux/reboot.h>
> #include <linux/slab.h>
> @@ -598,4 +599,16 @@ static int __init init_qe_ic_sysfs(void)
> return 0;
> }
>
> +static int __init qeic_of_init(struct device_node *node,
> + struct device_node *parent)
> +{
> + if (!node)
> + return -ENODEV;
How can node be NULL here?
> + qe_ic_init(node, 0, qe_ic_cascade_low_mpic,
> + qe_ic_cascade_high_mpic);
> + of_node_put(node);
> + return 0;
> +}
> +
> +IRQCHIP_DECLARE(qeic, "fsl,qe-ic", qeic_of_init);
> subsys_initcall(init_qe_ic_sysfs);
> --
> 1.7.1
>
Thanks,
M.
--
Jazz is not dead, it just smell funny.
next prev parent reply other threads:[~2019-03-25 9:20 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-25 3:52 [PATCH 0/4] This patchset is to remove PPCisms for QEIC Qiang Zhao
2019-03-25 3:53 ` [patch v14 1/4] irqchip/qeic: move qeic driver from drivers/soc/fsl/qe Qiang Zhao
2019-03-25 3:53 ` [patch v14 2/4] irqchip/qeic: merge qeic init code from platforms to a common function Qiang Zhao
2019-03-25 9:20 ` Marc Zyngier [this message]
2019-03-25 3:53 ` [patch v14 3/4] irqchip/qeic: merge qeic_of_init into qe_ic_init Qiang Zhao
2019-03-25 9:24 ` Marc Zyngier
2019-03-25 3:53 ` [patch v14 4/4] irqchip/qeic: remove PPCisms for QEIC Qiang Zhao
2019-03-25 9:27 ` Marc Zyngier
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=865zs7s42q.wl-marc.zyngier@arm.com \
--to=marc.zyngier@arm.com \
--cc=jason@lakedaemon.net \
--cc=linux-kernel@vger.kernel.org \
--cc=qiang.zhao@nxp.com \
--cc=tglx@linutronix.de \
/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).