[U-Boot] [PATCH v3] Add "cpu_config" command for PPC4xx bootstrap configuration

Wolfgang Denk
2009-07-17T20:58:48Z

Dear Matthias Fuchs,

In message <200907172157.12244.matthias.fuchs@esd.eu> you wrote:
...

[450+ lines of full quote deleted.]

Please quote only relevant code snippets. Thanks.

> > + for (i = 0; i < ppc4xx_config_count; i++) {
> > + /*
> > + * Search for configuration name/label
> > + */
> > + if (strcmp(argv[1], ppc4xx_config_val[i].label) == 0) {
> > + printf("Using configuration:\n%-16s - %s\n",
> > + ppc4xx_config_val[i].label,
> > + ppc4xx_config_val[i].description);
> > +
> > + ret = i2c_write(CONFIG_4xx_CONFIG_I2C_EEPROM_ADDR, 0, 1,
> > + ppc4xx_config_val[i].val,
> > + CONFIG_4xx_CONFIG_BLOCKSIZE);
> I would like to see eeprom_write() here. On 405EP the strapping data is 0x20
> bytes but the/our EEPROM has a page size of 16 bytes so i2c_write makes
> problems with the 2nd half of data. Also eeprom_write handles the write
> protection stuff. See some esd boards or the recent sbe command implementation
> in my last PMC405DE patch.

I disagree here. There is no guarantee (and actually no need) that
CONFIG_CMD_EEPROM is enabled in a configuration that want to use this
feature.

If i2c_write() has issues on your boards that is IMO a bug that needs
to be fixed (but that's another story).

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: wd at denx.de
HANDLE WITH EXTREME CARE: This Product Contains Minute Electrically
Charged Particles Moving at Velocities in Excess of Five Hundred
Million Miles Per Hour.