All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Shawn.Dong" <shawn.dong.cx@gmail.com>
To: Wolfram Sang <w.sang@pengutronix.de>
Cc: linux-mmc@vger.kernel.org
Subject: Re: [PATCH]mmc: sdhci: use udelay instead of mdelay for some cases
Date: Thu, 27 Oct 2011 13:09:41 +0800	[thread overview]
Message-ID: <20111027050939.GA27531@gmail.com> (raw)
In-Reply-To: <20111027051532.GA28387@pengutronix.de>

On Thu, Oct 27, 2011 at 07:15:32AM +0200, Wolfram Sang wrote:
>Hi,
>
>On Thu, Oct 27, 2011 at 12:18:53PM +0800, Shawn.Dong wrote:
>> sdhci_set_clock or sdhci_reset or sdhci_send_command may be used in
>> critical region which is protected by spin_lock_irqsave. Thus, these
>> functions will delay the responsing of the kernel interrupts.
>
>Yes, so this needs to be improved, not the delay values.
>
>> So in this case, using a mdelay will cause unnecessary latency. Our
>> hardware, in most case will not cause 1ms to finish its job. Using
>> udelay instead can reduce it.
>
>Could you guarantee this for all other SDHCI hardware out there as well?
Even there are some SDHCI hardwares cannot be stable in microseconds, I
think this is also OK since they just need to wait for a few more loops. The
total waiting time is the same as before.

For the SDHCI hardware which need less time to be stable, this patch can improve
performance for them.

Thanks
Shawn

  reply	other threads:[~2011-10-27  5:22 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-27  4:18 [PATCH]mmc: sdhci: use udelay instead of mdelay for some cases Shawn.Dong
2011-10-27  5:09 ` Barry Song
2011-10-27  5:15 ` Wolfram Sang
2011-10-27  5:09   ` Shawn.Dong [this message]
2011-10-27  6:02     ` Wolfram Sang
2011-11-04  8:24       ` Shawn.Dong

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=20111027050939.GA27531@gmail.com \
    --to=shawn.dong.cx@gmail.com \
    --cc=linux-mmc@vger.kernel.org \
    --cc=w.sang@pengutronix.de \
    /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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.