1
0
Fork 0
forked from nuttx/nuttx-update

drivers/usbdev_fs: when the device is not opened, the received data is retained.

It is up to the app to determine whether the data is valid when opened

Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
This commit is contained in:
sunkun3 2023-11-27 16:53:35 +08:00 committed by Xiang Xiao
parent 1b7a95c756
commit e3a6368c9a

View file

@ -263,15 +263,7 @@ static void usbdev_fs_rdcomplete(FAR struct usbdev_ep_s *ep,
usbtrace(TRACE_CLASSRDCOMPLETE, sq_count(&fs_ep->reqq));
/* Restart request due to either no reader or
* empty frame received.
*/
if (fs_ep->crefs == 0)
{
uwarn("drop frame\n");
goto restart_req;
}
/* Restart request due to empty frame received */
if (req->xfrd <= 0)
{