On 02/03/2010 15:33, Joe Culler wrote: > 1. First, I set default CONFIG_ETHADDR(for example, 02:80:ad:20:31:e8) > in u-boot, then use flash writer to burn the flash on each board. > 2. I have a program for burning mac address on Linux. > After booting linux kernel, my program can burn the mac address. > Reboot the system if burning the mac address successfully. > 3. Since the mac address is already stored in mtd2, for example. > I want u-boot to detect the correct mac address I burned in mtd2 > partition rather than the default setting 02:80:ad:20:31:e8. > > Is it the correct way I do or do you have any better idea? Thank you.
I just use U-Boot tools "fw_setenv" to update the U-Boot ETHADDR variable from within Linux. If you do this, it may be advisable to move the environment out of the code sector in case of failure during writeback. http://www.denx.de/wiki/DULG/HowCanIAccessUBootEnvironmentVariablesInLinux http://elinux.org/U-boot_environment_variables_in_linux Ian. _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot