sunxi: Request macpwr gpio before using it
authorHans de Goede <hdegoede@redhat.com>
Sun, 7 Jun 2015 13:26:42 +0000 (15:26 +0200)
committerHans de Goede <hdegoede@redhat.com>
Wed, 10 Jun 2015 14:52:12 +0000 (16:52 +0200)
This fixes ethernet no longer working on boards which use a gpio to enable
the phy.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Ian Campbell <ijc@hellion.org.uk>
arch/arm/cpu/armv7/sunxi/board.c

index a82c8b9..4b2494e 100644 (file)
@@ -223,6 +223,7 @@ int cpu_eth_init(bd_t *bis)
        __maybe_unused int rc;
 
 #ifdef CONFIG_MACPWR
+       gpio_request(CONFIG_MACPWR, "macpwr");
        gpio_direction_output(CONFIG_MACPWR, 1);
        mdelay(200);
 #endif