You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
mmcsd_sdio: SDIO_RECVSETUP/SENDSETUP return values ignored on the non-DMA data paths #20399
In drivers/mmcsd/mmcsd_sdio.c the return value of SDIO_RECVSETUP is discarded on the non-DMA read paths, 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:
mmcsd_readsingle() — line 1665
mmcsd_readmultiple() — line 1821
The DMA paths in the same functions 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.
Activity