diff options
Diffstat (limited to 'drivers/media/IR')
-rw-r--r-- | drivers/media/IR/lirc_dev.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/media/IR/lirc_dev.c b/drivers/media/IR/lirc_dev.c index 9e141d51df91..64170fa58006 100644 --- a/drivers/media/IR/lirc_dev.c +++ b/drivers/media/IR/lirc_dev.c | |||
@@ -657,7 +657,9 @@ ssize_t lirc_dev_fop_read(struct file *file, | |||
657 | 657 | ||
658 | if (mutex_lock_interruptible(&ir->irctl_lock)) { | 658 | if (mutex_lock_interruptible(&ir->irctl_lock)) { |
659 | ret = -ERESTARTSYS; | 659 | ret = -ERESTARTSYS; |
660 | break; | 660 | remove_wait_queue(&ir->buf->wait_poll, &wait); |
661 | set_current_state(TASK_RUNNING); | ||
662 | goto out_unlocked; | ||
661 | } | 663 | } |
662 | 664 | ||
663 | if (!ir->attached) { | 665 | if (!ir->attached) { |
@@ -676,6 +678,7 @@ ssize_t lirc_dev_fop_read(struct file *file, | |||
676 | set_current_state(TASK_RUNNING); | 678 | set_current_state(TASK_RUNNING); |
677 | mutex_unlock(&ir->irctl_lock); | 679 | mutex_unlock(&ir->irctl_lock); |
678 | 680 | ||
681 | out_unlocked: | ||
679 | dev_dbg(ir->d.dev, LOGHEAD "read result = %s (%d)\n", | 682 | dev_dbg(ir->d.dev, LOGHEAD "read result = %s (%d)\n", |
680 | ir->d.name, ir->d.minor, ret ? "-EFAULT" : "OK", ret); | 683 | ir->d.name, ir->d.minor, ret ? "-EFAULT" : "OK", ret); |
681 | 684 | ||