Signed-off-by: Chen-Yu Tsai <w...@csie.org>
---
 arch/arm/cpu/armv7/sunxi/board.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/arch/arm/cpu/armv7/sunxi/board.c b/arch/arm/cpu/armv7/sunxi/board.c
index 386b16e..5d19a64 100644
--- a/arch/arm/cpu/armv7/sunxi/board.c
+++ b/arch/arm/cpu/armv7/sunxi/board.c
@@ -160,7 +160,12 @@ int cpu_eth_init(bd_t *bis)
 #endif
 
        /* Configure pin mux settings for GMAC */
-       for (pin = SUNXI_GPA(0); pin <= SUNXI_GPA(17); pin++) {
+       for (pin = SUNXI_GPA(0); pin <= SUNXI_GPA(16); pin++) {
+#ifdef CONFIG_RGMII
+               /* skip unused pins in RGMII mode */
+               if (pin == SUNXI_GPA(9) || pin == SUNXI_GPA(14))
+                   continue;
+#endif
                sunxi_gpio_set_cfgpin(pin, 5);
                sunxi_gpio_set_drv(pin, 3);
        }
-- 
1.8.5.1

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to linux-sunxi+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to