summaryrefslogtreecommitdiffstats
path: root/drivers/iio/industrialio-buffer.c
diff options
context:
space:
mode:
authorJiapeng Chong <jiapeng.chong@linux.alibaba.com>2021-05-17 12:11:57 +0200
committerJonathan Cameron <Jonathan.Cameron@huawei.com>2021-06-03 19:24:12 +0200
commite50f8e0495541e827e8c3d13118dc30feaee99fb (patch)
treeda9ea3f10f50fea554725c0537449ce4b51ae398 /drivers/iio/industrialio-buffer.c
parentiio: hid: trigger: Balance runtime pm + use pm_runtime_resume_and_get() (diff)
downloadlinux-e50f8e0495541e827e8c3d13118dc30feaee99fb.tar.xz
linux-e50f8e0495541e827e8c3d13118dc30feaee99fb.zip
iio: buffer: Remove redundant assignment to in_loc
Variable in_loc is being assigned a value from a calculation however the assignment is never read, so this redundant assignment can be removed. Clean up the following clang-analyzer warning: drivers/iio/industrialio-buffer.c:929:3: warning: Value stored to 'in_loc' is never read [clang-analyzer-deadcode.DeadStores]. Reported-by: Abaci Robot <abaci@linux.alibaba.com> Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com> Link: https://lore.kernel.org/r/1621246317-62725-1-git-send-email-jiapeng.chong@linux.alibaba.com Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'drivers/iio/industrialio-buffer.c')
-rw-r--r--drivers/iio/industrialio-buffer.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/iio/industrialio-buffer.c b/drivers/iio/industrialio-buffer.c
index 10923b40c76d..fdd623407b96 100644
--- a/drivers/iio/industrialio-buffer.c
+++ b/drivers/iio/industrialio-buffer.c
@@ -926,7 +926,6 @@ static int iio_buffer_update_demux(struct iio_dev *indio_dev,
if (ret)
goto error_clear_mux_table;
out_loc += length;
- in_loc += length;
}
buffer->demux_bounce = kzalloc(out_loc, GFP_KERNEL);
if (buffer->demux_bounce == NULL) {