Skip to content

Commit

Permalink
Staging: comedi: unlock on error in usbduxsigma_attach()
Browse files Browse the repository at this point in the history
We should release the udev->sem lock before returning.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Dan Carpenter authored and Greg Kroah-Hartman committed Dec 8, 2011
1 parent d6610a5 commit 2f30866
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/staging/comedi/drivers/usbduxsigma.c
Original file line number Diff line number Diff line change
Expand Up @@ -2691,6 +2691,7 @@ static int usbduxsigma_attach(struct comedi_device *dev,
if (ret < 0) {
dev_err(&udev->interface->dev,
"comedi%d: no space for subdev\n", dev->minor);
up(&udev->sem);
up(&start_stop_sem);
return ret;
}
Expand Down

0 comments on commit 2f30866

Please sign in to comment.