public inbox for linuxppc-dev@ozlabs.org 
 help / color / mirror / Atom feed
From: Chris Ball <cjb@laptop•org>
To: Shaohui Xie <Shaohui.Xie@freescale•com>
Cc: linuxppc-dev@lists•ozlabs.org, linux-mmc@vger•kernel.org
Subject: Re: [PATCH][v2] mmc:sdhci: restore the enabled dma when do reset all
Date: Wed, 11 Jan 2012 14:25:34 -0500	[thread overview]
Message-ID: <m2zkdudosx.fsf@bob.laptop.org> (raw)
In-Reply-To: <1325147580-31281-1-git-send-email-Shaohui.Xie@freescale.com> (Shaohui Xie's message of "Thu, 29 Dec 2011 16:33:00 +0800")

Hi Shaohui,

On Thu, Dec 29 2011, Shaohui Xie wrote:
> If dma is enabled, it'll be cleared when reset all is performed, this can
> be observed on some platforms, such as P2041 which has a version 2.3
> controller, but platform like P4080 which has a version 2.2 controller,
> does not suffer this, so we will check if the dma is enabled, we should
> restore it after reset all.
>
> Signed-off-by: Shaohui Xie <Shaohui.Xie@freescale•com>
> ---
> based on http://git.kernel.org/pub/scm/linux/kernel/git/cjb/mmc.git,
> branch 'for-linus'.
>
> changes for v2:
> call the wrapper API instead of access the register directly.
>
>  drivers/mmc/host/sdhci.c |    5 +++++
>  1 files changed, 5 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
> index 19ed580..cf6a048 100644
> --- a/drivers/mmc/host/sdhci.c
> +++ b/drivers/mmc/host/sdhci.c
> @@ -214,6 +214,11 @@ static void sdhci_reset(struct sdhci_host *host, u8 mask)
>  
>  	if (host->quirks & SDHCI_QUIRK_RESTORE_IRQS_AFTER_RESET)
>  		sdhci_clear_set_irqs(host, SDHCI_INT_ALL_MASK, ier);
> +
> +	if (host->flags & (SDHCI_USE_SDMA | SDHCI_USE_ADMA)) {
> +		if ((host->ops->enable_dma) && (mask & SDHCI_RESET_ALL))
> +			host->ops->enable_dma(host);
> +	}
>  }
>  
>  static void sdhci_set_ios(struct mmc_host *mmc, struct mmc_ios *ios);

Thanks, I'll merge this for 3.3.

- Chris.
-- 
Chris Ball   <cjb@laptop•org>   <http://printf.net/>
One Laptop Per Child

      parent reply	other threads:[~2012-01-11 19:59 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-29  8:33 [PATCH][v2] mmc:sdhci: restore the enabled dma when do reset all Shaohui Xie
2012-01-06  7:57 ` Xie Shaohui-B21989
2012-01-11  9:12 ` Xie Shaohui-B21989
2012-01-11 19:25 ` Chris Ball [this message]

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=m2zkdudosx.fsf@bob.laptop.org \
    --to=cjb@laptop$(echo .)org \
    --cc=Shaohui.Xie@freescale$(echo .)com \
    --cc=linux-mmc@vger$(echo .)kernel.org \
    --cc=linuxppc-dev@lists$(echo .)ozlabs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox