iio: adf4350: fix compiler warning [-Wuninitialized]
drivers/iio/frequency/adf4350.c:316:32: warning: ‘val’ may be used uninitialized in this function [-Wuninitialized] Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Reported-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
42b38207c3
commit
a21e6bfeb4
@ -310,6 +310,8 @@ static ssize_t adf4350_read(struct iio_dev *indio_dev,
|
|||||||
case ADF4350_PWRDOWN:
|
case ADF4350_PWRDOWN:
|
||||||
val = !!(st->regs[ADF4350_REG2] & ADF4350_REG2_POWER_DOWN_EN);
|
val = !!(st->regs[ADF4350_REG2] & ADF4350_REG2_POWER_DOWN_EN);
|
||||||
break;
|
break;
|
||||||
|
default:
|
||||||
|
ret = -ENODEV;
|
||||||
}
|
}
|
||||||
mutex_unlock(&indio_dev->mlock);
|
mutex_unlock(&indio_dev->mlock);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user