Add gspca subdriver for webcam Speedlink VAD Laplace (EM2765+OV2640)
Subsystems (2)
RFC PATCH v2 1/1 Add gspca subdriver for webcam Speedlink VAD Laplace (EM2765+OV2640)
This patch is the result of 3 months of reverse engineering work.
Although the driver is feature complete and working stable, it is NOT intended for kernel inclusion at this point.
Its main purpose is to provide an insight into the charactersitics and functionality of this device and to start a discussion about the best approach to add support for this device to the kernel.
The "natural" driver for this device would be the em28xx driver, which is very complicating and would require heavy modifications/extensions. For a better understanding of the device, also see http://linuxtv.org/wiki/index.php/VAD_Laplace.
Changelog V2:
- converted the driver to the new V4L2 control framework
- fixed exposure/gain fluctuations during the first 1-2 seconds after streaming start by moving the sensor initialization from sd_init to sd_start
- addressed remarks from Jean-Francois Moine:
- moved start of gpio polling from sd_config() to sd_init()
- removed the debug messages which were using the obsolete flags debug flags D_USBI, D_USBO
- use macro module_usb_driver();
- added a delay before retrying after read/write errors
- killed the last C++ comments
- some error handling fixes
- coding style and comment fixes/cleanups
ToDo:
- driver name ?
- add EM2765 chip ID to v4l2-chip-ident.h
- returned errors ok ?
- stricter error handling ?
ToDo (long term):
- use ov2640-sub-driver (needs modifictions)
--- drivers/media/usb/gspca/Kconfig | 9 + drivers/media/usb/gspca/Makefile | 2 + drivers/media/usb/gspca/em27xx.c | 1792 ++++++++++++++++++++++++++++++++++++++ 3 files changed, 1803 insertions(+), 0 deletions(-) create mode 100644 drivers/media/usb/gspca/em27xx.c
drivers/media/usb/gspca/Kconfig +9 -0
@@ -50,6 +50,15 @@ config USB_GSPCA_CPIA1 To compile this driver as a module, choose M here: the module will be called gspca_cpia1. +config USB_GSPCA_EM27XX + tristate "EM27xx USB Camera Driver" + depends on VIDEO_V4L2 && USB_GSPCA + help + Say Y here if you want support for cameras based on EM27xx chips. + + To compile this driver as a module, choose M here: the + module will be called gspca_em27xx. + config USB_GSPCA_ETOMS tristate "Etoms USB Camera Driver" depends on VIDEO_V4L2 && USB_GSPCA
drivers/media/usb/gspca/Makefile +2 -0
@@ -2,6 +2,7 @@ obj-$(CONFIG_USB_GSPCA) += gspca_main.o obj-$(CONFIG_USB_GSPCA_BENQ) += gspca_benq.o obj-$(CONFIG_USB_GSPCA_CONEX) += gspca_conex.o obj-$(CONFIG_USB_GSPCA_CPIA1) += gspca_cpia1.o +obj-$(CONFIG_USB_GSPCA_EM27XX) += gspca_em27xx.o obj-$(CONFIG_USB_GSPCA_ETOMS) += gspca_etoms.o obj-$(CONFIG_USB_GSPCA_FINEPIX) += gspca_finepix.o obj-$(CONFIG_USB_GSPCA_JEILINJ) += gspca_jeilinj.o
@@ -47,6 +48,7 @@ gspca_main-objs := gspca.o autogain_functions.o gspca_benq-objs := benq.o gspca_conex-objs := conex.o gspca_cpia1-objs := cpia1.o +gspca_em27xx-objs := em27xx.o gspca_etoms-objs := etoms.o gspca_finepix-objs := finepix.o gspca_jeilinj-objs := jeilinj.o
drivers/media/usb/gspca/em27xx.c new file +1792 -0
1,792 lines not on this page · raw message
Signature · 1 line
1.7.7