From: Jonathan Cameron <jic23@kernel.org>
To: David Lechner <dlechner@baylibre.com>
Cc: Angelo Dureghello <adureghello@baylibre.com>,
Michael Hennerich <michael.hennerich@analog.com>,
Lars-Peter Clausen <lars@metafoo.de>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Alexandru Ardelean <aardelean@baylibre.com>,
Jonathan Cameron <Jonathan.Cameron@huawei.com>,
linux-fbdev@vger.kernel.org, linux-iio@vger.kernel.org,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
Guillaume Stols <gstols@baylibre.com>
Subject: Re: [PATCH v3 08/10] iio: adc: ad7606: change r/w_register signature
Date: Sat, 1 Feb 2025 12:53:17 +0000 [thread overview]
Message-ID: <20250201125317.1de8d599@jic23-huawei> (raw)
In-Reply-To: <2f604280-f4dd-494f-9f54-83e8f613b64f@baylibre.com>
On Fri, 31 Jan 2025 15:31:18 -0600
David Lechner <dlechner@baylibre.com> wrote:
> On 1/29/25 5:03 AM, Angelo Dureghello wrote:
> > From: Guillaume Stols <gstols@baylibre.com>
> >
> > The register read/write with IIO backend will require to claim the
> > direct mode, and doing so requires passing the corresponding iio_dev
> > structure.
> > So we need to modify the function signature to pass the iio_dev
> > structure.
> >
> > Signed-off-by: Guillaume Stols <gstols@baylibre.com>
> > ---
> I don't think calling iio_device_claim_direct_mode() inside there reg_read/write
> functions is the right place to do that. It should be done at a higher level (in
> case we need to combine multiple reads/writes in an atomic operation). So I
> think we should drop this patch.
>
I think this is a tricky corner if it is only needed when the backend is
involved. Not sure what the best answer is as we probably don't want the
higher levels having to comprehend that it is sometimes needed and sometimes
not. Maybe fine to add it in all cases, but that sounds like it risks an
ABI change.
Jonathan
next prev parent reply other threads:[~2025-02-01 12:53 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-29 11:03 [PATCH v3 00/10] add support for Software mode on AD7606's iio backend driver Angelo Dureghello
2025-01-29 11:03 ` [PATCH v3 01/10] dt-bindings: iio: dac: adi-axi-adc: fix ad7606 pwm-names Angelo Dureghello
2025-01-29 16:43 ` Rob Herring (Arm)
2025-02-01 12:54 ` Jonathan Cameron
2025-01-29 11:03 ` [PATCH v3 02/10] dt-bindings: iio: dac: adi-axi-adc: add ad7606 variant Angelo Dureghello
2025-01-29 16:46 ` Rob Herring (Arm)
2025-01-29 11:03 ` [PATCH v3 03/10] iio: adc: ad7606: fix wrong scale available Angelo Dureghello
2025-02-01 12:57 ` Jonathan Cameron
2025-01-29 11:03 ` [PATCH v3 04/10] iio: adc: ad7606: move the software mode configuration Angelo Dureghello
2025-01-29 11:03 ` [PATCH v3 05/10] iio: adc: ad7606: move software functions into common file Angelo Dureghello
2025-01-29 11:03 ` [PATCH v3 06/10] iio: adc: adi-axi-adc: add platform children support Angelo Dureghello
2025-01-31 21:17 ` David Lechner
2025-01-29 11:03 ` [PATCH v3 07/10] iio: adc: adi-axi-adc: add support for AD7606 register writing Angelo Dureghello
2025-01-31 21:27 ` David Lechner
2025-02-01 13:07 ` Jonathan Cameron
2025-01-29 11:03 ` [PATCH v3 08/10] iio: adc: ad7606: change r/w_register signature Angelo Dureghello
2025-01-31 21:31 ` David Lechner
2025-02-01 12:53 ` Jonathan Cameron [this message]
2025-01-29 11:03 ` [PATCH v3 09/10] iio: adc: ad7606: change channel macros parameters Angelo Dureghello
2025-01-29 11:03 ` [PATCH v3 10/10] iio: adc: ad7606: add support for writing registers when using backend Angelo Dureghello
2025-02-01 13:14 ` 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=20250201125317.1de8d599@jic23-huawei \
--to=jic23@kernel.org \
--cc=Jonathan.Cameron@huawei.com \
--cc=aardelean@baylibre.com \
--cc=adureghello@baylibre.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dlechner@baylibre.com \
--cc=gstols@baylibre.com \
--cc=krzk+dt@kernel.org \
--cc=lars@metafoo.de \
--cc=linux-fbdev@vger.kernel.org \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=michael.hennerich@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