* [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent()
@ 2025-08-27 23:09 Inochi Amaoto
2025-08-28 1:37 ` Wei Fang
` (4 more replies)
0 siblings, 5 replies; 9+ messages in thread
From: Inochi Amaoto @ 2025-08-27 23:09 UTC (permalink / raw)
To: Bjorn Helgaas, Thomas Gleixner, Marc Zyngier, Lorenzo Pieralisi,
Inochi Amaoto, Shradha Gupta, Chen Wang
Cc: linux-pci, linux-kernel, Yixun Lan, Longbin Li,
Linux Kernel Functional Testing, Nathan Chancellor, Wei Fang,
Jon Hunter
For msi controller that only supports MSI_FLAG_PCI_MSI_MASK_PARENT,
the newly added callback irq_startup() and irq_shutdown() for
pci_msi[x]_template will not unmask/mask the interrupt when startup/
shutdown the interrupt. This will prevent the interrupt from being
enabled/disabled normally.
Add the missing check for MSI_FLAG_PCI_MSI_MASK_PARENT in the
cond_[startup|shutdown]_parent(). So the interrupt can be normally
unmasked/masked if it does not support MSI_FLAG_PCI_MSI_MASK_PARENT.
Fixes: 54f45a30c0d0 ("PCI/MSI: Add startup/shutdown for per device domains")
Reported-by: Linux Kernel Functional Testing <lkft@linaro.org>
Closes: https://lore.kernel.org/regressions/aK4O7Hl8NCVEMznB@monster/
Reported-by: Nathan Chancellor <nathan@kernel.org>
Closes: https://lore.kernel.org/regressions/20250826220959.GA4119563@ax162/
Reported-by: Wei Fang <wei.fang@nxp.com>
Closes: https://lore.kernel.org/all/20250827093911.1218640-1-wei.fang@nxp.com/
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
Tested-by: Nathan Chancellor <nathan@kernel.org>
Tested-by: Linux Kernel Functional Testing <lkft@linaro.org>
Tested-by: Jon Hunter <jonathanh@nvidia.com>
Acked-by: Bjorn Helgaas <bhelgaas@google.com>
---
Change from v1:
- https://lore.kernel.org/all/20250827062911.203106-1-inochiama@gmail.com/
1. Apply Tested-by, Reported-by and Tested-by from original post [1].
2. update mistake in the comments.
[1] https://lore.kernel.org/regressions/aK4O7Hl8NCVEMznB@monster/
---
drivers/pci/msi/irqdomain.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drivers/pci/msi/irqdomain.c b/drivers/pci/msi/irqdomain.c
index e0a800f918e8..b11b7f63f0d6 100644
--- a/drivers/pci/msi/irqdomain.c
+++ b/drivers/pci/msi/irqdomain.c
@@ -154,6 +154,8 @@ static void cond_shutdown_parent(struct irq_data *data)
if (unlikely(info->flags & MSI_FLAG_PCI_MSI_STARTUP_PARENT))
irq_chip_shutdown_parent(data);
+ else if (unlikely(info->flags & MSI_FLAG_PCI_MSI_MASK_PARENT))
+ irq_chip_mask_parent(data);
}
static unsigned int cond_startup_parent(struct irq_data *data)
@@ -162,6 +164,9 @@ static unsigned int cond_startup_parent(struct irq_data *data)
if (unlikely(info->flags & MSI_FLAG_PCI_MSI_STARTUP_PARENT))
return irq_chip_startup_parent(data);
+ else if (unlikely(info->flags & MSI_FLAG_PCI_MSI_MASK_PARENT))
+ irq_chip_unmask_parent(data);
+
return 0;
}
--
2.51.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* RE: [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent()
2025-08-27 23:09 [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent() Inochi Amaoto
@ 2025-08-28 1:37 ` Wei Fang
2025-08-28 3:07 ` Chen Wang
` (3 subsequent siblings)
4 siblings, 0 replies; 9+ messages in thread
From: Wei Fang @ 2025-08-28 1:37 UTC (permalink / raw)
To: Inochi Amaoto
Cc: linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org,
Yixun Lan, Longbin Li, Linux Kernel Functional Testing,
Nathan Chancellor, Jon Hunter, Bjorn Helgaas, Thomas Gleixner,
Marc Zyngier, Lorenzo Pieralisi, Shradha Gupta, Chen Wang
> For msi controller that only supports MSI_FLAG_PCI_MSI_MASK_PARENT,
> the newly added callback irq_startup() and irq_shutdown() for
> pci_msi[x]_template will not unmask/mask the interrupt when startup/
> shutdown the interrupt. This will prevent the interrupt from being
> enabled/disabled normally.
>
> Add the missing check for MSI_FLAG_PCI_MSI_MASK_PARENT in the
> cond_[startup|shutdown]_parent(). So the interrupt can be normally
> unmasked/masked if it does not support MSI_FLAG_PCI_MSI_MASK_PARENT.
>
> Fixes: 54f45a30c0d0 ("PCI/MSI: Add startup/shutdown for per device
> domains")
Thanks for fixing this issue.
Tested-by: Wei Fang <wei.fang@nxp.com>
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent()
2025-08-27 23:09 [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent() Inochi Amaoto
2025-08-28 1:37 ` Wei Fang
@ 2025-08-28 3:07 ` Chen Wang
2025-09-01 13:30 ` Anders Roxell
` (2 subsequent siblings)
4 siblings, 0 replies; 9+ messages in thread
From: Chen Wang @ 2025-08-28 3:07 UTC (permalink / raw)
To: Inochi Amaoto, Bjorn Helgaas, Thomas Gleixner, Marc Zyngier,
Lorenzo Pieralisi, Shradha Gupta
Cc: linux-pci, linux-kernel, Yixun Lan, Longbin Li,
Linux Kernel Functional Testing, Nathan Chancellor, Wei Fang,
Jon Hunter
On 8/28/2025 7:09 AM, Inochi Amaoto wrote:
> For msi controller that only supports MSI_FLAG_PCI_MSI_MASK_PARENT,
> the newly added callback irq_startup() and irq_shutdown() for
> pci_msi[x]_template will not unmask/mask the interrupt when startup/
> shutdown the interrupt. This will prevent the interrupt from being
> enabled/disabled normally.
>
> Add the missing check for MSI_FLAG_PCI_MSI_MASK_PARENT in the
> cond_[startup|shutdown]_parent(). So the interrupt can be normally
> unmasked/masked if it does not support MSI_FLAG_PCI_MSI_MASK_PARENT.
>
> Fixes: 54f45a30c0d0 ("PCI/MSI: Add startup/shutdown for per device domains")
> Reported-by: Linux Kernel Functional Testing <lkft@linaro.org>
> Closes: https://lore.kernel.org/regressions/aK4O7Hl8NCVEMznB@monster/
> Reported-by: Nathan Chancellor <nathan@kernel.org>
> Closes: https://lore.kernel.org/regressions/20250826220959.GA4119563@ax162/
> Reported-by: Wei Fang <wei.fang@nxp.com>
> Closes: https://lore.kernel.org/all/20250827093911.1218640-1-wei.fang@nxp.com/
> Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
> Tested-by: Nathan Chancellor <nathan@kernel.org>
> Tested-by: Linux Kernel Functional Testing <lkft@linaro.org>
> Tested-by: Jon Hunter <jonathanh@nvidia.com>
> Acked-by: Bjorn Helgaas <bhelgaas@google.com>
Tested-by: Chen Wang <unicorn_wang@outlook.com> # Pioneerbox/SG2042
Thanks,
Chen
> ---
> Change from v1:
> - https://lore.kernel.org/all/20250827062911.203106-1-inochiama@gmail.com/
> 1. Apply Tested-by, Reported-by and Tested-by from original post [1].
> 2. update mistake in the comments.
>
> [1] https://lore.kernel.org/regressions/aK4O7Hl8NCVEMznB@monster/
> ---
> drivers/pci/msi/irqdomain.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/drivers/pci/msi/irqdomain.c b/drivers/pci/msi/irqdomain.c
> index e0a800f918e8..b11b7f63f0d6 100644
> --- a/drivers/pci/msi/irqdomain.c
> +++ b/drivers/pci/msi/irqdomain.c
> @@ -154,6 +154,8 @@ static void cond_shutdown_parent(struct irq_data *data)
>
> if (unlikely(info->flags & MSI_FLAG_PCI_MSI_STARTUP_PARENT))
> irq_chip_shutdown_parent(data);
> + else if (unlikely(info->flags & MSI_FLAG_PCI_MSI_MASK_PARENT))
> + irq_chip_mask_parent(data);
> }
>
> static unsigned int cond_startup_parent(struct irq_data *data)
> @@ -162,6 +164,9 @@ static unsigned int cond_startup_parent(struct irq_data *data)
>
> if (unlikely(info->flags & MSI_FLAG_PCI_MSI_STARTUP_PARENT))
> return irq_chip_startup_parent(data);
> + else if (unlikely(info->flags & MSI_FLAG_PCI_MSI_MASK_PARENT))
> + irq_chip_unmask_parent(data);
> +
> return 0;
> }
>
> --
> 2.51.0
>
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent()
2025-08-27 23:09 [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent() Inochi Amaoto
2025-08-28 1:37 ` Wei Fang
2025-08-28 3:07 ` Chen Wang
@ 2025-09-01 13:30 ` Anders Roxell
2025-09-01 14:56 ` Jon Hunter
2025-09-01 22:20 ` Inochi Amaoto
2025-09-02 12:47 ` [tip: irq/drivers] " tip-bot2 for Inochi Amaoto
4 siblings, 1 reply; 9+ messages in thread
From: Anders Roxell @ 2025-09-01 13:30 UTC (permalink / raw)
To: Inochi Amaoto
Cc: Bjorn Helgaas, Thomas Gleixner, Marc Zyngier, Lorenzo Pieralisi,
Shradha Gupta, Chen Wang, linux-pci, linux-kernel, Yixun Lan,
Longbin Li, Linux Kernel Functional Testing, Nathan Chancellor,
Wei Fang, Jon Hunter, Stephen Rothwell
On Thu, 28 Aug 2025 at 01:10, Inochi Amaoto <inochiama@gmail.com> wrote:
>
> For msi controller that only supports MSI_FLAG_PCI_MSI_MASK_PARENT,
> the newly added callback irq_startup() and irq_shutdown() for
> pci_msi[x]_template will not unmask/mask the interrupt when startup/
> shutdown the interrupt. This will prevent the interrupt from being
> enabled/disabled normally.
>
> Add the missing check for MSI_FLAG_PCI_MSI_MASK_PARENT in the
> cond_[startup|shutdown]_parent(). So the interrupt can be normally
> unmasked/masked if it does not support MSI_FLAG_PCI_MSI_MASK_PARENT.
>
> Fixes: 54f45a30c0d0 ("PCI/MSI: Add startup/shutdown for per device domains")
> Reported-by: Linux Kernel Functional Testing <lkft@linaro.org>
> Closes: https://lore.kernel.org/regressions/aK4O7Hl8NCVEMznB@monster/
> Reported-by: Nathan Chancellor <nathan@kernel.org>
> Closes: https://lore.kernel.org/regressions/20250826220959.GA4119563@ax162/
> Reported-by: Wei Fang <wei.fang@nxp.com>
> Closes: https://lore.kernel.org/all/20250827093911.1218640-1-wei.fang@nxp.com/
> Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
> Tested-by: Nathan Chancellor <nathan@kernel.org>
> Tested-by: Linux Kernel Functional Testing <lkft@linaro.org>
> Tested-by: Jon Hunter <jonathanh@nvidia.com>
> Acked-by: Bjorn Helgaas <bhelgaas@google.com>
Any updates on this? It pretty much breaks testing on linux-next for ARM.
Cheers,
Anders
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent()
2025-09-01 13:30 ` Anders Roxell
@ 2025-09-01 14:56 ` Jon Hunter
2025-09-01 22:19 ` Inochi Amaoto
0 siblings, 1 reply; 9+ messages in thread
From: Jon Hunter @ 2025-09-01 14:56 UTC (permalink / raw)
To: Anders Roxell, Inochi Amaoto
Cc: Bjorn Helgaas, Thomas Gleixner, Marc Zyngier, Lorenzo Pieralisi,
Shradha Gupta, Chen Wang, linux-pci, linux-kernel, Yixun Lan,
Longbin Li, Linux Kernel Functional Testing, Nathan Chancellor,
Wei Fang, Stephen Rothwell
On 01/09/2025 14:30, Anders Roxell wrote:
> On Thu, 28 Aug 2025 at 01:10, Inochi Amaoto <inochiama@gmail.com> wrote:
>>
>> For msi controller that only supports MSI_FLAG_PCI_MSI_MASK_PARENT,
>> the newly added callback irq_startup() and irq_shutdown() for
>> pci_msi[x]_template will not unmask/mask the interrupt when startup/
>> shutdown the interrupt. This will prevent the interrupt from being
>> enabled/disabled normally.
>>
>> Add the missing check for MSI_FLAG_PCI_MSI_MASK_PARENT in the
>> cond_[startup|shutdown]_parent(). So the interrupt can be normally
>> unmasked/masked if it does not support MSI_FLAG_PCI_MSI_MASK_PARENT.
>>
>> Fixes: 54f45a30c0d0 ("PCI/MSI: Add startup/shutdown for per device domains")
>> Reported-by: Linux Kernel Functional Testing <lkft@linaro.org>
>> Closes: https://lore.kernel.org/regressions/aK4O7Hl8NCVEMznB@monster/
>> Reported-by: Nathan Chancellor <nathan@kernel.org>
>> Closes: https://lore.kernel.org/regressions/20250826220959.GA4119563@ax162/
>> Reported-by: Wei Fang <wei.fang@nxp.com>
>> Closes: https://lore.kernel.org/all/20250827093911.1218640-1-wei.fang@nxp.com/
>> Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
>> Tested-by: Nathan Chancellor <nathan@kernel.org>
>> Tested-by: Linux Kernel Functional Testing <lkft@linaro.org>
>> Tested-by: Jon Hunter <jonathanh@nvidia.com>
>> Acked-by: Bjorn Helgaas <bhelgaas@google.com>
>
> Any updates on this? It pretty much breaks testing on linux-next for ARM.
Also does it make sense to squash this fix with the original patch? It
caused boot failures on at least 3 of our boards and so could impact the
ability to bisect other issues.
Jon
--
nvpublic
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent()
2025-09-01 14:56 ` Jon Hunter
@ 2025-09-01 22:19 ` Inochi Amaoto
0 siblings, 0 replies; 9+ messages in thread
From: Inochi Amaoto @ 2025-09-01 22:19 UTC (permalink / raw)
To: Jon Hunter, Anders Roxell, Inochi Amaoto
Cc: Bjorn Helgaas, Thomas Gleixner, Marc Zyngier, Lorenzo Pieralisi,
Shradha Gupta, Chen Wang, linux-pci, linux-kernel, Yixun Lan,
Longbin Li, Linux Kernel Functional Testing, Nathan Chancellor,
Wei Fang, Stephen Rothwell
On Mon, Sep 01, 2025 at 03:56:04PM +0100, Jon Hunter wrote:
>
> On 01/09/2025 14:30, Anders Roxell wrote:
> > On Thu, 28 Aug 2025 at 01:10, Inochi Amaoto <inochiama@gmail.com> wrote:
> > >
> > > For msi controller that only supports MSI_FLAG_PCI_MSI_MASK_PARENT,
> > > the newly added callback irq_startup() and irq_shutdown() for
> > > pci_msi[x]_template will not unmask/mask the interrupt when startup/
> > > shutdown the interrupt. This will prevent the interrupt from being
> > > enabled/disabled normally.
> > >
> > > Add the missing check for MSI_FLAG_PCI_MSI_MASK_PARENT in the
> > > cond_[startup|shutdown]_parent(). So the interrupt can be normally
> > > unmasked/masked if it does not support MSI_FLAG_PCI_MSI_MASK_PARENT.
> > >
> > > Fixes: 54f45a30c0d0 ("PCI/MSI: Add startup/shutdown for per device domains")
> > > Reported-by: Linux Kernel Functional Testing <lkft@linaro.org>
> > > Closes: https://lore.kernel.org/regressions/aK4O7Hl8NCVEMznB@monster/
> > > Reported-by: Nathan Chancellor <nathan@kernel.org>
> > > Closes: https://lore.kernel.org/regressions/20250826220959.GA4119563@ax162/
> > > Reported-by: Wei Fang <wei.fang@nxp.com>
> > > Closes: https://lore.kernel.org/all/20250827093911.1218640-1-wei.fang@nxp.com/
> > > Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
> > > Tested-by: Nathan Chancellor <nathan@kernel.org>
> > > Tested-by: Linux Kernel Functional Testing <lkft@linaro.org>
> > > Tested-by: Jon Hunter <jonathanh@nvidia.com>
> > > Acked-by: Bjorn Helgaas <bhelgaas@google.com>
> >
> > Any updates on this? It pretty much breaks testing on linux-next for ARM.
>
> Also does it make sense to squash this fix with the original patch? It
> caused boot failures on at least 3 of our boards and so could impact the
> ability to bisect other issues.
>
As Thomas has taken the original series, I think it is hard to do a squash.
I will ping Thomas to see if he can take it.
Regards,
Inochi
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent()
2025-08-27 23:09 [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent() Inochi Amaoto
` (2 preceding siblings ...)
2025-09-01 13:30 ` Anders Roxell
@ 2025-09-01 22:20 ` Inochi Amaoto
2025-09-02 12:35 ` Thomas Gleixner
2025-09-02 12:47 ` [tip: irq/drivers] " tip-bot2 for Inochi Amaoto
4 siblings, 1 reply; 9+ messages in thread
From: Inochi Amaoto @ 2025-09-01 22:20 UTC (permalink / raw)
To: Thomas Gleixner
Cc: Bjorn Helgaas, Marc Zyngier, Lorenzo Pieralisi, Inochi Amaoto,
Shradha Gupta, Chen Wang, linux-pci, linux-kernel, Yixun Lan,
Longbin Li, Linux Kernel Functional Testing, Nathan Chancellor,
Wei Fang, Jon Hunter
On Thu, Aug 28, 2025 at 07:09:42AM +0800, Inochi Amaoto wrote:
> For msi controller that only supports MSI_FLAG_PCI_MSI_MASK_PARENT,
> the newly added callback irq_startup() and irq_shutdown() for
> pci_msi[x]_template will not unmask/mask the interrupt when startup/
> shutdown the interrupt. This will prevent the interrupt from being
> enabled/disabled normally.
>
> Add the missing check for MSI_FLAG_PCI_MSI_MASK_PARENT in the
> cond_[startup|shutdown]_parent(). So the interrupt can be normally
> unmasked/masked if it does not support MSI_FLAG_PCI_MSI_MASK_PARENT.
>
> Fixes: 54f45a30c0d0 ("PCI/MSI: Add startup/shutdown for per device domains")
> Reported-by: Linux Kernel Functional Testing <lkft@linaro.org>
> Closes: https://lore.kernel.org/regressions/aK4O7Hl8NCVEMznB@monster/
> Reported-by: Nathan Chancellor <nathan@kernel.org>
> Closes: https://lore.kernel.org/regressions/20250826220959.GA4119563@ax162/
> Reported-by: Wei Fang <wei.fang@nxp.com>
> Closes: https://lore.kernel.org/all/20250827093911.1218640-1-wei.fang@nxp.com/
> Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
> Tested-by: Nathan Chancellor <nathan@kernel.org>
> Tested-by: Linux Kernel Functional Testing <lkft@linaro.org>
> Tested-by: Jon Hunter <jonathanh@nvidia.com>
> Acked-by: Bjorn Helgaas <bhelgaas@google.com>
> ---
> Change from v1:
> - https://lore.kernel.org/all/20250827062911.203106-1-inochiama@gmail.com/
> 1. Apply Tested-by, Reported-by and Tested-by from original post [1].
> 2. update mistake in the comments.
>
> [1] https://lore.kernel.org/regressions/aK4O7Hl8NCVEMznB@monster/
> ---
> drivers/pci/msi/irqdomain.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/drivers/pci/msi/irqdomain.c b/drivers/pci/msi/irqdomain.c
> index e0a800f918e8..b11b7f63f0d6 100644
> --- a/drivers/pci/msi/irqdomain.c
> +++ b/drivers/pci/msi/irqdomain.c
> @@ -154,6 +154,8 @@ static void cond_shutdown_parent(struct irq_data *data)
>
> if (unlikely(info->flags & MSI_FLAG_PCI_MSI_STARTUP_PARENT))
> irq_chip_shutdown_parent(data);
> + else if (unlikely(info->flags & MSI_FLAG_PCI_MSI_MASK_PARENT))
> + irq_chip_mask_parent(data);
> }
>
> static unsigned int cond_startup_parent(struct irq_data *data)
> @@ -162,6 +164,9 @@ static unsigned int cond_startup_parent(struct irq_data *data)
>
> if (unlikely(info->flags & MSI_FLAG_PCI_MSI_STARTUP_PARENT))
> return irq_chip_startup_parent(data);
> + else if (unlikely(info->flags & MSI_FLAG_PCI_MSI_MASK_PARENT))
> + irq_chip_unmask_parent(data);
> +
> return 0;
> }
>
> --
> 2.51.0
>
Hi Thomas,
Could you take this patch? I think this fix is good to go now.
Regards,
Inochi
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent()
2025-09-01 22:20 ` Inochi Amaoto
@ 2025-09-02 12:35 ` Thomas Gleixner
0 siblings, 0 replies; 9+ messages in thread
From: Thomas Gleixner @ 2025-09-02 12:35 UTC (permalink / raw)
To: Inochi Amaoto
Cc: Bjorn Helgaas, Marc Zyngier, Lorenzo Pieralisi, Inochi Amaoto,
Shradha Gupta, Chen Wang, linux-pci, linux-kernel, Yixun Lan,
Longbin Li, Linux Kernel Functional Testing, Nathan Chancellor,
Wei Fang, Jon Hunter
On Tue, Sep 02 2025 at 06:20, Inochi Amaoto wrote:
> Could you take this patch? I think this fix is good to go now.
I was AFK last week. Looking at it now.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [tip: irq/drivers] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent()
2025-08-27 23:09 [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent() Inochi Amaoto
` (3 preceding siblings ...)
2025-09-01 22:20 ` Inochi Amaoto
@ 2025-09-02 12:47 ` tip-bot2 for Inochi Amaoto
4 siblings, 0 replies; 9+ messages in thread
From: tip-bot2 for Inochi Amaoto @ 2025-09-02 12:47 UTC (permalink / raw)
To: linux-tip-commits
Cc: Linux Kernel Functional Testing, Nathan Chancellor, Wei Fang,
Inochi Amaoto, Thomas Gleixner, Jon Hunter, Chen Wang,
Bjorn Helgaas, x86, linux-kernel
The following commit has been merged into the irq/drivers branch of tip:
Commit-ID: 727e914bbfbbda9e6efa5cb1abe4e96a949d576f
Gitweb: https://git.kernel.org/tip/727e914bbfbbda9e6efa5cb1abe4e96a949d576f
Author: Inochi Amaoto <inochiama@gmail.com>
AuthorDate: Thu, 28 Aug 2025 07:09:42 +08:00
Committer: Thomas Gleixner <tglx@linutronix.de>
CommitterDate: Tue, 02 Sep 2025 14:42:09 +02:00
PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent()
For MSI controllers which only support MSI_FLAG_PCI_MSI_MASK_PARENT, the
newly added callback irq_startup() and irq_shutdown() for
pci_msi[x]_template will not unmask or mask the interrupt when startup()
resp. shutdown() is invoked. This prevents the interrupt from being
enabled resp. disabled.
Invoke irq_[un]mask_parent() in cond_[startup|shutdown]_parent(), when the
interrupt has the MSI_FLAG_PCI_MSI_MASK_PARENT flag set.
Fixes: 54f45a30c0d0 ("PCI/MSI: Add startup/shutdown for per device domains")
Reported-by: Linux Kernel Functional Testing <lkft@linaro.org>
Reported-by: Nathan Chancellor <nathan@kernel.org>
Reported-by: Wei Fang <wei.fang@nxp.com>
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Tested-by: Nathan Chancellor <nathan@kernel.org>
Tested-by: Linux Kernel Functional Testing <lkft@linaro.org>
Tested-by: Jon Hunter <jonathanh@nvidia.com>
Tested-by: Wei Fang <wei.fang@nxp.com>
Tested-by: Chen Wang <unicorn_wang@outlook.com> # Pioneerbox/SG2042
Acked-by: Bjorn Helgaas <bhelgaas@google.com>
Link: https://lore.kernel.org/all/20250827230943.17829-1-inochiama@gmail.com
Closes: https://lore.kernel.org/regressions/aK4O7Hl8NCVEMznB@monster/
Closes: https://lore.kernel.org/regressions/20250826220959.GA4119563@ax162/
Closes: https://lore.kernel.org/all/20250827093911.1218640-1-wei.fang@nxp.com/
---
drivers/pci/msi/irqdomain.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drivers/pci/msi/irqdomain.c b/drivers/pci/msi/irqdomain.c
index e0a800f..b11b7f6 100644
--- a/drivers/pci/msi/irqdomain.c
+++ b/drivers/pci/msi/irqdomain.c
@@ -154,6 +154,8 @@ static void cond_shutdown_parent(struct irq_data *data)
if (unlikely(info->flags & MSI_FLAG_PCI_MSI_STARTUP_PARENT))
irq_chip_shutdown_parent(data);
+ else if (unlikely(info->flags & MSI_FLAG_PCI_MSI_MASK_PARENT))
+ irq_chip_mask_parent(data);
}
static unsigned int cond_startup_parent(struct irq_data *data)
@@ -162,6 +164,9 @@ static unsigned int cond_startup_parent(struct irq_data *data)
if (unlikely(info->flags & MSI_FLAG_PCI_MSI_STARTUP_PARENT))
return irq_chip_startup_parent(data);
+ else if (unlikely(info->flags & MSI_FLAG_PCI_MSI_MASK_PARENT))
+ irq_chip_unmask_parent(data);
+
return 0;
}
^ permalink raw reply related [flat|nested] 9+ messages in thread
end of thread, other threads:[~2025-09-02 12:47 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-27 23:09 [PATCH v2] PCI/MSI: Check MSI_FLAG_PCI_MSI_MASK_PARENT in cond_[startup|shutdown]_parent() Inochi Amaoto
2025-08-28 1:37 ` Wei Fang
2025-08-28 3:07 ` Chen Wang
2025-09-01 13:30 ` Anders Roxell
2025-09-01 14:56 ` Jon Hunter
2025-09-01 22:19 ` Inochi Amaoto
2025-09-01 22:20 ` Inochi Amaoto
2025-09-02 12:35 ` Thomas Gleixner
2025-09-02 12:47 ` [tip: irq/drivers] " tip-bot2 for Inochi Amaoto
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.