For the proper reboot Odroid-C4 board requires to switch TFLASH_VDD_EN
pin to the high impedance mode, otherwise the board is stuck in the
middle of loading early stages of the bootloader from SD card.

This can be achieved by using the OPEN_DRAIN flag instead if the
ACTIVE_HIGH, what will leave the pin in input to achieve high state (pin
has the pull-up) and solve the issue.

Suggested-by: Neil Armstrong <narmstr...@baylibre.com>
Signed-off-by: Marek Szyprowski <m.szyprow...@samsung.com>
---
This is a result of the discussion in the "[PATCH/RFC] board: amlogic:
Fix Odroid-C4 SD card reboot issue" thread:
https://lists.denx.de/pipermail/u-boot/2020-December/435295.html

Patch for the upstream Linux DTS has been already submitted:
https://lore.kernel.org/linux-amlogic/20201218102228.16211-1-m.szyprow...@samsung.com/
---
 arch/arm/dts/meson-sm1-odroid-c4-u-boot.dtsi | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/arm/dts/meson-sm1-odroid-c4-u-boot.dtsi 
b/arch/arm/dts/meson-sm1-odroid-c4-u-boot.dtsi
index c431988075..fbcc8287c5 100644
--- a/arch/arm/dts/meson-sm1-odroid-c4-u-boot.dtsi
+++ b/arch/arm/dts/meson-sm1-odroid-c4-u-boot.dtsi
@@ -11,3 +11,7 @@
        snps,reset-delays-us = <0 10000 1000000>;
        snps,reset-active-low;
 };
+
+&tflash_vdd {
+       gpio = <&gpio_ao GPIOAO_3 GPIO_OPEN_DRAIN>;
+};
-- 
2.17.1

Reply via email to