On 13/03/17 17:56, sayli karnik wrote: > The patch removes unnecessary use of goto statement. > > Signed-off-by: sayli karnik <karniksayli1995@xxxxxxxxx> Applied. Thanks, Jonathan > --- > v3: > Uncompressed return logic to avoid calling the function twice > > drivers/staging/iio/frequency/ad9834.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/staging/iio/frequency/ad9834.c b/drivers/staging/iio/frequency/ad9834.c > index 2dffe48..af108e9 100644 > --- a/drivers/staging/iio/frequency/ad9834.c > +++ b/drivers/staging/iio/frequency/ad9834.c > @@ -149,7 +149,7 @@ static ssize_t ad9834_write(struct device *dev, > > ret = kstrtoul(buf, 10, &val); > if (ret) > - goto error_ret; > + return ret; > > mutex_lock(&st->lock); > switch ((u32)this_attr->address) { > @@ -211,7 +211,6 @@ static ssize_t ad9834_write(struct device *dev, > } > mutex_unlock(&st->lock); > > -error_ret: > return ret ? ret : len; > } > > -- To unsubscribe from this list: send the line "unsubscribe linux-iio" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html