[U-Boot] [PATCH v5 1/2][NEXT] davinci_emac: davinci_eth_set_mac_addr to ->write_hwaddr

Nick Thompson nick.thompson at ge.com
Thu Sep 23 15:49:43 CEST 2010


On 23/09/10 14:33, Ben Gardiner wrote:
> This patch proposes to migrate the davinci_emac driver to using the
> eth_device->write_hwaddr function pointer as suggested by Ben Warren.
> 
> All the davinci boards had the behaviour, prior to this patch, of
> sync'ing the environment variable enetaddr with the MAC address read
> from non-volatile storage on boot -- when the two locations disagreed,
> the environment variable value took precendence. This patch keeps the
> same behaviour but lets eth_initialize take care of it.
> 
> This patch refactors davinci_emac setup in the boards so that the MAC
> address is read from non-volatile storage into the environment variable
> and then the environment variable value is use in eth_intialize. The
> only exception is the direct call to davinci_eth_set_mac_addr made by
> the da830evm board init which was changed into an assignment of the
> enetaddr field.
> 
> Signed-off-by: Ben Gardiner <bengardiner at nanometrics.ca>
> CC: Ben Warren <biggerbadderben at gmail.com>
> CC: Nick Thompson <nick.thompson at ge.com>
> 
> --
> V5:
>   * don't check return code of write_hwaddr in da830 board setup
> V4:
>   * No change
> V3:
>   * rebased to u-boot/next, removed additional direct call of
>     davinci_eth_set_mac_addr added to board_init_r by Heiko's
>     relocation patches
> V2:
>   * introduced this patch
> ---

Shouldn't this version information go below the '---' line. As it is,
it appears in the log message after using 'git am' to apply. Sorry,
I should have noticed that earlier.

Patch works correctly on da830evm.

Tested-by: Nick Thompson <nick.thompson at ge.com>

Thanks,
Nick.


More information about the U-Boot mailing list