> -----Original Message----- > From: Wolfgang Denk [mailto:[email protected]] > Sent: Friday, September 02, 2011 7:14 PM > To: Premi, Sanjeev > Cc: [email protected] > Subject: Re: [U-Boot] [PATCH] omap3evm: Set environment > variable 'ethaddr' > > Dear Sanjeev Premi, > > In message <[email protected]> you wrote: > > It is now responsibility of the board specific init > > code to set the environment variable corresponding > > to the MAC address. > > > > Signed-off-by: Sanjeev Premi <[email protected]> > > This looks all wrong to me. In U-Boot, the "ethaddr" environment > variable is normally the primary storage for the MAC address. Only > when this variable is not set, other potential storage locations may > be referenced to initialize this value. > > Your patch always and unconditionally overwrites any existing > "ethaddr" settings. This is not acceptable.
For the EVM, MAC address is always probed from the chip. Hence, I assumed it safe to set the ethaddr - without checking for env var. It was unlikely that someone would be setting it - to different value. But, I see your point that I should be checking for existence of a valid ethaddr before setting/overwriting it. ~sanjeev > > Best regards, > > Wolfgang Denk > > -- > DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel > HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany > Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: [email protected] > Build a system that even a fool can use and only a fool will want to > use it. > _______________________________________________ U-Boot mailing list [email protected] http://lists.denx.de/mailman/listinfo/u-boot

