From: Jonathan Cameron <jic23@kernel.org>
To: Marcelo Schmitt <marcelo.schmitt@analog.com>
Cc: <linux-iio@vger.kernel.org>, <devicetree@vger.kernel.org>,
<linux-kernel@vger.kernel.org>, <nuno.sa@analog.com>,
<Michael.Hennerich@analog.com>, <dlechner@baylibre.com>,
<andy@kernel.org>, <robh@kernel.org>, <krzk+dt@kernel.org>,
<conor+dt@kernel.org>, <julianbraha@gmail.com>,
<marcelo.schmitt1@gmail.com>
Subject: Re: [PATCH v9 6/6] iio: ABI: Encourage differential voltage ABI usage
Date: Wed, 12 Aug 2026 05:01:08 +0100 [thread overview]
Message-ID: <20260812050051.4313cd91@jic23-huawei> (raw)
In-Reply-To: <959734dd1111f76c5928515b82dd17f3a9dff5c8.1785186980.git.marcelo.schmitt@analog.com>
On Mon, 27 Jul 2026 18:32:18 -0300
Marcelo Schmitt <marcelo.schmitt@analog.com> wrote:
> So far, parts that could only do differential voltage measurements were
> only required to have a consistent labeling of their channels by complying
> either to voltageY or to voltageY-voltageZ ABI. Over time, code maintainers
> came to the conclusion that the voltageY-voltageZ ABI is better suited for
> differential-only chips as it provides a simple indication to users that
> the channels measure the difference of two inputs.
>
> Adjust the ABI documentation to recommend using the voltageY-voltageZ ABI
> for chips that do only differential voltage measurements.
>
> Signed-off-by: Marcelo Schmitt <marcelo.schmitt@analog.com>
Hi Marcelo
Whilst looking at another series, I noticed we did something different
again in the devicetree bindings for those devices that have
restrictive muxes that means the positive and negative lines
always change together. For those we let
diff-channels = <1 1>
which tends to map to
in_voltageX-voltageX_raw
I'm not sure if we want to explicitly call that out as an option.
There is nothing in your new text saying we can't do that.
Worth also noting there are short circuit parts where you
really do connect both ends of the differential ADC to the
same input pin. I think it can be useful for testing / calibration?
Jonathan
> ---
> No changes in v9.
>
> Documentation/ABI/testing/sysfs-bus-iio | 9 +++++----
> 1 file changed, 5 insertions(+), 4 deletions(-)
>
> diff --git a/Documentation/ABI/testing/sysfs-bus-iio b/Documentation/ABI/testing/sysfs-bus-iio
> index 5cc2e82c4997..7446e07b9ab2 100644
> --- a/Documentation/ABI/testing/sysfs-bus-iio
> +++ b/Documentation/ABI/testing/sysfs-bus-iio
> @@ -162,10 +162,11 @@ Contact: linux-iio@vger.kernel.org
> Description:
> Raw (unscaled) differential voltage measurement equivalent to
> channel Y - channel Z where these channel numbers apply to the
> - physically equivalent inputs when non differential readings are
> - separately available. In differential only parts, then all that
> - is required is a consistent labeling. Units after application
> - of scale and offset are millivolts.
> + physically equivalent inputs when non-differential readings are
> + separately available. Even though differential-only parts had
> + been merely required to have consistent channel labeling, this
> + ABI is preferred over the non-differential one for those chips.
> + Units after application of scale and offset are millivolts.
>
> What: /sys/bus/iio/devices/iio:deviceX/in_altvoltageY_rms_raw
> KernelVersion: 6.18
next prev parent reply other threads:[~2026-08-12 4:01 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-27 21:30 [PATCH v9 0/6] iio: adc: Add support for LTC2378 and similar ADCs Marcelo Schmitt
2026-07-27 21:30 ` [PATCH v9 1/6] dt-bindings: iio: adc: Add ltc2378 Marcelo Schmitt
2026-07-27 21:30 ` [PATCH v9 2/6] iio: adc: ltc2378: Add support for LTC2378-20 and similar ADCs Marcelo Schmitt
2026-07-27 21:31 ` [PATCH v9 3/6] iio: adc: ltc2378: Enable high-speed data capture Marcelo Schmitt
2026-07-27 21:31 ` [PATCH v9 4/6] iio: adc: ltc2378: Enable triggered buffer " Marcelo Schmitt
2026-07-27 21:31 ` [PATCH v9 5/6] iio: adc: ltc2378: Add support for LTC2338-18 Marcelo Schmitt
2026-08-10 7:37 ` Andy Shevchenko
2026-08-11 2:45 ` Marcelo Schmitt
2026-08-11 8:56 ` Andy Shevchenko
2026-08-12 4:03 ` Jonathan Cameron
2026-07-27 21:32 ` [PATCH v9 6/6] iio: ABI: Encourage differential voltage ABI usage Marcelo Schmitt
2026-08-12 4:01 ` Jonathan Cameron [this message]
2026-08-12 18:25 ` Marcelo Schmitt
2026-08-15 1:39 ` Jonathan Cameron
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=20260812050051.4313cd91@jic23-huawei \
--to=jic23@kernel.org \
--cc=Michael.Hennerich@analog.com \
--cc=andy@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dlechner@baylibre.com \
--cc=julianbraha@gmail.com \
--cc=krzk+dt@kernel.org \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=marcelo.schmitt1@gmail.com \
--cc=marcelo.schmitt@analog.com \
--cc=nuno.sa@analog.com \
--cc=robh@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®