diff options
author | Seunghui Lee <sh043.lee@samsung.com> | 2022-07-13 12:36:34 +0900 |
---|---|---|
committer | Ulf Hansson <ulf.hansson@linaro.org> | 2022-07-13 12:44:41 +0200 |
commit | 3beb0ab5bffba625007ea5c9e5e0ee5eef05c1ea (patch) | |
tree | db059021eb00edacef6acb8dd546749439f7d7a5 /drivers/mmc/core/bus.c | |
parent | 54c16b522e00583ba1151501286b0cf4c91e08c3 (diff) | |
download | linux-3beb0ab5bffba625007ea5c9e5e0ee5eef05c1ea.tar.gz linux-3beb0ab5bffba625007ea5c9e5e0ee5eef05c1ea.tar.bz2 linux-3beb0ab5bffba625007ea5c9e5e0ee5eef05c1ea.zip |
mmc: core: Use mmc_card_* macro and add a new for the sd_combo type
Add mmc_card_sd_combo() macro for sd combo type card and use the mmc_card_*
macro to simplify code instead of comparing card->type.
Signed-off-by: Seunghui Lee <sh043.lee@samsung.com>
Link: https://lore.kernel.org/r/20220713033635.28432-2-sh043.lee@samsung.com
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Diffstat (limited to 'drivers/mmc/core/bus.c')
-rw-r--r-- | drivers/mmc/core/bus.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/mmc/core/bus.c b/drivers/mmc/core/bus.c index 58a60afa650b..d8762fa3d5cd 100644 --- a/drivers/mmc/core/bus.c +++ b/drivers/mmc/core/bus.c @@ -85,7 +85,7 @@ mmc_bus_uevent(struct device *dev, struct kobj_uevent_env *env) return retval; } - if (card->type == MMC_TYPE_SDIO || card->type == MMC_TYPE_SD_COMBO) { + if (mmc_card_sdio(card) || mmc_card_sd_combo(card)) { retval = add_uevent_var(env, "SDIO_ID=%04X:%04X", card->cis.vendor, card->cis.device); if (retval) @@ -107,7 +107,7 @@ mmc_bus_uevent(struct device *dev, struct kobj_uevent_env *env) * SDIO (non-combo) cards are not handled by mmc_block driver and do not * have accessible CID register which used by mmc_card_name() function. */ - if (card->type == MMC_TYPE_SDIO) + if (mmc_card_sdio(card)) return 0; retval = add_uevent_var(env, "MMC_NAME=%s", mmc_card_name(card)); |