summaryrefslogtreecommitdiffstats
path: root/kernel/drivers/mmc/card
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/drivers/mmc/card')
-rw-r--r--kernel/drivers/mmc/card/block.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/kernel/drivers/mmc/card/block.c b/kernel/drivers/mmc/card/block.c
index 60f7141a6..31d2627d9 100644
--- a/kernel/drivers/mmc/card/block.c
+++ b/kernel/drivers/mmc/card/block.c
@@ -208,6 +208,8 @@ static ssize_t power_ro_lock_show(struct device *dev,
ret = snprintf(buf, PAGE_SIZE, "%d\n", locked);
+ mmc_blk_put(md);
+
return ret;
}
@@ -1910,9 +1912,11 @@ static int mmc_blk_issue_rw_rq(struct mmc_queue *mq, struct request *rqc)
break;
case MMC_BLK_CMD_ERR:
ret = mmc_blk_cmd_err(md, card, brq, req, ret);
- if (!mmc_blk_reset(md, card->host, type))
- break;
- goto cmd_abort;
+ if (mmc_blk_reset(md, card->host, type))
+ goto cmd_abort;
+ if (!ret)
+ goto start_new_req;
+ break;
case MMC_BLK_RETRY:
if (retry++ < 5)
break;