From: Lukas Wunner <lukas@wunner.de>
To: Hongbo Yao <andy.xu@hj-micro.com>
Cc: bhelgaas@google.com, linux-pci@vger.kernel.org,
linux-kernel@vger.kernel.org, peter.du@hj-micro.com,
jemma.zhang@hj-micro.com, rick.yan@hj-micro.com
Subject: Re: [RFC PATCH] PCI: pciehp: Allow more time for link activation after slot power-on
Date: Sun, 13 Sep 2026 14:24:21 +0200 [thread overview]
Message-ID: <aqaV9TeD6iw-bY4w@wunner.de> (raw)
In-Reply-To: <20260910015151.1876630-1-andy.xu@hj-micro.com>
On Thu, Sep 10, 2026 at 09:51:51AM +0800, Hongbo Yao wrote:
> The OCP NIC 3.0 Specification, version 1.6.0, Figure 132 [1], requires
> an interval greater than one second between Main Power Valid and PERST#
> deassertion. The diagram labels this interval T_PVPERL. PCIe link
> activation requires additional time after PERST# is deasserted.
The 1 sec delay implemented by:
board_added()
pciehp_power_on_slot() # turn on the power
pciehp_check_link_status()
pcie_wait_for_link()
pcie_wait_for_link_delay() # wait 1 sec for DLLLA,
# then wait another 100 msec
... is specified by PCIe r7.0 sec 6.7.3.3, which is referenced by
sec 6.7.1.8 ("Power Controller").
In particular, sec 6.7.3.3 says:
"The Data Link Layer State Changed event must occur within 1 second
of the event that initiates the hot-insertion. If a power controller
is supported, the time out interval is measured from when software
initiated a write to the Slot Control register to turn on the power.
[...] Software is allowed to time out on a hot add operation if the
Data Link Layer State Changed event does not occur within 1 second."
So I think the delays observed by pciehp are conforming to the spec.
The PCIe CEM Spec r6.0.1 sec 2.11.2 specifies Tpvperl as "min 100 ms".
I don't know why the OCP NIC Spec says "> 1s" instead, but that number
isn't what the PCIe CEM Spec says and that's the authoritative document.
So I'm inclined to say the number in the OCP NIC Spec is wrong and
needs to be fixed.
> This is observed with an OCP ConnectX-7 (MT2910 family) adapter. On the
> affected platform, power-on to PERST# deassertion takes about 1.2 seconds,
> followed by a few hundred milliseconds for link activation, exceeding
> the existing polling budget.
Which platform are we talking about? A chassis from HJ Micro?
Has this already been shipped to customers or is it still in
internal validation? If it's still in validation, please fix
the hardware to shorten the delays in accordance with the PCIe
Base and CEM Spec, ignoring the bogus value in the OCP NIC spec.
If it's already in customers' hands, can you fix this through
a firmware update or something like that?
I'd like to avoid lengthening the delays in pciehp beyond what
the spec prescribes, only to work around non-conforming platforms.
Thanks,
Lukas
prev parent reply other threads:[~2026-09-13 12:24 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-10 1:51 [RFC PATCH] PCI: pciehp: Allow more time for link activation after slot power-on Hongbo Yao
2026-09-10 2:04 ` sashiko-bot
2026-09-13 12:24 ` Lukas Wunner [this message]
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=aqaV9TeD6iw-bY4w@wunner.de \
--to=lukas@wunner.de \
--cc=andy.xu@hj-micro.com \
--cc=bhelgaas@google.com \
--cc=jemma.zhang@hj-micro.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=peter.du@hj-micro.com \
--cc=rick.yan@hj-micro.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