Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1247966

[PATCH v3 3/5] ARM: mvebu: set SW polling as SDHCI card detection on A388-GP

From Marcin Wojtas <mw@semihalf.com>
Newsgroups linux.kernel
Subject [PATCH v3 3/5] ARM: mvebu: set SW polling as SDHCI card detection on A388-GP
Date 2015-10-15 18:20 +0200
Message-ID <qjTq4-3aG-59@gated-at.bofh.it> (permalink)
References <qjTq2-3aG-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


The newest revisions of A388-GP (v1.5 and higher) support only
DAT3-based card detection. Revisions < v1.5 based on GPIO detection
via I2C expander, but this solution is supposed to be deprecated on
new boards. In order to satisfy all type of hardware this commit
changes card detection to use software polling mechanism. Also a
comment is added on possible card detection options in A388-GP
DT board file.

Signed-off-by: Marcin Wojtas <mw@semihalf.com>
Acked-by: Andrew Lunn <andrew@lunn.ch>
---
 arch/arm/boot/dts/armada-388-gp.dts | 15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/armada-388-gp.dts b/arch/arm/boot/dts/armada-388-gp.dts
index 391dea9..3deba13 100644
--- a/arch/arm/boot/dts/armada-388-gp.dts
+++ b/arch/arm/boot/dts/armada-388-gp.dts
@@ -213,8 +213,21 @@
 			sdhci@d8000 {
 				pinctrl-names = "default";
 				pinctrl-0 = <&sdhci_pins>;
-				cd-gpios = <&expander0 5 GPIO_ACTIVE_LOW>;
 				no-1-8-v;
+				/*
+				 * A388-GP board v1.5 and higher replace
+				 * hitherto card detection method based on GPIO
+				 * with the one using DAT3 pin. As they are
+				 * incompatible, software-based polling is
+				 * enabled with 'broken-cd' property. For boards
+				 * older than v1.5 it can be replaced with:
+				 * 'cd-gpios = <&expander0 5 GPIO_ACTIVE_LOW>;',
+				 * whereas for the newer ones following can be
+				 * used instead:
+				 * 'dat3-cd;'
+				 * 'cd-inverted;'
+				 */
+				broken-cd;
 				wp-inverted;
 				bus-width = <8>;
 				status = "okay";
-- 
1.8.3.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v3 0/5] Armada 38x SDHCI driver improvements Marcin Wojtas <mw@semihalf.com> - 2015-10-15 18:20 +0200
  [PATCH v3 3/5] ARM: mvebu: set SW polling as SDHCI card detection on A388-GP Marcin Wojtas <mw@semihalf.com> - 2015-10-15 18:20 +0200
    Re: [PATCH v3 3/5] ARM: mvebu: set SW polling as SDHCI card detection on A388-GP Gregory CLEMENT <gregory.clement@free-electrons.com> - 2015-10-16 19:20 +0200
  [PATCH v3 1/5] mmc: sdhci-pxav3: enable proper resuming on Armada 38x SoC Marcin Wojtas <mw@semihalf.com> - 2015-10-15 18:20 +0200

csiph-web