Re: [PATCH V6 1/7] iio: adc: Convert the QCOM SPMI ADC bindings to .yaml format
On Sun, 31 May 2020 11:36:12 +0100 Jonathan Cameron wrote: > On Thu, 28 May 2020 22:24:23 +0530 > Jishnu Prakash wrote: > > > Convert the adc bindings from .txt to .yaml format. > > > > Signed-off-by: Jishnu Prakash > > Reviewed-by: Amit Kucheria > > Reviewed-by: Rob Herring > > Acked-by: Linus Walleij > > Jishnu, Patch is fine, but I'd like to have seen a cover > letter and clear statement of changes from v5. > Applied to the togreg branch of iio.git and pushed out as testing. Note we've missed the merge window now for IIO so this will be in the following cycle. Thanks, J > Thanks, > > Jonathan > > > --- > > .../devicetree/bindings/iio/adc/qcom,spmi-vadc.txt | 173 -- > > .../bindings/iio/adc/qcom,spmi-vadc.yaml | 252 > > + > > 2 files changed, 252 insertions(+), 173 deletions(-) > > delete mode 100644 > > Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt > > create mode 100644 > > Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml > > > > diff --git a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt > > b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt > > deleted file mode 100644 > > index c878768..000 > > --- a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt > > +++ /dev/null > > @@ -1,173 +0,0 @@ > > -Qualcomm's SPMI PMIC ADC > > - > > -- SPMI PMIC voltage ADC (VADC) provides interface to clients to read > > - voltage. The VADC is a 15-bit sigma-delta ADC. > > -- SPMI PMIC5 voltage ADC (ADC) provides interface to clients to read > > - voltage. The VADC is a 16-bit sigma-delta ADC. > > - > > -VADC node: > > - > > -- compatible: > > -Usage: required > > -Value type: > > -Definition: Should contain "qcom,spmi-vadc". > > -Should contain "qcom,spmi-adc5" for PMIC5 ADC driver. > > -Should contain "qcom,spmi-adc-rev2" for PMIC rev2 ADC > > driver. > > -Should contain "qcom,pms405-adc" for PMS405 PMIC > > - > > -- reg: > > -Usage: required > > -Value type: > > -Definition: VADC base address in the SPMI PMIC register map. > > - > > -- #address-cells: > > -Usage: required > > -Value type: > > -Definition: Must be one. Child node 'reg' property should define ADC > > -channel number. > > - > > -- #size-cells: > > -Usage: required > > -Value type: > > -Definition: Must be zero. > > - > > -- #io-channel-cells: > > -Usage: required > > -Value type: > > -Definition: Must be one. For details about IIO bindings see: > > -Documentation/devicetree/bindings/iio/iio-bindings.txt > > - > > -- interrupts: > > -Usage: optional > > -Value type: > > -Definition: End of conversion interrupt. > > - > > -Channel node properties: > > - > > -- reg: > > -Usage: required > > -Value type: > > -Definition: ADC channel number. > > -See include/dt-bindings/iio/qcom,spmi-vadc.h > > - > > -- label: > > -Usage: required for "qcom,spmi-adc5" and "qcom,spmi-adc-rev2" > > -Value type: > > -Definition: ADC input of the platform as seen in the schematics. > > -For thermistor inputs connected to generic AMUX or GPIO inputs > > -these can vary across platform for the same pins. Hence select > > -the platform schematics name for this channel. > > - > > -- qcom,decimation: > > -Usage: optional > > -Value type: > > -Definition: This parameter is used to decrease ADC sampling rate. > > -Quicker measurements can be made by reducing decimation ratio. > > -- For compatible property "qcom,spmi-vadc", valid values are > > - 512, 1024, 2048, 4096. If property is not found, default > > value > > - of 512 will be used. > > -- For compatible property "qcom,spmi-adc5", valid values are > > 250, 420 > > - and 840. If property is not found, default value of 840 is > > used. > > -- For compatible property "qcom,spmi-adc-rev2", valid values > > are 256, > > - 512 and 1024. If property is not present, default value is > > 1024. > > - > > -- qcom,pre-scaling: > > -Usage: optional > > -Value type: > > -Definition: Used for scaling the channel input signal before the > > signal is > > -fed to VADC. The configuration for this node is to know the > > -pre-determined ratio and use it for post scaling. Select one > > from > > -the following options. > > -<1 1>, <1 3>, <1 4>, <1 6>, <1 20>, <1 8>, <10 81>, <1 10> > > -If property is not found default value depending on chip will > > be used. > > - > > -- qcom,ratiometric: > > -Usage: optional > > -Value type: > > -Definition: Channel calibration type. > > -- For compatible property "qcom,spmi-vadc", if this property is > > - specified VADC will
Re: [PATCH V6 1/7] iio: adc: Convert the QCOM SPMI ADC bindings to .yaml format
On Thu, 28 May 2020 22:24:23 +0530 Jishnu Prakash wrote: > Convert the adc bindings from .txt to .yaml format. > > Signed-off-by: Jishnu Prakash > Reviewed-by: Amit Kucheria > Reviewed-by: Rob Herring > Acked-by: Linus Walleij Jishnu, Patch is fine, but I'd like to have seen a cover letter and clear statement of changes from v5. Thanks, Jonathan > --- > .../devicetree/bindings/iio/adc/qcom,spmi-vadc.txt | 173 -- > .../bindings/iio/adc/qcom,spmi-vadc.yaml | 252 > + > 2 files changed, 252 insertions(+), 173 deletions(-) > delete mode 100644 > Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt > create mode 100644 > Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml > > diff --git a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt > b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt > deleted file mode 100644 > index c878768..000 > --- a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt > +++ /dev/null > @@ -1,173 +0,0 @@ > -Qualcomm's SPMI PMIC ADC > - > -- SPMI PMIC voltage ADC (VADC) provides interface to clients to read > - voltage. The VADC is a 15-bit sigma-delta ADC. > -- SPMI PMIC5 voltage ADC (ADC) provides interface to clients to read > - voltage. The VADC is a 16-bit sigma-delta ADC. > - > -VADC node: > - > -- compatible: > -Usage: required > -Value type: > -Definition: Should contain "qcom,spmi-vadc". > -Should contain "qcom,spmi-adc5" for PMIC5 ADC driver. > -Should contain "qcom,spmi-adc-rev2" for PMIC rev2 ADC driver. > -Should contain "qcom,pms405-adc" for PMS405 PMIC > - > -- reg: > -Usage: required > -Value type: > -Definition: VADC base address in the SPMI PMIC register map. > - > -- #address-cells: > -Usage: required > -Value type: > -Definition: Must be one. Child node 'reg' property should define ADC > -channel number. > - > -- #size-cells: > -Usage: required > -Value type: > -Definition: Must be zero. > - > -- #io-channel-cells: > -Usage: required > -Value type: > -Definition: Must be one. For details about IIO bindings see: > -Documentation/devicetree/bindings/iio/iio-bindings.txt > - > -- interrupts: > -Usage: optional > -Value type: > -Definition: End of conversion interrupt. > - > -Channel node properties: > - > -- reg: > -Usage: required > -Value type: > -Definition: ADC channel number. > -See include/dt-bindings/iio/qcom,spmi-vadc.h > - > -- label: > -Usage: required for "qcom,spmi-adc5" and "qcom,spmi-adc-rev2" > -Value type: > -Definition: ADC input of the platform as seen in the schematics. > -For thermistor inputs connected to generic AMUX or GPIO inputs > -these can vary across platform for the same pins. Hence select > -the platform schematics name for this channel. > - > -- qcom,decimation: > -Usage: optional > -Value type: > -Definition: This parameter is used to decrease ADC sampling rate. > -Quicker measurements can be made by reducing decimation ratio. > -- For compatible property "qcom,spmi-vadc", valid values are > - 512, 1024, 2048, 4096. If property is not found, default value > - of 512 will be used. > -- For compatible property "qcom,spmi-adc5", valid values are > 250, 420 > - and 840. If property is not found, default value of 840 is > used. > -- For compatible property "qcom,spmi-adc-rev2", valid values are > 256, > - 512 and 1024. If property is not present, default value is > 1024. > - > -- qcom,pre-scaling: > -Usage: optional > -Value type: > -Definition: Used for scaling the channel input signal before the signal > is > -fed to VADC. The configuration for this node is to know the > -pre-determined ratio and use it for post scaling. Select one from > -the following options. > -<1 1>, <1 3>, <1 4>, <1 6>, <1 20>, <1 8>, <10 81>, <1 10> > -If property is not found default value depending on chip will be > used. > - > -- qcom,ratiometric: > -Usage: optional > -Value type: > -Definition: Channel calibration type. > -- For compatible property "qcom,spmi-vadc", if this property is > - specified VADC will use the VDD reference (1.8V) and GND for > - channel calibration. If property is not found, channel will be > - calibrated with 0.625V and 1.25V reference channels, also > - known as absolute calibration. > -- For compatible property "qcom,spmi-adc5" and > "qcom,spmi-adc-rev2", > - if this property is specified VADC will use the VDD reference > - (1.875V) and GND for channel calibration. If property is not > found, > -