From: Dan Carpenter Date: Thu, 29 Nov 2012 14:17:25 +0000 (+0300) Subject: staging: gdm72xx: unlock on error in init_usb() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e143ef8f297d980037149fe2dc62af72621a0f5e;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git staging: gdm72xx: unlock on error in init_usb() We recently added locking here and there was an error path which is missing an unlock. Signed-off-by: Dan Carpenter Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/gdm72xx/gdm_usb.c b/drivers/staging/gdm72xx/gdm_usb.c index 3709824e7ca3..bce6104bbab8 100644 --- a/drivers/staging/gdm72xx/gdm_usb.c +++ b/drivers/staging/gdm72xx/gdm_usb.c @@ -205,6 +205,7 @@ static int init_usb(struct usbwm_dev *udev) for (i = 0; i < MAX_NR_SDU_BUF; i++) { t = alloc_tx_struct(tx); if (t == NULL) { + spin_unlock_irqrestore(&tx->lock, flags); ret = -ENOMEM; goto fail; }