Skip to content

PCI: dwc: Revert Link Up IRQ support

Niklas Cassel linux-arm-kernel linux-arm-msm linux-pci linux-rockchip stable 2 versions – Applied

Status from this message: Applied, thanks!

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest6 patches 9 repliesApplied
  2. v16 patches 16 repliesSuperseded

Changes in v2 from the cover letter

-Rebased against latest pci/controller/dwc
-Picked up tags.

Patches in v2 Applied

#Subject and filesSizeRepliesApplied
1/6Revert "PCI: dw-rockchip: Don't wait for link since we can detect Link Up"drivers/pci/controller/dwc/pcie-dw-rockchip.c+0 -12 replies
2/6Revert "PCI: dw-rockchip: Enumerate endpoints based on dll_link_up IRQ"drivers/pci/controller/dwc/pcie-dw-rockchip.c+3 -560 replies
3/6Revert "PCI: qcom: Don't wait for link if we can detect Link Up"drivers/pci/controller/dwc/pcie-qcom.c+1 -40 replies
4/6Revert "PCI: qcom: Enable MSI interrupts together with Link up if 'Global IRQ' is supported"drivers/pci/controller/dwc/pcie-qcom.c+1 -33 replies
5/6Revert "PCI: qcom: Enumerate endpoints based on Link up event in 'global_irq' interrupt"drivers/pci/controller/dwc/pcie-qcom.c+1 -573 replies
6/6Revert "PCI: dwc: Don't wait for link up if driver can detect Link Up event"drivers/pci/controller/dwc/pcie-designware-host.c drivers/pci/controller/dwc/pcie-designware.h+2 -90 replies

Reviews trailers per patch

All 6 patches have a Reviewed-by or Acked-by.

PatchShawn Lin
1/6A-b T-b
2/6A-b T-b
3/6A-b T-b
4/6A-b T-b
5/6A-b T-b
6/6A-b T-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/6] PCI: dwc: Revert Link Up IRQ support

Revert all patches related to pcie-designware Root Complex Link Up IRQ support.

While this fake hotplugging was a nice idea, it has shown that this feature
does not handle PCIe switches correctly:
pci_bus 0004:43: busn_res: can not insert [bus 43-41] under [bus 42-41] (conflicts with (null) [bus 42-41]) pci_bus 0004:43: busn_res: [bus 43-41] end is updated to 43
pci_bus 0004:43: busn_res: can not insert [bus 43] under [bus 42-41] (conflicts with (null) [bus 42-41]) pci 0004:42:00.0: devices behind bridge are unusable because [bus 43] cannot be assigned for them pci_bus 0004:44: busn_res: can not insert [bus 44-41] under [bus 42-41] (conflicts with (null) [bus 42-41]) pci_bus 0004:44: busn_res: [bus 44-41] end is updated to 44
pci_bus 0004:44: busn_res: can not insert [bus 44] under [bus 42-41] (conflicts with (null) [bus 42-41]) pci 0004:42:02.0: devices behind bridge are unusable because [bus 44] cannot be assigned for them pci_bus 0004:45: busn_res: can not insert [bus 45-41] under [bus 42-41] (conflicts with (null) [bus 42-41]) pci_bus 0004:45: busn_res: [bus 45-41] end is updated to 45
pci_bus 0004:45: busn_res: can not insert [bus 45] under [bus 42-41] (conflicts with (null) [bus 42-41]) pci 0004:42:06.0: devices behind bridge are unusable because [bus 45] cannot be assigned for them pci_bus 0004:46: busn_res: can not insert [bus 46-41] under [bus 42-41] (conflicts with (null) [bus 42-41]) pci_bus 0004:46: busn_res: [bus 46-41] end is updated to 46
pci_bus 0004:46: busn_res: can not insert [bus 46] under [bus 42-41] (conflicts with (null) [bus 42-41]) pci 0004:42:0e.0: devices behind bridge are unusable because [bus 46] cannot be assigned for them pci_bus 0004:42: busn_res: [bus 42-41] end is updated to 46
pci_bus 0004:42: busn_res: can not insert [bus 42-46] under [bus 41] (conflicts with (null) [bus 41]) pci 0004:41:00.0: devices behind bridge are unusable because [bus 42-46] cannot be assigned for them pcieport 0004:40:00.0: bridge has subordinate 41 but max busn 46

During the initial scan, PCI core doesn't see the switch and since the Root Port is not hot plug capable, the secondary bus number gets assigned as the subordinate bus number. This means, the PCI core assumes that only one bus will appear behind the Root Port since the Root Port is not hot plug capable.

This works perfectly fine for PCIe endpoints connected to the Root Port, since they don't extend the bus. However, if a PCIe switch is connected, then there is a problem when the downstream busses starts showing up and the PCI core doesn't extend the subordinate bus number after initial scan during boot.

The long term plan is to migrate this driver to the pwrctrl framework, once it adds proper support for powering up and enumerating PCIe switches.

Changes since v1:
-Rebased against latest pci/controller/dwc
-Picked up tags.

Niklas Cassel (6):
Revert "PCI: dw-rockchip: Don't wait for link since we can detect Link

    Up"

Revert "PCI: dw-rockchip: Enumerate endpoints based on dll_link_up
IRQ"
Revert "PCI: qcom: Don't wait for link if we can detect Link Up" Revert "PCI: qcom: Enable MSI interrupts together with Link up if
'Global IRQ' is supported"
Revert "PCI: qcom: Enumerate endpoints based on Link up event in
'global_irq' interrupt"
Revert "PCI: dwc: Don't wait for link up if driver can detect Link Up
event"

 .../pci/controller/dwc/pcie-designware-host.c | 10 +--
 drivers/pci/controller/dwc/pcie-designware.h  |  1 -
 drivers/pci/controller/dwc/pcie-dw-rockchip.c | 60 +-----------------
 drivers/pci/controller/dwc/pcie-qcom.c        | 63 +------------------
 4 files changed, 6 insertions(+), 128 deletions(-)

base-commit: cfd2fdfd0a8da2e5bbfdc4009b9c4b8bf164c937

Signature · 1 line
2.52.0