diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2009-11-03 00:52:16 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2009-11-03 00:52:16 +0000 |
commit | 6c6f9149193bdaf07556e82fee458df8974cd486 (patch) | |
tree | c90ad1eeda0d93c9eb7e1b085ee41ec31721cd19 | |
parent | f04bc06e98febf39134e8800e18ccb382093a7de (diff) | |
download | nuttx-6c6f9149193bdaf07556e82fee458df8974cd486.tar.gz nuttx-6c6f9149193bdaf07556e82fee458df8974cd486.tar.bz2 nuttx-6c6f9149193bdaf07556e82fee458df8974cd486.zip |
If SETUP received, that also means the end of a previous TX
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@2215 42af7a65-404d-4744-a932-0658087f49c3
-rw-r--r-- | nuttx/arch/arm/src/stm32/stm32_usbdev.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/nuttx/arch/arm/src/stm32/stm32_usbdev.c b/nuttx/arch/arm/src/stm32/stm32_usbdev.c index dbc0ce5a6..7c4035b6f 100644 --- a/nuttx/arch/arm/src/stm32/stm32_usbdev.c +++ b/nuttx/arch/arm/src/stm32/stm32_usbdev.c @@ -1479,7 +1479,6 @@ static void stm32_epdone(struct stm32_usbdev_s *priv, ubyte epno) /* Handle write requests */ - privep->txbusy = FALSE; priv->rxstatus = USB_EPR_STATRX_NAK; stm32_wrrequest(priv, privep); @@ -1544,9 +1543,10 @@ static void stm32_ep0setup(struct stm32_usbdev_s *priv) stm32_reqcomplete(ep0, result); } - /* Assume NOT stalled */ + /* Assume NOT stalled; no TX in progress */ ep0->stalled = 0; + ep0->txbusy = 0; /* Get a 32-bit PMA address and use that to get the 8-byte setup request */ @@ -2944,7 +2944,6 @@ static int stm32_epstall(struct usbdev_ep_s *ep, boolean resume) if (!stm32_rqempty(privep)) { - privep->txbusy = FALSE; (void)stm32_wrrequest(priv, privep); stm32_seteptxstatus(epno, USB_EPR_STATTX_VALID); } |