]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
mmc: core: use defined R1_STATE_PRG macro for card status
authorJaehoon Chung <jh80.chung@samsung.com>
Wed, 10 Aug 2011 09:46:28 +0000 (18:46 +0900)
committerChris Ball <cjb@laptop.org>
Sat, 13 Aug 2011 18:50:31 +0000 (14:50 -0400)
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>
drivers/mmc/card/mmc_test.c
drivers/mmc/core/core.c
drivers/mmc/core/mmc_ops.c

index 742dc98a034c1d0609bc88a741a65d0c51af2229..2bf229acd3b8110c3a03bc3dbb9783e2451ef099 100644 (file)
@@ -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);
 }
 
 /*
index 89bdeaec7182904f83a4e3810925bcefffc3c55b..91a0a7460ebbe855d4a7753cf89db54432b35545 100644 (file)
@@ -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;
 }
index 845ce7c533b901b0895a6bf4c5715c676c5cd902..770c3d06f5dcd1a01814065464d7c20a6f7d051f 100644 (file)
@@ -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)