[PATCH] usb: chipidea: udc: fix setup_status condition in isr

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

 



The isr is going to check for a status phase on the indexed endpoint.
Input endpoints have no status bits and can be skipped for that test.

Signed-off-by: Michael Grzeschik <m.grzeschik@xxxxxxxxxxxxxx>
---
This patch is based on the change mentioned by Matthieu CASTET,
but moves the check before using hw_test_and_clear_setup_status.

 drivers/usb/chipidea/udc.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/usb/chipidea/udc.c b/drivers/usb/chipidea/udc.c
index 69d20fb..9364184 100644
--- a/drivers/usb/chipidea/udc.c
+++ b/drivers/usb/chipidea/udc.c
@@ -989,6 +989,7 @@ __acquires(ci->lock)
 		}
 
 		if (hwep->type != USB_ENDPOINT_XFER_CONTROL ||
+		    (i >= ci->hw_ep_max / 2) ||
 		    !hw_test_and_clear_setup_status(ci, i))
 			continue;
 
-- 
1.8.5.2

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux