diff --git a/src/drivers/bus/usb.c b/src/drivers/bus/usb.c index d8db3849a..d18751c66 100644 --- a/src/drivers/bus/usb.c +++ b/src/drivers/bus/usb.c @@ -405,13 +405,6 @@ static int usb_endpoint_reset ( struct usb_endpoint *ep ) { /* Sanity check */ assert ( ! list_empty ( &ep->halted ) ); - /* Reset endpoint */ - if ( ( rc = ep->host->reset ( ep ) ) != 0 ) { - DBGC ( usb, "USB %s %s could not reset: %s\n", - usb->name, usb_endpoint_name ( ep ), strerror ( rc ) ); - return rc; - } - /* Clear transaction translator, if applicable */ if ( ( rc = usb_endpoint_clear_tt ( ep ) ) != 0 ) return rc; @@ -427,6 +420,13 @@ static int usb_endpoint_reset ( struct usb_endpoint *ep ) { return rc; } + /* Reset endpoint */ + if ( ( rc = ep->host->reset ( ep ) ) != 0 ) { + DBGC ( usb, "USB %s %s could not reset: %s\n", + usb->name, usb_endpoint_name ( ep ), strerror ( rc ) ); + return rc; + } + /* Remove from list of halted endpoints */ list_del ( &ep->halted ); INIT_LIST_HEAD ( &ep->halted );