Chaithrika U S <[email protected]> writes:
> DA850/OMAP-L138 EVM has a RMII Ethernet PHY on the UI daughter card. The PHY
> is enabled by proper programming of the IO Expander (TCA6416) ports. Also for
> RMII PHY to work, the MDIO clock of MII PHY has to be disabled since both the
> PHYs have the same address. This is done via the GPIO2[6] pin. This patch adds
> support for RMII PHY.
>
> This patch also adds a menuconfig option to select one or no peripheral
> connected to expander. Currently, sub-options in this menu are RMII and no
> peripheral.This menuconfig option is similar to the one present for UI card on
> DA830/OMAP-L137 EVM.
>
> Signed-off-by: Chaithrika U S <[email protected]>
Now that we have runtime detection for the UI card, It now seems like
a lot of Kconfig work just to set soc_info->emac_pdata->rmii_en, but I
guess I'm OK with that as it seems we'll need it for other UI
peripherals like the LCD as well. Speaking of which, should the
da8xx_register_lcdc() be moved inside the UI expander setup hook also?
Pushing today after some minor fixups to apply on current tree.
Details below...
[...]
> static __init void da850_evm_init(void)
> {
> struct davinci_soc_info *soc_info = &davinci_soc_info;
> int ret;
>
> +#ifdef CONFIG_DA850_UI_RMII
> + soc_info->emac_pdata->rmii_en = 1;
> +#else
> + soc_info->emac_pdata->rmii_en = 0;
> +#endif
> +
I moved this down to...
> ret = da8xx_register_edma();
> if (ret)
> pr_warning("da850_evm_init: edma registration failed: %d\n",
> @@ -383,12 +448,10 @@ static __init void da850_evm_init(void)
>
> soc_info->emac_pdata->phy_mask = DA850_EVM_PHY_MASK;
> soc_info->emac_pdata->mdio_max_freq = DA850_EVM_MDIO_FREQUENCY;
here.
> - soc_info->emac_pdata->rmii_en = 0;
>
> - ret = da8xx_pinmux_setup(da850_cpgmac_pins);
> + ret = da850_evm_config_emac(soc_info->emac_pdata->rmii_en);
> if (ret)
> - pr_warning("da850_evm_init: cpgmac mux setup failed: %d\n",
> - ret);
> + pr_warning("da850_evm_init: emac setup failed: %d\n", ret);
>
> ret = da8xx_register_emac();
> if (ret)
Kevin
_______________________________________________
Davinci-linux-open-source mailing list
[email protected]
http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source