Skip to contentSkip to conversation

usb: ehci-hcd: use is_timeout_non_interruptible()

PATCH Applied Peter Mamonov 2 participants 2 messages Sep 9, 2015 – Sep 10, 2015

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 usb: ehci-hcd: use is_timeout_non_interruptible()

Use is_timeout_non_interruptible() intead of is_timeout() to avoid re-entering ehci-hcd functions from pollers, registered by usb drivers.

---
 drivers/usb/host/ehci-hcd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/usb/host/ehci-hcd.c +2 -2
index 1077ac4..7ca77bf 100644
@@ -137,7 +137,7 @@ static int handshake(uint32_t *ptr, uint32_t mask, uint32_t done, int usec)
 		result &= mask;
 		if (result == done)
 			return 0;
-		if (is_timeout(start, usec * USECOND))
+		if (is_timeout_non_interruptible(start, usec * USECOND))
 			return -ETIMEDOUT;
 	}
 }
@@ -357,7 +357,7 @@ ehci_submit_async(struct usb_device *dev, unsigned long pipe, void *buffer,
 	do {
 		token = hc32_to_cpu(vtd->qt_token);
 		token = hc32_to_cpu(__raw_readl((void *)&vtd->qt_token));
-		if (is_timeout(start, timeout_val)) {
+		if (is_timeout_non_interruptible(start, timeout_val)) {
 			/* Disable async schedule. */
 			cmd = ehci_readl(&ehci->hcor->or_usbcmd);
 			cmd &= ~CMD_ASE;
Signature · 7 lines
2.1.4


_______________________________________________
barebox mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/barebox
Applied
#1 lore raw
Quoted 5 lines · Peter Mamonov

Use is_timeout_non_interruptible() intead of is_timeout() to avoid re-entering ehci-hcd functions from pollers, registered by usb drivers.

Applied, thanks

Sascha

Signature · 9 lines
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/barebox