Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[linux-dvb] Re: NEWSTRUCT questions



Ralph Metzler wrote:
>  Gerd Knorr writes:
>  > > > The DVB driver should be able to tell the I2C subsystem to probe for
>  > > > frontends only on a specific I2C bus. (The frontend drivers are
>  > > > the same for all systems, so they know nothing about the busses.)
>  > >  
>  > >  Thats true. At least it would be fine to have such a situation ;)
>  > 
>  > Easily doable in the i2c_driver->attach_adapter() function, just check
>  > i2c_adapter->id before calling the i2c_probe() function.
>  
>  But then you have to check for all IDs of known adapters. New DVB
>  drivers with other I2C adapter IDs would be ignored until all drivers 
>  are adjusted.
>  Adapters and drivers should have entries which tell what general 
>  type (DVB driver, DVB tuner, TV tuner, TV encoder/decoder, etc.) they are.

Yes, that would make maintaining that kind of information easier.

Just adding a new element to i2c_adapter should help here, together with
some #defines along the lines ...

#define I2C_BUS_CLASS_SMBUS      0x0001
#define I2C_BUS_CLASS_DCC        0x0002
#define I2C_BUS_CLASS_TV_ANALOG  0x0004
#define I2C_BUS_CLASS_TV_DVB     0x0008
[ ... ]

>  > What exactly is the point of having two different i2c layers?  Why don't
>  > you simply use the linux i2c layer for everything?
>  
>  I think part of the reason were the unnecessary and sometimes long
>  delays caused by drivers which tried to attach to all I2C busses
>  although they had no business there. This could be resolved by better
>  checking of device types as explained above.

IMHO nothing serious, should be easily fixable.  Tried to send patches
to the i2c folks?

  Gerd

-- 
You can't please everybody.  And usually if you _try_ to please
everybody, the end result is one big mess.
				-- Linus Torvalds, 2002-04-20


-- 
Info:
To unsubscribe send a mail to listar@linuxtv.org with "unsubscribe linux-dvb" as subject.



Home | Main Index | Thread Index