[U-Boot] [PATCH 13/17] post/i2c: Add ability to ignore I2C devices

Peter Tyser ptyser at xes-inc.com
Thu Sep 30 15:00:49 CEST 2010


> What I don't understand yet: why do we need a balck (ignore) list at
> all, when we already have a white list (I2C_ADDR_LIST) ?
> 
> Should not one be sufficient?

Currently the POST code makes sure every entry in the white list is
found, but it also considers any unexpected devices found an error.  Eg
you plug in a daughter card with an EEPROM on it that isn't listed in
I2C_ADDR_LIST, and the POST fails with:
I2C: addr 50 not expected

As an alternative to this patch we could not treat unexpected devices as
an error, but you'd lose a small amount of POST coverage and
flexibility.

> > > Hmm.. as this is only used in post code, this should be visible
> > > in the defines name, what with:
> > > 
> > > I2C_POST_ADDR_IGNORE_LIST
> > 
> > I was following the lead of the existing I2C_ADDR_LIST define.  Agreed
> > it should be named differently.  I'll go with CONFIG_SYS_POST_I2C_ADDRS
> > and CONFIG_SYS_POST_I2C_IGNORES unless someone else chimes in.
> 
> Argh... I don't like identifiers that need half a line or more...

Agreed, but its hard when over half the name is the mandatory
CONFIG_SYS_POST_ prefix.  Any suggestions?

Regards,
Peter



More information about the U-Boot mailing list