On Thu, Dec 12, 2024 at 04:19:12PM +0800, Wenbin Yao (Consultant) wrote:As per DWC registers data book, NUM_OF_LANES is referred to as the "Predetermined Number of Lanes" in section 4.2.6.2.1 of the PCI Express Base 3.0 Specification, revision 1.0.
PORT_LOGIC_LINK_WIDTH field of the PCIE_LINK_WIDTH_SPEED_CONTROL registerWhere in the spec it is defined?
indicates the number of lanes to check for exit from Electrical Idle in
Polling.Active and L2.Idle. It is used to limit the effective link width to
ignore broken or unused lanes that detect a receiver to prevent one or more
bad Receivers or Transmitters from holding up a valid Link from being
configured.
In a PCIe link that support muiltiple lanes, setting PORT_LOGIC_LINK_WIDTH
to 1 will not affect the link width that is actually intended to be used.
Yes, According to the theory metioned above, let's say in a 8 lanes PCIe link, if we set NUM_OF_LANES to 8, then all lanes that detect a Receiver during Detect need to receive eight consecutive training sequences, otherwise the LTSSM can not enter Poll.Configuration and linktraing will fail.
But setting it to a value other than 1 will lead to link training fail ifWhich means the link partner is not able to downsize the link during LTSSM?
one or more lanes are broken.
Althouh we met this issue on some Modem platforms where PCIe port works in EP mode. But this is not a specific endpoint/controller issue. This register will be set to 1 by default after reset in new QCOM platform. But upstream kernel will still program it to other value here.
Hence, always set PORT_LOGIC_LINK_WIDTH to 1 no matter how many lanes theThis looks like a specific endpoint/controller issue to me. Where exactly did
port actually supports to make linking up more robust. Link can still be
established with one lane at least if other lanes are broken.
you see the issue?
--
- Mani