[PATCH 15/15] usb: xhci: Do not panic on event timeouts

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This ports U-Boot commit 2fd7037122a920ae22377b06aa5b32651cc71f13:

| Author:     Hector Martin <marcan@xxxxxxxxx>
| AuthorDate: Sun Oct 29 15:37:43 2023 +0900
|
| usb: xhci: Do not panic on event timeouts
|
| Now that we always check the return value, just return NULL on timeouts.
| We can still log the error since this is a problem, but it's not reason
| to panic.
|
| Signed-off-by: Hector Martin <marcan@xxxxxxxxx>

Signed-off-by: Ahmad Fatoum <a.fatoum@xxxxxxxxxxxxxx>
---
 drivers/usb/host/xhci-ring.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c
index 6a859dbbfac9..5f68bc7c2f35 100644
--- a/drivers/usb/host/xhci-ring.c
+++ b/drivers/usb/host/xhci-ring.c
@@ -497,8 +497,9 @@ union xhci_trb *xhci_wait_for_event(struct xhci_ctrl *ctrl, trb_type expected,
 	if (expected == TRB_TRANSFER)
 		return NULL;
 
-	dev_err(ctrl->dev, "XHCI timeout on event type %d... cannot recover.\n", expected);
-	BUG();
+	dev_warn(ctrl->dev, "XHCI timeout on event type %d...\n", expected);
+
+	return NULL;
 }
 
 /*
-- 
2.39.2





[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux