arm: marvell: Extract kirkwood gpio functions into new common file gpio.c

This makes is possible to use those gpio functions from other MVEBU SoC's as well.

Signed-off-by: Stefan Roese <sr@denx.de>
Tested-by: Luka Perkov <luka@openwrt.org>
Acked-by: Prafulla Wadaskar <prafulla@marvell.com>
diff --git a/board/Seagate/goflexhome/goflexhome.c b/board/Seagate/goflexhome/goflexhome.c
index 3e4ae89..c3f4cbf 100644
--- a/board/Seagate/goflexhome/goflexhome.c
+++ b/board/Seagate/goflexhome/goflexhome.c
@@ -83,9 +83,9 @@
 	 * There are maximum 64 gpios controlled through 2 sets of registers
 	 * the  below configuration configures mainly initial LED status
 	 */
-	kw_config_gpio(GOFLEXHOME_OE_VAL_LOW,
-		       GOFLEXHOME_OE_VAL_HIGH,
-		       GOFLEXHOME_OE_LOW, GOFLEXHOME_OE_HIGH);
+	mvebu_config_gpio(GOFLEXHOME_OE_VAL_LOW,
+			  GOFLEXHOME_OE_VAL_HIGH,
+			  GOFLEXHOME_OE_LOW, GOFLEXHOME_OE_HIGH);
 	kirkwood_mpp_conf(kwmpp_config, NULL);
 	return 0;
 }
@@ -149,7 +149,7 @@
 	u32 oe;
 	u32 bl;
 
-	r = (struct kwgpio_registers *)KW_GPIO1_BASE;
+	r = (struct kwgpio_registers *)MVEBU_GPIO1_BASE;
 	oe = readl(&r->oe) | BOTH_LEDS;
 	writel(oe & ~leds, &r->oe);	/* active low */
 	bl = readl(&r->blink_en) & ~BOTH_LEDS;