rikaken2004 opened a new issue, #20399: URL: https://github.com/apache/nuttx/issues/20399
In drivers/mmcsd/mmcsd_sdio.c the return value of SDIO_RECVSETUP is discarded in mmcsd_readsingle() (:1665) and mmcsd_readmultiple() (:1821), so when the lower half fails to set up the receive the driver still issues CMD17/CMD18 and the failure only surfaces later as an unrelated-looking transfer timeout. The DMA paths in the same functions do check SDIO_DMARECVSETUP and bail out (:1654-1661, :1810-1818), which makes the unchecked non-DMA paths look like an oversight. The write side has the same asymmetry: SDIO_SENDSETUP goes unchecked in mmcsd_writesingle() (:2016) and mmcsd_writemultiple() (:2268) while the DMA send paths check theirs. There are a few more unchecked sites as well (:573, :2839, :3431, :3568, :3696). The fix is to check the return value, SDIO_CANCEL and propagate the error, mirroring the DMA paths. Happy to open a PR. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
