Johannes Stezenbach wrote:
The i2c protocol was never specified to be flexible, it does a very special task and it does it quite well. Ok, i2c has it's quirks, but that's not our problem right now, our problem is the linux i2c infrastructure implementation by people who misunderstood the reality.Holger Waechtler wrote:Michael Hunold wrote:IMHO using kernel i2c is the right thing to do.we don't talk about dvb_i2c but about removing the braindead autoprobing infrastructure based on the i2c_client crap and replace it by simple direct calls from the card driver.
Not all i2c adapters have dedicated i2c hardware; bt8xx and cx88 need to use bitbanging, which is fully implemented in kernel i2c. With dvb i2c, the communication functions must be duplicated.
Autoprobing isn't braindead. Braindead is that chip vendors omit the device id registers one needs to do autoprobing _right_. (It's Philips' fault that they didn't include device ids in the I2C spec.)
You can pass a device pointer when calling class_simple_device_add(). This can then get used for backreferencing.Some frontends need firmware. With kernel i2c, firmware uploading is easily done through firmware_class interface without much hassle.Thanks to Marko Kothala we have a sysfs/udev interface for every DVB subdevice. See dvbdev.c.
Which doesn't work for firmware uploads, because it doesn't know nothing about I2C. Even if you could sensibly do request_firmware() you don't have access to the I2C bus where you want to write the firmware to.
The firmware argument for i2c is just void, we had trivial firmware loaders implemented before and if we would rely on i2c for firmware loading at all we would have a serious problem for demuxes and MPEG decoders: I don't know any which has an i2c interface.
No one claimed that one needs I2C to do firmware downloads. The old syscalls-in-kernel firmware loaders are legacy crap. Linux is OSS, but you still have to play by the rules given by the main kernel maintainers. If Linux demands that we use request_firmware() instead of sys_open()/sys_read(), then so be it. If you want to argue against that, then please do it on lkml and not here.
You can do so without being a registered i2c_client. Holger