diff options
Diffstat (limited to 'drivers/mmc/card')
-rw-r--r-- | drivers/mmc/card/block.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/mmc/card/block.c b/drivers/mmc/card/block.c index 93fe2e5dd616..0da341acf32b 100644 --- a/drivers/mmc/card/block.c +++ b/drivers/mmc/card/block.c | |||
@@ -154,7 +154,7 @@ static u32 mmc_sd_num_wr_blocks(struct mmc_card *card) | |||
154 | cmd.flags = MMC_RSP_R1 | MMC_CMD_AC; | 154 | cmd.flags = MMC_RSP_R1 | MMC_CMD_AC; |
155 | 155 | ||
156 | err = mmc_wait_for_cmd(card->host, &cmd, 0); | 156 | err = mmc_wait_for_cmd(card->host, &cmd, 0); |
157 | if ((err != MMC_ERR_NONE) || !(cmd.resp[0] & R1_APP_CMD)) | 157 | if (err || !(cmd.resp[0] & R1_APP_CMD)) |
158 | return (u32)-1; | 158 | return (u32)-1; |
159 | 159 | ||
160 | memset(&cmd, 0, sizeof(struct mmc_command)); | 160 | memset(&cmd, 0, sizeof(struct mmc_command)); |
@@ -192,7 +192,7 @@ static u32 mmc_sd_num_wr_blocks(struct mmc_card *card) | |||
192 | 192 | ||
193 | mmc_wait_for_req(card->host, &mrq); | 193 | mmc_wait_for_req(card->host, &mrq); |
194 | 194 | ||
195 | if (cmd.error != MMC_ERR_NONE || data.error != MMC_ERR_NONE) | 195 | if (cmd.error || data.error) |
196 | return (u32)-1; | 196 | return (u32)-1; |
197 | 197 | ||
198 | blocks = ntohl(blocks); | 198 | blocks = ntohl(blocks); |