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

Configure Feed

Select the types of activity you want to include in your feed.

mmc: core: Enable SDUC

Enable SDUC if the card responded to ACMD41 with HCS & HO2T bits set.

Reviewed-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Avri Altman <avri.altman@wdc.com>
Link: https://lore.kernel.org/r/20241006051148.160278-11-avri.altman@wdc.com
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>

authored by

Avri Altman and committed by
Ulf Hansson
899404e1 a7861651

+8 -2
+8 -2
drivers/mmc/core/sd.c
··· 836 836 * block-addressed SDHC cards. 837 837 */ 838 838 err = mmc_send_if_cond(host, ocr); 839 - if (!err) 839 + if (!err) { 840 840 ocr |= SD_OCR_CCS; 841 + /* Set HO2T as well - SDUC card won't respond otherwise */ 842 + ocr |= SD_OCR_2T; 843 + } 841 844 842 845 /* 843 846 * If the host supports one of UHS-I modes, request the card ··· 1451 1448 } 1452 1449 1453 1450 if (!oldcard) { 1454 - err = mmc_sd_get_csd(card, false); 1451 + u32 sduc_arg = SD_OCR_CCS | SD_OCR_2T; 1452 + bool is_sduc = (rocr & sduc_arg) == sduc_arg; 1453 + 1454 + err = mmc_sd_get_csd(card, is_sduc); 1455 1455 if (err) 1456 1456 goto free_card; 1457 1457