From: Bjorn Helgaas <helgaas@kernel.org>
To: Niklas Cassel <cassel@kernel.org>
Cc: "Jingoo Han" <jingoohan1@gmail.com>,
"Manivannan Sadhasivam" <mani@kernel.org>,
"Lorenzo Pieralisi" <lpieralisi@kernel.org>,
"Krzysztof Wilczyński" <kwilczynski@kernel.org>,
"Rob Herring" <robh@kernel.org>,
"Bjorn Helgaas" <bhelgaas@google.com>,
"Koichiro Den" <den@valinux.co.jp>,
"Shinichiro Kawasaki" <shinichiro.kawasaki@wdc.com>,
linux-pci@vger.kernel.org
Subject: Re: [PATCH] PCI: dwc: ep: Fix regression in dw_pcie_ep_raise_msi_irq()
Date: Wed, 11 Feb 2026 12:08:38 -0600 [thread overview]
Message-ID: <20260211180838.GA116930@bhelgaas> (raw)
In-Reply-To: <aYxDUoPWLTz774f9@ryzen>
On Wed, Feb 11, 2026 at 09:52:34AM +0100, Niklas Cassel wrote:
> On Tue, Feb 10, 2026 at 02:39:49PM -0600, Bjorn Helgaas wrote:
> > On Tue, Feb 10, 2026 at 09:22:58PM +0100, Niklas Cassel wrote:
> > > On Tue, Feb 10, 2026 at 01:32:05PM -0600, Bjorn Helgaas wrote:
> >
> > The scenario I'm asking about is the following, where the single
> > change of MSI target as the host boots is concurrent with
> > dw_pcie_ep_raise_msi_irq()::
> >
> > - host writes PCI_MSI_ADDRESS_LO
> >
> > - dw_pcie_ep_raise_msi_irq() reads PCI_MSI_ADDRESS_LO and
> > PCI_MSI_ADDRESS_HI
> >
> > - dw_pcie_ep_raise_msi_irq() maps msg_addr built from an old
> > PCI_MSI_ADDRESS_HI and a new PCI_MSI_ADDRESS_LO
> >
> > - host writes PCI_MSI_ADDRESS_HI
> >
> > This could be mitigated by re-reading PCI_MSI_ADDRESS_* to detect the
> > tearing.
>
> Ok, now I understand.
>
> This must be extremely unlikely to happen.
>
> Since the host writes the MSI target address very early, before even
> enumerating the bus.
>
> So the EP reading a half updated 64-bit MSI address, seems very
> unlikely.
Very unlikely for sure, and the patch is OK with me as-is, although
writing to the wrong address would be very difficult to debug.
I think it's probably more important to pay attention to the MSI and
MSI-X enable bits to make sure we don't generate MSIs when disabled.
next prev parent reply other threads:[~2026-02-11 18:08 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-10 18:12 [PATCH] PCI: dwc: ep: Fix regression in dw_pcie_ep_raise_msi_irq() Niklas Cassel
2026-02-10 19:32 ` Bjorn Helgaas
2026-02-10 20:22 ` Niklas Cassel
2026-02-10 20:33 ` Niklas Cassel
2026-02-10 20:39 ` Bjorn Helgaas
2026-02-11 8:52 ` Niklas Cassel
2026-02-11 18:08 ` Bjorn Helgaas [this message]
2026-02-25 14:59 ` Manivannan Sadhasivam
2026-02-11 16:44 ` Koichiro Den
2026-02-12 9:42 ` Shinichiro Kawasaki
2026-02-25 15:01 ` Manivannan Sadhasivam
2026-02-25 15:51 ` Niklas Cassel
2026-02-25 16:30 ` Manivannan Sadhasivam
2026-02-25 20:05 ` Bjorn Helgaas
2026-02-25 21:56 ` Niklas Cassel
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=20260211180838.GA116930@bhelgaas \
--to=helgaas@kernel.org \
--cc=bhelgaas@google.com \
--cc=cassel@kernel.org \
--cc=den@valinux.co.jp \
--cc=jingoohan1@gmail.com \
--cc=kwilczynski@kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=lpieralisi@kernel.org \
--cc=mani@kernel.org \
--cc=robh@kernel.org \
--cc=shinichiro.kawasaki@wdc.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