Skip to content

Commit

Permalink
V4L/DVB (4996): Msp3400: fix kthread_run error check
Browse files Browse the repository at this point in the history
The return value of kthread_run() should be checked by IS_ERR().

Signed-off-by: Akinobu Mita <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
  • Loading branch information
mita authored and mchehab committed Dec 27, 2006
1 parent 054afee commit 2582140
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/media/video/msp3400-driver.c
Original file line number Diff line number Diff line change
Expand Up @@ -949,7 +949,7 @@ static int msp_attach(struct i2c_adapter *adapter, int address, int kind)
if (thread_func) {
state->kthread = kthread_run(thread_func, client, "msp34xx");

if (state->kthread == NULL)
if (IS_ERR(state->kthread))
v4l_warn(client, "kernel_thread() failed\n");
msp_wake_thread(client);
}
Expand Down

0 comments on commit 2582140

Please sign in to comment.