From 6ebec89ac675de86f989b60c43c9b52f652c515d Mon Sep 17 00:00:00 2001 From: Amaury Pouly Date: Thu, 14 Oct 2010 19:15:22 +0000 Subject: [PATCH] as3525v2-usb! fix suspicious calculation of next endpoint in INs chaining code git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28281 a1c6a512-1295-4272-9138-f99709370657 --- firmware/target/arm/as3525/usb-drv-as3525v2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/firmware/target/arm/as3525/usb-drv-as3525v2.c b/firmware/target/arm/as3525/usb-drv-as3525v2.c index 63f6e83dff..a507f54355 100644 --- a/firmware/target/arm/as3525/usb-drv-as3525v2.c +++ b/firmware/target/arm/as3525/usb-drv-as3525v2.c @@ -303,7 +303,7 @@ static void reset_endpoints(void) /* Setup next chain for IN eps */ FOR_EACH_IN_EP_AND_EP0(i, ep) { - int next_ep = in_ep_list[(i + 2) % (NUM_IN_EP + 1)]; + int next_ep = in_ep_list[(i + 1) % (NUM_IN_EP + 1)]; DIEPCTL(ep) = (DIEPCTL(ep) & ~bitm(DEPCTL, nextep)) | (next_ep << DEPCTL_nextep_bitp); } }