diff options
Diffstat (limited to 'drivers/media/usb/zr364xx/zr364xx.c')
-rw-r--r-- | drivers/media/usb/zr364xx/zr364xx.c | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/drivers/media/usb/zr364xx/zr364xx.c b/drivers/media/usb/zr364xx/zr364xx.c index a9bcba4fa9c6..637962825d7a 100644 --- a/drivers/media/usb/zr364xx/zr364xx.c +++ b/drivers/media/usb/zr364xx/zr364xx.c @@ -141,7 +141,6 @@ struct zr364xx_pipeinfo { }; struct zr364xx_fmt { - char *name; u32 fourcc; int depth; }; @@ -149,7 +148,6 @@ struct zr364xx_fmt { /* image formats. */ static const struct zr364xx_fmt formats[] = { { - .name = "JPG", .fourcc = V4L2_PIX_FMT_JPEG, .depth = 24 } @@ -199,12 +197,10 @@ static int send_control_msg(struct usb_device *udev, u8 request, u16 value, { int status; - unsigned char *transfer_buffer = kmalloc(size, GFP_KERNEL); + unsigned char *transfer_buffer = kmemdup(cp, size, GFP_KERNEL); if (!transfer_buffer) return -ENOMEM; - memcpy(transfer_buffer, cp, size); - status = usb_control_msg(udev, usb_sndctrlpipe(udev, 0), request, @@ -376,8 +372,7 @@ static int buffer_prepare(struct videobuf_queue *vq, struct videobuf_buffer *vb, vb); int rc; - DBG("%s, field=%d, fmt name = %s\n", __func__, field, - cam->fmt ? cam->fmt->name : ""); + DBG("%s, field=%d\n", __func__, field); if (!cam->fmt) return -EINVAL; @@ -751,8 +746,6 @@ static int zr364xx_vidioc_enum_fmt_vid_cap(struct file *file, { if (f->index > 0) return -EINVAL; - f->flags = V4L2_FMT_FLAG_COMPRESSED; - strscpy(f->description, formats[0].name, sizeof(f->description)); f->pixelformat = formats[0].fourcc; return 0; } |