diff mbox series

[SRU,F,1/2] UBUNTU: SAUCE: Revert "Revert "xhci: Set HCD flag to defer primary roothub registration""

Message ID 1882e96daa8c1b10fa2f4db53d9b36ebf7bc9427.1649357153.git.luke.nowakowskikrijger@canonical.com
State New
Headers show
Series Fix USB devices not being detected at boot | expand

Commit Message

Luke Nowakowski-Krijger April 7, 2022, 8 p.m. UTC
BugLink: https://bugs.launchpad.net/bugs/1968210

This reverts commit 85c9591f77e68480ab6dfc3ce25f9033af28cf07.

Reintroduce this commit as it fixes an issue with certain intel xHCI
controllers where device enumeration happens before xHC is running,
causing USB devices not to be detected at boot time.

This commit will be reintroduced upstream due to previous bugs
being fixed, but lets reintroduce it now to fix the problem users are
experiencing.

Signed-off-by: Luke Nowakowski-Krijger <luke.nowakowskikrijger@canonical.com>
---
 drivers/usb/host/xhci.c | 1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c
index 1c8070023161..ca673a93fa8b 100644
--- a/drivers/usb/host/xhci.c
+++ b/drivers/usb/host/xhci.c
@@ -693,6 +693,7 @@  int xhci_run(struct usb_hcd *hcd)
 		if (ret)
 			xhci_free_command(xhci, command);
 	}
+	set_bit(HCD_FLAG_DEFER_RH_REGISTER, &hcd->flags);
 	xhci_dbg_trace(xhci, trace_xhci_dbg_init,
 			"Finished xhci_run for USB2 roothub");