From: Andy Shevchenko <andriy.shevchenko@intel.com>
To: Jonathan Cameron <jic23@kernel.org>
Cc: "Chen-Yu Tsai" <wens@kernel.org>,
"David Lechner" <dlechner@baylibre.com>,
"Nuno Sá" <nuno.sa@analog.com>,
"Andy Shevchenko" <andy@kernel.org>,
linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] iio: core: Use datasheet name as fallback for label
Date: Tue, 28 Oct 2025 10:04:31 +0200 [thread overview]
Message-ID: <aQB5Dw2Eg0tVdNow@smile.fi.intel.com> (raw)
In-Reply-To: <20251027144327.09f59982@jic23-huawei>
On Mon, Oct 27, 2025 at 02:43:27PM +0000, Jonathan Cameron wrote:
> On Mon, 27 Oct 2025 20:42:09 +0800
> Chen-Yu Tsai <wens@kernel.org> wrote:
>
> > Some IIO drivers do not provide labels or extended names for their
> > channels. However they may provide datasheet names. axp20x-adc is
> > one such example.
> >
> > Use the datasheet name as a fallback for the channel label. This mainly
> > benefits iio-hwmon by letting the produced hwmon sensors have more
> > meaningful names rather than in_voltageX.
>
> I definitely don't want to have different behaviour for in kernel requests
> and for people reading the _label attributes.
> https://elixir.bootlin.com/linux/v6.18-rc2/source/drivers/iio/industrialio-core.c#L1232
> would need modifying to allow for the sysfs attributes to be created.
>
> In general I'm not sure I want to do this. Datasheet names can be exceptionally
> obscure which is why we've kept them hidden from userspace. At least dts writers
> tend to have those names on their circuit diagrams and tend to have datasheet access.
>
> Let's see if anyone else has feedback on this suggestion over next week or so.
This is an ABI change without
1) proper documentation;
2) backward compatibility (i.e. there is no knob to opt-out the change, or make
it opt-in).
In this form is definitely NAK.
If you wish something like this, better to have a separate attribute. But the
problem maybe also that the same component (or 100% compatible one) made by
different vendors and have different datasheet names. This means that the new
attribute may still be ambiguous. Hence I see a little sense to have it, rather
better to have these links / names to be put in DT schema. At least there we
have different vendors and compatibility mappings.
--
With Best Regards,
Andy Shevchenko
next prev parent reply other threads:[~2025-10-28 8:04 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-27 12:42 [PATCH] iio: core: Use datasheet name as fallback for label Chen-Yu Tsai
2025-10-27 14:43 ` Jonathan Cameron
2025-10-28 8:04 ` Andy Shevchenko [this message]
2025-10-28 9:22 ` Nuno Sá
2025-10-28 14:36 ` Chen-Yu Tsai
2025-10-28 14:51 ` Andy Shevchenko
2025-10-28 15:17 ` Nuno Sá
2025-11-02 12:07 ` 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=aQB5Dw2Eg0tVdNow@smile.fi.intel.com \
--to=andriy.shevchenko@intel.com \
--cc=andy@kernel.org \
--cc=dlechner@baylibre.com \
--cc=jic23@kernel.org \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=nuno.sa@analog.com \
--cc=wens@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 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.