aboutsummaryrefslogtreecommitdiff
path: root/drivers/media/video/v4l2-device.c
AgeCommit message (Collapse)Author
2010-12-01[media] V4L: improve the BKL replacement heuristicHans Verkuil
The BKL replacement mutex had some serious performance side-effects on V4L drivers. It is replaced by a better heuristic that works around the worst of the side-effects. Read the v4l2-dev.c comments for the whole sorry story. This is a temporary measure only until we can convert all v4l drivers to use unlocked_ioctl. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-08-08V4L/DVB: v4l2: hook up the new control framework into the core frameworkHans Verkuil
Add the calls needed to automatically merge subdev controls into a bridge control handler. Hook up the control framework in __video_ioctl2 and video_register_device. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-05-18V4L/DVB: Add SPI support to V4L2Dmitri Belimov
Add support SPI bus to v4l2. Useful for control some device with SPI bus like hardware MPEG2 encoders and etc. Signed-off-by: Beholder Intl. Ltd. Dmitry Belimov <d.belimov@gmail.com> Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-06-16V4L/DVB (11936): Fix v4l2-device usage of i2c_unregister_device()Randy Dunlap
Fix v4l2-device usage of i2c_unregister_device() and handle the case of CONFIG_I2C=m & CONFIG_MEDIA_VIDEO=y. Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-06-16V4L/DVB (11758): 2: handle unregister for non-I2C buildsRandy Dunlap
Build fails when CONFIG_I2C=n, so handle that case in the if block: drivers/built-in.o: In function `v4l2_device_unregister': (.text+0x157821): undefined reference to `i2c_unregister_device' Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-06-16V4L/DVB (11673): v4l2-device: unregister i2c_clients when unregistering the ↵Hans Verkuil
v4l2_device. Until now I relied on i2c_del_adapter to unregister the i2c_clients for me, however, if the i2c bus is a platform bus then it is never deleted. So instead I need to unregister i2c clients when unregistering the v4l2_device. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-06-16V4L/DVB (11671): v4l2: add v4l2_device_set_name()Hans Verkuil
Add a utility function that can be used to setup the v4l2_device's name field in a standard manner. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (11044): v4l2-device: add v4l2_device_disconnectHans Verkuil
Call v4l2_device_disconnect when the parent of a hotpluggable device disconnects. This ensures that you do not have a pointer to a device that is no longer present. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10644): v4l2-subdev: rename dev field to v4l2_devHans Verkuil
Remain consistent in the naming: fields pointing to v4l2_device should be called v4l2_dev. There are too many device-like entities without adding to the confusion by mixing naming conventions. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-30V4L/DVB (10643): v4l2-device: allow a NULL parent device when registering.Hans Verkuil
Some drivers (e.g. for ISA devices) have no parent device because there is no associated bus driver. Allow the parent device to be NULL in those cases when registering v4l2_device. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2009-03-24v4l: struct device - replace bus_id with dev_name(), dev_set_name()Kay Sievers
Cc: mchehab@infradead.org Cc: linux-media@vger.kernel.org Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
2009-01-07V4L/DVB (10181): v4l2-device: Fix some sparse warningsMauro Carvalho Chehab
/home/v4l/master/v4l/v4l2-device.c:32:2: warning: Using plain integer as NULL pointer /home/v4l/master/v4l/v4l2-device.c:64:2: warning: Using plain integer as NULL pointer Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2008-12-30V4L/DVB (9820): v4l2: add v4l2_device and v4l2_subdev structs to the v4l2 ↵Hans Verkuil
framework. Start implementing a proper v4l2 framework as discussed during the Linux Plumbers Conference 2008. Introduces v4l2_device (for device instances) and v4l2_subdev (representing sub-device instances). Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Reviewed-by: Laurent Pinchart <laurent.pinchart@skynet.be> Reviewed-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Reviewed-by: Andy Walls <awalls@radix.net> Reviewed-by: David Brownell <david-b@pacbell.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>