This is an automated email from the ASF dual-hosted git repository.
pkarashchenko pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git
The following commit(s) were added to refs/heads/master by this push:
new 673cb18a7a drivers/mmcsd: mmcsd_sdinitialize should save csd register
into priv->csd
673cb18a7a is described below
commit 673cb18a7a25d151ae8021f66880a38998801218
Author: Xiang Xiao <[email protected]>
AuthorDate: Tue Oct 17 23:38:52 2023 +0800
drivers/mmcsd: mmcsd_sdinitialize should save csd register into priv->csd
just like what mmcsd_mmcinitialize do
Signed-off-by: Xiang Xiao <[email protected]>
---
drivers/mmcsd/mmcsd_sdio.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/mmcsd/mmcsd_sdio.c b/drivers/mmcsd/mmcsd_sdio.c
index a570568d72..68ee8ff5d2 100644
--- a/drivers/mmcsd/mmcsd_sdio.c
+++ b/drivers/mmcsd/mmcsd_sdio.c
@@ -3260,7 +3260,6 @@ static int mmcsd_multi_iocmd(FAR struct mmcsd_state_s
*priv,
static int mmcsd_sdinitialize(FAR struct mmcsd_state_s *priv)
{
uint32_t cid[4];
- uint32_t csd[4];
uint32_t scr[2];
int ret;
@@ -3331,14 +3330,14 @@ static int mmcsd_sdinitialize(FAR struct mmcsd_state_s
*priv)
*/
mmcsd_sendcmdpoll(priv, MMCSD_CMD9, (uint32_t)priv->rca << 16);
- ret = SDIO_RECVR2(priv->dev, MMCSD_CMD9, csd);
+ ret = SDIO_RECVR2(priv->dev, MMCSD_CMD9, priv->csd);
if (ret != OK)
{
ferr("ERROR: Could not get SD CSD register(%d)\n", ret);
return ret;
}
- mmcsd_decode_csd(priv, csd);
+ mmcsd_decode_csd(priv, priv->csd);
/* Send CMD7 with the argument == RCA in order to select the card.
* Since we are supporting only a single card, we just leave the