]> git.baikalelectronics.ru Git - kernel.git/commit
staging: iio: tsl2583: check for error code from i2c_smbus_read_byte()
authorBrian Masney <masneyb@onstation.org>
Fri, 28 Oct 2016 10:00:13 +0000 (06:00 -0400)
committerJonathan Cameron <jic23@kernel.org>
Tue, 1 Nov 2016 18:50:04 +0000 (18:50 +0000)
commit00b9b9c4e64abebdb1a7cb23fccbd909e18a97eb
treee5d9f37b32e36904fde581d18b052e380fc5a86f
parente885ef607f3802641c1212c75bb951de5718b95d
staging: iio: tsl2583: check for error code from i2c_smbus_read_byte()

taos_i2c_read() and taos_als_calibrate() does not check to see if the
value returned by i2c_smbus_read_byte() was an error code. This patch
adds the appropriate error handling.

Signed-off-by: Brian Masney <masneyb@onstation.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/staging/iio/light/tsl2583.c