From 81e08fb2ca97b65841ee03c14a60dea2b742c99d Mon Sep 17 00:00:00 2001 From: Maya Erez Date: Wed, 24 Nov 2010 08:48:18 +0200 Subject: mmc: core: Workaround to fix a hardware bug in Qualcomm-SDIO client on MDM Qualcomm-SDIO client on MDM contains NULL tuple for all SDIO functions 1 to 7 and doesn't contain any valid data. This patch is a temporary software workaround (not to read CIS if it is NULL tuple) until the hardware bug is resolved. The device ID 0x23F0 is for the SDIO client core on MDM8220. The device ID 0x23F1 is used for msm8660_charm. Change-Id: I82f44d313b3d499462977a0a9bbc0759f489ae95 Signed-off-by: Maya Erez Signed-off-by: Murali Palnati Signed-off-by: Raj Kushwaha [sboyd: Squash in two other device id patches] Signed-off-by: Stephen Boyd --- drivers/mmc/core/sdio_cis.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'drivers') diff --git a/drivers/mmc/core/sdio_cis.c b/drivers/mmc/core/sdio_cis.c index 8e94e555b788..1ab4560003ef 100644 --- a/drivers/mmc/core/sdio_cis.c +++ b/drivers/mmc/core/sdio_cis.c @@ -270,8 +270,16 @@ static int sdio_read_cis(struct mmc_card *card, struct sdio_func *func) break; /* null entries have no link field or data */ - if (tpl_code == 0x00) - continue; + if (tpl_code == 0x00) { + if (card->cis.vendor == 0x70 && + (card->cis.device == 0x2460 || + card->cis.device == 0x0460 || + card->cis.device == 0x23F1 || + card->cis.device == 0x23F0)) + break; + else + continue; + } ret = mmc_io_rw_direct(card, 0, 0, ptr++, 0, &tpl_link); if (ret) -- cgit v1.2.3