summaryrefslogtreecommitdiff
path: root/linux/drivers
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@infradead.org>2006-12-20 11:04:00 -0200
committerMauro Carvalho Chehab <mchehab@infradead.org>2006-12-20 11:04:00 -0200
commit745a73747ae253f939f272fba08ed2739448cded (patch)
treeafcebf7b9e526087dc267e9db70ae3331ee4b8d1 /linux/drivers
parentd0ba028476be663d9871ec33a547431bb98b052b (diff)
downloadmediapointer-dvb-s2-745a73747ae253f939f272fba08ed2739448cded.tar.gz
mediapointer-dvb-s2-745a73747ae253f939f272fba08ed2739448cded.tar.bz2
Vivi: fix kthread_run() error check
From: Akinobu Mita <akinobu.mita@gmail.com> The return value of kthread_run() should be checked by IS_ERR(). Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'linux/drivers')
-rw-r--r--linux/drivers/media/video/vivi.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/linux/drivers/media/video/vivi.c b/linux/drivers/media/video/vivi.c
index fb69c6dbb..5370538bc 100644
--- a/linux/drivers/media/video/vivi.c
+++ b/linux/drivers/media/video/vivi.c
@@ -592,9 +592,9 @@ static int vivi_start_thread(struct vivi_dmaqueue *dma_q)
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)
dma_q->kthread = kthread_run(vivi_thread, dma_q, "vivi");
- if (dma_q->kthread == NULL) {
+ if (IS_ERR(dma_q->kthread)) {
printk(KERN_ERR "vivi: kernel_thread() failed\n");
- return -EINVAL;
+ return PTR_ERR(dma_q->kthread);
}
#else
DECLARE_MUTEX_LOCKED(sem);