Thread (4 messages) 4 messages, 3 authors, 2010-08-02

RE: [PATCH 3/3 v2] mmc: Add ESDHC weird voltage bits workaround

From: Zang Roy-R61911 <hidden>
Date: 2010-08-02 06:20:12
Also in: linux-mmc

=20
-----Original Message-----
From: Anton Vorontsov [mailto:cbouatmailru@gmail.com]=20
Sent: Friday, July 30, 2010 15:06 PM
To: Zang Roy-R61911
Cc: linux-mmc@vger.kernel.org; linuxppc-dev@ozlabs.org;=20
akpm@linux-foundation.org
Subject: Re: [PATCH 3/3 v2] mmc: Add ESDHC weird voltage bits=20
workaround
=20
On Fri, Jul 30, 2010 at 11:52:57AM +0800, Roy Zang wrote:
quoted
P4080 ESDHC controller does not support 1.8V and 3.0V=20
voltage. but the
quoted
host controller capabilities register wrongly set the bits.
This patch adds the workaround to correct the weird voltage=20
setting bits.
quoted
=20
Signed-off-by: Roy Zang <redacted>
---
[...]
quoted
diff --git a/drivers/mmc/host/sdhci-of-core.c=20
b/drivers/mmc/host/sdhci-of-core.c
quoted
index 0c30242..1f3913d 100644
--- a/drivers/mmc/host/sdhci-of-core.c
+++ b/drivers/mmc/host/sdhci-of-core.c
@@ -164,6 +164,10 @@ static int __devinit=20
sdhci_of_probe(struct of_device *ofdev,
quoted
 	if (sdhci_of_wp_inverted(np))
 		host->quirks |=3D SDHCI_QUIRK_INVERTED_WRITE_PROTECT;
=20
+	if (of_device_is_compatible(np, "fsl,p4080-esdhc"))
+		host->quirks |=3D (SDHCI_QUIRK_QORIQ_NO_VDD_180
+				|SDHCI_QUIRK_QORIQ_NO_VDD_300);
+
=20
It should be two properties, something like sdhci,no-vdd-180
and sdhci,no-vdd-300. But it might be even better: we have
voltage-ranges for mmc-spi case, see
Documentation/powerpc/dts-bindings/mmc-spi-slot.txt.
=20
If voltage-ranges specified, then we use it, not capabilities
register.
=20
For p4080 it will be 'voltage-ranges =3D <3200 3400>;'. So, with
voltage-ranges we can do fine grained VDD control without
introducing anything new.
why not
               voltage-ranges =3D <3300 3300>;
?
Roy
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help