linux/drivers/iio/adc
Dan Carpenter 82a5803c78 staging: iio: ad799x: remove some unneeded IS_ERR() checks
My static checker is upset that we check IS_ERR(t->reg) when we know it
is not an ERR_PTR.

Checking for IS_ERR() twice is often a sign of confusion and buggy code.
In this case, if the call to "ret = regulator_enable(st->vref);" fails,
then we call "regulator_disable(st->vref);" and that's a mistake because
"st->vref" is not enabled.

I fixed these problems and Hartmut Knaack pointed out a couple unneeded
IS_ERR() checks in ad799x_remove() so I have removed those as well.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Hartmut Knaack <knaack.h@gmx.de>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2014-05-03 11:14:01 +01:00
..
ad799x.c staging: iio: ad799x: remove some unneeded IS_ERR() checks 2014-05-03 11:14:01 +01:00
ad7266.c iio:ad7266: Mark transfer buffer as __be16 2013-12-03 20:22:27 +00:00
ad7298.c iio:ad7298: Use iio_push_to_buffers_with_timestamp() 2013-09-21 19:23:52 +01:00
ad7476.c iio:ad7476: Report scale as fractional value 2013-10-01 16:19:12 +01:00
ad7791.c iio:ad7791: Report scale as fractional value 2013-10-01 16:19:12 +01:00
ad7793.c iio: adc: ad7793: Use devm_* APIs 2013-08-03 18:40:39 +01:00
ad7887.c iio:adc:ad7887 Fix channel reported endianness from cpu to big endian 2013-12-17 20:37:14 +00:00
ad7923.c iio:ad7923: Use iio_push_to_buffers_with_timestamp() 2013-09-21 19:23:53 +01:00
ad_sigma_delta.c tree-wide: use reinit_completion instead of INIT_COMPLETION 2013-11-15 09:32:21 +09:00
at91_adc.c iio: adc: at91_adc: correct default shtim value 2014-03-15 16:32:44 +00:00
exynos_adc.c iio: exynos_adc: do a reinit_completion before the conversion 2014-04-30 21:47:47 +01:00
Kconfig First round of IIO new driver, functionality and cleanups for the 3.16 cycle. 2014-04-26 08:12:25 -07:00
lp8788_adc.c iio: adc: lp8788_adc: Use devm_* APIs 2013-08-03 18:40:40 +01:00
Makefile First round of IIO new driver, functionality and cleanups for the 3.16 cycle. 2014-04-26 08:12:25 -07:00
max1363.c iio:max1363 fix typos of int_vref_mv 2014-02-18 08:44:11 +00:00
mcp320x.c iio: adc: mcp320x: Use devm_* APIs 2013-08-03 18:40:41 +01:00
mcp3422.c Add support for Microchip Technology's MCP3426/7/8 ADC 2014-03-16 18:00:34 +00:00
men_z188_adc.c iio: adc: Fix build error discovered by 0-day build bot 2014-03-08 21:57:17 -08:00
nau7802.c tree-wide: use reinit_completion instead of INIT_COMPLETION 2013-11-15 09:32:21 +09:00
ti_am335x_adc.c First set of new drivers and cleanups for IIO in the 3.15 cycle. 2014-02-11 14:12:12 -08:00
ti-adc081c.c iio: adc: ti-adc081c: Include linux/of.h header 2013-10-18 20:05:56 +01:00
twl4030-madc.c mfd: Delete non-required instances of include <linux/init.h> 2014-03-19 08:58:07 +00:00
twl6030-gpadc.c First set of new drivers and cleanups for IIO in the 3.15 cycle. 2014-02-11 14:12:12 -08:00
vf610_adc.c iio:adc:vf610 ensure correct handing of interruption of wait for completion 2014-03-02 21:45:28 +00:00
viperboard_adc.c iio: adc: viperboard: Drop platform_set_drvdata call 2014-02-03 19:27:59 +00:00
xilinx-xadc-core.c iio:adc: Add Xilinx XADC driver 2014-03-01 21:04:29 +00:00
xilinx-xadc-events.c iio:adc: Add Xilinx XADC driver 2014-03-01 21:04:29 +00:00
xilinx-xadc.h iio:adc: Add Xilinx XADC driver 2014-03-01 21:04:29 +00:00