staging: iio: light: isl29018: add support for isl29023 and isl29035
authorLaurentiu Palcu <laurentiu.palcu@intel.com>
Fri, 29 Aug 2014 14:26:00 +0000 (15:26 +0100)
committerJonathan Cameron <jic23@kernel.org>
Sat, 30 Aug 2014 10:12:36 +0000 (11:12 +0100)
commit609acefa46090fbe814aa5dbfec79338b49cf784
tree0af75a6ea1aebfee76cd2ce2eb7040a30c83ff1b
parent5b4b5b9c6851418268cd0d5949942ba262106938
staging: iio: light: isl29018: add support for isl29023 and isl29035

Intersil chips ISL29018, ISL29023 and ISL29035 are very similar. They're
all ambience light sensors. The ISL29018, however, is also a proximity
sensor. The registers are similar too:

-------------+----------+----------
AVAILABLE IN | ADDR REG | NAME
   290xx     |          |
-------------+----------+----------
     18/23/35|       00h| COMMANDI
     18/23/35|       01h| COMMANDII (B4-7 are used only in 29018 for proximity)
     18/23/35|       02h| DATALSB
     18/23/35|       03h| DATAMSB
     18/23/35|       04h| INT_LT_LSB
     18/23/35|       05h| INT_LT_MSB
     18/23/35|       06h| INT_HT_LSB
     18/23/35|       07h| INT_HT_MSB
        18/23|       08h| TEST
           35|       0Fh| ID
-------------+----------+-----------

So, this patch will add support for ISL29023 and ISL29035 to the
existing isl29018 driver. Since these 2 chips don't have proximity
detection, the proximity sysfs attribute is not needed.

Also, for ISL29035, since it has an ID register, make use of it in order
to properly detect the chip and clear the brownout bit.

Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/staging/iio/light/isl29018.c
This page took 0.025056 seconds and 5 git commands to generate.