Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2d895cb5 authored by Ritesh Harjani's avatar Ritesh Harjani Committed by Gerrit - the friendly Code Review server
Browse files

mmc: cmdq_hci: Notify sdhci for enhanced strobe



Provide cmdq_host ops of enhanced strobe to notify
sdhci 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: I36ead91ca8c9aeed967f120f8bdc3d2180af7746
Signed-off-by: default avatarRitesh Harjani <riteshh@codeaurora.org>
parent f0cc8eb8
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -361,6 +361,8 @@ static int cmdq_enable(struct mmc_host *mmc)
	if (cq_host->ops->clear_set_dumpregs)
		cq_host->ops->clear_set_dumpregs(mmc, 1);

	if (cq_host->ops->enhanced_strobe_mask)
		cq_host->ops->enhanced_strobe_mask(mmc, true);
out:
	cmdq_runtime_pm_put(cq_host);
	return err;
@@ -376,6 +378,9 @@ static void cmdq_disable(struct mmc_host *mmc, bool soft)
				    cq_host, CQCFG) & ~(CQ_ENABLE),
			    CQCFG);
	}
	if (cq_host->ops->enhanced_strobe_mask)
		cq_host->ops->enhanced_strobe_mask(mmc, false);

	cmdq_runtime_pm_put(cq_host);
	cq_host->enabled = false;
}
+1 −0
Original line number Diff line number Diff line
@@ -199,6 +199,7 @@ struct cmdq_host_ops {
	void (*write_l)(struct cmdq_host *host, u32 val, int reg);
	u32 (*read_l)(struct cmdq_host *host, int reg);
	void (*clear_set_dumpregs)(struct mmc_host *mmc, bool set);
	void (*enhanced_strobe_mask)(struct mmc_host *mmc, bool set);
	int (*reset)(struct mmc_host *mmc);
	int (*crypto_cfg)(struct mmc_host *mmc, struct mmc_request *mrq,
				u32 slot);