mmcsd: Add gotextcsd callback to sdio_dev_s
so the driver implementation could get critical EXTCSD info Signed-off-by: anjianjun <anjianjun@xiaomi.com>
This commit is contained in:
parent
5b214888aa
commit
f95d13b3a1
@ -2758,6 +2758,8 @@ static int mmcsd_read_csd(FAR struct mmcsd_state_s *priv)
|
||||
finfo("MMC ext CSD read succsesfully, number of block %" PRId32 "\n",
|
||||
priv->nblocks);
|
||||
|
||||
SDIO_GOTEXTCSD(priv->dev, buffer);
|
||||
|
||||
/* Return value: One sector read */
|
||||
|
||||
return OK;
|
||||
|
@ -539,6 +539,24 @@
|
||||
|
||||
#define SDIO_CLOCK(dev,rate) ((dev)->clock(dev,rate))
|
||||
|
||||
/****************************************************************************
|
||||
* Name: SDIO_GOTEXTCSD
|
||||
*
|
||||
* Description:
|
||||
* Notify driver EXT CSD data
|
||||
*
|
||||
* Input Parameters:
|
||||
* dev - An instance of the SDIO device interface
|
||||
* buffer - Ext Csd data
|
||||
*
|
||||
* Returned Value:
|
||||
* None.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#define SDIO_GOTEXTCSD(dev,buffer) \
|
||||
((dev)->gotextcsd?(dev)->gotextcsd(dev,buffer):OK)
|
||||
|
||||
/****************************************************************************
|
||||
* Name: SDIO_ATTACH
|
||||
*
|
||||
@ -1008,6 +1026,7 @@ struct sdio_dev_s
|
||||
int (*dmasendsetup)(FAR struct sdio_dev_s *dev,
|
||||
FAR const uint8_t *buffer, size_t buflen);
|
||||
#endif /* CONFIG_SDIO_DMA */
|
||||
void (*gotextcsd)(FAR struct sdio_dev_s *dev, FAR const uint8_t *buffer);
|
||||
};
|
||||
|
||||
/****************************************************************************
|
||||
|
Loading…
Reference in New Issue
Block a user