aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimon Horman <horms+renesas@verge.net.au>2013-12-03 23:12:20 -0500
committerSimon Horman <horms+renesas@verge.net.au>2014-02-06 19:20:03 -0500
commit03fec7dee502d43114f384a1588ce84a3c9bf38d (patch)
tree80515896ed719917fc4c5ab5e38bda9633a43585
parenta70eda7e40d09b8bf1a817488a255ce907587a71 (diff)
ARM: shmobile: genmai: Enable r7s72100-ether
Acked-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: Simon Horman <horms@verge.net.au>
-rw-r--r--arch/arm/mach-shmobile/board-genmai.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/arch/arm/mach-shmobile/board-genmai.c b/arch/arm/mach-shmobile/board-genmai.c
index c4064610e223..e240980cc227 100644
--- a/arch/arm/mach-shmobile/board-genmai.c
+++ b/arch/arm/mach-shmobile/board-genmai.c
@@ -20,6 +20,7 @@
20 20
21#include <linux/kernel.h> 21#include <linux/kernel.h>
22#include <linux/platform_device.h> 22#include <linux/platform_device.h>
23#include <linux/sh_eth.h>
23#include <linux/spi/rspi.h> 24#include <linux/spi/rspi.h>
24#include <linux/spi/spi.h> 25#include <linux/spi/spi.h>
25#include <mach/common.h> 26#include <mach/common.h>
@@ -28,6 +29,20 @@
28#include <asm/mach-types.h> 29#include <asm/mach-types.h>
29#include <asm/mach/arch.h> 30#include <asm/mach/arch.h>
30 31
32/* Ether */
33static const struct sh_eth_plat_data ether_pdata __initconst = {
34 .phy = 0x00, /* PD60610 */
35 .edmac_endian = EDMAC_LITTLE_ENDIAN,
36 .phy_interface = PHY_INTERFACE_MODE_MII,
37 .no_ether_link = 1
38};
39
40static const struct resource ether_resources[] __initconst = {
41 DEFINE_RES_MEM(0xe8203000, 0x800),
42 DEFINE_RES_MEM(0xe8204800, 0x200),
43 DEFINE_RES_IRQ(gic_iid(359)),
44};
45
31/* RSPI */ 46/* RSPI */
32#define RSPI_RESOURCE(idx, baseaddr, irq) \ 47#define RSPI_RESOURCE(idx, baseaddr, irq) \
33static const struct resource rspi##idx##_resources[] __initconst = { \ 48static const struct resource rspi##idx##_resources[] __initconst = { \
@@ -67,6 +82,11 @@ static void __init genmai_add_standard_devices(void)
67 r7s72100_clock_init(); 82 r7s72100_clock_init();
68 r7s72100_add_dt_devices(); 83 r7s72100_add_dt_devices();
69 84
85 platform_device_register_resndata(&platform_bus, "r7s72100-ether", -1,
86 ether_resources,
87 ARRAY_SIZE(ether_resources),
88 &ether_pdata, sizeof(ether_pdata));
89
70 r7s72100_register_rspi(0); 90 r7s72100_register_rspi(0);
71 r7s72100_register_rspi(1); 91 r7s72100_register_rspi(1);
72 r7s72100_register_rspi(2); 92 r7s72100_register_rspi(2);