From: Maxime Ripard <maxime@cerno.tech>
To: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: Rob Herring <robh+dt@kernel.org>,
Frank Rowand <frowand.list@gmail.com>,
devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org,
Andrzej Hajda <andrzej.hajda@intel.com>,
Neil Armstrong <narmstrong@baylibre.com>,
Robert Foss <robert.foss@linaro.org>,
Jonas Karlman <jonas@kwiboo.se>,
Jernej Skrabec <jernej.skrabec@gmail.com>,
Daniel Vetter <daniel.vetter@intel.com>,
David Airlie <airlied@linux.ie>,
Jagan Teki <jagan@amarulasolutions.com>,
Marek Vasut <marex@denx.de>, Sakari Ailus <sakari.ailus@iki.fi>
Subject: Re: [PATCH] dt-bindings: display: bridge: Drop requirement on input port for DSI devices
Date: Thu, 24 Mar 2022 15:23:24 +0100 [thread overview]
Message-ID: <20220324142324.monalktzzpypu74x@houat> (raw)
In-Reply-To: <Yjx1jjB2hWqOPGsi@pendragon.ideasonboard.com>
[-- Attachment #1: Type: text/plain, Size: 5243 bytes --]
On Thu, Mar 24, 2022 at 03:43:42PM +0200, Laurent Pinchart wrote:
> On Thu, Mar 24, 2022 at 09:18:19AM +0100, Maxime Ripard wrote:
> > On Wed, Mar 23, 2022 at 10:38:19PM +0200, Laurent Pinchart wrote:
> > > Hi Maxime,
> > >
> > > (CC'ing Sakari)
> > >
> > > Thank you for the patch.
> > >
> > > On Wed, Mar 23, 2022 at 04:48:23PM +0100, Maxime Ripard wrote:
> > > > MIPI-DSI devices, if they are controlled through the bus itself, have to
> > > > be described as a child node of the controller they are attached to.
> > > >
> > > > Thus, there's no requirement on the controller having an OF-Graph output
> > > > port to model the data stream: it's assumed that it would go from the
> > > > parent to the child.
> > > >
> > > > However, some bridges controlled through the DSI bus still require an
> > > > input OF-Graph port, thus requiring a controller with an OF-Graph output
> > > > port. This prevents those bridges from being used with the controllers
> > > > that do not have one without any particular reason to.
> > > >
> > > > Let's drop that requirement.
> > >
> > > I'm sure this won't come as a surprise, I'm very much opposed to this
> > > change, for two reasons.
> > >
> > > First, ports are part of the hardware, even if they're not connected. It
> > > thus simplifies handling in drivers if they're always present.
> > >
> > > Then, and that's the most important reason, I think it's a mistake not
> > > to model the DSI data connection using OF graph unconditionally, even
> > > when the DSI sink device is also controlled through the DSI bus (using
> > > DCS) and is in that case a child of the DSI source device in the DT
> > > hierarchy.
> >
> > That's the way we do for any other device though. You never addressed
> > that comment, but it's very much the same that occurs for i2c or spi
> > controllers and their device. They all get their data from the parent
> > bus. I don't see you advocate for using OF-Graph for those devices.
>
> Those are different, there's no data stream independent of the control
> communications.
Fine, then you have Ethernet PHYs, or any MMIO device that does DMA.
> > > The device tree describes a control hierarchy between devices. OF graph
> > > overlays on top of that a data transfer graph. The two are different
> > > concepts, and the fact that DSI can sometimes be used as a control bus
> > > doesn't change the concept. Using OF graph unconditionally to describe
> > > the data connections for DSI leads to less variation in the device tree
> > > structure, and thus less complexity in the implementation. We're
> > > suffering from the fact we haven't made it a requirement in the first
> > > place, which can't be fixed due to ABI breakage constraints, but let's
> > > not acknowledge it as a good idea.
> >
> > Honestly, it doesn't matter one bit.
> >
> > We have a huge discrepancy here today, and only a couple of bridges have
> > that arbitrary restriction. The situation you don't want to acknowledge
> > is the de-facto standard, by the generic binding and by what all the
> > bridges and panels are implementing. Even panel-simple-dsi is doing it.
> > So it's very much there already.
>
> It's here, and I think we should move away from it for new DSI sinks.
> I'd like OF graph to be used consistently for new drivers. We can't
> change existing DT bindings and drivers to drop support for the
> non-OF-graph description due to ABI stability, but we can avoid
> repeating the mistake going forward.
>
> > What I'm trying to address here is that some controllers that do
> > everything right can't be used because that restriction is completely
> > arbitrary and in opposition to the consensus. And they can't be used
> > *today*.
> >
> > If we want to change that consensus, fine, but we should still have one.
> > Having some bridges enforcing custom rules for no reason is very much
> > unacceptable.
> >
> > And changing that consensus won't happen overtime, we'll have to take
> > care of the backward compatibility, etc. So it won't fix the issue that
> > we can't use any bridge with any controller any time soon.
>
> I don't think that's the issue at hand here. You can still use a
> non-OF-graph DT event if the nodes for the two bridges affected by this
> patch define a port@0. It can just be left unconnected.
>
> I do agree it will cause some DT bindings for DCS-based DSI sinks to
> have ports will others won't. If your concern is that all DT bindings
> should be coherent, would you be OK with a patch that makes the sink
> port mandatory in all DT bindings for DSI bridges and panels (and fixes
> the mainline DT sources accordingly to make sure they validate) ? The
> port would not be connected of course (at least when used with DSI
> source drivers that don't use OF graph today). That would make DT
> bindings coherent, and would be a first step towards using OF graph
> everywhere.
I'm trying to fix a (recent) mistake/cargo-cult in new bindings. That
discussion is not going to be fairly controversial and I don't see how
that can be solved quickly. So, as a second step, why not. But this one
needs to come first.
Maxime
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2022-03-24 14:23 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-23 15:48 [PATCH] dt-bindings: display: bridge: Drop requirement on input port for DSI devices Maxime Ripard
2022-03-23 20:38 ` Laurent Pinchart
2022-03-24 8:18 ` Maxime Ripard
2022-03-24 13:43 ` Laurent Pinchart
2022-03-24 14:23 ` Maxime Ripard [this message]
2022-03-24 14:50 ` Laurent Pinchart
2022-03-30 9:45 ` Maxime Ripard
2022-03-25 10:42 ` Tomi Valkeinen
2022-03-30 10:00 ` Maxime Ripard
2022-03-31 23:52 ` Rob Herring
2022-04-01 1:22 ` Marek Vasut
2022-04-01 9:58 ` Laurent Pinchart
2022-04-01 17:34 ` Rob Herring
2022-04-01 18:06 ` Marek Vasut
2022-04-01 18:21 ` Rob Herring
2022-04-01 18:25 ` Marek Vasut
2022-04-01 18:33 ` Rob Herring
2022-04-01 18:48 ` Laurent Pinchart
2022-04-01 19:43 ` Rob Herring
2022-04-05 7:52 ` (subset) " Maxime Ripard
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=20220324142324.monalktzzpypu74x@houat \
--to=maxime@cerno.tech \
--cc=airlied@linux.ie \
--cc=andrzej.hajda@intel.com \
--cc=daniel.vetter@intel.com \
--cc=devicetree@vger.kernel.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=frowand.list@gmail.com \
--cc=jagan@amarulasolutions.com \
--cc=jernej.skrabec@gmail.com \
--cc=jonas@kwiboo.se \
--cc=laurent.pinchart@ideasonboard.com \
--cc=marex@denx.de \
--cc=narmstrong@baylibre.com \
--cc=robert.foss@linaro.org \
--cc=robh+dt@kernel.org \
--cc=sakari.ailus@iki.fi \
/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;
as well as URLs for NNTP newsgroup(s).