aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHector Martin <marcan@marcan.st>2023-10-29 15:37:42 +0900
committerMarek Vasut <marex@denx.de>2023-12-01 14:06:04 +0100
commitfb5502be2544f9c3a7f662e6618e26f0831d242d (patch)
tree01b074554ec476ae9c64ae65d782173e65fe306f
parent9d88bd4dcf1628bf129163eb5a25c48068423601 (diff)
downloadu-boot-fb5502be2544f9c3a7f662e6618e26f0831d242d.zip
u-boot-fb5502be2544f9c3a7f662e6618e26f0831d242d.tar.gz
u-boot-fb5502be2544f9c3a7f662e6618e26f0831d242d.tar.bz2
usb: xhci: Fail on attempt to queue TRBs to a halted endpoint
This isn't going to work, don't pretend it will and then end up timing out. Signed-off-by: Hector Martin <marcan@marcan.st> Reviewed-by: Marek Vasut <marex@denx.de>
-rw-r--r--drivers/usb/host/xhci-ring.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c
index db8b8f2..a969eaf 100644
--- a/drivers/usb/host/xhci-ring.c
+++ b/drivers/usb/host/xhci-ring.c
@@ -243,7 +243,8 @@ static int prepare_ring(struct xhci_ctrl *ctrl, struct xhci_ring *ep_ring,
puts("WARN waiting for error on ep to be cleared\n");
return -EINVAL;
case EP_STATE_HALTED:
- puts("WARN halted endpoint, queueing URB anyway.\n");
+ puts("WARN endpoint is halted\n");
+ return -EINVAL;
case EP_STATE_STOPPED:
case EP_STATE_RUNNING:
debug("EP STATE RUNNING.\n");