summaryrefslogtreecommitdiffstats
path: root/arch/m68k/platform/532x
diff options
context:
space:
mode:
authorGreg Ungerer <gerg@uclinux.org>2012-04-17 13:25:38 +1000
committerGreg Ungerer <gerg@uclinux.org>2012-05-20 21:21:47 +1000
commitf23c144d4265b9251a4146e057af668bcd7667cb (patch)
treef92ed6eec91ab1839cfd3aea3632885c7ee2e9e5 /arch/m68k/platform/532x
parent943c0cd0adf66ebfd7695715e0178e331fc72f43 (diff)
downloadtalos-obmc-linux-f23c144d4265b9251a4146e057af668bcd7667cb.tar.gz
talos-obmc-linux-f23c144d4265b9251a4146e057af668bcd7667cb.zip
m68knommu: make duplicated ColdFire GPIO init code common for all
The code that adds each ColdFire platforms GPIO signals is duplicated in each platforms specific code. Remove it from each platforms code and put a single version in the existing ColdFire gpio subsystem init code. Signed-off-by: Greg Ungerer <gerg@uclinux.org> Acked-by: Steven King <sfking@fdwdc.com>
Diffstat (limited to 'arch/m68k/platform/532x')
-rw-r--r--arch/m68k/platform/532x/gpio.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/arch/m68k/platform/532x/gpio.c b/arch/m68k/platform/532x/gpio.c
index 9454c65e40ef..3e1b71dc7042 100644
--- a/arch/m68k/platform/532x/gpio.c
+++ b/arch/m68k/platform/532x/gpio.c
@@ -20,7 +20,7 @@
#include <asm/mcfsim.h>
#include <asm/mcfgpio.h>
-static struct mcf_gpio_chip mcf_gpio_chips[] = {
+struct mcf_gpio_chip mcf_gpio_chips[] = {
MCFGPS(PIRQ, 0, 8, MCFEPORT_EPDDR, MCFEPORT_EPDR, MCFEPORT_EPPDR),
MCFGPF(FECH, 8, 8),
MCFGPF(FECL, 16, 8),
@@ -40,12 +40,4 @@ static struct mcf_gpio_chip mcf_gpio_chips[] = {
MCFGPF(LCDCTLL, 128, 8),
};
-static int __init mcf_gpio_init(void)
-{
- unsigned i = 0;
- while (i < ARRAY_SIZE(mcf_gpio_chips))
- (void)gpiochip_add((struct gpio_chip *)&mcf_gpio_chips[i++]);
- return 0;
-}
-
-core_initcall(mcf_gpio_init);
+unsigned int mcf_gpio_chips_size = ARRAY_SIZE(mcf_gpio_chips);
OpenPOWER on IntegriCloud