From: Hartmut Knaack <knaack.h-Mmb7MZpHnFY@public.gmane.org>
To: Stanimir Varbanov
<svarbanov-NEYub+7Iv8PQT0dZR+AlfA@public.gmane.org>,
Ian Campbell
<ijc+devicetree-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org>,
Pawel Moll <pawel.moll-5wv7dgnIgG8@public.gmane.org>,
Rob Herring <robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
Kumar Gala <galak-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>,
Mark Rutland <mark.rutland-5wv7dgnIgG8@public.gmane.org>,
Grant Likely
<grant.likely-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>,
Jonathan Cameron <jic23-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
Cc: linux-arm-msm-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-iio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
Greg Kroah-Hartman
<gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org>,
Lars-Peter Clausen <lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org>,
Angelo Compagnucci
<angelo.compagnucci-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
Doug Anderson <dianders-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>,
Fugang Duan <B38611-KZfg59tc24xl57MIdRCFDg@public.gmane.org>,
Johannes Thumshirn
<johannes.thumshirn-csrFAY9JiS4@public.gmane.org>,
Jean Delvare <jdelvare-l3A5Bk7waGM@public.gmane.org>,
Philippe Reynes <tremyfr-Qt13gs6zZMY@public.gmane.org>,
Lee Jones <lee.jones-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>,
Josh Cartwright <joshc-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>,
Stephen Boyd <sboyd-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>,
David Collins <collinsd-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>,
"Ivan T. Ivanov"
<iivanov-NEYub+7Iv8PQT0dZR+AlfA@public.gmane.org>
Subject: Re: [PATCH 2/2] DT: iio: vadc: document dt binding
Date: Wed, 10 Sep 2014 00:22:47 +0200 [thread overview]
Message-ID: <540F7DB7.9090007@gmx.de> (raw)
In-Reply-To: <1409919274-13419-3-git-send-email-svarbanov-NEYub+7Iv8PQT0dZR+AlfA@public.gmane.org>
Stanimir Varbanov schrieb, Am 05.09.2014 14:14:
> Document DT binding for Qualcomm SPMI PMIC voltage ADC
> driver.
>
> Signed-off-by: Stanimir Varbanov <svarbanov-NEYub+7Iv8PQT0dZR+AlfA@public.gmane.org>
> Signed-off-by: Ivan T. Ivanov <iivanov-NEYub+7Iv8PQT0dZR+AlfA@public.gmane.org>
> ---
> .../devicetree/bindings/iio/adc/qcom,spmi-vadc.txt | 110 ++++++++++++++++++++
> 1 files changed, 110 insertions(+), 0 deletions(-)
> create mode 100644 Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt
>
> diff --git a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt
> new file mode 100644
> index 0000000..f9c780f
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt
> @@ -0,0 +1,110 @@
> +Qualcomm's SPMI PMIC voltage ADC
> +
> +SPMI PMIC voltage ADC (VADC) provides interface to clients to read
> +voltage. A 15 bit ADC is used for voltage measurements. There are multiple
> +peripherals to the VADC and the scope of the driver is to provide interface
> +for the USR peripheral of the VADC.
> +
> +VADC node:
> +
> +- compatible:
> + Usage: required
> + Value type: <string>
> + Definition: Should contain "qcom,spmi-vadc".
> +
> +- reg:
> + Usage: required
> + Value type: <u32>
> + Definition: Base address in the SPMI PMIC register map.
> +
> +- interrupts:
> + Usage: required
> + Value type: <prop-encoded-array>
> + Definition: End of convertion interrupt number.
Typo: conversion
> +
> +- qcom,poll-eoc:
> + Usage: optional
> + Value type: <empty>
> + Definition: Use polling instead of interrupt for end of conversion
> + completion.
> +
> +Channel node properities:
Typo: properties
> +
> +- qcom,channel:
> + Usage: required
> + Value type: <u32>
> + Definition: AMUX channel number.
> +
> +- qcom,decimation:
> + Usage: optional
> + Value type: <u32>
> + Definition: Sampling rate to use for the individual channel measurement.
> + Quicker measurements can be made by reducing decimation ratio.
> + Valid values are 512, 1024, 2048, 4096.
> + If property is not found, default value of 512 will be used.
> +
> +- qcom,pre-scaling:
> + Usage: optional
> + Value type: <u32 array>
> + 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 of chip will be used.
> +
> +- qcom,ratiometric:
> + Usage: optional
> + Value type: <empty>
> + Definition: Channel calibration type. If this property is specified
> + VADC will use the VDD reference(1.8V) and GND for channel
> + calibration. If properity is not found, channel will be
Typo: property
> + calibrated with 625mv and 1.25V reference channels.
> +
> +- qcom,hw-settle-time:
> + Usage: optional
> + Value type: <u32>
> + Definition: Time between AMUX getting configured and the ADC starting
> + conversion. Delay = 100us * (value) for value < 11, and
> + 2ms * (value - 10) otherwise.
> + Valid values are: 0, 100, 200, 300, 400, 500, 600, 700, 800,
> + 900 us and 1, 2, 4, 6, 8, 10 ms
> + If property is not found, channel will use 0us.
> +
> +- qcom,avg-samples:
> + Usage: optional
> + Value type: <u32>
> + Definition: Number of samples to be used for measurement.
> + Fast averaging provides the option to obtain a single measurement
> + from the ADC that is an average of multiple samples. The value
> + selected is 2^(value).
> + Valid values are: 1, 2, 4, 8, 16, 32, 64, 128, 256, 512
> + If property is not found, 1 sample will be used.
> +
> +- label:
> + Usage: optional
> + Value type: <string>
> + Definition: Channel name used for sysfs entry. If not provided
> + configuration device node name will be used.
> +
> +NOTE: At least one channel node is required.
> +
> +Example:
> + /* VADC node */
> + vadc@3100 {
> + compatible = "qcom,spmi-vadc";
> + reg = <0x3100>;
> + interrupts = <0x0 0x31 0x0 IRQ_TYPE_EDGE_RISING>;
> + #io-channel-cells = <1>;
> + io-channel-ranges;
> +
> + /* Channel node */
> + usb_id_nopull@39 {
> + qcom,channel = <VADC_LR_MUX10_USB_ID>;
> + qcom,decimation = <512>;
> + qcom,ratiometric;
> + qcom,hw-settle-time = <200>;
> + qcom,avg-samples = <1>;
> + qcom,pre-scaling = <1 3>
> + };
> + };
>
WARNING: multiple messages have this Message-ID (diff)
From: Hartmut Knaack <knaack.h@gmx.de>
To: Stanimir Varbanov <svarbanov@mm-sol.com>,
Ian Campbell <ijc+devicetree@hellion.org.uk>,
Pawel Moll <pawel.moll@arm.com>, Rob Herring <robh+dt@kernel.org>,
Kumar Gala <galak@codeaurora.org>,
Mark Rutland <mark.rutland@arm.com>,
Grant Likely <grant.likely@linaro.org>,
Jonathan Cameron <jic23@kernel.org>
Cc: linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-iio@vger.kernel.org, devicetree@vger.kernel.org,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Lars-Peter Clausen <lars@metafoo.de>,
Angelo Compagnucci <angelo.compagnucci@gmail.com>,
Doug Anderson <dianders@chromium.org>,
Fugang Duan <B38611@freescale.com>,
Johannes Thumshirn <johannes.thumshirn@men.de>,
Jean Delvare <jdelvare@suse.de>,
Philippe Reynes <tremyfr@yahoo.fr>,
Lee Jones <lee.jones@linaro.org>,
Josh Cartwright <joshc@codeaurora.org>,
Stephen Boyd <sboyd@codeaurora.org>,
David Collins <collinsd@codeaurora.org>,
"Ivan T. Ivanov" <iivanov@mm-sol.com>
Subject: Re: [PATCH 2/2] DT: iio: vadc: document dt binding
Date: Wed, 10 Sep 2014 00:22:47 +0200 [thread overview]
Message-ID: <540F7DB7.9090007@gmx.de> (raw)
In-Reply-To: <1409919274-13419-3-git-send-email-svarbanov@mm-sol.com>
Stanimir Varbanov schrieb, Am 05.09.2014 14:14:
> Document DT binding for Qualcomm SPMI PMIC voltage ADC
> driver.
>
> Signed-off-by: Stanimir Varbanov <svarbanov@mm-sol.com>
> Signed-off-by: Ivan T. Ivanov <iivanov@mm-sol.com>
> ---
> .../devicetree/bindings/iio/adc/qcom,spmi-vadc.txt | 110 ++++++++++++++++++++
> 1 files changed, 110 insertions(+), 0 deletions(-)
> create mode 100644 Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt
>
> diff --git a/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt
> new file mode 100644
> index 0000000..f9c780f
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.txt
> @@ -0,0 +1,110 @@
> +Qualcomm's SPMI PMIC voltage ADC
> +
> +SPMI PMIC voltage ADC (VADC) provides interface to clients to read
> +voltage. A 15 bit ADC is used for voltage measurements. There are multiple
> +peripherals to the VADC and the scope of the driver is to provide interface
> +for the USR peripheral of the VADC.
> +
> +VADC node:
> +
> +- compatible:
> + Usage: required
> + Value type: <string>
> + Definition: Should contain "qcom,spmi-vadc".
> +
> +- reg:
> + Usage: required
> + Value type: <u32>
> + Definition: Base address in the SPMI PMIC register map.
> +
> +- interrupts:
> + Usage: required
> + Value type: <prop-encoded-array>
> + Definition: End of convertion interrupt number.
Typo: conversion
> +
> +- qcom,poll-eoc:
> + Usage: optional
> + Value type: <empty>
> + Definition: Use polling instead of interrupt for end of conversion
> + completion.
> +
> +Channel node properities:
Typo: properties
> +
> +- qcom,channel:
> + Usage: required
> + Value type: <u32>
> + Definition: AMUX channel number.
> +
> +- qcom,decimation:
> + Usage: optional
> + Value type: <u32>
> + Definition: Sampling rate to use for the individual channel measurement.
> + Quicker measurements can be made by reducing decimation ratio.
> + Valid values are 512, 1024, 2048, 4096.
> + If property is not found, default value of 512 will be used.
> +
> +- qcom,pre-scaling:
> + Usage: optional
> + Value type: <u32 array>
> + 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 of chip will be used.
> +
> +- qcom,ratiometric:
> + Usage: optional
> + Value type: <empty>
> + Definition: Channel calibration type. If this property is specified
> + VADC will use the VDD reference(1.8V) and GND for channel
> + calibration. If properity is not found, channel will be
Typo: property
> + calibrated with 625mv and 1.25V reference channels.
> +
> +- qcom,hw-settle-time:
> + Usage: optional
> + Value type: <u32>
> + Definition: Time between AMUX getting configured and the ADC starting
> + conversion. Delay = 100us * (value) for value < 11, and
> + 2ms * (value - 10) otherwise.
> + Valid values are: 0, 100, 200, 300, 400, 500, 600, 700, 800,
> + 900 us and 1, 2, 4, 6, 8, 10 ms
> + If property is not found, channel will use 0us.
> +
> +- qcom,avg-samples:
> + Usage: optional
> + Value type: <u32>
> + Definition: Number of samples to be used for measurement.
> + Fast averaging provides the option to obtain a single measurement
> + from the ADC that is an average of multiple samples. The value
> + selected is 2^(value).
> + Valid values are: 1, 2, 4, 8, 16, 32, 64, 128, 256, 512
> + If property is not found, 1 sample will be used.
> +
> +- label:
> + Usage: optional
> + Value type: <string>
> + Definition: Channel name used for sysfs entry. If not provided
> + configuration device node name will be used.
> +
> +NOTE: At least one channel node is required.
> +
> +Example:
> + /* VADC node */
> + vadc@3100 {
> + compatible = "qcom,spmi-vadc";
> + reg = <0x3100>;
> + interrupts = <0x0 0x31 0x0 IRQ_TYPE_EDGE_RISING>;
> + #io-channel-cells = <1>;
> + io-channel-ranges;
> +
> + /* Channel node */
> + usb_id_nopull@39 {
> + qcom,channel = <VADC_LR_MUX10_USB_ID>;
> + qcom,decimation = <512>;
> + qcom,ratiometric;
> + qcom,hw-settle-time = <200>;
> + qcom,avg-samples = <1>;
> + qcom,pre-scaling = <1 3>
> + };
> + };
>
next prev parent reply other threads:[~2014-09-09 22:22 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-05 12:14 [PATCH 0/2] Intial support for voltage ADC Stanimir Varbanov
2014-09-05 12:14 ` Stanimir Varbanov
2014-09-05 12:14 ` [PATCH 1/2] iio: vadc: Qualcomm SPMI PMIC voltage ADC driver Stanimir Varbanov
2014-09-05 12:26 ` Arnd Bergmann
2014-09-05 12:26 ` Arnd Bergmann
2014-09-08 8:13 ` Stanimir Varbanov
2014-09-08 8:13 ` Stanimir Varbanov
2014-09-08 10:19 ` Arnd Bergmann
2014-09-08 10:19 ` Arnd Bergmann
2014-09-08 15:30 ` Stanimir Varbanov
2014-09-08 15:30 ` Stanimir Varbanov
2014-09-09 10:32 ` Arnd Bergmann
2014-09-09 10:32 ` Arnd Bergmann
2014-09-09 12:49 ` Stanimir Varbanov
2014-09-09 12:49 ` Stanimir Varbanov
2014-09-10 9:49 ` Ivan T. Ivanov
2014-09-10 9:49 ` Ivan T. Ivanov
2014-09-05 12:46 ` Peter Meerwald
2014-09-07 22:42 ` Stanimir Varbanov
[not found] ` <1409919274-13419-1-git-send-email-svarbanov-NEYub+7Iv8PQT0dZR+AlfA@public.gmane.org>
2014-09-05 12:14 ` [PATCH 2/2] DT: iio: vadc: document dt binding Stanimir Varbanov
2014-09-05 12:14 ` Stanimir Varbanov
[not found] ` <1409919274-13419-3-git-send-email-svarbanov-NEYub+7Iv8PQT0dZR+AlfA@public.gmane.org>
2014-09-09 22:22 ` Hartmut Knaack [this message]
2014-09-09 22:22 ` Hartmut Knaack
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=540F7DB7.9090007@gmx.de \
--to=knaack.h-mmb7mzphnfy@public.gmane.org \
--cc=B38611-KZfg59tc24xl57MIdRCFDg@public.gmane.org \
--cc=angelo.compagnucci-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=collinsd-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org \
--cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=dianders-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org \
--cc=galak-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org \
--cc=grant.likely-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
--cc=gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org \
--cc=iivanov-NEYub+7Iv8PQT0dZR+AlfA@public.gmane.org \
--cc=ijc+devicetree-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org \
--cc=jdelvare-l3A5Bk7waGM@public.gmane.org \
--cc=jic23-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
--cc=johannes.thumshirn-csrFAY9JiS4@public.gmane.org \
--cc=joshc-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org \
--cc=lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org \
--cc=lee.jones-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
--cc=linux-arm-msm-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-iio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=mark.rutland-5wv7dgnIgG8@public.gmane.org \
--cc=pawel.moll-5wv7dgnIgG8@public.gmane.org \
--cc=robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
--cc=sboyd-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org \
--cc=svarbanov-NEYub+7Iv8PQT0dZR+AlfA@public.gmane.org \
--cc=tremyfr-Qt13gs6zZMY@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.