aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-davinci/dm365.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-davinci/dm365.c')
-rw-r--r--arch/arm/mach-davinci/dm365.c23
1 files changed, 21 insertions, 2 deletions
diff --git a/arch/arm/mach-davinci/dm365.c b/arch/arm/mach-davinci/dm365.c
index 7781e35daec3..a12065e87266 100644
--- a/arch/arm/mach-davinci/dm365.c
+++ b/arch/arm/mach-davinci/dm365.c
@@ -691,7 +691,6 @@ static struct emac_platform_data dm365_emac_pdata = {
691 .ctrl_reg_offset = DM365_EMAC_CNTRL_OFFSET, 691 .ctrl_reg_offset = DM365_EMAC_CNTRL_OFFSET,
692 .ctrl_mod_reg_offset = DM365_EMAC_CNTRL_MOD_OFFSET, 692 .ctrl_mod_reg_offset = DM365_EMAC_CNTRL_MOD_OFFSET,
693 .ctrl_ram_offset = DM365_EMAC_CNTRL_RAM_OFFSET, 693 .ctrl_ram_offset = DM365_EMAC_CNTRL_RAM_OFFSET,
694 .mdio_reg_offset = DM365_EMAC_MDIO_OFFSET,
695 .ctrl_ram_size = DM365_EMAC_CNTRL_RAM_SIZE, 694 .ctrl_ram_size = DM365_EMAC_CNTRL_RAM_SIZE,
696 .version = EMAC_VERSION_2, 695 .version = EMAC_VERSION_2,
697}; 696};
@@ -699,7 +698,7 @@ static struct emac_platform_data dm365_emac_pdata = {
699static struct resource dm365_emac_resources[] = { 698static struct resource dm365_emac_resources[] = {
700 { 699 {
701 .start = DM365_EMAC_BASE, 700 .start = DM365_EMAC_BASE,
702 .end = DM365_EMAC_BASE + 0x47ff, 701 .end = DM365_EMAC_BASE + SZ_16K - 1,
703 .flags = IORESOURCE_MEM, 702 .flags = IORESOURCE_MEM,
704 }, 703 },
705 { 704 {
@@ -734,6 +733,21 @@ static struct platform_device dm365_emac_device = {
734 .resource = dm365_emac_resources, 733 .resource = dm365_emac_resources,
735}; 734};
736 735
736static struct resource dm365_mdio_resources[] = {
737 {
738 .start = DM365_EMAC_MDIO_BASE,
739 .end = DM365_EMAC_MDIO_BASE + SZ_4K - 1,
740 .flags = IORESOURCE_MEM,
741 },
742};
743
744static struct platform_device dm365_mdio_device = {
745 .name = "davinci_mdio",
746 .id = 0,
747 .num_resources = ARRAY_SIZE(dm365_mdio_resources),
748 .resource = dm365_mdio_resources,
749};
750
737static u8 dm365_default_priorities[DAVINCI_N_AINTC_IRQ] = { 751static u8 dm365_default_priorities[DAVINCI_N_AINTC_IRQ] = {
738 [IRQ_VDINT0] = 2, 752 [IRQ_VDINT0] = 2,
739 [IRQ_VDINT1] = 6, 753 [IRQ_VDINT1] = 6,
@@ -1219,7 +1233,12 @@ static int __init dm365_init_devices(void)
1219 1233
1220 davinci_cfg_reg(DM365_INT_EDMA_CC); 1234 davinci_cfg_reg(DM365_INT_EDMA_CC);
1221 platform_device_register(&dm365_edma_device); 1235 platform_device_register(&dm365_edma_device);
1236
1237 platform_device_register(&dm365_mdio_device);
1222 platform_device_register(&dm365_emac_device); 1238 platform_device_register(&dm365_emac_device);
1239 clk_add_alias(NULL, dev_name(&dm365_mdio_device.dev),
1240 NULL, &dm365_emac_device.dev);
1241
1223 /* Add isif clock alias */ 1242 /* Add isif clock alias */
1224 clk_add_alias("master", dm365_isif_dev.name, "vpss_master", NULL); 1243 clk_add_alias("master", dm365_isif_dev.name, "vpss_master", NULL);
1225 platform_device_register(&dm365_vpss_device); 1244 platform_device_register(&dm365_vpss_device);