mmc: sdhci: Notify sdhci-msm for enhanced strobe

Provide sdhci host ops of enhanced strobe to notify
sdhci-msm on enabling/disabling cmdq. This is needed
because of following:

Before running CMDQ transfers in HS400 Enhanced Strobe mode,
SW should write 3 to
HC_VENDOR_SPECIFIC_FUNC3.CMDEN_HS400_INPUT_MASK_CNT register.
Default reset value of this register is 2.

Change-Id: I987605cd21f137dea49ddf3e8db3f1f41b5b501f
Signed-off-by: Ritesh Harjani <riteshh@codeaurora.org>
[subhashj@codeaurora.org: fixed trivial merge conflicts]
Signed-off-by: Subhash Jadavani <subhashj@codeaurora.org>
This commit is contained in:
Ritesh Harjani 2015-07-15 13:31:06 +05:30 committed by Subhash Jadavani
parent 48d05392f8
commit 2be603cfa5
2 changed files with 15 additions and 0 deletions

View file

@ -3436,6 +3436,14 @@ static void sdhci_cmdq_set_block_size(struct mmc_host *mmc)
sdhci_set_blk_size_reg(host, 512, 0);
}
static void sdhci_enhanced_strobe_mask(struct mmc_host *mmc, bool set)
{
struct sdhci_host *host = mmc_priv(mmc);
if (host->ops->enhanced_strobe_mask)
host->ops->enhanced_strobe_mask(host, set);
}
static void sdhci_cmdq_clear_set_dumpregs(struct mmc_host *mmc, bool set)
{
struct sdhci_host *host = mmc_priv(mmc);
@ -3489,6 +3497,11 @@ static void sdhci_cmdq_set_block_size(struct mmc_host *mmc)
}
static void sdhci_enhanced_strobe_mask(struct mmc_host *mmc, bool set)
{
}
static void sdhci_cmdq_clear_set_dumpregs(struct mmc_host *mmc, bool set)
{
@ -3510,6 +3523,7 @@ static const struct cmdq_host_ops sdhci_cmdq_ops = {
.dump_vendor_regs = sdhci_cmdq_dump_vendor_regs,
.set_block_size = sdhci_cmdq_set_block_size,
.clear_set_dumpregs = sdhci_cmdq_clear_set_dumpregs,
.enhanced_strobe_mask = sdhci_enhanced_strobe_mask,
.crypto_cfg = sdhci_cmdq_crypto_cfg,
.post_cqe_halt = sdhci_cmdq_post_cqe_halt,
};

View file

@ -665,6 +665,7 @@ struct sdhci_ops {
u32 type);
int (*enable_controller_clock)(struct sdhci_host *host);
void (*clear_set_dumpregs)(struct sdhci_host *host, bool set);
void (*enhanced_strobe_mask)(struct sdhci_host *host, bool set);
void (*dump_vendor_regs)(struct sdhci_host *host);
void (*toggle_cdr)(struct sdhci_host *host, bool enable);
void (*voltage_switch)(struct sdhci_host *host);