Skip to contentSkip to conversation

PCI: fix the printed delay amount in info print

PATCH Applied Wilfred Mallawa 5 participants 5 messages Apr 14, 2025 – Apr 17, 2025 PCI

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 PCI: fix the printed delay amount in info print

From: Wilfred Mallawa <[email protected]>

Print the delay amount that pcie_wait_for_link_delay() is invoked with instead of the hardcoded 1000ms value in the debug info print.

Fixes 7b3ba09febf4 ("PCI/PM: Shorten pci_bridge_wait_for_secondary_bus() wait time for slow links")
---
 drivers/pci/pci.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/pci/pci.c +1 -1
index 869d204a70a3..8139b70cafa9 100644
@@ -4935,7 +4935,7 @@ int pci_bridge_wait_for_secondary_bus(struct pci_dev *dev, char *reset_type)
 		delay);
 	if (!pcie_wait_for_link_delay(dev, true, delay)) {
 		/* Did not train, no need to wait any further */
-		pci_info(dev, "Data Link Layer Link Active not set in 1000 msec\n");
+		pci_info(dev, "Data Link Layer Link Active not set in %d msec\n", delay);
 		return -ENOTTY;
 	}
 
Signature · 1 line
2.49.0
Reviewed-by on v2 1/1
#1 lore raw
Quoted 9 lines · Wilfred Mallawa

From: Wilfred Mallawa <[email protected]>

Print the delay amount that pcie_wait_for_link_delay() is invoked with instead of the hardcoded 1000ms value in the debug info print.

Fixes 7b3ba09febf4 ("PCI/PM: Shorten pci_bridge_wait_for_secondary_bus() wait time for slow links")

---

Quoted 16 lines
  drivers/pci/pci.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
drivers/pci/pci.c +1 -1
index 869d204a70a3..8139b70cafa9 100644
@@ -4935,7 +4935,7 @@ int pci_bridge_wait_for_secondary_bus(struct pci_dev *dev, char *reset_type)
  		delay);
  	if (!pcie_wait_for_link_delay(dev, true, delay)) {
  		/* Did not train, no need to wait any further */
-		pci_info(dev, "Data Link Layer Link Active not set in 1000 msec\n");
+		pci_info(dev, "Data Link Layer Link Active not set in %d msec\n", delay);
  		return -ENOTTY;
  	}
 
Signature · 2 lines
Sathyanarayanan Kuppuswamy
Linux Kernel Developer
Reviewed-by on v2 1/1
#2 lore raw
In reply to Wilfred Mallawa
Quoted 8 lines · Wilfred Mallawa

From: Wilfred Mallawa <[email protected]>

Print the delay amount that pcie_wait_for_link_delay() is invoked with instead of the hardcoded 1000ms value in the debug info print.

Fixes 7b3ba09febf4 ("PCI/PM: Shorten pci_bridge_wait_for_secondary_bus() wait time for slow links")
Reviewed-by on v2 1/1
#3 lore raw
In reply to Wilfred Mallawa
Quoted 18 lines · Wilfred Mallawa

From: Wilfred Mallawa <[email protected]>

Print the delay amount that pcie_wait_for_link_delay() is invoked with instead of the hardcoded 1000ms value in the debug info print.

Fixes 7b3ba09febf4 ("PCI/PM: Shorten pci_bridge_wait_for_secondary_bus() wait time for slow links")
---
 drivers/pci/pci.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/pci/pci.c +0 -0
index 869d204a70a3..8139b70cafa9 100644

drivers/pci/pci.c int pci_bridge_wait_for_secondary_bus(struct pci_dev *dev, char *reset_type) · line 4941

Quoted 8 lines
drivers/pci/pci.c +1 -1
@@ -4935,7 +4935,7 @@ int pci_bridge_wait_for_secondary_bus(struct pci_dev *dev, char *reset_type)
 		delay);
 	if (!pcie_wait_for_link_delay(dev, true, delay)) {
 		/* Did not train, no need to wait any further */
-		pci_info(dev, "Data Link Layer Link Active not set in 1000 msec\n");
+		pci_info(dev, "Data Link Layer Link Active not set in %d msec\n", delay);
 		return -ENOTTY;
 	}
 
Signature · 1 line
 i.
#4 lore raw
In reply to Wilfred Mallawa
Quoted 8 lines · Wilfred Mallawa

From: Wilfred Mallawa <[email protected]>

Print the delay amount that pcie_wait_for_link_delay() is invoked with instead of the hardcoded 1000ms value in the debug info print.

Fixes 7b3ba09febf4 ("PCI/PM: Shorten pci_bridge_wait_for_secondary_bus() wait time for slow links")

Applied to pci/enumeration for v6.16, thanks!

Quoted 20 lines
---
 drivers/pci/pci.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/pci/pci.c +1 -1
index 869d204a70a3..8139b70cafa9 100644
@@ -4935,7 +4935,7 @@ int pci_bridge_wait_for_secondary_bus(struct pci_dev *dev, char *reset_type)
 		delay);
 	if (!pcie_wait_for_link_delay(dev, true, delay)) {
 		/* Did not train, no need to wait any further */
-		pci_info(dev, "Data Link Layer Link Active not set in 1000 msec\n");
+		pci_info(dev, "Data Link Layer Link Active not set in %d msec\n", delay);
 		return -ENOTTY;
 	}
 
Signature · 1 line
2.49.0