hwmon: (ad7418) Catch I2C errors
authorBrandon Maier <brandon.maier@rockwellcollins.com>
Thu, 7 Feb 2019 21:50:36 +0000 (15:50 -0600)
committerGuenter Roeck <linux@roeck-us.net>
Mon, 18 Feb 2019 22:23:29 +0000 (14:23 -0800)
commit45034e48276c310bf4d4c7d7110169756d4a6265
tree8a9f3b8d8434b6c39b61a9b585a3f9da0bd39b24
parente9b95485c12c31e07dbb1694e794f18565144099
hwmon: (ad7418) Catch I2C errors

If there is an i2c failure, the ad7416 reports its temperature as 0C.
Return an error code so users can properly detect errors.

Signed-off-by: Brandon Maier <brandon.maier@rockwellcollins.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
drivers/hwmon/ad7418.c