linux-mips.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Florian Fainelli <f.fainelli@gmail.com>
To: Marc Zyngier <maz@kernel.org>, Rob Herring <robh@kernel.org>
Cc: Florian Fainelli <f.fainelli@gmail.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Ray Jui <rjui@broadcom.com>,
	Scott Branden <sbranden@broadcom.com>,
	"maintainer:BROADCOM BCM281XX/BCM11XXX/BCM216XX ARM ARCHITE..." 
	<bcm-kernel-feedback-list@broadcom.com>,
	Russell King <linux@armlinux.org.uk>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will@kernel.org>,
	Thomas Bogendoerfer <tsbogend@alpha.franken.de>,
	Thomas Gleixner <tglx@linutronix.de>,
	Frank Rowand <frowand.list@gmail.com>,
	"moderated list:ARM SUB-ARCHITECTURES" 
	<linux-arm-kernel@lists.infradead.org>,
	"open list:MIPS" <linux-mips@vger.kernel.org>,
	"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE" 
	<devicetree@vger.kernel.org>
Subject: Re: [PATCH v4 09/14] irqchip: Provide platform_device to of_irq_init_cb_t
Date: Wed, 20 Oct 2021 08:14:07 -0700	[thread overview]
Message-ID: <ef9f4279-1820-3e90-482e-c4e710859af6@gmail.com> (raw)
In-Reply-To: <87tuhcnlwt.wl-maz@kernel.org>



On 10/20/2021 1:24 AM, Marc Zyngier wrote:
> On Tue, 19 Oct 2021 23:23:52 +0100,
> Rob Herring <robh@kernel.org> wrote:
>>
>>   On Tue, Oct 19, 2021 at 4:43 PM Marc Zyngier <maz@kernel.org> wrote:
>>>
>>> diff --git a/include/linux/irqchip.h b/include/linux/irqchip.h
>>> index ccf32758ea85..146a9d80a6a2 100644
>>> --- a/include/linux/irqchip.h
>>> +++ b/include/linux/irqchip.h
>>> @@ -33,7 +33,15 @@ extern int platform_irqchip_probe(struct platform_device *pdev);
>>>   #define IRQCHIP_PLATFORM_DRIVER_BEGIN(drv_name) \
>>>   static const struct of_device_id drv_name##_irqchip_match_table[] = {
>>>
>>> -#define IRQCHIP_MATCH(compat, fn) { .compatible = compat, .data = fn },
>>> +/* Undefined on purpose */
>>> +int typecheck_irq_init_cb(struct device_node *, struct device_node *,
>>> +                         struct platform_device *);
>>> +
>>> +#define typecheck_irq_init_cb(fn)                                      \
>>> +       __typecheck(typecheck_irq_init_cb, fn) ? fn : fn
>>
>> That's nice! Shouldn't it also be used for IRQCHIP_DECLARE?
> 
> Absolutely. And enabling this shows that changing of_irq_init_cb_t
> breaks *all users* of IRQCHIP_DECLARE(). Not an acceptable outcome
> when we're at -rc5. >
> Why can't the relevant drivers use of_find_device_by_node() instead?
> That would allow us to keep the status-quo on of_irq_init_cb_t.

Rob had suggested several solutions, including using 
of_find_device_by_node(), however updating of_irq_init_cb_t was 
indicated to be the better way. I had intentionally not updated 
IRQCHIP_DECLARE() because it would ignore the 3rd argument we passed to 
it (platform_device *) so I thought.

If I am spinning a v6 using of_find_device_by_node() would that be 
acceptable to you?
-- 
Florian

  reply	other threads:[~2021-10-20 15:14 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-09  2:20 [PATCH v4 00/14] Modular Broadcom irqchip drivers Florian Fainelli
2021-10-09  2:20 ` [PATCH v4 01/14] MIPS: BMIPS: Remove use of irq_cpu_offline Florian Fainelli
2021-10-09  2:20 ` [PATCH v4 02/14] irqchip/irq-bcm7038-l1: Remove .irq_cpu_offline() Florian Fainelli
2021-10-09  2:20 ` [PATCH v4 03/14] irqchip/irq-bcm7038-l1: Use irq_get_irq_data() Florian Fainelli
2021-10-09  2:20 ` [PATCH v4 04/14] irqchip/irq-bcm7038-l1: Gate use of CPU logical map to MIPS Florian Fainelli
2021-10-09  2:20 ` [PATCH v4 05/14] irqchip/irq-bcm7038-l1: Restrict affinity setting " Florian Fainelli
2021-10-09  2:20 ` [PATCH v4 06/14] irqchip/irq-bcm7038-l1: Switch to IRQCHIP_PLATFORM_DRIVER Florian Fainelli
2021-10-09  2:20 ` [PATCH v4 07/14] genirq: Export irq_gc_{unmask_enable,mask_disable}_reg Florian Fainelli
2021-10-09  2:20 ` [PATCH v4 08/14] irqchip/irq-brcmstb-l2: Switch to IRQCHIP_PLATFORM_DRIVER Florian Fainelli
2021-10-09  2:20 ` [PATCH v4 09/14] irqchip: Provide platform_device to of_irq_init_cb_t Florian Fainelli
2021-10-19 21:43   ` Marc Zyngier
2021-10-19 21:52     ` Florian Fainelli
2021-10-19 22:23     ` Rob Herring
2021-10-20  8:24       ` Marc Zyngier
2021-10-20 15:14         ` Florian Fainelli [this message]
2021-10-20 15:28           ` Marc Zyngier
2021-10-09  2:20 ` [PATCH v4 10/14] genirq: Export irq_gc_noop() Florian Fainelli
2021-10-09  2:20 ` [PATCH v4 11/14] irqchip/irq-bcm7120-l2: Switch to IRQCHIP_PLATFORM_DRIVER Florian Fainelli
2021-10-09  2:20 ` [PATCH v4 12/14] arm64: broadcom: Removed forced select of interrupt controllers Florian Fainelli
2021-10-09  2:20 ` [PATCH v4 13/14] ARM: bcm: " Florian Fainelli
2021-10-09  2:20 ` [PATCH v4 14/14] irqchip: Fix kernel-doc parameter typo for IRQCHIP_DECLARE Florian Fainelli
2021-10-19 19:13 ` [PATCH v4 00/14] Modular Broadcom irqchip drivers Florian Fainelli
2021-10-19 21:46   ` 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=ef9f4279-1820-3e90-482e-c4e710859af6@gmail.com \
    --to=f.fainelli@gmail.com \
    --cc=bcm-kernel-feedback-list@broadcom.com \
    --cc=catalin.marinas@arm.com \
    --cc=devicetree@vger.kernel.org \
    --cc=frowand.list@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mips@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=maz@kernel.org \
    --cc=rjui@broadcom.com \
    --cc=robh@kernel.org \
    --cc=sbranden@broadcom.com \
    --cc=tglx@linutronix.de \
    --cc=tsbogend@alpha.franken.de \
    --cc=will@kernel.org \
    /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).