summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [media] V4L: at91: add Atmel Image Sensor Interface (ISI) supportJosh Wu2011-07-274-0/+1176
| | | | | | | | | This patch is to enable Atmel Image Sensor Interface (ISI) driver support. Signed-off-by: Josh Wu <josh.wu@atmel.com> Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] V4L: soc-camera: remove several now unused soc-camera client operationsGuennadi Liakhovetski2011-07-272-15/+5
| | | | | | | | | | | | | | | | | This patch removes .enum_input(), .suspend() and .resume() soc-camera client operations. Functionality, provided by .enum_input(), if needed, can be implemented using the v4l2-subdev API. As for .suspend() and .resume(), the only client driver, implementing these methods has been mt9m111, and the only host driver, using them has been pxa-camera. Now that both those drivers have been converted to the standard subdev .s_power() operation, .suspend() and .resume() can be removed. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] V4L: mt9m111: switch to v4l2-subdev .s_power() methodGuennadi Liakhovetski2011-07-271-12/+39
| | | | | | | | Eliminate soc-camera specific .suspend() and .restore() methods in favour of the standard v4l2-subdev .s_power() method Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] V4L: mt9m111: propagate higher level abstraction down in functionsGuennadi Liakhovetski2011-07-271-85/+82
| | | | | | | | | | It is more convenient to propagate the higher level abstraction - the struct mt9m111 object into functions and then retrieve a pointer to the i2c client, if needed, than to do the reverse. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Acked-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] V4L: soc-camera: MIPI flags are not sensor flagsGuennadi Liakhovetski2011-07-271-6/+6
| | | | | | | | SOCAM_MIPI_[1234]LANE flags are not board-specific sensor flags, they are bus configuration flags. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] V4L: tw9910: remove bogus ENUMINPUT implementationGuennadi Liakhovetski2011-07-271-11/+0
| | | | | | | | tw9910 is a TV decoder, it doesn't have a tuner. Besides, the .enum_input soc-camera operation is optional and normally not needed. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] V4L: sh_mobile_ceu_camera: remove redundant calculationsGuennadi Liakhovetski2011-07-271-5/+0
| | | | | | | | soc_camera core now performs the standard .bytesperline and .sizeimage calculations internally, no need to duplicate in drivers. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] V4L: mx2_camera: .try_fmt shouldn't failGuennadi Liakhovetski2011-07-271-5/+10
| | | | | | | | If the user is requesting too large a frame, instead of failing select an acceptable geometry, preserving the requested aspect ratio. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] V4L: pxa-camera: switch to using subdev .s_power() core operationGuennadi Liakhovetski2011-07-271-4/+12
| | | | | | | | | soc-camera specific .suspend() and .resume() methods are deprecated and should be replaced by the subdev standard .s_power() operation. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Acked-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] V4L: pxa-camera: try to force progressive video formatGuennadi Liakhovetski2011-07-271-1/+2
| | | | | | | | | | | The pxa-camera driver only supports progressive video so far. Passing down to the client the same format, as what the user has requested can result in interlaced video, even if the client supports both. This patch avoids such cases. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Acked-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] V4L: pxa_camera: remove redundant calculationsGuennadi Liakhovetski2011-07-271-6/+0
| | | | | | | | | soc_camera core now performs the standard .bytesperline and .sizeimage calculations internally, no need to duplicate in drivers. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Acked-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] V4L: mx3_camera: remove redundant calculationsGuennadi Liakhovetski2011-07-271-12/+0
| | | | | | | | soc_camera core now performs the standard .bytesperline and .sizeimage calculations internally, no need to duplicate in drivers. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-ctrls: make manual_mode_value 8 bits and check against control ↵Hans Verkuil2011-07-272-1/+2
| | | | | | | range Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-compat-ioctl32: add VIDIOC_DQEVENT supportHans Verkuil2011-07-272-0/+38
| | | | | Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] ivtv: add control event supportHans Verkuil2011-07-272-3/+10
| | | | | Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] vivi: support control eventsHans Verkuil2011-07-271-2/+26
| | | | | Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] V4L2 spec: document control eventsHans Verkuil2011-07-272-2/+157
| | | | | Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-ctrls: simplify event subscriptionHans Verkuil2011-07-272-0/+40
| | | | | Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-ctrls: add control eventsHans Verkuil2011-07-276-50/+253
| | | | | | | | | | | Whenever a control changes value or state an event is sent to anyone that subscribed to it. This functionality is useful for control panels but also for applications that need to wait for (usually status) controls to change value. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-ctrls: add v4l2_fh pointer to the set control functionsHans Verkuil2011-07-274-29/+36
| | | | | | | | | | | | | | When an application changes a control you want to generate an event. However, you want to avoid sending such an event back to the application (file handle) that caused the change. Add the filehandle to the various set control functions. The filehandle isn't used yet, but the control event patches will need this. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] vivi: add autogain/gain support to test the autocluster functionalityHans Verkuil2011-07-271-1/+24
| | | | | Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] Documentation: Improve cluster documentation and document the new ↵Hans Verkuil2011-07-271-0/+56
| | | | | | | autoclusters Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-ctrls: add v4l2_ctrl_auto_cluster to simplify autogain/gain ↵Hans Verkuil2011-07-272-12/+102
| | | | | | | | | | | | | | | | | scenarios It is a bit tricky to handle autogain/gain type scenerios correctly. Such controls need to be clustered and the V4L2_CTRL_FLAG_UPDATE should be set on the autofoo controls. In addition, the manual controls should be marked inactive when the automatic mode is on, and active when the manual mode is on. This also requires specialized volatile handling. The chances of drivers doing all these things correctly are pretty remote. So a new v4l2_ctrl_auto_cluster function was added that takes care of these issues. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-controls.txt: update to latest v4l2-ctrl.c changesHans Verkuil2011-07-271-9/+4
| | | | | Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-ctrls: fix and improve volatile control handlingHans Verkuil2011-07-274-12/+48
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If you have a cluster of controls that is a mix of volatile and non-volatile controls, then requesting the value of the volatile control would fail if the master control of that cluster was non-volatile. The code assumed that the volatile state of the master control was the same for all other controls in the cluster. This is now fixed. In addition, it was clear from bugs in some drivers that it was confusing that the ctrl->cur union had to be used in g_volatile_ctrl. Several drivers used the 'new' values instead. The framework was changed so that drivers now set the new value instead of the current value. This has an additional benefit as well: the volatile values are now only stored in the 'new' value, leaving the current value alone. This is useful for autofoo/foo control clusters where you want to have a 'foo' control act like a volatile control if 'autofoo' is on, but as a normal control when it is off. Since with this change the cur value is no longer overwritten when g_volatile_ctrl is called, you can use it to remember the original 'foo' value. For example: autofoo = 0, foo = 10 and foo is non-volatile. Now autofoo is set to 1 and foo is marked volatile. Retrieving the foo value will get the volatile value. Set autofoo back to 0, which marks foo as non- volatile again, and retrieving foo will get the old current value of 10. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-subdev: implement per-filehandle control handlersHans Verkuil2011-07-272-7/+8
| | | | | | | To be consistent with v4l2-ioctl.c. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-ioctl: add ctrl_handler to v4l2_fhHans Verkuil2011-07-273-9/+31
| | | | | | | | This is required to implement control events and is also needed to allow for per-filehandle control handlers. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-ctrls: drivers should be able to ignore the READ_ONLY flagHans Verkuil2011-07-271-3/+3
| | | | | | | | | | | | | When applications try to set READ_ONLY controls an error should be returned. However, when drivers do that it should be accepted. Those controls could reflect some driver status which the application can't change but the driver obviously has to be able to change it. This is needed among others for future HDMI status controls. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-ctrls: simplify error_idx handlingHans Verkuil2011-07-271-15/+9
| | | | | | | | | The lower-level prepare functions just set error_idx for each control that might have an error. The high-level functions will override this with cs->count in the get and set cases. Only try will keep the error_idx. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-ctrls: introduce call_op defineHans Verkuil2011-07-271-8/+11
| | | | | | | | Add the call_op define to safely call the control ops. This also allows for controls without any ops such as the 'control class' controls. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] DocBook/v4l: Document the new system-wide version behaviorMauro Carvalho Chehab2011-07-273-7/+24
| | | | | Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] radio: Use the subsystem version control for VIDIOC_QUERYCAPMauro Carvalho Chehab2011-07-2720-74/+27
| | | | | | | | Just like the video drivers, the right thing to do is to use the per-subsystem version control. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] Stop using linux/version.h on the remaining video driversMauro Carvalho Chehab2011-07-2721-75/+30
| | | | | | | | | | | | | Standardize the remaining video drivers to return the API version for the VIDIOC_QUERYCAP version, instead of a per-driver version. Those drivers had the version updated more recently or are SoC drivers. Even so, it doesn't sound a good idea to keep a per-driver version control, so, let's use the per-subsystem version control instead. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] gspca: don't include linux/version.hMauro Carvalho Chehab2011-07-271-8/+4
| | | | | | | | | | | | | Instead of handling a per-driver driver version, use the per-subsystem one. As reviewed by Jean-Francois Moine <moinejf@free.fr>: - the 'info' may be simplified: Reviewed-by: Jean-Francois Moine <moinejf@free.fr> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Jean-Francois Moine <moinejf@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] uvcvideo: Use LINUX_VERSION_CODE for VIDIOC_QUERYCAPMauro Carvalho Chehab2011-07-273-4/+4
| | | | | | | | | uvcvideo doesn't use vidioc_ioctl2. As the API is changing to use a common version for all drivers, we need to expliticly fix this driver. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] sn9c102: Use LINUX_VERSION_CODE for VIDIOC_QUERYCAPMauro Carvalho Chehab2011-07-272-4/+3
| | | | | | | | | sn9c102 doesn't use vidioc_ioctl2. As the API is changing to use a common version for all drivers, we need to expliticly fix this driver. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] pvrusb2: Use LINUX_VERSION_CODE for VIDIOC_QUERYCAPMauro Carvalho Chehab2011-07-272-1/+2
| | | | | | | | | pvrusb2 doesn't use vidioc_ioctl2. As the API is changing to use a common version for all drivers, we need to expliticly fix this driver. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] et61x251: Use LINUX_VERSION_CODE for VIDIOC_QUERYCAPMauro Carvalho Chehab2011-07-272-4/+3
| | | | | | | | | et61x251 doesn't use vidioc_ioctl2. As the API is changing to use a common version for all drivers, we need to expliticly fix this driver. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] ivtv,cx18: Use default version control for VIDIOC_QUERYCAPMauro Carvalho Chehab2011-07-276-17/+2
| | | | | | | | | After discussing with Andy Walls on irc, we've agreed that this is the best thing to do. No regressions will be introduced, as 3.x.y is greater then the current versions for cx18 and ivtv. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] pwc: Use the default version for VIDIOC_QUERYCAPMauro Carvalho Chehab2011-07-272-7/+1
| | | | | | | | | | | | | | | | | | | | | After discussing with Hans, change pwc to use the default version control. The only version ever used for pwc driver is 10.0.12, due to commit 2b455db6d456ef2d44808a8377fd3bc832e08317. Changing it to 3.x.y won't conflict with the old version. There's no namespace conflicts in any predictable future. Even on the remote far-away case where we might have a conflict, it will be on just one specific stable Kernel release (Kernel 10.0.12), if we ever have such stable release. So, it is safe and consistent on using 3.x.y numering schema for it. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] Stop using linux/version.h on most video driversMauro Carvalho Chehab2011-07-2748-227/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | All the modified drivers didn't have any version increment since Jan, 1 2011. Several of them didn't have any version increment for a long time, even having new features and important bug fixes happening. As we're now filling the QUERYCAP version with the current Kernel Release, we don't need to maintain a per-driver version control anymore. So, let's just use the default. In order to preserve the Kernel module version history, a KERNEL_VERSION() macro were added to all modified drivers, and the extraver number were incremented. I opted to preserve the per-driver version control to a few pwc, pvrusb2, s2255, s5p-fimc and sh_vou. A few drivers are still using the legacy way to handle ioctl's. So, we can't do such change on them, otherwise, they'll break. Those are: uvc, et61x251 and sn9c102. The rationale is that the per-driver version control seems to be actively maintained on those. Yet, I think that the better for them would be to just use the default version numbering, instead of doing that by themselves. While here, removed a few uneeded include linux/version.h Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] drxd, siano: Remove unused include linux/version.hMauro Carvalho Chehab2011-07-272-2/+0
| | | | | | | | | | Both drxd and siano drivers were including linux/version.h without any reason. Probably, this is due to some compatibility code that used to exist before having their support added into the Linux Kernel. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l2-ioctl: Add a default value for kernel versionMauro Carvalho Chehab2011-07-271-0/+2
| | | | | | | | | | | | | Most drivers don't increase kernel versions as newer features are added or bug fixes are solved. So, vidioc_querycap returned value for cap->version is meaningless. Instead of keeping this situation forever, let's add a default value matching the current Linux version. Drivers that want to keep their own version control can still do it, as they can override the default value for cap->version. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] DocBook/v4l: Remove references to the old V4L1 compat layerMauro Carvalho Chehab2011-07-271-12/+5
| | | | | | | The old V4L1 Kernel copatibility layer was removed, but the API spec still says that it is there. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] marvell-cam: implement contiguous DMA operationJonathan Corbet2011-07-275-54/+205
| | | | | | | | | | The core driver can now operate in either vmalloc or dma-contig modes; obviously the latter is preferable when it is supported. Default is currently vmalloc on all platforms; load the module with buffer_mode=1 for contiguous DMA mode. Signed-off-by: Jonathan Corbet <corbet@lwn.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] marvell-cam: Don't spam the logs on frame lossJonathan Corbet2011-07-271-2/+0
| | | | | | | | The sequence numbers already give that information if user space cares; this is a frequent occurrence on slower machines, alas. Signed-off-by: Jonathan Corbet <corbet@lwn.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] marvell-cam: no need to initialize the DMA buffersJonathan Corbet2011-07-271-2/+0
| | | | | | | | This was an old debugging thing from years ago. It's only done at initialization time, but it's still unnecessary; take it out. Signed-off-by: Jonathan Corbet <corbet@lwn.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] marvell-cam: include file cleanupJonathan Corbet2011-07-271-8/+6
| | | | | | | | Put the includes into a slightly more readable ordering and get rid of a few unneeded ones. Signed-off-by: Jonathan Corbet <corbet@lwn.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] marvell-cam: convert to videobuf2Jonathan Corbet2011-07-273-411/+196
| | | | | | | | | | | This is a basic, naive conversion to the videobuf2 infrastructure, removing a lot of code in the process. For now, we're using vmalloc, which is suboptimal, but it does match what the cafe driver did before. In the cafe case, it may have to stay that way just because memory is too tight to do direct streaming; mmp-camera will be able to do better. Signed-off-by: Jonathan Corbet <corbet@lwn.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l: Fix minor typos in the documentationSylwester Nawrocki2011-07-273-3/+3
| | | | | Signed-off-by: Sylwester Nawrocki <snjw23@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
OpenPOWER on IntegriCloud