diff options
author | Martin Blumenstingl | 2019-06-15 12:38:29 +0200 |
---|---|---|
committer | Kevin Hilman | 2019-06-20 05:34:09 +0200 |
commit | ed5e8f6891548fefe26cf883d5b037aab5c105b4 (patch) | |
tree | 99d96390e0051bf04bd1b5be8ae0b64a28e99ce1 /arch/arm64/boot/dts/amlogic/meson-gxm-nexbox-a1.dts | |
parent | arm64: dts: meson: g12a: sort sdio nodes correctly (diff) | |
download | kernel-qcow2-linux-ed5e8f6891548fefe26cf883d5b037aab5c105b4.tar.gz kernel-qcow2-linux-ed5e8f6891548fefe26cf883d5b037aab5c105b4.tar.xz kernel-qcow2-linux-ed5e8f6891548fefe26cf883d5b037aab5c105b4.zip |
arm64: dts: meson: g12a: x96-max: fix the Ethernet PHY reset line
The Odroid-N2 schematics show that the following pins are used for the
reset and interrupt lines:
- GPIOZ_14 is the PHY interrupt line
- GPIOZ_15 is the PHY reset line
The GPIOZ_14 and GPIOZ_15 pins are special. The datasheet describes that
they are "3.3V input tolerant open drain (OD) output pins". This means
the GPIO controller can drive the output LOW to reset the PHY. To
release the reset it can only switch the pin to input mode. The output
cannot be driven HIGH for these pins.
This requires configuring the reset line as GPIO_OPEN_DRAIN because
otherwise the PHY will be stuck in "reset" state (because driving the
pin HIGH seems to result in the same signal as driving it LOW).
The reset line works together with a pull-up resistor (R143 in the
Odroid-N2 schematics). The SoC can drive GPIOZ_14 LOW to assert the PHY
reset. However, since the SoC can't drive the pin HIGH (to release the
reset) we switch the mode to INPUT and let the pull-up resistor take
care of driving the reset line HIGH.
Switch to GPIOZ_15 for the PHY reset line instead of using GPIOZ_14
(which actually is the interrupt line).
Move from the "snps" specific resets to the MDIO framework's
reset-gpios because only the latter honors the GPIO flags.
Use the GPIO flags (GPIO_ACTIVE_LOW | GPIO_OPEN_DRAIN) to match with
the pull-up resistor because this will:
- drive the output LOW to reset the PHY (= active low)
- switch the pin to INPUT mode so the pull-up will take the PHY out of
reset
Fixes: 51d116557b2044 ("arm64: dts: meson-g12a-x96-max: Add Gigabit Ethernet Support")
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Diffstat (limited to 'arch/arm64/boot/dts/amlogic/meson-gxm-nexbox-a1.dts')
0 files changed, 0 insertions, 0 deletions