From: Keith Busch <keith.busch@intel.com>
To: Gabriele Paoloni <gabriele.paoloni@huawei.com>
Cc: "linux-pci@vger.kernel.org" <linux-pci@vger.kernel.org>,
Linuxarm <linuxarm@huawei.com>,
"liudongdong (C)" <liudongdong3@huawei.com>,
zhangjukuo <zhangjukuo@huawei.com>,
"Wangzhou (B)" <wangzhou1@hisilicon.com>
Subject: Re: Question: PCIe DPC not allowing for link retraining and bus re-scan
Date: Thu, 2 Feb 2017 18:22:54 -0500 [thread overview]
Message-ID: <20170202232253.GC24601@localhost.localdomain> (raw)
In-Reply-To: <EE11001F9E5DDD47B7634E2F8A612F2E1F9FA346@lhreml507-mbx>
On Tue, Jan 31, 2017 at 04:59:31PM +0000, Gabriele Paoloni wrote:
> Many thanks for this, I'll try to get such switch too so maybe
> I can help with development and/or validation.
> If you know of specific switches that support for sure such SW
> trigger feature please let me know and I'll try to buy them.
I'm not trying to advertise for any particular product, but this is what
I'm currently using for testing my NVMe drives:
http://www.serialcables.com/products.asp?cat=350&tier=264
It uses these PCIe switches:
https://www.broadcom.com/products/pcie-switches-bridges/expressfabric/pex9781
I just use this for PCIe SSDs, but there are other vendors that have
capable switches too.
These do support DPC sofware triggering, and the method I mentioned
before is correct:
# setpci -s <B:D.f> ECAP_DPC+6.w=40:40
On all my testing, the DPC event necesssarily triggers a PCIe HP event
that automatically does the rescan when the containment is released.
Here is a sequence from a single software trigger and nothing else,
using 4.10-rc6:
root@localhost: ~# setpci -s 89:03.0 ECAP_DPC+6.w=40:40
dpc 0000:89:03.0:pcie210: DPC containment event, status:0x002f source:0x0000
dpc 0000:89:03.0:pcie210: DPC extended error triggered, remove downstream devices
pciehp 0000:89:03.0:pcie204: Slot(3): Link Down
dpc 0000:89:03.0:pcie210: DPC containment event, status:0x0006 source:0x0000
pciehp 0000:89:03.0:pcie204: Slot(3): Card not present
dpc 0000:89:03.0:pcie210: DPC containment event, status:0x0006 source:0x0000
pciehp 0000:89:03.0:pcie204: Slot(3): Card present
dpc 0000:89:03.0:pcie210: DPC containment event, status:0x0006 source:0x0000
pciehp 0000:89:03.0:pcie204: Slot(3): Link Up
pciehp 0000:89:03.0:pcie204: Slot(3): Link Up event ignored; already powering on
pci 0000:8d:00.0: [8086:0953] type 00 class 0x010802
pci 0000:8d:00.0: reg 0x10: [mem 0x00000000-0x00003fff 64bit]
pci 0000:8d:00.0: reg 0x30: [mem 0x00000000-0x0000ffff pref]
pci 0000:8d:00.0: Max Payload Size set to 256 (was 128, max 256)
pci 0000:8d:00.0: BAR 6: assigned [mem 0xec000000-0xec00ffff pref]
pci 0000:8d:00.0: BAR 0: assigned [mem 0xec010000-0xec013fff 64bit]
pcieport 0000:89:03.0: PCI bridge to [bus 8d]
pcieport 0000:89:03.0: bridge window [mem 0xec000000-0xec0fffff]
pcieport 0000:89:03.0: bridge window [mem 0x840c00000-0x840dfffff 64bit pre
So I think we're okay to not have DPC initiate the rescan since it would
just compete with pciehp. The only thing we need to do differently is
wait for RP busy if it implements that capability, and no such device
for general availabilty currently exists, as far as I know.
next prev parent reply other threads:[~2017-02-02 23:13 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-30 11:56 Question: PCIe DPC not allowing for link retraining and bus re-scan Gabriele Paoloni
2017-01-30 16:14 ` Keith Busch
2017-01-31 9:35 ` Gabriele Paoloni
2017-01-31 15:53 ` Keith Busch
2017-01-31 16:59 ` Gabriele Paoloni
2017-02-02 23:22 ` Keith Busch [this message]
2017-02-03 8:26 ` Gabriele Paoloni
2017-02-03 10:35 ` Gabriele Paoloni
2017-02-03 20:52 ` Keith Busch
2017-02-04 6:29 ` Gabriele Paoloni
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=20170202232253.GC24601@localhost.localdomain \
--to=keith.busch@intel.com \
--cc=gabriele.paoloni@huawei.com \
--cc=linux-pci@vger.kernel.org \
--cc=linuxarm@huawei.com \
--cc=liudongdong3@huawei.com \
--cc=wangzhou1@hisilicon.com \
--cc=zhangjukuo@huawei.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.