Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: klaus.goger@theobroma-systems.com (klaus.goger at theobroma-systems.com)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: dts: sunxi: Explicitly enable pull-ups for MMC pins
Date: Thu, 17 Nov 2016 21:57:43 +0100	[thread overview]
Message-ID: <ea02ec937a12d6ca2a2e0d8bbea5c484@theobroma-systems.com> (raw)
In-Reply-To: <20161117093438.17988-1-wens@csie.org>

On 2016-11-17 10:34, Chen-Yu Tsai wrote:
> Given that MMC starts in open-drain mode and the pull-ups are required,
> it's best to enable it for all the pin settings.

It's even more complicated than that with MMC. It starts in open-drain 
mode for
CMD during initialization but changes to push-pull afterwards. The card 
has
internal pull-ups to prevent bus floating during setup and will disable 
them
after switching to 4bit mode (or 8bit for eMMC when available).
But even after switching to push-pull drivers there are states the bus 
would
float and pull ups have to ensure a high level on the bus.

See JESD84-A441 chapter 7.15 ff as reference.

   The difference between the P-bit and Z-bit is that a P-bit is actively 
driven
   to HIGH by the card respectively host output driver, while Z-bit is 
driven to
  (respectively kept) HIGH by the pull-up resistors Rcmd respectively 
Rdat.


Enabling the pull ups on the CPU would be the right choice considering 
that
most boards will not have external pull-ups. Even if they would have 
one,
adding the internal in parallel would work in almost all cases and the
increase in power consumption would be negligible.

Cheers,
Klaus

  parent reply	other threads:[~2016-11-17 20:57 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-17  9:34 [PATCH] ARM: dts: sunxi: Explicitly enable pull-ups for MMC pins Chen-Yu Tsai
2016-11-17 20:40 ` Maxime Ripard
2016-11-17 20:57 ` klaus.goger at theobroma-systems.com [this message]
2016-11-18  9:18   ` Linus Walleij

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=ea02ec937a12d6ca2a2e0d8bbea5c484@theobroma-systems.com \
    --to=klaus.goger@theobroma-systems.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox