diff options
Diffstat (limited to 'arch/arm/mach-davinci/dm644x.c')
-rw-r--r-- | arch/arm/mach-davinci/dm644x.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/arch/arm/mach-davinci/dm644x.c b/arch/arm/mach-davinci/dm644x.c index d428ef192eac..0419d571bdca 100644 --- a/arch/arm/mach-davinci/dm644x.c +++ b/arch/arm/mach-davinci/dm644x.c @@ -444,6 +444,25 @@ static struct platform_device dm644x_edma_device = { }; /*----------------------------------------------------------------------*/ +#if defined(CONFIG_TI_DAVINCI_EMAC) || defined(CONFIG_TI_DAVINCI_EMAC_MODULE) + +void dm644x_init_emac(struct emac_platform_data *pdata) +{ + pdata->ctrl_reg_offset = DM644X_EMAC_CNTRL_OFFSET; + pdata->ctrl_mod_reg_offset = DM644X_EMAC_CNTRL_MOD_OFFSET; + pdata->ctrl_ram_offset = DM644X_EMAC_CNTRL_RAM_OFFSET; + pdata->mdio_reg_offset = DM644X_EMAC_MDIO_OFFSET; + pdata->ctrl_ram_size = DM644X_EMAC_CNTRL_RAM_SIZE; + pdata->version = EMAC_VERSION_1; + dm644x_emac_device.dev.platform_data = pdata; + platform_device_register(&dm644x_emac_device); +} +#else + +void dm644x_init_emac(struct emac_platform_data *unused) {} + +#endif + void __init dm644x_init(void) { davinci_clk_init(dm644x_clks); |