Re: [PATCH] V4L: soc-camera: provide support for S_INPUT.

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

 



On Wed, 4 Jan 2012, javier Martin wrote:

[snip]

> For ov7725 it is a natural thing to do since it was originally
> developed for soc-camera and it can easily do the following to access
> platform data:
> 
> struct soc_camera_link	*icl = soc_camera_i2c_to_link(client);
> pdata = icl->priv;
> 
> However, tvp5150 is not aware about soc_camera. I should be able to
> tell whether it's being used with soc-camera or not. If soc camera was
> used I would do the previous method to retrieve platform data.
> But if soc-camera was not used I would do the classic method:
> 
> struct tvp5150_platform_data *pdata = client->dev.platform_data;
> 
> The problem is how to distinguish in tvp5150 whether I am using
> soc_camera or not.

Right, that _is_ the problem now. And we've known about it since the very 
first time we started to think about re-using the subdev drivers. The only 
solution I see so far is to introduce a standard platform data struct for 
all subdevices, similar to soc_camera_link. We could use it as a basis, of 
course, use a generic name, maybe reconsider fields - rename / remove / 
add, but the principle would be the same: a standard platform data struct 
with an optional private field.

Alternatively - would it be possible to find all tvp5150 users and port 
them to use struct soc_camera_link too?

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/
--
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