lkml.org 
[lkml]   [2015]   [May]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] iio: buffer: remove unneeded test
Date
The same code is executed regardless ret value, so this test
can be removed.
Also fix coverity scan CID 1268786.

Signed-off-by: Laurent Navet <laurent.navet@gmail.com>
---
drivers/iio/industrialio-buffer.c | 2 --
1 file changed, 2 deletions(-)

diff --git a/drivers/iio/industrialio-buffer.c b/drivers/iio/industrialio-buffer.c
index df919f4..e7fbcce 100644
--- a/drivers/iio/industrialio-buffer.c
+++ b/drivers/iio/industrialio-buffer.c
@@ -806,8 +806,6 @@ static ssize_t iio_buffer_store_enable(struct device *dev,
ret = __iio_update_buffers(indio_dev,
NULL, indio_dev->buffer);

- if (ret < 0)
- goto done;
done:
mutex_unlock(&indio_dev->mlock);
return (ret < 0) ? ret : len;
--
2.1.4


\
 
 \ /
  Last update: 2015-05-30 22:41    [W:0.038 / U:28.104 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site