From: poza@codeaurora.org
To: Keith Busch <keith.busch@intel.com>
Cc: Oza Pawandeep <oza.pawandeep@gmail.com>,
Sinan Kaya <okaya@codeaurora.org>,
Bjorn Helgaas <bhelgaas@google.com>,
Linux PCI <linux-pci@vger.kernel.org>,
linux-pci-owner@vger.kernel.org
Subject: Re: [PATCH 2/6] PCI/DPC: Leave interrupts enabled while handling event
Date: Wed, 31 Jan 2018 10:51:50 +0530 [thread overview]
Message-ID: <2dd320d31f058ddaf4f209b5a2ba1f26@codeaurora.org> (raw)
In-Reply-To: <20180130181738.GB27205@localhost.localdomain>
On 2018-01-30 23:47, Keith Busch wrote:
> On Mon, Jan 29, 2018 at 10:34:44PM -0800, poza@codeaurora.org wrote:
>> On 2018-01-30 11:59, Oza Pawandeep wrote:
>> > + Oza
>> >
>> > On Tue, Jan 30, 2018 at 7:41 AM, Sinan Kaya <okaya@codeaurora.org>
>> > wrote:
>> >> On 1/29/2018 4:31 PM, Keith Busch wrote:
>> >>> + if (!work_busy(&dpc->work))
>> >>> + schedule_work(&dpc->work);
>> >>
>> >> Isn't there a race condition between the time that dpc_work() clears
>> >> PCI_EXP_DPC_STATUS
>> >> register and when work actually completes by returning from
>> >> dpc_work()?
>> >>
>> >> If the interrupt arrives just in this window, this code will not
>> >> schedule the work.
>> >>
>> >> --
>> >> Sinan Kaya
>> >> Qualcomm Datacenter Technologies, Inc. as an affiliate of Qualcomm
>> >> Technologies, Inc.
>> >> Qualcomm Technologies, Inc. is a member of the Code Aurora Forum, a
>> >> Linux Foundation Collaborative Project.
>>
>> besides, there is one more problem which I was debugging:
>> if RP doesnt support MSI, then legacy interrupts are not well handled
>> and we get interrupt storm.
>> this is because;
>> PCI_EXP_DPC_STATUS_INTERRUPT is being cleared in deferred work.
>> which should get cleared in dpc_irq interrupt handler.
>
> Okay, thanks for that information. I haven't got a DPC capable device
> that
> supports INTx, so that's a gap in my current testing capabilities.
>
> It looks like as you're suggesting, we should clear DPC Interrupt
> Status
> in the top-half IRQ handler, and we should not see another DPC
> interrupt
> raised until after we clear DPC Trigger Status in the bottom-half.
yes that's right. I am preparing a patch with that, and testing it on
our platform.
please let me know on what branch should I post it ?
because other mail from Bjorn suggests me to post on pci/master. since
he will take care of merging it.
Regards,
Oza.
next prev parent reply other threads:[~2018-01-31 5:21 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-29 21:31 [PATCH 1/6] PCI/DPC: Defer all event handling to work queue Keith Busch
2018-01-29 21:31 ` [PATCH 2/6] PCI/DPC: Leave interrupts enabled while handling event Keith Busch
2018-01-30 2:11 ` Sinan Kaya
2018-01-30 6:29 ` Oza Pawandeep
2018-01-30 6:34 ` poza
2018-01-30 6:40 ` poza
2018-01-30 18:17 ` Keith Busch
2018-01-31 5:21 ` poza [this message]
2018-01-30 18:30 ` Bjorn Helgaas
2018-01-31 5:23 ` poza
2018-01-29 21:31 ` [PATCH 3/6] PCI/DPC: Remove rp_pio_status from dpc struct Keith Busch
2018-01-29 21:31 ` [PATCH 4/6] PCI/DPC: Cleanup declarations Keith Busch
2018-01-29 21:31 ` [PATCH 5/6] PCI/DPC: Enable ERR_COR Keith Busch
2018-01-29 21:31 ` [PATCH 6/6] PCI/DPC: Print AER status in DPC event handling Keith Busch
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=2dd320d31f058ddaf4f209b5a2ba1f26@codeaurora.org \
--to=poza@codeaurora.org \
--cc=bhelgaas@google.com \
--cc=keith.busch@intel.com \
--cc=linux-pci-owner@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=okaya@codeaurora.org \
--cc=oza.pawandeep@gmail.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 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.