Re: [RFC] PCIe host controller async probe vs PHY request_module deadlock

From: Hans Zhang

Date: Fri Nov 27 2026 - 11:04:57 EST




On 11/27/26 22:59, Andrew Lunn wrote:
Andrew suggested:

drivers/pci/controller/cadence/pci-sky1.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/pci/controller/cadence/pci-sky1.c
b/drivers/pci/controller/cadence/pci-sky1.c
index 82f4ae5c04a8..4448ee3d5e73 100644
--- a/drivers/pci/controller/cadence/pci-sky1.c
+++ b/drivers/pci/controller/cadence/pci-sky1.c
@@ -235,7 +235,7 @@ static struct platform_driver sky1_pcie_driver = {
.driver = {
.name = "sky1-pcie",
.of_match_table = of_sky1_pcie_match,
- .probe_type = PROBE_PREFER_ASYNCHRONOUS,
+ .probe_type = PROBE_FORCE_SYNCHRONOUS,

Sorry, i was ambiguous. I meant the MAC driver should probe
synchronous, not the PCIe bus driver.

I don't know the details, but i assume this is some sort of tree, and
a list. The root node enumerates, and adds to the list of things to be
probed. The device core then has a bunch of workers which take stuff
off the list and does the probe. Those probes can add more things to
the list, and it works its way down the tree. The first iteration will
only pull jobs of the list which have PROBE_PREFER_ASYNCHRONOUS, so
you can prevent branches of the tree from enumerating by setting
PROBE_FORCE_SYNCHRONOUS on the driver at that level in the tree.

So i assume you can mark the MAC driver hanging of the PCIe bus probe
to happen later, while other sorts of PCIe devices probe async?



Hello Andrew,


Would you have time to review the previous discussion? Additionally, I will continue to conduct tests based on your previous reply.

https://lore.kernel.org/driver-core/DGZJBMG2Y738.2MU5LXVGEDD47@xxxxxxxxxx/

The modification will be made in the MAC driver.


Best regards,
Hans