Move ret variable to the IIO_CHAN_INFO_RAW switch since currently
only used within that scope.
Signed-off-by: Matt Ranostay <matt.ranostay@konsulko.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
{
struct atlas_ezo_data *data = iio_priv(indio_dev);
struct i2c_client *client = data->client;
- int ret = 0;
if (chan->type != IIO_CONCENTRATION)
return -EINVAL;
switch (mask) {
case IIO_CHAN_INFO_RAW: {
+ int ret;
long tmp;
mutex_lock(&data->lock);
return IIO_VAL_INT_PLUS_MICRO;
}
- return ret;
+ return 0;
}
static const struct iio_info atlas_info = {