]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commitdiff
staging: iio: ad9834: Remove unnecessary goto statement
authorsayli karnik <karniksayli1995@gmail.com>
Mon, 13 Mar 2017 17:56:18 +0000 (23:26 +0530)
committerJonathan Cameron <jic23@kernel.org>
Wed, 15 Mar 2017 22:13:57 +0000 (22:13 +0000)
The patch removes unnecessary use of goto statement.

Signed-off-by: sayli karnik <karniksayli1995@gmail.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/staging/iio/frequency/ad9834.c

index 2dffe48035f3915fa6b3194c9669cd12b94ab7a5..af108e96b3ecbc43b26b04193def4f6de07f1b41 100644 (file)
@@ -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;
 }