aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/vivi.c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@infradead.org>2007-01-13 07:25:16 -0500
committerMauro Carvalho Chehab <mchehab@infradead.org>2007-02-21 10:34:21 -0500
commitdf3a710458462aa9427cdeec947bf71af257e8dd (patch)
treee670084d11b28fe3da8e46cf03fff909b1a7c19e /drivers/media/video/vivi.c
parentae1942c5712f700c9ccc8cc287c51db4daaa50d7 (diff)
V4L/DVB (5073): Fix OOPS on some waitqueue conditions
If for some reason vivi_thread() fails, vivi will suffer an OOPS at thread stop code, since waitqueue wouldn't be properly initializated. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/vivi.c')
-rw-r--r--drivers/media/video/vivi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/video/vivi.c b/drivers/media/video/vivi.c
index cfb6b1f0402c..119cfd5ce312 100644
--- a/drivers/media/video/vivi.c
+++ b/drivers/media/video/vivi.c
@@ -538,7 +538,6 @@ static int vivi_start_thread(struct vivi_dmaqueue *dma_q)
538 dma_q->ini_jiffies=jiffies; 538 dma_q->ini_jiffies=jiffies;
539 539
540 dprintk(1,"%s\n",__FUNCTION__); 540 dprintk(1,"%s\n",__FUNCTION__);
541 init_waitqueue_head(&dma_q->wq);
542 541
543 dma_q->kthread = kthread_run(vivi_thread, dma_q, "vivi"); 542 dma_q->kthread = kthread_run(vivi_thread, dma_q, "vivi");
544 543
@@ -1352,6 +1351,7 @@ static int __init vivi_init(void)
1352 /* init video dma queues */ 1351 /* init video dma queues */
1353 INIT_LIST_HEAD(&dev->vidq.active); 1352 INIT_LIST_HEAD(&dev->vidq.active);
1354 INIT_LIST_HEAD(&dev->vidq.queued); 1353 INIT_LIST_HEAD(&dev->vidq.queued);
1354 init_waitqueue_head(&dev->vidq.wq);
1355 1355
1356 /* initialize locks */ 1356 /* initialize locks */
1357 init_MUTEX(&dev->lock); 1357 init_MUTEX(&dev->lock);