All of lore.kernel.org
 help / color / mirror / Atom feed
From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Peter Rosin <peda@axentia.se>
Cc: Andrzej Hajda <a.hajda@samsung.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	David Airlie <airlied@linux.ie>, Rob Herring <robh+dt@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Archit Taneja <architt@codeaurora.org>,
	"dri-devel@lists.freedesktop.org"
	<dri-devel@lists.freedesktop.org>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>
Subject: Re: [PATCH 2/3] dt-bindings: display: bridge: lvds-transmitter: add pwdn-gpios
Date: Wed, 19 Dec 2018 13:38:57 +0200	[thread overview]
Message-ID: <2541072.bfOLpEHFeN@avalon> (raw)
In-Reply-To: <7c2f1268-43a3-1dc2-bb2d-6da9d74a5a43@axentia.se>

Hello,

On Wednesday, 19 December 2018 11:57:32 EET Peter Rosin wrote:
> On 2018-12-19 10:12, Andrzej Hajda wrote:
> > On 19.12.2018 00:19, Peter Rosin wrote:
> >> Add optional property to specify a power-down GPIO.
> >> The pwdn-gpios name is already in use by the thine,thc63lvdm83d
> >> binding, so go with that.
> >>
> >> Signed-off-by: Peter Rosin <peda@axentia.se>
> >> ---
> >> 
> >>  Documentation/devicetree/bindings/display/bridge/lvds-transmitter.txt |
> >>  3 +++ 
> >>  1 file changed, 3 insertions(+)
> >>
> >> diff --git
> >> a/Documentation/devicetree/bindings/display/bridge/lvds-transmitter.txt
> >> b/Documentation/devicetree/bindings/display/bridge/lvds-transmitter.txt
> >> index f9e7dd666f58..47941d39f92f 100644
> >> ---
> >> a/Documentation/devicetree/bindings/display/bridge/lvds-transmitter.txt
> >> +++
> >> b/Documentation/devicetree/bindings/display/bridge/lvds-transmitter.txt
> >> @@ -31,6 +31,9 @@ Required properties:
> >>    device-specific version corresponding to the device first
> >>    followed by the generic version.
> >> 
> >> +Optional properties:
> >> +- pwdn-gpios: Power-down control GPIO
> >> +
> > 
> > Since naming is not enforced by any datasheet I would propose something
> > more popular with less twisted logic. Maybe:
> > 
> > - enable-gpios: ... (active high).
> 
> That was my original thought too, but the driver implementing the
> lvds-encoder bindings also handles the mentioned thine,thc63lvdm83d
> lvds encoder, and that binding has the "pwdn" naming. So, for driver
> implementation simplicity I went with what was already there, thus
> allowing adding support for both bindings with one implementation
> (in patch 3/3).
> 
> Adding code just to handle multiple names for the same thing does
> not sounds too appealing.

I'm afraid I think we shouldn't add pwdn-gpios support to the lvds encoder DT 
bindings. The reason is that control GPIOs (and regulators) come with device-
specific semantics. If we add pwdn-gpios now, we'll then add reset-gpios, and 
power supplies, and all of a sudden we'll end up having to encode sequencing 
of GPIOs and power supplies in DT. That path has been tried in the past, with 
no good results.

I would instead create device-specific bindings, like done for 
thine,thc63lvdm83d. It's fine to then add support for the pwdn-gpios property 
in the lvds-encoder driver, as long as the meaning of the property comes from 
specific DT bindings, not from the generic ones.

-- 
Regards,

Laurent Pinchart

  reply	other threads:[~2018-12-19 11:38 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-18 23:19 [PATCH 0/3] drm/bridge: various small lvds-encoder things Peter Rosin
2018-12-18 23:19 ` [PATCH 1/3] dt-bindings: display: bridge: lvds-transmitter: add ti,ds90c187 Peter Rosin
2018-12-18 23:19 ` [PATCH 2/3] dt-bindings: display: bridge: lvds-transmitter: add pwdn-gpios Peter Rosin
2018-12-19  9:12   ` Andrzej Hajda
2018-12-19  9:57     ` Peter Rosin
2018-12-19 11:38       ` Laurent Pinchart [this message]
2018-12-19 12:54         ` Peter Rosin
2018-12-18 23:19 ` [PATCH 3/3] drm/bridge: add pwdn-gpios support to the lvds-encoder Peter Rosin

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=2541072.bfOLpEHFeN@avalon \
    --to=laurent.pinchart@ideasonboard.com \
    --cc=a.hajda@samsung.com \
    --cc=airlied@linux.ie \
    --cc=architt@codeaurora.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=peda@axentia.se \
    --cc=robh+dt@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.