Skip to contentSkip to conversation

lirc_dev: stray unlock in lirc_dev_fop_poll()

PATCH In review Dan Carpenter 2 participants 2 messages Nov 17, 2010

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/3 lirc_dev: stray unlock in lirc_dev_fop_poll()

We shouldn't unlock here. I think this was a cut and paste error.

drivers/media/IR/lirc_dev.c +1 -3
index 8418b14..8ab9d87 100644
@@ -522,10 +522,8 @@ unsigned int lirc_dev_fop_poll(struct file *file, poll_table *wait)
 
 	dev_dbg(ir->d.dev, LOGHEAD "poll called\n", ir->d.name, ir->d.minor);
 
-	if (!ir->attached) {
-		mutex_unlock(&ir->irctl_lock);
+	if (!ir->attached)
 		return POLLERR;
-	}
 
 	poll_wait(file, &ir->buf->wait_poll, wait);