linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: w.sang@pengutronix.de (Wolfram Sang)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH V3 0/5] sdhci-esdhc-imx: use gpio for write protection and card detection
Date: Thu, 24 Feb 2011 20:45:57 +0100	[thread overview]
Message-ID: <20110224194557.GA20877@pengutronix.de> (raw)
In-Reply-To: <20110224160300.GA1483@S2100-06.ap.freescale.net>

On Fri, Feb 25, 2011 at 12:03:01AM +0800, Shawn Guo wrote:
> On Thu, Feb 24, 2011 at 11:51:28PM +0800, Shawn Guo wrote:
> > On Thu, Feb 24, 2011 at 04:18:05PM +0800, Shawn Guo wrote:
> > > Hi Wolfram,
> > > 
> > > On Wed, Feb 23, 2011 at 02:51:53PM +0100, Wolfram Sang wrote:
> > > > Take #3, changes:
> > > > 
> > > > * also intercept calls to SDHCI_SIGNAL_ENABLE (needed on mx25)
> > > > * remove unconditional BROKEN_CARD_DETECTION (leftover)
> > > > * improved kernel-doc about unused GPIO
> > > > * added tags from Eric
> > > > 
> > > > Tested now by me and Marc on mx35, Eric on mx25/35/51. Arnaud, did you have a
> > > > chance to retest on mx51? What about the FSL guys? :)
> > > > 
> > > I'm testing it on mx25 3ds and mx51 babbage. Both card-detect and
> > > write-protect are working on mx25 3ds, but write-protect has some
> > > problem on babbage, and I need some time to figure it out.
> > > 
> > I just figured out why wp_gpio does not work on mx51.
> > 
> > +       if (cpu_is_mx25() || cpu_is_mx35()) {
> > +               /* Fix errata ENGcm07207 present on i.MX25 and i.MX35 */
> >                 host->quirks |= SDHCI_QUIRK_NO_MULTIBLOCK;
> > +               /* write_protect can't be routed to controller, use gpio */
> > +               sdhci_esdhc_ops.get_ro = esdhc_pltfm_get_ro;
> > +       }
> > 
> > Would it make sense to do the same for mx51?  On babbage board,
> > SD1_WP is routed to controller, but SD2_WP is not, so we have to use
> > gpio for SD2 write_protect.
> > 
> We should probably have esdhc_pltfm_get_ro whenever platform provides
> a wp_gpio, and fall on controller SD_WP only when platform does not
> provide the wp_gpio.

OK, will think about it. Thanks for testing!

-- 
Pengutronix e.K.                           | Wolfram Sang                |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20110224/1e00e5e7/attachment.sig>

  reply	other threads:[~2011-02-24 19:45 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-23 13:51 [PATCH V3 0/5] sdhci-esdhc-imx: use gpio for write protection and card detection Wolfram Sang
2011-02-23 13:51 ` [PATCH 1/5] mmc: sdhci-esdhc-imx: add support for write protect on custom GPIO Wolfram Sang
2011-02-23 13:51 ` [PATCH 2/5] mmc: sdhci-esdhc: broken card detection is not a default quirk Wolfram Sang
2011-02-23 13:51 ` [PATCH 3/5] mmc: sdhci-esdhc-imx: add card detect on custom GPIO Wolfram Sang
2011-02-23 13:51 ` [PATCH 4/5] arm: mach-mx3: pcm043: add write-protect and card-detect for SD1 Wolfram Sang
2011-02-23 13:51 ` [PATCH 5/5] arm: mach-mx3: use IMX_GPIO_NR instead of hard-coded values Wolfram Sang
2011-02-24  8:18 ` [PATCH V3 0/5] sdhci-esdhc-imx: use gpio for write protection and card detection Shawn Guo
2011-02-24 15:51   ` Shawn Guo
2011-02-24 16:03     ` Shawn Guo
2011-02-24 19:45       ` Wolfram Sang [this message]
2011-02-24 11:40 ` Arnaud Patard (Rtp)
2011-02-24 13:12   ` Wolfram Sang
2011-02-24 19:00   ` Eric Benard
2011-02-25 19:31     ` Arnaud Patard (Rtp)
2011-02-25 21:29       ` Eric Benard

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=20110224194557.GA20877@pengutronix.de \
    --to=w.sang@pengutronix.de \
    --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;
as well as URLs for NNTP newsgroup(s).