diff mbox

[RFC,4/4] mmc: mmci: do an EOT for write DMA requests.

Message ID 1400269567-15574-1-git-send-email-srinivas.kandagatla@linaro.org (mailing list archive)
State New, archived
Headers show

Commit Message

Srinivas Kandagatla May 16, 2014, 7:46 p.m. UTC
From: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>

This patch adds an hack to get the BAM working. In general generic
drivers are not allowed to call SOC specific functions, but as this is
just an hack for demo.

Currently, Andy Gross is looking at, how to expose this function in more
generic way.

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
 drivers/mmc/host/mmci.c | 4 ++++
 1 file changed, 4 insertions(+)
diff mbox


diff --git a/drivers/mmc/host/mmci.c b/drivers/mmc/host/mmci.c
index 847a4ba..5ba8c80 100644
--- a/drivers/mmc/host/mmci.c
+++ b/drivers/mmc/host/mmci.c
@@ -652,6 +652,7 @@  static inline int mmci_dma_prep_next(struct mmci_host *host,
 	return __mmci_dma_prep_data(host, data, &nd->dma_chan, &nd->dma_desc);
+extern void qcom_bam_set_desc_eot(struct dma_async_tx_descriptor *txd);
 static int mmci_dma_start_data(struct mmci_host *host, unsigned int datactrl)
 	int ret;
@@ -661,6 +662,9 @@  static int mmci_dma_start_data(struct mmci_host *host, unsigned int datactrl)
 	if (ret)
 		return ret;
+	if (data->flags & MMC_DATA_WRITE)
+		qcom_bam_set_desc_eot(host->dma_desc_current);
 	/* Okay, go for it. */
 		 "Submit MMCI DMA job, sglen %d blksz %04x blks %04x flags %08x\n",