diff options
author | Mauro Carvalho Chehab <mchehab@infradead.org> | 2006-06-23 13:57:52 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2006-06-23 13:57:52 -0300 |
commit | 27db32c1fbbd03a1427f7b783dcc7eee372c953e (patch) | |
tree | 15019ebf9583a5bac96b03f0d3b2be7507363872 /linux/drivers/media/video/pwc | |
parent | 81d3af21e291c984f3e302fe4b142eb066ad5e44 (diff) | |
parent | 515941d047746d1026ffe99a794edd9ffea7a4d1 (diff) | |
download | mediapointer-dvb-s2-27db32c1fbbd03a1427f7b783dcc7eee372c953e.tar.gz mediapointer-dvb-s2-27db32c1fbbd03a1427f7b783dcc7eee372c953e.tar.bz2 |
merge: http://www.linuxtv.org/hg/~manu/v4l-algo
From: Mauro Carvalho Chehab <mchehab@infradead.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'linux/drivers/media/video/pwc')
-rw-r--r-- | linux/drivers/media/video/pwc/pwc-ctrl.c | 4 | ||||
-rw-r--r-- | linux/drivers/media/video/pwc/pwc-dec23.c | 4 | ||||
-rw-r--r-- | linux/drivers/media/video/pwc/pwc-if.c | 12 | ||||
-rw-r--r-- | linux/drivers/media/video/pwc/pwc-v4l.c | 38 | ||||
-rw-r--r-- | linux/drivers/media/video/pwc/pwc.h | 2 |
5 files changed, 29 insertions, 31 deletions
diff --git a/linux/drivers/media/video/pwc/pwc-ctrl.c b/linux/drivers/media/video/pwc/pwc-ctrl.c index c64f498f1..acd8d4af1 100644 --- a/linux/drivers/media/video/pwc/pwc-ctrl.c +++ b/linux/drivers/media/video/pwc/pwc-ctrl.c @@ -925,7 +925,7 @@ int pwc_set_leds(struct pwc_device *pdev, int on_value, int off_value) return SendControlMsg(SET_STATUS_CTL, LED_FORMATTER, 2); } -int pwc_get_leds(struct pwc_device *pdev, int *on_value, int *off_value) +static int pwc_get_leds(struct pwc_device *pdev, int *on_value, int *off_value) { unsigned char buf[2]; int ret; @@ -1404,7 +1404,7 @@ int pwc_ioctl(struct pwc_device *pdev, unsigned int cmd, void *arg) ARG_IN(leds) ret = pwc_set_leds(pdev, ARGR(leds).led_on, ARGR(leds).led_off); - break; + break; } diff --git a/linux/drivers/media/video/pwc/pwc-dec23.c b/linux/drivers/media/video/pwc/pwc-dec23.c index 39eaf5839..9e2d91f26 100644 --- a/linux/drivers/media/video/pwc/pwc-dec23.c +++ b/linux/drivers/media/video/pwc/pwc-dec23.c @@ -105,7 +105,7 @@ static void build_bit_powermask_table(struct pwc_dec23_private *pdec) static void build_table_color(const unsigned int romtable[16][8], - unsigned char p0004[16][1024], + unsigned char p0004[16][1024], unsigned char p8004[16][256]) { int compression_mode, j, k, bit, pw; @@ -787,7 +787,7 @@ static void DecompressBand23(struct pwc_dec23_private *pdec, * */ static void DecompressBandBayer(struct pwc_dec23_private *pdec, - const unsigned char *rawyuv, + const unsigned char *rawyuv, unsigned char *rgbbayer, unsigned int compressed_image_width, unsigned int real_image_width) diff --git a/linux/drivers/media/video/pwc/pwc-if.c b/linux/drivers/media/video/pwc/pwc-if.c index fbe7ae2a9..a241a3060 100644 --- a/linux/drivers/media/video/pwc/pwc-if.c +++ b/linux/drivers/media/video/pwc/pwc-if.c @@ -133,7 +133,7 @@ static int default_fbufs = 3; /* Default number of frame buffers */ #endif static int power_save = 0; static int led_on = 100, led_off = 0; /* defaults to LED that is on while in use */ - int pwc_preferred_compression = 1; /* 0..3 = uncompressed..high */ +static int pwc_preferred_compression = 1; /* 0..3 = uncompressed..high */ static struct { int type; char serial_number[30]; @@ -1097,7 +1097,7 @@ static const char *pwc_sensor_type_to_string(unsigned int sensor_type) case 0x101: return "PAL MR sensor"; default: - return "unknown type of sensor"; + return "unknown type of sensor"; } } #endif @@ -1744,10 +1744,10 @@ static int usb_pwc_probe(struct usb_interface *intf, const struct usb_device_id (device_hint[hint].pdev == NULL)) { /* so far, so good... try serial number */ if ((device_hint[hint].serial_number[0] == '*') || !strcmp(device_hint[hint].serial_number, serial_number)) { - /* match! */ - video_nr = device_hint[hint].device_node; - PWC_DEBUG_PROBE("Found hint, will try to register as /dev/video%d\n", video_nr); - break; + /* match! */ + video_nr = device_hint[hint].device_node; + PWC_DEBUG_PROBE("Found hint, will try to register as /dev/video%d\n", video_nr); + break; } } } diff --git a/linux/drivers/media/video/pwc/pwc-v4l.c b/linux/drivers/media/video/pwc/pwc-v4l.c index 86faadd48..bd918b87c 100644 --- a/linux/drivers/media/video/pwc/pwc-v4l.c +++ b/linux/drivers/media/video/pwc/pwc-v4l.c @@ -678,9 +678,9 @@ int pwc_video_do_ioctl(struct inode *inode, struct file *file, break; } - /* V4L2 Layer */ - case VIDIOC_QUERYCAP: - { + /* V4L2 Layer */ + case VIDIOC_QUERYCAP: + { struct v4l2_capability *cap = arg; PWC_DEBUG_IOCTL("ioctl(VIDIOC_QUERYCAP) This application "\ @@ -696,8 +696,8 @@ int pwc_video_do_ioctl(struct inode *inode, struct file *file, return 0; } - case VIDIOC_ENUMINPUT: - { + case VIDIOC_ENUMINPUT: + { struct v4l2_input *i = arg; if ( i->index ) /* Only one INPUT is supported */ @@ -708,14 +708,14 @@ int pwc_video_do_ioctl(struct inode *inode, struct file *file, return 0; } - case VIDIOC_G_INPUT: + case VIDIOC_G_INPUT: { int *i = arg; *i = 0; /* Only one INPUT is supported */ return 0; } - case VIDIOC_S_INPUT: - { + case VIDIOC_S_INPUT: + { int *i = arg; if ( *i ) { /* Only one INPUT is supported */ @@ -727,7 +727,7 @@ int pwc_video_do_ioctl(struct inode *inode, struct file *file, } /* TODO: */ - case VIDIOC_QUERYCTRL: + case VIDIOC_QUERYCTRL: { struct v4l2_queryctrl *c = arg; int i; @@ -965,13 +965,13 @@ int pwc_video_do_ioctl(struct inode *inode, struct file *file, case VIDIOC_ENUM_FMT: { - struct v4l2_fmtdesc *f = arg; + struct v4l2_fmtdesc *f = arg; int index; if (f->type != V4L2_BUF_TYPE_VIDEO_CAPTURE) return -EINVAL; - /* We only support two format: the raw format, and YUV */ + /* We only support two format: the raw format, and YUV */ index = f->index; memset(f,0,sizeof(struct v4l2_fmtdesc)); f->type = V4L2_BUF_TYPE_VIDEO_CAPTURE; @@ -980,23 +980,23 @@ int pwc_video_do_ioctl(struct inode *inode, struct file *file, { case 0: /* RAW format */ - f->pixelformat = pdev->type<=646?V4L2_PIX_FMT_PWC1:V4L2_PIX_FMT_PWC2; + f->pixelformat = pdev->type<=646?V4L2_PIX_FMT_PWC1:V4L2_PIX_FMT_PWC2; f->flags = V4L2_FMT_FLAG_COMPRESSED; - strlcpy(f->description,"Raw Philips Webcam",sizeof(f->description)); + strlcpy(f->description,"Raw Philips Webcam",sizeof(f->description)); break; case 1: - f->pixelformat = V4L2_PIX_FMT_YUV420; - strlcpy(f->description,"4:2:0, planar, Y-Cb-Cr",sizeof(f->description)); + f->pixelformat = V4L2_PIX_FMT_YUV420; + strlcpy(f->description,"4:2:0, planar, Y-Cb-Cr",sizeof(f->description)); break; - default: + default: return -EINVAL; } return 0; } - case VIDIOC_G_FMT: + case VIDIOC_G_FMT: { - struct v4l2_format *f = arg; + struct v4l2_format *f = arg; PWC_DEBUG_IOCTL("ioctl(VIDIOC_G_FMT) return size %dx%d\n",pdev->image.x,pdev->image.y); if (f->type != V4L2_BUF_TYPE_VIDEO_CAPTURE) @@ -1010,7 +1010,7 @@ int pwc_video_do_ioctl(struct inode *inode, struct file *file, case VIDIOC_TRY_FMT: return pwc_vidioc_try_fmt(pdev, arg); - case VIDIOC_S_FMT: + case VIDIOC_S_FMT: return pwc_vidioc_set_fmt(pdev, arg); case VIDIOC_G_STD: diff --git a/linux/drivers/media/video/pwc/pwc.h b/linux/drivers/media/video/pwc/pwc.h index a087108d0..629f79e44 100644 --- a/linux/drivers/media/video/pwc/pwc.h +++ b/linux/drivers/media/video/pwc/pwc.h @@ -274,7 +274,6 @@ extern "C" { #if CONFIG_PWC_DEBUG extern int pwc_trace; #endif -extern int pwc_preferred_compression; extern int pwc_mbufs; /** functions in pwc-if.c */ @@ -308,7 +307,6 @@ extern int pwc_set_gamma(struct pwc_device *pdev, int value); extern int pwc_get_saturation(struct pwc_device *pdev, int *value); extern int pwc_set_saturation(struct pwc_device *pdev, int value); extern int pwc_set_leds(struct pwc_device *pdev, int on_value, int off_value); -extern int pwc_get_leds(struct pwc_device *pdev, int *on_value, int *off_value); extern int pwc_get_cmos_sensor(struct pwc_device *pdev, int *sensor); extern int pwc_restore_user(struct pwc_device *pdev); extern int pwc_save_user(struct pwc_device *pdev); |