From: Stephen Warren <swarren@wwwdotorg.org>
To: Trent Piepho <tpiepho@impinj.com>,
"jingoohan1@gmail.com" <jingoohan1@gmail.com>,
"gustavo.pimentel@synopsys.com" <gustavo.pimentel@synopsys.com>
Cc: "jpinto@synopsys.com" <jpinto@synopsys.com>,
"marex@denx.de" <marex@denx.de>,
"shawn.guo@linaro.org" <shawn.guo@linaro.org>,
"tharvey@gateworks.com" <tharvey@gateworks.com>,
"lorenzo.pieralisi@arm.com" <lorenzo.pieralisi@arm.com>,
"swarren@nvidia.com" <swarren@nvidia.com>,
"m.mann@arkona-technologies.de" <m.mann@arkona-technologies.de>,
"faiz_abbas@ti.com" <faiz_abbas@ti.com>,
"xobs@kosagi.com" <xobs@kosagi.com>,
"hrhaan@gmail.com" <hrhaan@gmail.com>,
"jbe@pengutronix.de" <jbe@pengutronix.de>,
"linux-pci@vger.kernel.org" <linux-pci@vger.kernel.org>,
"bhelgaas@google.com" <bhelgaas@google.com>,
"arnd@arndb.de" <arnd@arndb.de>
Subject: Re: [PATCH] PCI: dwc: fix MSI IRQ handler ordering
Date: Fri, 4 Jan 2019 16:00:46 -0700 [thread overview]
Message-ID: <1ff5138e-3de9-e7f9-38e6-feee4b8cefa7@wwwdotorg.org> (raw)
In-Reply-To: <1546641949.14247.20.camel@impinj.com>
On 1/4/19 3:45 PM, Trent Piepho wrote:
> On Fri, 2019-01-04 at 14:45 -0700, Stephen Warren wrote:
>> From: Stephen Warren <swarren@nvidia.com>
>>
>> The current code does this when handling MSI IRQs:
>>
>> a) Process the irq.
>> b) Clear the latched IRQ status.
>>
>> If a new IRQ occurs any time after (a) has read the IRQ status for the
>> last time and before (b), it will be lost. For example, this occurs in
>
> There was a patch series to fix this bug, sent in October, stretching
> to December.
>
> See "PCI: dwc: Fix interrupt race in when handling MSI"
>
> And "PCI: designware: Move interrupt acking into the proper callback"
>
> The result was more code changes, which in the end produce the same
> order of operations as is done here to fix the race. But it uses the
> irq framework correctly.
>
> I do not think this problem was introduced until 4.14, so the nvidia
> 4.9 must have additional patches if this is observed there. I'm sure
> it was not present in 4.12, as we used that, and did not see the issue
> until updating to 4.16.
Yes, I took the DWC driver from our 4.14 kernel and dropped it into the
4.9 kernel, so that's why the issue shows up in 4.9 for us.
> The current fix (for 4.21?) depends on significant restructuring that
> was done to this driver around 4.17, see "PCI: dwc: Move MSI IRQs
> allocation to IRQ domains hierarchical API".
>
> I think my original patch ("Fix interrupt race ..") or your patch here,
> which is basically the same, should be ported to 4.14 stable. But
> there are some other opinions on that. It's not clear to me if the
> hierarchical domain stuff would be back ported to stable series. It
> does not seem to me to be a good idea to do so.
Hmm. Well I guess I'll go for the patch I posted in our downstream
kernels, since back-porting a bunch of not-yet-available restructuring
to our ancient kernels doesn't sound pleasant:-) But I'll go and take a
quick look at the other patches you mentioned just in case. Thanks!
next prev parent reply other threads:[~2019-01-04 23:00 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-04 21:45 [PATCH] PCI: dwc: fix MSI IRQ handler ordering Stephen Warren
2019-01-04 22:45 ` Trent Piepho
2019-01-04 23:00 ` Stephen Warren [this message]
2019-01-04 23:23 ` Stephen Warren
2019-01-05 0:15 ` Trent Piepho
2019-01-07 9:36 ` Gustavo Pimentel
2019-01-07 17:16 ` Stephen Warren
2019-01-07 18:09 ` Gustavo Pimentel
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=1ff5138e-3de9-e7f9-38e6-feee4b8cefa7@wwwdotorg.org \
--to=swarren@wwwdotorg.org \
--cc=arnd@arndb.de \
--cc=bhelgaas@google.com \
--cc=faiz_abbas@ti.com \
--cc=gustavo.pimentel@synopsys.com \
--cc=hrhaan@gmail.com \
--cc=jbe@pengutronix.de \
--cc=jingoohan1@gmail.com \
--cc=jpinto@synopsys.com \
--cc=linux-pci@vger.kernel.org \
--cc=lorenzo.pieralisi@arm.com \
--cc=m.mann@arkona-technologies.de \
--cc=marex@denx.de \
--cc=shawn.guo@linaro.org \
--cc=swarren@nvidia.com \
--cc=tharvey@gateworks.com \
--cc=tpiepho@impinj.com \
--cc=xobs@kosagi.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;
as well as URLs for NNTP newsgroup(s).