Commit e50f8e04 authored by Jiapeng Chong's avatar Jiapeng Chong Committed by Jonathan Cameron

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: default avatarAbaci Robot <abaci@linux.alibaba.com>
Signed-off-by: default avatarJiapeng Chong <jiapeng.chong@linux.alibaba.com>
Link: https://lore.kernel.org/r/1621246317-62725-1-git-send-email-jiapeng.chong@linux.alibaba.comSigned-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
parent af51ec8c
......@@ -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) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment