Skip to content

Commit

Permalink
mmc: core: use defined R1_STATE_PRG macro for card status
Browse files Browse the repository at this point in the history
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
  • Loading branch information
Jaehoon Chung authored and Chris Ball committed Aug 13, 2011
1 parent 65be3fe commit 7435bb7
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion drivers/mmc/card/mmc_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ static void mmc_test_prepare_mrq(struct mmc_test_card *test,
static int mmc_test_busy(struct mmc_command *cmd)
{
return !(cmd->resp[0] & R1_READY_FOR_DATA) ||
(R1_CURRENT_STATE(cmd->resp[0]) == 7);
(R1_CURRENT_STATE(cmd->resp[0]) == R1_STATE_PRG);
}

/*
Expand Down
2 changes: 1 addition & 1 deletion drivers/mmc/core/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1502,7 +1502,7 @@ static int mmc_do_erase(struct mmc_card *card, unsigned int from,
goto out;
}
} while (!(cmd.resp[0] & R1_READY_FOR_DATA) ||
R1_CURRENT_STATE(cmd.resp[0]) == 7);
R1_CURRENT_STATE(cmd.resp[0]) == R1_STATE_PRG);
out:
return err;
}
Expand Down
2 changes: 1 addition & 1 deletion drivers/mmc/core/mmc_ops.c
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,7 @@ int mmc_switch(struct mmc_card *card, u8 set, u8 index, u8 value,
break;
if (mmc_host_is_spi(card->host))
break;
} while (R1_CURRENT_STATE(status) == 7);
} while (R1_CURRENT_STATE(status) == R1_STATE_PRG);

if (mmc_host_is_spi(card->host)) {
if (status & R1_SPI_ILLEGAL_COMMAND)
Expand Down

0 comments on commit 7435bb7

Please sign in to comment.