diff options
author | Matt Ranostay <matt.ranostay@konsulko.com> | 2018-06-08 23:58:15 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2018-10-10 08:52:03 +0200 |
commit | 2c4d20c8c2d6556b793b870b618e76b7d0cc6b74 (patch) | |
tree | bbc516e696d7b809d991897f8bbc7cf92bc3591d /drivers/misc/vmw_vmci/vmci_queue_pair.c | |
parent | 52965d6f52e69bfcc55e60145f116840d8529d9d (diff) |
tsl2550: fix lux1_input error in low light
[ Upstream commit ce054546cc2c26891cefa2f284d90d93b52205de ]
ADC channel 0 photodiode detects both infrared + visible light,
but ADC channel 1 just detects infrared. However, the latter is a bit
more sensitive in that range so complete darkness or low light causes
a error condition in which the chan0 - chan1 is negative that
results in a -EAGAIN.
This patch changes the resulting lux1_input sysfs attribute message from
"Resource temporarily unavailable" to a user-grokable lux value of 0.
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Matt Ranostay <matt.ranostay@konsulko.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc/vmw_vmci/vmci_queue_pair.c')
0 files changed, 0 insertions, 0 deletions