LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Juergen Borleis <jbe@pengutronix.de>
To: linux-mmc@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, festevam@gmail.com,
	wsa+renesas@sang-engineering.com, dianders@chromium.org,
	ulf.hansson@linaro.org, kernel@pengutronix.de
Subject: [PATCH 1/2] mmc: mxcmmc: really configure the DMA on demand
Date: Thu, 29 Jul 2021 09:29:28 +0200	[thread overview]
Message-ID: <20210729072929.10267-2-jbe@pengutronix.de> (raw)
In-Reply-To: <20210729072929.10267-1-jbe@pengutronix.de>

Calling mxcmci_use_dma(host) is intended for the next transfer only, not
for generic detection if DMA is possible. Without this change, the DMA gets
never configured and thus, never used.

Signed-off-by: Juergen Borleis <jbe@pengutronix.de>
---
 drivers/mmc/host/mxcmmc.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/mmc/host/mxcmmc.c b/drivers/mmc/host/mxcmmc.c
index 2fe6fcd..611f827 100644
--- a/drivers/mmc/host/mxcmmc.c
+++ b/drivers/mmc/host/mxcmmc.c
@@ -834,7 +834,8 @@ static void mxcmci_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
 	else
 		burstlen = 4;
 
-	if (mxcmci_use_dma(host) && burstlen != host->burstlen) {
+	if (host->dma != NULL && burstlen != host->burstlen) {
+		/* reconfigure DMA on changes only */
 		host->burstlen = burstlen;
 		ret = mxcmci_setup_dma(mmc);
 		if (ret) {
-- 
2.20.1


  reply	other threads:[~2021-07-29  7:29 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-29  7:29 Make the i.MX MMC device using DMA again Juergen Borleis
2021-07-29  7:29 ` Juergen Borleis [this message]
2021-08-11 11:36   ` [PATCH 1/2] mmc: mxcmmc: really configure the DMA on demand Ulf Hansson
2021-07-29  7:29 ` [PATCH 2/2] mmc: mxcmmc: don't expect a DMA operation if DMA seems present Juergen Borleis

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210729072929.10267-2-jbe@pengutronix.de \
    --to=jbe@pengutronix.de \
    --cc=dianders@chromium.org \
    --cc=festevam@gmail.com \
    --cc=kernel@pengutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=ulf.hansson@linaro.org \
    --cc=wsa+renesas@sang-engineering.com \
    --subject='Re: [PATCH 1/2] mmc: mxcmmc: really configure the DMA on demand' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).