diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2009-01-26 11:26:02 -0500 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2009-03-13 05:34:06 -0400 |
commit | 879fea1b486d2b6fa399c40b8aed172b0dfdedb9 (patch) | |
tree | 24f33831d65222ea3ebee086e149c599ed3aff6c /arch/arm/mach-mx2 | |
parent | fe7316bff119a11e68f895ecf9a5a713ed30004c (diff) |
[ARM] MX2: Add FEC platform device
The in kernel FEC driver has recently been ported to a platform driver.
Add a platform_device for it and register it for pcm038 and mx27ads.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/arm/mach-mx2')
-rw-r--r-- | arch/arm/mach-mx2/devices.c | 20 | ||||
-rw-r--r-- | arch/arm/mach-mx2/devices.h | 1 | ||||
-rw-r--r-- | arch/arm/mach-mx2/mx27ads.c | 1 | ||||
-rw-r--r-- | arch/arm/mach-mx2/pcm038.c | 1 |
4 files changed, 23 insertions, 0 deletions
diff --git a/arch/arm/mach-mx2/devices.c b/arch/arm/mach-mx2/devices.c index 07061e644545..684d5d92c2e4 100644 --- a/arch/arm/mach-mx2/devices.c +++ b/arch/arm/mach-mx2/devices.c | |||
@@ -258,7 +258,27 @@ struct platform_device mxc_fb_device = { | |||
258 | .coherent_dma_mask = 0xFFFFFFFF, | 258 | .coherent_dma_mask = 0xFFFFFFFF, |
259 | }, | 259 | }, |
260 | }; | 260 | }; |
261 | #endif | ||
261 | 262 | ||
263 | #ifdef CONFIG_MACH_MX27 | ||
264 | static struct resource mxc_fec_resources[] = { | ||
265 | { | ||
266 | .start = FEC_BASE_ADDR, | ||
267 | .end = FEC_BASE_ADDR + 0xfff, | ||
268 | .flags = IORESOURCE_MEM | ||
269 | }, { | ||
270 | .start = MXC_INT_FEC, | ||
271 | .end = MXC_INT_FEC, | ||
272 | .flags = IORESOURCE_IRQ | ||
273 | }, | ||
274 | }; | ||
275 | |||
276 | struct platform_device mxc_fec_device = { | ||
277 | .name = "fec", | ||
278 | .id = 0, | ||
279 | .num_resources = ARRAY_SIZE(mxc_fec_resources), | ||
280 | .resource = mxc_fec_resources, | ||
281 | }; | ||
262 | #endif | 282 | #endif |
263 | 283 | ||
264 | /* GPIO port description */ | 284 | /* GPIO port description */ |
diff --git a/arch/arm/mach-mx2/devices.h b/arch/arm/mach-mx2/devices.h index f4cb0ce29f13..d85d5b26c986 100644 --- a/arch/arm/mach-mx2/devices.h +++ b/arch/arm/mach-mx2/devices.h | |||
@@ -14,3 +14,4 @@ extern struct platform_device mxc_uart_device5; | |||
14 | extern struct platform_device mxc_w1_master_device; | 14 | extern struct platform_device mxc_w1_master_device; |
15 | extern struct platform_device mxc_nand_device; | 15 | extern struct platform_device mxc_nand_device; |
16 | extern struct platform_device mxc_fb_device; | 16 | extern struct platform_device mxc_fb_device; |
17 | extern struct platform_device mxc_fec_device; | ||
diff --git a/arch/arm/mach-mx2/mx27ads.c b/arch/arm/mach-mx2/mx27ads.c index 3c967f460b30..4a3b097adc12 100644 --- a/arch/arm/mach-mx2/mx27ads.c +++ b/arch/arm/mach-mx2/mx27ads.c | |||
@@ -180,6 +180,7 @@ static int uart_mxc_port5_exit(struct platform_device *pdev) | |||
180 | 180 | ||
181 | static struct platform_device *platform_devices[] __initdata = { | 181 | static struct platform_device *platform_devices[] __initdata = { |
182 | &mx27ads_nor_mtd_device, | 182 | &mx27ads_nor_mtd_device, |
183 | &mxc_fec_device, | ||
183 | }; | 184 | }; |
184 | 185 | ||
185 | static int mxc_fec_pins[] = { | 186 | static int mxc_fec_pins[] = { |
diff --git a/arch/arm/mach-mx2/pcm038.c b/arch/arm/mach-mx2/pcm038.c index 58552a01c0d3..d246eb1bb3ce 100644 --- a/arch/arm/mach-mx2/pcm038.c +++ b/arch/arm/mach-mx2/pcm038.c | |||
@@ -191,6 +191,7 @@ static struct mxc_nand_platform_data pcm038_nand_board_info = { | |||
191 | static struct platform_device *platform_devices[] __initdata = { | 191 | static struct platform_device *platform_devices[] __initdata = { |
192 | &pcm038_nor_mtd_device, | 192 | &pcm038_nor_mtd_device, |
193 | &mxc_w1_master_device, | 193 | &mxc_w1_master_device, |
194 | &mxc_fec_device, | ||
194 | &pcm038_sram_mtd_device, | 195 | &pcm038_sram_mtd_device, |
195 | }; | 196 | }; |
196 | 197 | ||