aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/gspca/jeilinj.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/video/gspca/jeilinj.c')
-rw-r--r--drivers/media/video/gspca/jeilinj.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/media/video/gspca/jeilinj.c b/drivers/media/video/gspca/jeilinj.c
index 84ecd56c6470..12d9cf4caba2 100644
--- a/drivers/media/video/gspca/jeilinj.c
+++ b/drivers/media/video/gspca/jeilinj.c
@@ -50,7 +50,7 @@ struct sd {
50 struct workqueue_struct *work_thread; 50 struct workqueue_struct *work_thread;
51 u8 quality; /* image quality */ 51 u8 quality; /* image quality */
52 u8 jpegqual; /* webcam quality */ 52 u8 jpegqual; /* webcam quality */
53 u8 *jpeg_hdr; 53 u8 jpeg_hdr[JPEG_HDR_SZ];
54}; 54};
55 55
56 struct jlj_command { 56 struct jlj_command {
@@ -282,7 +282,6 @@ static void sd_stop0(struct gspca_dev *gspca_dev)
282 destroy_workqueue(dev->work_thread); 282 destroy_workqueue(dev->work_thread);
283 dev->work_thread = NULL; 283 dev->work_thread = NULL;
284 mutex_lock(&gspca_dev->usb_lock); 284 mutex_lock(&gspca_dev->usb_lock);
285 kfree(dev->jpeg_hdr);
286} 285}
287 286
288/* this function is called at probe and resume time */ 287/* this function is called at probe and resume time */
@@ -298,9 +297,6 @@ static int sd_start(struct gspca_dev *gspca_dev)
298 int ret; 297 int ret;
299 298
300 /* create the JPEG header */ 299 /* create the JPEG header */
301 dev->jpeg_hdr = kmalloc(JPEG_HDR_SZ, GFP_KERNEL);
302 if (dev->jpeg_hdr == NULL)
303 return -ENOMEM;
304 jpeg_define(dev->jpeg_hdr, gspca_dev->height, gspca_dev->width, 300 jpeg_define(dev->jpeg_hdr, gspca_dev->height, gspca_dev->width,
305 0x21); /* JPEG 422 */ 301 0x21); /* JPEG 422 */
306 jpeg_set_qual(dev->jpeg_hdr, dev->quality); 302 jpeg_set_qual(dev->jpeg_hdr, dev->quality);