[PATCH v3 3/4] hwmon: adc128d818: Support operation modes 1-3

2017-01-06 Thread Alexander Koch
Add support for operation modes 1-3 of the ADC128D818 (see datasheet sec. 8.4.1). These differ in the number and type of the available input signals, requiring the driver to selectively hide sysfs nodes according to the operation mode configured via devicetree. Signed-off-by: Alexander Koch

[PATCH v3 1/4] devicetree: hwmon: Add bindings for ADC128D818

2017-01-06 Thread Alexander Koch
Add bindings documentation for the ADC128D818 driver, featuring default I2C properties along with the optional 'mode' property for chip operation mode selection (see datasheet, sec. 8.4.1). Signed-off-by: Alexander Koch Acked-by: Michael Hornung --- .../devicetree/bindings/hwmon/adc1

[PATCH v3 2/4] hwmon: adc128d818: Implement mode selection via dt

2017-01-06 Thread Alexander Koch
e 'ti,mode' property here, the driver still supports nothing else than the default mode 0. [1] Documentation/devicetree/bindings/hwmon/adc128d818.txt Signed-off-by: Alexander Koch Acked-by: Michael Hornung --- drivers/hwmon/adc128d818.c | 24 1 file changed, 24 inserti

[PATCH v3 4/4] hwmon: adc128d818: Preserve operation mode

2017-01-06 Thread Alexander Koch
Preserve chip operation mode if no mode is specified via devicetree. This enables operation when chip configuration is done by BIOS/ROMMON. Signed-off-by: Alexander Koch Acked-by: Michael Hornung --- drivers/hwmon/adc128d818.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff

[PATCH v3 0/4] hwmon: adc128d818: Support missing operation modes

2017-01-06 Thread Alexander Koch
reserve logical atomicity of code changes - Improve sysfs device node handling (use is_visible() instead of duplicate attribute list) - Add trivial code refactoring stage for checkpatch.pl to succeed Alexander Koch (4): devicetree: hwmon: Add bindings for ADC128D818 hwmon: adc128d818: Implemen

Re: [RFC PATCH v2 3/4] hwmon: adc128d818: Trivial code style fixup

2016-12-29 Thread Alexander Koch
On 12/29/2016 08:46 PM, Guenter Roeck wrote: > On Thu, Dec 29, 2016 at 07:22:12PM +0100, Alexander Koch wrote: >> On 12/26/2016 11:47 AM, Guenter Roeck wrote: >>> On 12/23/2016 02:12 PM, Alexander Koch wrote: >>>> Replace sysfs symbolic file permissions, e.g. '

Re: [RFC PATCH v2 3/4] hwmon: adc128d818: Trivial code style fixup

2016-12-29 Thread Alexander Koch
On 12/26/2016 11:47 AM, Guenter Roeck wrote: > On 12/23/2016 02:12 PM, Alexander Koch wrote: >> Replace sysfs symbolic file permissions, e.g. 'S_IRUGO', by octal >> permissions. This fixes checkpatch.pl warnings. >> >> Signed-off-by: Alexander Koch > > P

[RFC PATCH v2 2/4] hwmon: adc128d818: Implement mode selection via dt

2016-12-23 Thread Alexander Koch
' property here, the driver still supports nothing else than the default mode 0. [1] Documentation/devicetree/bindings/hwmon/adc128d818.txt Signed-off-by: Alexander Koch --- drivers/hwmon/adc128d818.c | 24 1 file changed, 24 insertions(+) diff --git a/drivers/

[RFC PATCH v2 0/4] hwmon: adc128d818: Support missing operation modes

2016-12-23 Thread Alexander Koch
licate attribute list) - Add trivial code refactoring stage for checkpatch.pl to succeed Alexander Koch (4): devicetree: hwmon: Add bindings for ADC128D818 hwmon: adc128d818: Implement mode selection via dt hwmon: adc128d818: Trivial code style fixup hwmon: adc128d818: Support operation

[RFC PATCH v2 1/4] devicetree: hwmon: Add bindings for ADC128D818

2016-12-23 Thread Alexander Koch
Add bindings documentation for the ADC128D818 driver, featuring default I2C properties along with the optional 'mode' property for chip operation mode selection (see datasheet, sec. 8.4.1). Signed-off-by: Alexander Koch --- .../devicetree/bindings/hwmon/adc128d818.txt

[RFC PATCH v2 3/4] hwmon: adc128d818: Trivial code style fixup

2016-12-23 Thread Alexander Koch
Replace sysfs symbolic file permissions, e.g. 'S_IRUGO', by octal permissions. This fixes checkpatch.pl warnings. Signed-off-by: Alexander Koch --- drivers/hwmon/adc128d818.c | 99 ++ 1 file changed, 39 insertions(+), 60 deletions(-) di

[RFC PATCH v2 4/4] hwmon: adc128d818: Support operation modes 1-3

2016-12-23 Thread Alexander Koch
Add support for operation modes 1-3 of the ADC128D818 (see datasheet sec. 8.4.1). These differ in the number and type of the available input signals, requiring the driver to selectively hide sysfs nodes according to the operation mode configured via devicetree. Signed-off-by: Alexander Koch

Re: [PATCH 1/2] hwmon: adc128d818: Implement chip mode selection

2016-12-22 Thread Alexander Koch
On Tue, Mar 29, 2016 at 21:53, Guenter Roeck wrote: > On Tue, Mar 29, 2016 at 09:03:38PM +0200, Alexander Koch wrote: >> The ADC128D818 offers four operation modes (see datasheet sec. 8.4.1) >> which vary in the number of available input signals and their types >> (diff

[PATCH 2/2] hwmon: adc128d818: Implement operation mode 1

2016-03-29 Thread Alexander Koch
Implement chip operation mode 1 (see datasheet sec. 8.4.1) which offers an additional analog input signal on channel 7 but no temperature reading. Signed-off-by: Alexander Koch Michael Hornung --- drivers/hwmon/adc128d818.c | 48 +- 1 file changed

[PATCH 1/2] hwmon: adc128d818: Implement chip mode selection

2016-03-29 Thread Alexander Koch
= <0x1d>; mode = /bits/ 8 <0>; }; Signed-off-by: Alexander Koch Acked-by: Michael Hornung --- drivers/hwmon/adc128d818.c | 67 +- 1 file changed, 49 insertions(+), 18 deletions(-) diff --git a/drivers/hwmon/adc12

[PATCH 0/2] hwmon: adc128d818: Support operation mode 1

2016-03-29 Thread Alexander Koch
mode = /bits/ 8 <1>; }; The changes are transparent as 'mode' defaults to mode 0 which yields the previous behaviour. Code has been tested on real hardware using an evaluation board. Alexander Koch (2): hwmon: adc128d818: Implement chip mode selection hwm

Re: [PATCH v2 3/3] iio: light: opt3001: enable operation w/o IRQ

2016-01-23 Thread Alexander Koch
Am 18.01.2016 um 18:07 schrieb Martin Kepplinger: > Am 2016-01-16 um 17:14 schrieb Alexander Koch: >> Enable operation of the TI OPT3001 light sensor without having an >> interrupt line available to connect the INT pin to. >> >> In this operation mode, we issue a convers