diff --git a/drivers/media/video/msp3400-driver.c b/drivers/media/video/msp3400-driver.c index 3bb7d6634862be289f789b810a7b1d73c7fd3ac7..507b1d4260ed2ab7f451a2fa44a26dd4033c5c79 100644 --- a/drivers/media/video/msp3400-driver.c +++ b/drivers/media/video/msp3400-driver.c @@ -157,8 +157,7 @@ static int msp_read(struct i2c_client *client, int dev, int addr) break; v4l_warn(client, "I/O error #%d (read 0x%02x/0x%02x)\n", err, dev, addr); - current->state = TASK_INTERRUPTIBLE; - schedule_timeout(msecs_to_jiffies(10)); + schedule_timeout_interruptible(msecs_to_jiffies(10)); } if (err == 3) { v4l_warn(client, "giving up, resetting chip. Sound will go off, sorry folks :-|\n"); @@ -197,8 +196,7 @@ static int msp_write(struct i2c_client *client, int dev, int addr, int val) break; v4l_warn(client, "I/O error #%d (write 0x%02x/0x%02x)\n", err, dev, addr); - current->state = TASK_INTERRUPTIBLE; - schedule_timeout(msecs_to_jiffies(10)); + schedule_timeout_interruptible(msecs_to_jiffies(10)); } if (err == 3) { v4l_warn(client, "giving up, resetting chip. Sound will go off, sorry folks :-|\n"); diff --git a/drivers/media/video/vino.c b/drivers/media/video/vino.c index 0c658b74f2c428aabff64c71e106d901e016d15f..e94a9a6036f59d59723bc07a799318653f716c61 100644 --- a/drivers/media/video/vino.c +++ b/drivers/media/video/vino.c @@ -2077,12 +2077,10 @@ static int vino_wait_for_frame(struct vino_channel_settings *vcs) init_waitqueue_entry(&wait, current); /* add ourselves into wait queue */ add_wait_queue(&vcs->fb_queue.frame_wait_queue, &wait); - /* and set current state */ - set_current_state(TASK_INTERRUPTIBLE); /* to ensure that schedule_timeout will return immediately - * if VINO interrupt was triggred meanwhile */ - schedule_timeout(HZ / 10); + * if VINO interrupt was triggered meanwhile */ + schedule_timeout_interruptible(HZ / 10); if (signal_pending(current)) err = -EINTR;