Hi, On 12.09.2004 16:08, Andrew de Quincey wrote:
I wouldn't care when kernel i2c would be crappy code inside (which I thing it isn't):) (it is - really: I've rarely seen anything broken-by-concept like this. And I've rarely seen anybody fighting like a pitbull for such a stupid concept.)
You seem to have the wrong end of the stick here. I'm only fighting to FIX i2c. I'm saying if we use i2c_transfer() as you suggest, then we have to register an i2c_adapter. If we register an i2c_adapter, it will be autoprobed as the *braindead* i2c stuff doesn't let you turn autoprobing OFF. If it is autoprobed, the _other_ i2c devices (e.g. the tda9887) in the system can stomp on us. The alternative is to stop using kernel i2c.I think it's easy to stop autoprobing by introducing a new .flags field to struct i2c_adapter, for example #define I2C_ADAP_NO_AUTOPROBE.
Since we can see this problem coming, why not fix it now, instead of waiting for it to bite us in the arse? :)IMO the fix is in the i2c subsystem. Sure, it's more hard to get changes done in there.