Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
tavorevb.c
Go to the documentation of this file.
1 /*
2  * linux/arch/arm/mach-mmp/tavorevb.c
3  *
4  * Support for the Marvell PXA910-based TavorEVB Development Platform.
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License version 2 as
8  * publishhed by the Free Software Foundation.
9  */
10 #include <linux/gpio.h>
11 #include <linux/init.h>
12 #include <linux/kernel.h>
13 #include <linux/platform_device.h>
14 #include <linux/smc91x.h>
15 
16 #include <asm/mach-types.h>
17 #include <asm/mach/arch.h>
18 #include <mach/addr-map.h>
19 #include <mach/mfp-pxa910.h>
20 #include <mach/pxa910.h>
21 #include <mach/irqs.h>
22 
23 #include "common.h"
24 
25 static unsigned long tavorevb_pin_config[] __initdata = {
26  /* UART2 */
29 
30  /* SMC */
37 
38  /* DFI */
61 };
62 
63 static struct smc91x_platdata tavorevb_smc91x_info = {
65 };
66 
67 static struct resource smc91x_resources[] = {
68  [0] = {
69  .start = SMC_CS1_PHYS_BASE + 0x300,
70  .end = SMC_CS1_PHYS_BASE + 0xfffff,
71  .flags = IORESOURCE_MEM,
72  },
73  [1] = {
74  .start = MMP_GPIO_TO_IRQ(80),
75  .end = MMP_GPIO_TO_IRQ(80),
77  }
78 };
79 
80 static struct platform_device smc91x_device = {
81  .name = "smc91x",
82  .id = 0,
83  .dev = {
84  .platform_data = &tavorevb_smc91x_info,
85  },
86  .num_resources = ARRAY_SIZE(smc91x_resources),
87  .resource = smc91x_resources,
88 };
89 
90 static void __init tavorevb_init(void)
91 {
92  mfp_config(ARRAY_AND_SIZE(tavorevb_pin_config));
93 
94  /* on-chip devices */
95  pxa910_add_uart(1);
97 
98  /* off-chip devices */
99  platform_device_register(&smc91x_device);
100 }
101 
102 MACHINE_START(TAVOREVB, "PXA910 Evaluation Board (aka TavorEVB)")
103  .map_io = mmp_map_io,
104  .nr_irqs = MMP_NR_IRQS,
105  .init_irq = pxa910_init_irq,
106  .timer = &pxa910_timer,
107  .init_machine = tavorevb_init,
108  .restart = mmp_restart,