Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 80d04f22 authored by Dan Carpenter's avatar Dan Carpenter Committed by Greg Kroah-Hartman
Browse files

synclink: add mutex_unlock() on error path



There is a path which still holds its mutex here.

Signed-off-by: default avatarDan Carpenter <error27@gmail.com>
Acked-by: default avatarAlan Cox <alan@linux.intel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 49bf7eaf
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -691,9 +691,11 @@ static int open(struct tty_struct *tty, struct file *filp)
	if (info->port.count == 1) {
		/* 1st open on this device, init hardware */
		retval = startup(info);
		if (retval < 0)
		if (retval < 0) {
			mutex_unlock(&info->port.mutex);
			goto cleanup;
		}
	}
	mutex_unlock(&info->port.mutex);
	retval = block_til_ready(tty, filp, info);
	if (retval) {