linux/drivers/iio/frequency
Dan Carpenter 507397d19b iio: frequency: admv1013: propagate errors from regulator_get_voltage()
The regulator_get_voltage() function returns negative error codes.
This function saves it to an unsigned int and then does some range
checking and, since the error code falls outside the correct range,
it returns -EINVAL.

Beyond the messiness, this is bad because the regulator_get_voltage()
function can return -EPROBE_DEFER and it's important to propagate that
back properly so it can be handled.

Fixes: da35a7b526 ("iio: frequency: admv1013: add support for ADMV1013")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Link: https://lore.kernel.org/r/ce75aac3-2aba-4435-8419-02e59fdd862b@moroto.mountain
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
2023-07-22 17:33:38 +01:00
..
ad9523.c iio: frequency: ad9523: Use devm_regulator_get_enable() 2022-11-23 19:44:01 +00:00
adf4350.c iio: frequency: adf4350: Fix alignment for DMA safety 2022-06-14 11:53:17 +01:00
adf4371.c iio: frequency: adf4371: Benefit from devm_clk_get_enabled() to simplify 2022-08-15 22:30:02 +01:00
adf4377.c iio: frequency: adf4377: add support for ADF4377 2022-11-23 21:05:51 +00:00
admv1013.c iio: frequency: admv1013: propagate errors from regulator_get_voltage() 2023-07-22 17:33:38 +01:00
admv1014.c iio: frequency: admv1014: return -EINVAL directly 2022-08-19 18:07:22 +01:00
admv4420.c iio: frequency: admv4420: Fix alignment for DMA safety 2022-06-14 11:53:18 +01:00
adrf6780.c iio: frequency: adrf6780: Benefit from devm_clk_get_enabled() to simplify 2022-08-15 22:30:02 +01:00
Kconfig iio: frequency: adf4377: add support for ADF4377 2022-11-23 21:05:51 +00:00
Makefile iio: frequency: adf4377: add support for ADF4377 2022-11-23 21:05:51 +00:00