Re: [patch] Staging: iio/adc/ad7150: release lock on error

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 10/06/11 07:17, Dan Carpenter wrote:
> The error_ret label should have been before the mutex_unlock().  It's
> a typo.
Good catch thanks!
> 
> Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
Acked-by: Jonathan Cameron <jic23@xxxxxxxxx>
> 
> diff --git a/drivers/staging/iio/adc/ad7150.c b/drivers/staging/iio/adc/ad7150.c
> index 8943420..d1767d8 100644
> --- a/drivers/staging/iio/adc/ad7150.c
> +++ b/drivers/staging/iio/adc/ad7150.c
> @@ -332,8 +332,8 @@ static int ad7150_write_event_value(struct iio_dev *indio_dev,
>  	/* write back if active */
>  	ret = ad7150_write_event_params(indio_dev, event_code);
>  
> -	mutex_unlock(&chip->state_lock);
>  error_ret:
> +	mutex_unlock(&chip->state_lock);
>  	return ret;
>  }
>  
> 

--
To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux