Skip to content

Commit

Permalink
mmc_test: use API to check card type
Browse files Browse the repository at this point in the history
There are methods to check card type. Let's use them instead of direct checking
type bits.

Signed-off-by: Andy Shevchenko <ext-andriy.shevchenko@nokia.com>
Cc: <linux-mmc@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Chris Ball <cjb@laptop.org>
  • Loading branch information
Andy Shevchenko authored and Chris Ball committed Oct 23, 2010
1 parent c8c8c1b commit 63be54c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/mmc/card/mmc_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -2064,7 +2064,7 @@ static int mmc_test_probe(struct mmc_card *card)
{
int ret;

if ((card->type != MMC_TYPE_MMC) && (card->type != MMC_TYPE_SD))
if (!mmc_card_mmc(card) && !mmc_card_sd(card))
return -ENODEV;

ret = device_create_file(&card->dev, &dev_attr_test);
Expand Down

0 comments on commit 63be54c

Please sign in to comment.