mirror of
https://github.com/apache/nuttx.git
synced 2026-06-06 16:50:55 +08:00
Finish event wait logic
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@2265 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
+280
-151
File diff suppressed because it is too large
Load Diff
@@ -425,13 +425,11 @@ static int mmcsd_getSCR(FAR struct mmcsd_state_s *priv, uint32 scr[2])
|
||||
int ret;
|
||||
|
||||
/* Set Block Size To 8 Bytes */
|
||||
/* Send CMD55 APP_CMD with argument as card's RCA */
|
||||
|
||||
mmcsd_sendcmdpoll(priv, MMCSD_CMD16, 8);
|
||||
ret = mmcsd_recvR1(priv, MMCSD_CMD16);
|
||||
ret = mmcsd_setblocklen(priv, 8);
|
||||
if (ret != OK)
|
||||
{
|
||||
fdbg("ERROR: RECVR1 for CMD16 failed: %d\n", ret);
|
||||
fdbg("ERROR: mmcsd_setblocklen failed: %d\n", ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
@@ -52,11 +52,11 @@
|
||||
* Wait events are used for event-waiting by SDIO_WAITENABLE and SDIO_EVENTWAIT
|
||||
*/
|
||||
|
||||
#define SDIOWAIT_CMDDONE (1 << 0) /* Bit 0: Command+response complete */
|
||||
#define SDIOWAIT_CMDBUSYDONE (1 << 1) /* Bit 1: Command with transition to not busy */
|
||||
#define SDIOWAIT_CMDDONE (1 << 0) /* Bit 0: Command complete */
|
||||
#define SDIOWAIT_RESPONSEDONE (1 << 1) /* Bit 1: Response to command available */
|
||||
#define SDIOWAIT_TRANSFERDONE (1 << 2) /* Bit 2: Data transfer/DMA done */
|
||||
|
||||
#define SDIOWAIT_ALLEVENTS 0x03
|
||||
#define SDIOWAIT_ALLEVENTS 0x07
|
||||
|
||||
/* Media events are used for enable/disable registered event callbacks */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user