]> git.baikalelectronics.ru Git - kernel.git/commit
mmc: sdio: Enable SDIO 4-bit bus if not support SD_SCR_BUS_WIDTH_4 for SD combo card
authorYue Hu <huyue2@yulong.com>
Mon, 8 Jun 2020 10:30:09 +0000 (18:30 +0800)
committerUlf Hansson <ulf.hansson@linaro.org>
Mon, 13 Jul 2020 10:18:23 +0000 (12:18 +0200)
commit65a13c03d0eed9906c9f47cfd4ec34dc601c2e13
tree141a6617873a5fb2488e1c8624c8ea715a24aebb
parentb619b2582e647dbc3df0a57bd46d00996b73a1b8
mmc: sdio: Enable SDIO 4-bit bus if not support SD_SCR_BUS_WIDTH_4 for SD combo card

If the card type is SD combo(MMC_TYPE_SD_COMBO) and the memory part does
not support wider bus(SD_SCR_BUS_WIDTH_4), nothing will be done except
return 0. However, we should check whether IO part support wider bus or
not. We should use available IO ability if supported.

In addition, there's a duplicated check to MMC_CAP_4_BIT_DATA since
sdio_enable_wide() will include that check. And we can also save one
call site to sdio_enable_wide() after this change.

Signed-off-by: Yue Hu <huyue2@yulong.com>
Link: https://lore.kernel.org/r/20200608103009.5000-1-zbestahu@gmail.com
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
drivers/mmc/core/sdio.c