mirror of
https://git.codelinaro.org/clo/qsdk/oss/boot/u-boot-2016.git
synced 2026-03-10 03:07:16 +01:00
driver: mmc: sdhci: Add condition for DAT inhibit bit.
This change will handle masking of DAT inhibit bit of present state register. This status bit is genarated if either the DAT Line Active or Read Transfer Active is set to 1. If this bit is 0, it indicates the host controller can issue the next command. Commands with busy signal belong to Command Inhibit(DAT). e.g (R1b, R5b type). Changing from 1 to 0 generates a transfer complete interrupt in normal interrupt status register. If this bit value is 1: Cannot issue command which uses DAT line. If this bit value is 0: Can issue command which uses DAT line. This change is masking SDHCI_DATA_INHIBIT bit only if card is in busy state. Without this change we can get the erase timeout error. error: MMC erase: dev # 0, block # 27682, count 16383 ... sdhci_send_command: MMC: 0 busy timeout increasing to: 2000 ms. Change-Id: I0612e576c09a7fd077bed1a1ee717afcddfa7e87 Signed-off-by: Md Sadre Alam <mdalam@codeaurora.org>
This commit is contained in:
parent
d917f0032a
commit
ca63b592db
1 changed files with 4 additions and 1 deletions
|
|
@ -252,7 +252,10 @@ static int sdhci_send_command(struct mmc *mmc, struct mmc_cmd *cmd,
|
|||
static unsigned int cmd_timeout = CONFIG_SDHCI_CMD_DEFAULT_TIMEOUT;
|
||||
|
||||
sdhci_writel(host, SDHCI_INT_ALL_MASK, SDHCI_INT_STATUS);
|
||||
mask = SDHCI_CMD_INHIBIT | SDHCI_DATA_INHIBIT;
|
||||
|
||||
mask = SDHCI_CMD_INHIBIT;
|
||||
if ((data != NULL) || (cmd->resp_type & MMC_RSP_BUSY))
|
||||
mask |= SDHCI_DATA_INHIBIT;
|
||||
|
||||
/* We shouldn't wait for data inihibit for stop commands, even
|
||||
though they might use busy signaling */
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue