Skip to contentSkip to conversation

atmel v4l2 soc driver

DISCUSSION Sedji Gaouaou 3 participants 11 messages Mar 11, 2009 – Nov 12, 2009 1 message not in the archive Media (V4L/DVB)

lore
Share & tools
lore
#0 lore raw

Hi,

I am currently porting an atmel isi driver to the soc layer, and I encounter some problems. I have based my driver on pax-camera. and sh_mobile_ceu_camera.c.
The point is I can't see any video entry in /dev when I do ls dev/ on my board...
So I wonder when is soc_camera_video_start(which call video_register_device) called? Is that at the probe?

Regards,
Sedji

#1 lore raw
Quoted 1 line · Sedji Gaouaou

I am currently porting an atmel isi driver to the soc layer,

This is good!

Quoted 6 lines

and I encounter some problems.
I have based my driver on pax-camera. and sh_mobile_ceu_camera.c. The point is I can't see any video entry in /dev when I do ls dev/ on my board...
So I wonder when is soc_camera_video_start(which call video_register_device) called? Is that at the probe?

Well, you could just do

grep soc_camera_video_start drivers/media/video/*.c

Then you would immediately see, that each specific camera (sensor, decoder, whatever) driver explicitly calls this function.

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer

#2 lore raw

Hi,

I am writing a driver for the ov9655 sensor from Omnivision.
To do so I am using the ov772x.c file as an example.
But I don't understant, because it seems that I never enter the video_probe function... Do you have any idea what could I do wrong? Is it coming from a wrong i2c config?

Regards,
Sedji

Quoted 25 lines · Guennadi Liakhovetski
Quoted 1 line · Sedji Gaouaou

I am currently porting an atmel isi driver to the soc layer,

This is good!

Quoted 6 lines

and I encounter some problems.
I have based my driver on pax-camera. and sh_mobile_ceu_camera.c. The point is I can't see any video entry in /dev when I do ls dev/ on my board...
So I wonder when is soc_camera_video_start(which call video_register_device) called? Is that at the probe?

Well, you could just do

grep soc_camera_video_start drivers/media/video/*.c

Then you would immediately see, that each specific camera (sensor, decoder, whatever) driver explicitly calls this function.

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer

#3 lore raw
Quoted 6 lines · Sedji Gaouaou

I am writing a driver for the ov9655 sensor from Omnivision.
To do so I am using the ov772x.c file as an example.
But I don't understant, because it seems that I never enter the video_probe function...
Do you have any idea what could I do wrong? Is it coming from a wrong i2c config?

Wouldn't ov9655 be similar enough to ov9650 as used in stk-sensor.c? Hans, would that one also be converted to v4l2-device? If so, Sedji, you don't need to write yet another driver for it.

What concerns your probing problem - you most likely are missing platform bindings in your board code. See arch/arm/mach-pxa/pcm990-baseboard.c for an example.

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer

#4 lore raw
Quoted 2 lines · Guennadi Liakhovetski

Wouldn't ov9655 be similar enough to ov9650 as used in stk-sensor.c? Hans, would that one also be converted to v4l2-device? If so, Sedji, you don't need to write yet another driver for it.

I had a look at the stk-sensor file. Does it follow the soc arch?

Regards,
sedji

#5 lore raw
Quoted 7 lines · Sedji Gaouaou
Quoted 4 lines · Guennadi Liakhovetski

Wouldn't ov9655 be similar enough to ov9650 as used in stk-sensor.c? Hans, would that one also be converted to v4l2-device? If so, Sedji, you don't need to write yet another driver for it.

I had a look at the stk-sensor file. Does it follow the soc arch?

No, it does not. But soc-camera is going to be converted to v4l2-device, so, if stkweb is going to be converted too, then the driver will be re-used.

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer

#6 lore raw

Well I am confused now...Should I still convert the atmel ISI driver to a soc driver?
My concern was not to release a driver for the ov9655, but to have one which is working so I could test my atmel-soc driver :) Because I only have an ov9655 sensor here...

Regards
Sedji

Quoted 16 lines · Guennadi Liakhovetski
Quoted 5 lines · Sedji Gaouaou
Quoted 3 lines · Guennadi Liakhovetski

Wouldn't ov9655 be similar enough to ov9650 as used in stk-sensor.c? Hans, would that one also be converted to v4l2-device? If so, Sedji, you don't need to write yet another driver for it.

I had a look at the stk-sensor file. Does it follow the soc arch?

No, it does not. But soc-camera is going to be converted to v4l2-device, so, if stkweb is going to be converted too, then the driver will be re-used.

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer

#7 lore raw
Quoted 2 lines · Sedji Gaouaou

Well I am confused now...Should I still convert the atmel ISI driver to a soc driver?

Yes, don't worry, all drivers in the mainline will be converted "automatically," whereas, if you don't convert it now - before the switch to v4l2-device, you'll have to convert your driver yourself:-)

Quoted 3 lines

My concern was not to release a driver for the ov9655, but to have one which is working so I could test my atmel-soc driver :)
Because I only have an ov9655 sensor here...

Ok, yes, sure, if you're not afraid of losing your time, just wanted to warn you, that yet another driver for ov9655 will probably be not accepted into the mainline, still it might be used during the v4l2-device conversion. But of course you can convert it to soc-camera for your tests.

As I said, look at the pxa example for how to bind a sensor and a host camera driver.

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer

#11 lore raw
In reply to Guennadi Liakhovetski
Quoted 11 lines · On Monday 23 March 2009 16:40:06 Guennadi Liakhovetski wrote:
Quoted 6 lines · Sedji Gaouaou

I am writing a driver for the ov9655 sensor from Omnivision. To do so I am using the ov772x.c file as an example.
But I don't understant, because it seems that I never enter the video_probe function...
Do you have any idea what could I do wrong? Is it coming from a wrong i2c config?

Wouldn't ov9655 be similar enough to ov9650 as used in stk-sensor.c? Hans, would that one also be converted to v4l2-device? If so, Sedji, you don't need to write yet another driver for it.

stk-sensor.c isn't a proper i2c driver: it's programmed through registers on the stk1125 control interface. That driver should probably be rewritten as a stk1125 driver that creates an i2c adapter which would allow stk-sensor.c to be rewritten as a proper i2c subdev.

Anyway, stk-sensor.c won't be (nor needs to be) converted. This obviously means that stk-sensor is not reusable in any other driver. There is no easy solution to that, other than a stk-*.c rewrite.

Note that there is also ov965x support in gspca/ov534.c. I think that several gspca drivers should really be rewritten so that they just create an i2c adapter and load the i2c sensor subdev.

Regards,

Hans

Quoted 13 lines

What concerns your probing problem - you most likely are missing platform bindings in your board code. See arch/arm/mach-pxa/pcm990-baseboard.c for an example.

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

Signature · 1 line
Hans Verkuil - video4linux developer - sponsored by TANDBERG
#8 lore raw
In reply to Sedji Gaouaou

Hi Sedji,

Quoted 5 lines · Sedji Gaouaou

Well I am confused now...Should I still convert the atmel ISI driver to a soc driver?
My concern was not to release a driver for the ov9655, but to have one which is working so I could test my atmel-soc driver :)
Because I only have an ov9655 sensor here...

What's the status of the ISI driver porting? Any progress? Or any plans idea when you will be able to work on it? If you have no plans to do the porting in the near future, maybe you could send me your latest patch, so, I could have a look at it and _maybe_ see, if I find time to convert it myself (no promise though)?

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/

#10 lore raw
In reply to a message not in the archive
Quoted 8 lines · Sedji Gaouaou

Hi,

Sorry to answer you so late about the driver.
I have a working version which is based on 2.6.27. It is using the V4L2 API, but not the soc-video.
I am not able to update it for the time being, even if it is something that we want to do.
Are you still interested by the "old" driver?

Yes, it would be nice to have the latest version of your driver available, although I cannot tell when I will find time to do the conversion. So far I'm quite loaded with work, so, it won't happen soon. But please do make your latest version available, maybe upload it to some site, where everyone can download it from and update if you get newer versions?

Thanks
Guennadi

Quoted 32 lines

Regards,
Sedji

Quoted 25 lines · Guennadi Liakhovetski

Hi Sedji,

Quoted 7 lines · Sedji Gaouaou

Well I am confused now...Should I still convert the atmel ISI driver to a soc
driver?
My concern was not to release a driver for the ov9655, but to have one which
is working so I could test my atmel-soc driver :)
Because I only have an ov9655 sensor here...

What's the status of the ISI driver porting? Any progress? Or any plans idea when you will be able to work on it? If you have no plans to do the porting in the near future, maybe you could send me your latest patch, so, I could have a look at it and _maybe_ see, if I find time to convert it myself (no promise though)?

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/

---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/