Skip to contentSkip to conversation

ARM: dts: logicpd-torpedo-37xx-devkit-u-boot: Fix MMC Card Detect

PATCH In review Adam Ford 3 participants 4 messages Sep 3, 2018 – Sep 8, 2018 Arm (32-bit)

lore
Share & tools
lore

Adam Ford

author
#0 lore raw

PATCH 1/1 ARM: dts: logicpd-torpedo-37xx-devkit-u-boot: Fix MMC Card Detect

When re-syncing the DTS files from the kernel, something caused the MMC driver to no longer detect the MMC card. Undoing the CD-invert appears to fix the issue.

Fixes e6ea2390cde3 ("ARM: DTS: Resync LogicPD-Torpedo-37xx-devkit

with Linux 4.18-RC4")

arch/arm/dts/logicpd-torpedo-37xx-devkit-u-boot.dtsi +0 -4
index 4028fe7642..d584b4a9ab 100644
@@ -20,10 +20,6 @@
 	clock-frequency = <400000>;
 };
 
-&mmc1 {
-	cd-inverted;
-};
-
 &mmc2 {
       status = "disabled";
 };
Signature · 1 line
2.17.1
#1 lore raw

PATCH 1/1 ARM: dts: logicpd-torpedo-37xx-devkit-u-boot: Fix MMC Card Detect

Hi Adam,

Quoted 7 lines · Adam Ford

When re-syncing the DTS files from the kernel, something caused the MMC driver to no longer detect the MMC card. Undoing the CD-invert appears to fix the issue.

Fixes e6ea2390cde3 ("ARM: DTS: Resync LogicPD-Torpedo-37xx-devkit

with Linux 4.18-RC4")

Looking at that commit, we see:

- cd-gpios = <&gpio4 31 IRQ_TYPE_LEVEL_LOW>; /* gpio127 */
+ cd-gpios = <&gpio4 31 GPIO_ACTIVE_LOW>; /* gpio127 */

IRQ_TYPE_LEVEL_LOW is defined as 8, which in this context should get interpreted as GPIO_TRANSITORY which is ignored by U-Boot. Thus the card-detect polarity got toggled by that commit.

If ACTIVE_LOW is indeed the correct polarity (and I'm guessing it is because otherwise MMC wouldn't work in Linux), this patch sounds correct.

- Tuomas

author
#2 lore raw

PATCH 1/1 ARM: dts: logicpd-torpedo-37xx-devkit-u-boot: Fix MMC Card Detect

Quoted 18 lines · Tuomas Tynkkynen

Hi Adam,

Quoted 7 lines · Adam Ford

When re-syncing the DTS files from the kernel, something caused the MMC driver to no longer detect the MMC card. Undoing the CD-invert appears to fix the issue.

Fixes e6ea2390cde3 ("ARM: DTS: Resync LogicPD-Torpedo-37xx-devkit

with Linux 4.18-RC4")

Looking at that commit, we see:

(quoted diff) +1 -1
-       cd-gpios = <&gpio4 31 IRQ_TYPE_LEVEL_LOW>;              /* gpio127 */
+       cd-gpios = <&gpio4 31 GPIO_ACTIVE_LOW>;         /* gpio127 */
Quoted 7 lines

IRQ_TYPE_LEVEL_LOW is defined as 8, which in this context should get interpreted as GPIO_TRANSITORY which is ignored by U-Boot. Thus the card-detect polarity got toggled by that commit.

If ACTIVE_LOW is indeed the correct polarity (and I'm guessing it is because otherwise MMC wouldn't work in Linux), this patch sounds correct.

That makes a lot of sense. Thanks for that.

adam

Quoted 2 lines

- Tuomas

#3 lore raw
In reply to Adam Ford

arch/arm/dts/logicpd-torpedo-37xx-devkit-u-boot.dtsi

Quoted 11 lines · Adam Ford

When re-syncing the DTS files from the kernel, something caused the MMC driver to no longer detect the MMC card. Undoing the CD-invert appears to fix the issue.

Fixes e6ea2390cde3 ("ARM: DTS: Resync LogicPD-Torpedo-37xx-devkit

with Linux 4.18-RC4")

arch/arm/dts/logicpd-torpedo-37xx-devkit-u-boot.dtsi +0 -0
index 4028fe7642..d584b4a9ab 100644

Applied to u-boot/master, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180906/c6211e13/attachment.sig>