[U-Boot] [PATCH v3] TI: DaVinci DM365: Enabling network Support on DM365 EVM

Ben Warren biggerbadderben at gmail.com
Tue Sep 29 19:05:57 CEST 2009


Hi Sandeep,

s-paulraj at ti.com wrote:
> From: Sandeep Paulraj <s-paulraj at ti.com>
>
> This patch enables EMAC on the DM365 EVM.
>
> Signed-off-by: Sandeep Paulraj <s-paulraj at ti.com>
> ---
>   
<snip>
> +	/* Read Ethernet MAC address from EEPROM */
> +	if (dvevm_read_mac_address(eeprom_enetaddr))
> +		dv_configure_mac_address(eeprom_enetaddr);
> +
>   
You should get rid of this function (dv_configure_mac_address), as it 
duplicates logic already present in net/eth.c, albeit in a different 
order.  Mike Frysinger has invested a lot of effort in cleaning this up 
(and documenting it too).  The correct behavior is as follows:

1. davinci_emac_initialize() should read programmed MAC address from ROM 
and stuff it into dev->enetaddr
2. eth_initialize() (in net/eth.c) reads from the environment and 
compares to the value in dev->enetaddr, warning on mismatch.
> +	davinci_emac_initialize();
> +
> +	return 0;
> +}
> +#endif
> +
>  #ifdef CONFIG_NAND_DAVINCI
>  static void nand_dm365evm_select_chip(struct mtd_info *mtd, int chip)
>  {
>   
regards,
Ben


More information about the U-Boot mailing list