Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mmc: card: add mmc_card_blk_no_cmd23

Add a helper to check for the missing CMD23 quirk, similar to other
quirk helpers. Also reorder the helpers to match the order of the quirk
bits defined in include/linux/mmc/card.h.

Signed-off-by: Benoît Monin <benoit.monin@bootlin.com>
Link: https://lore.kernel.org/r/20250818-mobileye-emmc-for-upstream-4-v4-2-34ecb3995e96@bootlin.com
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>

authored by

Benoît Monin and committed by
Ulf Hansson
05849fc5 18f7439f

+7 -2
+7 -2
drivers/mmc/core/card.h
··· 245 245 return c->quirks & MMC_QUIRK_BLKSZ_FOR_BYTE_MODE; 246 246 } 247 247 248 + static inline int mmc_card_nonstd_func_interface(const struct mmc_card *c) 249 + { 250 + return c->quirks & MMC_QUIRK_NONSTD_FUNC_IF; 251 + } 252 + 248 253 static inline int mmc_card_disable_cd(const struct mmc_card *c) 249 254 { 250 255 return c->quirks & MMC_QUIRK_DISABLE_CD; 251 256 } 252 257 253 - static inline int mmc_card_nonstd_func_interface(const struct mmc_card *c) 258 + static inline int mmc_card_blk_no_cmd23(const struct mmc_card *c) 254 259 { 255 - return c->quirks & MMC_QUIRK_NONSTD_FUNC_IF; 260 + return c->quirks & MMC_QUIRK_BLK_NO_CMD23; 256 261 } 257 262 258 263 static inline int mmc_card_broken_byte_mode_512(const struct mmc_card *c)