From: Conor Dooley <conor@kernel.org>
To: Mark Brown <broonie@kernel.org>
Cc: Francesco Dolcini <francesco@dolcini.it>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk@kernel.org>,
linux-spi@vger.kernel.org, devicetree@vger.kernel.org,
Max Krummenacher <max.oss.09@gmail.com>
Subject: Re: SPI loopback tests
Date: Tue, 10 Mar 2026 18:12:38 +0000 [thread overview]
Message-ID: <20260310-marlin-untoasted-ecca1e3e80e8@spud> (raw)
In-Reply-To: <09f06ce4-0405-442b-bf3d-5722a6977a4d@sirena.org.uk>
[-- Attachment #1: Type: text/plain, Size: 1510 bytes --]
On Tue, Mar 10, 2026 at 03:55:51PM +0000, Mark Brown wrote:
> On Tue, Mar 10, 2026 at 02:32:54PM +0100, Francesco Dolcini wrote:
>
> > So far to test this we had some out-of-tree DT overlay abusing the spidev
> > compatible, however we'd like to move away from this approach and have a
> > solution that is 100% in mainline.
>
> > Manually unbinding/binding the driver in userspace does not seems as an
> > option, because there is no device node.
>
> > One option that I could think of would be to add a new compatible that
> > to describe this single wire loopback connection (something like
> > `linux,spi-miso-mosi-loopback`) that would bind to the spidev driver.
>
> > I am aware that you all DT maintainers shared in a pretty clear way your
> > view on the abuse of the spidev multiple times.
>
> > What would you be your advice to handle the need of an SPI loopback
> > test? Am I missing something and there is a solution already available?
>
> I'm not aware of any idiomatic way to deal with this with DT
> unfortunately. Perhaps the DT people have some ideas here?
I dunno, the suggestion seems fairly reasonable to me. I don't think
it's really abuse of anything, because the compatible would represent a
real hardware configuration. The only think that feels "abusive" is the
fake reg property you'd need.
Not sure that there should be a "linux," vendor prefix though, there's
nothing linux-specific about doing loopback. Probably should be
vendor-less?
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2026-03-10 18:12 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-10 13:32 SPI loopback tests Francesco Dolcini
2026-03-10 15:55 ` Mark Brown
2026-03-10 18:12 ` Conor Dooley [this message]
2026-03-10 18:26 ` Mark Brown
2026-03-11 10:10 ` Conor Dooley
2026-03-11 11:16 ` Mark Brown
2026-03-11 13:58 ` Conor Dooley
2026-03-11 16:27 ` Krzysztof Kozlowski
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=20260310-marlin-untoasted-ecca1e3e80e8@spud \
--to=conor@kernel.org \
--cc=broonie@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=francesco@dolcini.it \
--cc=krzk@kernel.org \
--cc=linux-spi@vger.kernel.org \
--cc=max.oss.09@gmail.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