mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-24 13:43:28 +00:00
mmc: do not send cmd13 if the parameter 'send_status' is 0 for __mmc_switch
According to the code logic in __mmc_switch, if the parameter 'send_status' is zero, no need to send cmd13, just wait the stated timeout time, then can return directly. Signed-off-by: Haibo Chen <haibo.chen@nxp.com>
This commit is contained in:
parent
d3c610c623
commit
ef5ab0d13a
1 changed files with 3 additions and 1 deletions
|
@ -805,8 +805,10 @@ static int __mmc_switch(struct mmc *mmc, u8 set, u8 index, u8 value,
|
|||
* capable of polling by using mmc_wait_dat0, then rely on waiting the
|
||||
* stated timeout to be sufficient.
|
||||
*/
|
||||
if (ret == -ENOSYS && !send_status)
|
||||
if (ret == -ENOSYS && !send_status) {
|
||||
mdelay(timeout_ms);
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* Finally wait until the card is ready or indicates a failure
|
||||
* to switch. It doesn't hurt to use CMD13 here even if send_status
|
||||
|
|
Loading…
Reference in a new issue