Re: soc-camera -> v4l2-device: possible API extension requirements

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

 



On Wednesday 18 March 2009 09:41:58 Hans Verkuil wrote:
> Hi Guennadi,
>
> > 2. In a comment you write to v4l2_i2c_new_subdev():
> > /* Load an i2c sub-device. It assumes that i2c_get_adapdata(adapter)
> >    returns the v4l2_device and that i2c_get_clientdata(client)
> >    returns the v4l2_subdev. */
> > I don't think this is possible with generic SoC i2c adapters. On
> > soc-camera systems v4l2 subdevices are connected to generic i2c busses,
> > so, you cannot require, that "i2c_get_adapdata(adapter) returns the
> > v4l2_device."
>
> Good point, I'll look at this. I don't think it is difficult to change,
> although I will probably wait until several pending driver conversions
> are merged. Then I can fix this in one sweep.

The fix for this is simple: just add an extra struct v4l2_device to 
v4l2_i2c_new_(probed_)device and let those functions use that instead of 
calling i2c_get_adapdata(). It's the only place where it is currently used.

But I'm going to postpone implementing this until all outstanding conversion 
trees are merged. However, you can just do it yourself while working on the 
soc-camera conversion.

Regards,

	Hans

-- 
Hans Verkuil - video4linux developer - sponsored by TANDBERG
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux