[U-Boot] [PATCH] powerpc/eeprom: update MAX_NUM_PORTS to fix program failure
Timur Tabi
timur at tabi.org
Thu Aug 29 17:09:22 CEST 2013
On 08/29/2013 04:56 AM, Liu Shengzhou-B36685 wrote:
>> If the EEPROM is 128 bytes, then you have a non-conformant EEPROM.
> What is a conformant EEPROM?
A conformant EEPROM has a size of 256 bytes .
> The size of struct of EEPROM_NXID should be able to conform to real size of EEPROM, regardless it's 128 or 256 EEPROM.
The problem is that the CRC is at the end of the structure, so that
> It's not reasonable to limit MAX_NUM_PORTS to 23, generally we don't need 23 MAC addresses to store in EEPROM.
> 23 is just suitable to 256 bytes EEPROM.
Actually, the 23 should be changed to 31. York, this patch needs to be
applied: http://patchwork.ozlabs.org/patch/170753/
>> And using the #ifdef to determine this is definitely the wrong way.
> Why? What's your way?
If you need to define a new EEPROM format, then the version number needs
to be changed to v2, and the code needs to dynamically handle v1 and v2.
BTW, your patch breaks EVERY OTHER BOARD. You can't just change the 23
to a 9 for every board. Did you test your patch on other boards?
--
Timur Tabi
More information about the U-Boot
mailing list