ldube commented on code in PR #8879:
URL: https://github.com/apache/nuttx/pull/8879#discussion_r1146280898


##########
arch/arm/src/sama5/sam_ohci.c:
##########
@@ -3899,20 +3907,18 @@ static void sam_disconnect(struct usbhost_driver_s 
*drvr,
   DEBUGASSERT(rhport != NULL && hport != NULL && hport->ep0);
   ep0 = (struct sam_eplist_s *)hport->ep0;
 
-  /* Remove the disconnected port from the control list */
-
-  sam_ep0dequeue(ep0);

Review Comment:
   Calling this when ep0 is NULL will cause a crash.
   Should only be called for a root hub.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to