summaryrefslogtreecommitdiffstats
path: root/drivers/iio/light/ltr501.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-07-13 14:19:22 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-07-13 14:19:22 -0700
commit8c5dfdbbebf5d8c2cef33e3aea1b450db69b1f65 (patch)
treeb5a23e3c949e109516fddb8a81b796e61b972136 /drivers/iio/light/ltr501.c
parenta732cd437be58500214e617fbbf8a0fdc32ce226 (diff)
parent8d05abfaeff52bdf66aba3a3a337dcdbdb4911bf (diff)
downloadlinux-8c5dfdbbebf5d8c2cef33e3aea1b450db69b1f65.tar.gz
linux-8c5dfdbbebf5d8c2cef33e3aea1b450db69b1f65.tar.bz2
linux-8c5dfdbbebf5d8c2cef33e3aea1b450db69b1f65.zip
Merge tag 'iio-fixes-for-4.2b' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-linus
Jonathan writes: Second set of IIO fixes for the 4.2 cycle. Note these depend (mostly) on material in the recent merge window, hence their separation from set (a) as the fixes-togreg branch predated the merge window. I am running rather later with these than I would have liked hence the large set. * stk3310 fixes from Hartmut's review that came in post merge - fix direction of proximity inline with recent documentation clarification. - fix missing REGMAP_I2C dependency - rework the error handling for raw readings to fix an failure to power down in the event of a raw reading failing. - fix a bug in the compensation code which was toggling an extra bit in the register. * mmc35240 - reported samplign frequencies were wrong. * ltr501 fixes - fix a case of returning the return value of a regmap_read instead of the value read. - fix missing regmap dependency * sx9500 - fix missing default values for ret in a couple of places to handle the case of no enabled channels. * tmp006 - check that writes to info_mask elements are actually to writable ones. Otherwise, writing to any of them will change the sampling frequency.
Diffstat (limited to 'drivers/iio/light/ltr501.c')
-rw-r--r--drivers/iio/light/ltr501.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/iio/light/ltr501.c b/drivers/iio/light/ltr501.c
index 1ef7d3773ab9..b5a0e66b5f28 100644
--- a/drivers/iio/light/ltr501.c
+++ b/drivers/iio/light/ltr501.c
@@ -1302,7 +1302,7 @@ static int ltr501_init(struct ltr501_data *data)
if (ret < 0)
return ret;
- data->als_contr = ret | data->chip_info->als_mode_active;
+ data->als_contr = status | data->chip_info->als_mode_active;
ret = regmap_read(data->regmap, LTR501_PS_CONTR, &status);
if (ret < 0)