Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1189704 > unrolled thread
| Started by | Hanjun Guo <hanjun.guo@linaro.org> |
|---|---|
| First post | 2015-07-22 09:40 +0200 |
| Last post | 2015-07-22 10:00 +0200 |
| Articles | 5 — 3 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [PATCH 1/5] genirq: irqdomain: Use an accessor for the of_node field Hanjun Guo <hanjun.guo@linaro.org> - 2015-07-22 09:40 +0200
Re: [PATCH 1/5] genirq: irqdomain: Use an accessor for the of_node field Thomas Gleixner <tglx@linutronix.de> - 2015-07-22 10:00 +0200
Re: [PATCH 1/5] genirq: irqdomain: Use an accessor for the of_node field Thomas Gleixner <tglx@linutronix.de> - 2015-07-22 10:00 +0200
Re: [PATCH 1/5] genirq: irqdomain: Use an accessor for the of_node field Marc Zyngier <marc.zyngier@arm.com> - 2015-07-22 14:50 +0200
Re: [PATCH 1/5] genirq: irqdomain: Use an accessor for the of_node field Marc Zyngier <marc.zyngier@arm.com> - 2015-07-22 10:00 +0200
| From | Hanjun Guo <hanjun.guo@linaro.org> |
|---|---|
| Date | 2015-07-22 09:40 +0200 |
| Subject | Re: [PATCH 1/5] genirq: irqdomain: Use an accessor for the of_node field |
| Message-ID | <pOWNc-d3-13@gated-at.bofh.it> |
On 07/21/2015 06:07 PM, Marc Zyngier wrote:
> The struct irq_domain contains a "struct device_node *" field
> (of_node) that is almost the only link between the irqdomain
> and the device tree infrastructure.
>
> In order to prepare for the removal of that field, convert all
> users outside of kernel/irq/irqdomain.c to use an accessor.
>
> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
> ---
> arch/mips/cavium-octeon/octeon-irq.c | 4 ++--
> arch/powerpc/platforms/cell/axon_msi.c | 2 +-
> arch/powerpc/platforms/cell/spider-pic.c | 9 ++++++---
> arch/powerpc/platforms/powernv/opal-irqchip.c | 2 +-
> arch/powerpc/sysdev/ehv_pic.c | 3 ++-
> arch/powerpc/sysdev/fsl_msi.c | 2 +-
> arch/powerpc/sysdev/i8259.c | 3 ++-
> arch/powerpc/sysdev/ipic.c | 3 ++-
> arch/powerpc/sysdev/mpic.c | 3 ++-
> arch/powerpc/sysdev/mpic_msi.c | 2 +-
> arch/powerpc/sysdev/qe_lib/qe_ic.c | 3 ++-
> drivers/gpio/gpio-sodaville.c | 2 +-
> drivers/irqchip/exynos-combiner.c | 2 +-
> drivers/irqchip/irq-atmel-aic-common.c | 2 +-
> drivers/irqchip/irq-crossbar.c | 4 ++--
> drivers/irqchip/irq-gic-v2m.c | 2 +-
> drivers/irqchip/irq-gic-v3-its.c | 2 +-
> drivers/irqchip/irq-gic-v3.c | 2 +-
> drivers/irqchip/irq-gic.c | 2 +-
> drivers/irqchip/irq-hip04.c | 2 +-
> drivers/irqchip/irq-mtk-sysirq.c | 2 +-
> drivers/irqchip/irq-s3c24xx.c | 4 ++--
> drivers/irqchip/irq-tegra.c | 4 ++--
> drivers/irqchip/irq-vf610-mscm-ir.c | 5 +++--
> drivers/spmi/spmi-pmic-arb.c | 2 +-
> include/linux/irqdomain.h | 5 +++++
> 26 files changed, 46 insertions(+), 32 deletions(-)
It seems to me that some other files missed,
in arch/powerpc/platforms/pasemi/msi.c:
if (!mpic->irqhost->of_node ||
!of_device_is_compatible(mpic->irqhost->of_node,
"pasemi,pwrficient-openpic"))
return -ENODEV;
If you need more eyes to find all of them, please count me in :)
Thanks
Hanjun
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Thomas Gleixner <tglx@linutronix.de> |
|---|---|
| Date | 2015-07-22 10:00 +0200 |
| Message-ID | <pOX6x-zY-3@gated-at.bofh.it> |
| In reply to | #1189704 |
BOn Wed, 22 Jul 2015, Hanjun Guo wrote: > On 07/21/2015 06:07 PM, Marc Zyngier wrote: > > The struct irq_domain contains a "struct device_node *" field > > (of_node) that is almost the only link between the irqdomain > > and the device tree infrastructure. > > >1;2802;0c > In order to prepare for the removal of that field, convert all > > users outside of kernel/irq/irqdomain.c to use an accessor. > > > > Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> > > --- > > arch/mips/cavium-octeon/octeon-irq.c | 4 ++-- > > arch/powerpc/platforms/cell/axon_msi.c | 2 +- > > arch/powerpc/platforms/cell/spider-pic.c | 9 ++++++--- > > arch/powerpc/platforms/powernv/opal-irqchip.c | 2 +- > > arch/powerpc/sysdev/ehv_pic.c | 3 ++- > > arch/powerpc/sysdev/fsl_msi.c | 2 +- > > arch/powerpc/sysdev/i8259.c | 3 ++- > > arch/powerpc/sysdev/ipic.c | 3 ++- > > arch/powerpc/sysdev/mpic.c | 3 ++- > > arch/powerpc/sysdev/mpic_msi.c | 2 +- > > arch/powerpc/sysdev/qe_lib/qe_ic.c | 3 ++- > > drivers/gpio/gpio-sodaville.c | 2 +- > > drivers/irqchip/exynos-combiner.c | 2 +- > > drivers/irqchip/irq-atmel-aic-common.c | 2 +- > > drivers/irqchip/irq-crossbar.c | 4 ++-- > > drivers/irqchip/irq-gic-v2m.c | 2 +- > > drivers/irqchip/irq-gic-v3-its.c | 2 +- > > drivers/irqchip/irq-gic-v3.c | 2 +- > > drivers/irqchip/irq-gic.c | 2 +- > > drivers/irqchip/irq-hip04.c | 2 +- > > drivers/irqchip/irq-mtk-sysirq.c | 2 +- > > drivers/irqchip/irq-s3c24xx.c | 4 ++-- > > drivers/irqchip/irq-tegra.c | 4 ++-- > > drivers/irqchip/irq-vf610-mscm-ir.c | 5 +++-- > > drivers/spmi/spmi-pmic-arb.c | 2 +- > > include/linux/irqdomain.h | 5 +++++ > > 26 files changed, 46 insertions(+), 32 deletions(-) > > It seems to me that some other files missed, > in arch/powerpc/platforms/pasemi/msi.c: > > if (!mpic->irqhost->of_node || > !of_device_is_compatible(mpic->irqhost->of_node, > "pasemi,pwrficient-openpic")) > return -ENODEV; > > If you need more eyes to find all of them, please count me in :) The proper tool to find them is coccinelle, not eyes. Thanks, tglx -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [next] | [standalone]
| From | Thomas Gleixner <tglx@linutronix.de> |
|---|---|
| Date | 2015-07-22 10:00 +0200 |
| Message-ID | <pOX6y-zY-11@gated-at.bofh.it> |
| In reply to | #1189704 |
On Wed, 22 Jul 2015, Marc Zyngier wrote: > > Looks like my coccinelle foo is still lacking a bit... Oh well. Please post your semantic patch and don't forget to Cc Julia Lawall :) -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [next] | [standalone]
| From | Marc Zyngier <marc.zyngier@arm.com> |
|---|---|
| Date | 2015-07-22 14:50 +0200 |
| Message-ID | <pP1Db-765-9@gated-at.bofh.it> |
| In reply to | #1189719 |
On 22/07/15 08:58, Thomas Gleixner wrote:
> On Wed, 22 Jul 2015, Marc Zyngier wrote:
>>
>> Looks like my coccinelle foo is still lacking a bit... Oh well.
>
> Please post your semantic patch and don't forget to Cc Julia Lawall :)
>
Bah, found the problem. My semantic patch is extremely simple:
@init@
struct irq_domain *ptr;
position pos;
@@
(
ptr@pos->of_node
)
@ script:python @
p1 << init.pos;
@@
for p in p1:
print "%s:%s" % (p.file,p.line)
as I'm just grepping through the tree (I don't feel confident enough to
do the patching, and some cases are a bit more complicated).
But I forgot to add arch/$ARCH/include/asm as an include search path for
spatch. That had the side effect of spatch being unable to identify
constructs like:
arch/$ARCH/include/asm/foo.h:
struct foo {
struct irq_domain *bar;
};
arch/$ARCH/.../foo.c:
struct foo foo;
if (foo->bar->of_node) { ... }
Since spatch knows nothing about struct foo, it cannot identify bar as a
struct irq_domain, hence missing this occurrence.
Once I fixed the include path, I found an additional couple of victims.
I really love this thing! :-)
M.
--
Jazz is not dead. It just smells funny...
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [next] | [standalone]
| From | Marc Zyngier <marc.zyngier@arm.com> |
|---|---|
| Date | 2015-07-22 10:00 +0200 |
| Message-ID | <pOX6y-zY-7@gated-at.bofh.it> |
| In reply to | #1189704 |
On 22/07/15 08:35, Hanjun Guo wrote: > On 07/21/2015 06:07 PM, Marc Zyngier wrote: >> The struct irq_domain contains a "struct device_node *" field >> (of_node) that is almost the only link between the irqdomain >> and the device tree infrastructure. >> >> In order to prepare for the removal of that field, convert all >> users outside of kernel/irq/irqdomain.c to use an accessor. >> >> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> >> --- >> arch/mips/cavium-octeon/octeon-irq.c | 4 ++-- >> arch/powerpc/platforms/cell/axon_msi.c | 2 +- >> arch/powerpc/platforms/cell/spider-pic.c | 9 ++++++--- >> arch/powerpc/platforms/powernv/opal-irqchip.c | 2 +- >> arch/powerpc/sysdev/ehv_pic.c | 3 ++- >> arch/powerpc/sysdev/fsl_msi.c | 2 +- >> arch/powerpc/sysdev/i8259.c | 3 ++- >> arch/powerpc/sysdev/ipic.c | 3 ++- >> arch/powerpc/sysdev/mpic.c | 3 ++- >> arch/powerpc/sysdev/mpic_msi.c | 2 +- >> arch/powerpc/sysdev/qe_lib/qe_ic.c | 3 ++- >> drivers/gpio/gpio-sodaville.c | 2 +- >> drivers/irqchip/exynos-combiner.c | 2 +- >> drivers/irqchip/irq-atmel-aic-common.c | 2 +- >> drivers/irqchip/irq-crossbar.c | 4 ++-- >> drivers/irqchip/irq-gic-v2m.c | 2 +- >> drivers/irqchip/irq-gic-v3-its.c | 2 +- >> drivers/irqchip/irq-gic-v3.c | 2 +- >> drivers/irqchip/irq-gic.c | 2 +- >> drivers/irqchip/irq-hip04.c | 2 +- >> drivers/irqchip/irq-mtk-sysirq.c | 2 +- >> drivers/irqchip/irq-s3c24xx.c | 4 ++-- >> drivers/irqchip/irq-tegra.c | 4 ++-- >> drivers/irqchip/irq-vf610-mscm-ir.c | 5 +++-- >> drivers/spmi/spmi-pmic-arb.c | 2 +- >> include/linux/irqdomain.h | 5 +++++ >> 26 files changed, 46 insertions(+), 32 deletions(-) > > It seems to me that some other files missed, > in arch/powerpc/platforms/pasemi/msi.c: > > if (!mpic->irqhost->of_node || > !of_device_is_compatible(mpic->irqhost->of_node, > "pasemi,pwrficient-openpic")) > return -ENODEV; > > If you need more eyes to find all of them, please count me in :) Looks like my coccinelle foo is still lacking a bit... Oh well. Thanks for the help! M. -- Jazz is not dead. It just smells funny... -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web