[U-Boot] [PATCH] mvgbe: remove setting of ethaddr within the driver

Michael Walle michael at walle.cc
Tue Nov 8 18:34:17 CET 2011


Hi Wolfgang, Hi Mike,

Am Di, 8.11.2011, 16:17 schrieb Wolfgang Denk:
> Dear "Michael Walle",
>
> In message <89e599b8867346f857ae2f132e9717a3.squirrel at ssl.serverraum.org>
> you wrote:
>>
>> >> +#define CONFIG_ETH_ADDR 02:50:43:00:00:01
>> >
>> > NAK to this.  board configs are not allow to hardcode MACs.
>> mh, so why is there a CONFIG_ETH_ADDR macro? is it deprecated?
>> README.enetaddr explicitly refers to that config option.
>
> There are situations where it cannot be helped, like when programming
> the U-Boot image into a ROM (yes, a real ROM that cannot be changed
> any more by software alone).
>
> But in almost all normal situations this must not be used.  In any
> case, we will not accept it into mainline.

I have a Buffalo Linkstation Pro LS-XHL for which i plan to submit a BSP.
On this board, the MAC address is saved within the environment, which is
in turn stored in flash. Additionally this board does not have a serial
port, thus the only available console is the network console.

If someone will mess up the environment, it is possible to clear it by
holding a button upon powerup. Atm i have the CONFIG_ETH_ADDR set to a
default MAC address to be able to use the network console with the default
environment. To restore the original MAC address, a user have to manually
replace ethaddr with the one printed on the case.

But now, if i can't use the CONFIG_ETH_ADDR, i think i'm stuck :) Or do i
miss something? (Yeah there may be the MAC randomization, if accepted).

-- 
Michael



More information about the U-Boot mailing list