|
SyntekUSBVideoCamera
|
Driver for Syntek USB video camera. More...
#include <linux/module.h>#include <linux/init.h>#include <linux/kernel.h>#include <linux/version.h>#include <linux/errno.h>#include <linux/slab.h>#include <linux/kref.h>#include <linux/vmalloc.h>#include <linux/mm.h>#include <linux/usb.h>#include <media/v4l2-common.h>#include <media/v4l2-ioctl.h>#include "stk11xx.h"Go to the source code of this file.
Functions | |
| int | v4l_stk11xx_select_video_mode (struct usb_stk11xx *dev, int width, int height) |
| Select a video mode. More... | |
| static int | v4l_stk11xx_open (struct file *fp) |
| Open the video device. More... | |
| static int | v4l_stk11xx_release (struct file *fp) |
| Release an opened file. More... | |
| static ssize_t | v4l_stk11xx_read (struct file *fp, char __user *buf, size_t count, loff_t *f_pos) |
| Read the video device. More... | |
| static unsigned int | v4l_stk11xx_poll (struct file *fp, poll_table *wait) |
| Polling function. More... | |
| static int | v4l_stk11xx_mmap (struct file *fp, struct vm_area_struct *vma) |
| Memory map. More... | |
| static long | v4l_stk11xx_do_ioctl (struct file *fp, unsigned int cmd, void __user *arg) |
| Manage IOCTL. More... | |
| static long | v4l_stk11xx_ioctl (struct file *fp, unsigned int cmd, unsigned long arg) |
| Manage IOCTL. More... | |
| int | v4l_stk11xx_register_video_device (struct usb_stk11xx *dev) |
| Register the video device. More... | |
| int | v4l_stk11xx_unregister_video_device (struct usb_stk11xx *dev) |
| Unregister the video device. More... | |
Variables | |
| static struct v4l2_file_operations | v4l_stk11xx_fops |
| const struct stk11xx_coord | stk11xx_image_sizes [STK11XX_NBR_SIZES] |
| static struct v4l2_queryctrl | stk11xx_controls [] |
Driver for Syntek USB video camera.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Definition in file stk11xx-v4l.c.
|
static |
Manage IOCTL.
| fp | File pointer |
| cmd | Command |
| arg | Arguments of the command |
This function permits to manage all the IOCTL from the application.
Definition at line 664 of file stk11xx-v4l.c.
References DRIVER_VERSION_NUM, STK_DEBUG, usb_stk11xx::udev, usb_stk11xx::vdev, and usb_stk11xx::webcam_model.
Referenced by v4l_stk11xx_ioctl().
|
static |
Manage IOCTL.
| fp | File pointer |
| cmd | Command |
| arg | Arguements of the command |
This function permits to manage all the IOCTL from the application.
Definition at line 1460 of file stk11xx-v4l.c.
References usb_stk11xx::modlock, STK_DEBUG, and v4l_stk11xx_do_ioctl().
|
static |
Memory map.
| fp | File pointer |
| vma | VMA structure |
This function permits to map a memory space.
Definition at line 583 of file stk11xx-v4l.c.
References stk11xx_image_buf::offset, STK11XX_MAX_IMAGES, STK_ERROR, and STK_STREAM.
|
static |
Open the video device.
| fp | File pointer |
This function permits to open a video device (/dev/videoX)
Definition at line 308 of file stk11xx-v4l.c.
References stk11xx_video::depth, stk11xx_video::hue, usb_stk11xx::modlock, stk11xx_video::palette, stk11xx_allocate_buffers(), stk11xx_reset_buffers(), STK_DEBUG, STK_ERROR, usb_stk11xx::v1st_cap, usb_stk11xx::vframes_dumped, usb_stk11xx::vframes_error, usb_stk11xx::visoc_errors, usb_stk11xx::vopen, usb_stk11xx::vsettings, usb_stk11xx::vsync, and stk11xx_video::whiteness.
|
static |
Polling function.
| fp | File pointer |
| wait |
Definition at line 545 of file stk11xx-v4l.c.
References STK_STREAM, and usb_stk11xx::wait_frame.
|
static |
Read the video device.
| fp | File pointer |
| buf | Buffer in user space |
| count | |
| f_pos |
This function is called by the application is reading the video device.
Definition at line 446 of file stk11xx-v4l.c.
References usb_stk11xx::modlock, stk11xx_image_buf::offset, stk11xx_handle_frame(), stk11xx_next_image(), STK_STREAM, and usb_stk11xx::wait_frame.
| int v4l_stk11xx_register_video_device | ( | struct usb_stk11xx * | dev | ) |
Register the video device.
| dev | Device structure |
This function permits to register the USB device to the video device.
Definition at line 1497 of file stk11xx-v4l.c.
References DRIVER_DESC, usb_stk11xx::interface, STK_ERROR, STK_INFO, v4l_stk11xx_fops, and usb_stk11xx::vdev.
|
static |
Release an opened file.
| fp | File pointer |
This function permits to release an opened file with the 'open' method.
Definition at line 401 of file stk11xx-v4l.c.
References dev_stk11xx_camera_asleep(), dev_stk11xx_camera_off(), dev_stk11xx_stop_stream(), stk11xx_free_buffers(), STK_ERROR, usb_stk11xx_isoc_cleanup(), and usb_stk11xx::vopen.
| int v4l_stk11xx_select_video_mode | ( | struct usb_stk11xx * | dev, |
| int | width, | ||
| int | height | ||
| ) |
Select a video mode.
| dev | |
| width | Width of wished resolution |
| height | Height of wished resolution |
This function permits to check and select a video mode.
Definition at line 156 of file stk11xx-v4l.c.
References stk11xx_image_sizes, STK11XX_SXGA, usb_stk11xx::webcam_type, stk11xx_coord::x, and stk11xx_coord::y.
| int v4l_stk11xx_unregister_video_device | ( | struct usb_stk11xx * | dev | ) |
Unregister the video device.
| dev | Device structure |
This function permits to unregister the video device.
Definition at line 1530 of file stk11xx-v4l.c.
References STK_INFO, and usb_stk11xx::vdev.
Referenced by usb_stk11xx_disconnect().
|
static |
List of all V4Lv2 controls supported by the driver Default_value field will be overriden at runtime
Definition at line 78 of file stk11xx-v4l.c.
| const struct stk11xx_coord stk11xx_image_sizes[STK11XX_NBR_SIZES] |
List of all resolutions supported by the driver
Definition at line 59 of file stk11xx-v4l.c.
Referenced by v4l_stk11xx_select_video_mode().
|
static |
This variable contains some callback
Definition at line 52 of file stk11xx-v4l.c.
Referenced by v4l_stk11xx_register_video_device().
1.8.14