2 * linux/arch/arm/mach-mmp/flint.c
4 * Support for the Marvell Flint Development Platform.
6 * Copyright (C) 2009 Marvell International Ltd.
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License version 2 as
10 * publishhed by the Free Software Foundation.
13 #include <linux/init.h>
14 #include <linux/kernel.h>
15 #include <linux/platform_device.h>
16 #include <linux/smc91x.h>
18 #include <linux/gpio.h>
19 #include <linux/interrupt.h>
21 #include <asm/mach-types.h>
22 #include <asm/mach/arch.h>
23 #include <mach/addr-map.h>
24 #include <mach/mfp-mmp2.h>
25 #include <mach/mmp2.h>
29 #define FLINT_NR_IRQS (IRQ_BOARD_START + 48)
31 static unsigned long flint_pin_config[] __initdata = {
79 static struct smc91x_platdata flint_smc91x_info = {
80 .flags = SMC91X_USE_16BIT | SMC91X_NOWAIT,
83 static struct resource smc91x_resources[] = {
85 .start = SMC_CS1_PHYS_BASE + 0x300,
86 .end = SMC_CS1_PHYS_BASE + 0xfffff,
87 .flags = IORESOURCE_MEM,
90 .start = MMP_GPIO_TO_IRQ(155),
91 .end = MMP_GPIO_TO_IRQ(155),
92 .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_HIGHEDGE,
96 static struct platform_device smc91x_device = {
100 .platform_data = &flint_smc91x_info,
102 .num_resources = ARRAY_SIZE(smc91x_resources),
103 .resource = smc91x_resources,
106 static void __init flint_init(void)
108 mfp_config(ARRAY_AND_SIZE(flint_pin_config));
110 /* on-chip devices */
113 platform_device_register(&mmp2_device_gpio);
115 /* off-chip devices */
116 platform_device_register(&smc91x_device);
119 MACHINE_START(FLINT, "Flint Development Platform")
120 .map_io = mmp_map_io,
121 .nr_irqs = FLINT_NR_IRQS,
122 .init_irq = mmp2_init_irq,
123 .timer = &mmp2_timer,
124 .init_machine = flint_init,
125 .restart = mmp_restart,