linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Linus Walleij <linus.walleij@linaro.org>
To: Liam Girdwood <lgirdwood@gmail.com>, Mark Brown <broonie@kernel.org>
Cc: linux-kernel@vger.kernel.org,
	Linus Walleij <linus.walleij@linaro.org>,
	devicetree@vger.kernel.org,
	Leonard Crestez <leonard.crestez@nxp.com>
Subject: [PATCH] regulator: fixed: Use more standard GPIO binding
Date: Thu,  4 Oct 2018 11:06:54 +0200	[thread overview]
Message-ID: <20181004090654.32233-1-linus.walleij@linaro.org> (raw)

The fixed regulator uses "gpio" (singularis) for the GPIO line
but the standard GPIO bindings recommend "gpios" (pluralis).

We have augmented the Linux kernel to handle both, so recommend
the best practice and deprecate the singularis variant.

Cc: devicetree@vger.kernel.org
Cc: Leonard Crestez <leonard.crestez@nxp.com>
Suggested-by: Leonard Crestez <leonard.crestez@nxp.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
 .../devicetree/bindings/regulator/fixed-regulator.txt     | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/regulator/fixed-regulator.txt b/Documentation/devicetree/bindings/regulator/fixed-regulator.txt
index 0c2a6c8a1536..a0d7f15ef5ca 100644
--- a/Documentation/devicetree/bindings/regulator/fixed-regulator.txt
+++ b/Documentation/devicetree/bindings/regulator/fixed-regulator.txt
@@ -5,7 +5,7 @@ Required properties:
 - regulator-name: Defined in regulator.txt as optional, but required here.
 
 Optional properties:
-- gpio: gpio to use for enable control
+- gpios: gpio to use for enable control
 - startup-delay-us: startup time in microseconds
 - enable-active-high: Polarity of GPIO is Active high
 If this property is missing, the default assumed is Active low.
@@ -13,6 +13,10 @@ If this property is missing, the default assumed is Active low.
   If this property is missing then default assumption is false.
 -vin-supply: Input supply name.
 
+Deprecated properties:
+- gpio: singularis variant of "gpios" is allowed in accordance with the
+  GPIO bindings specification, but not recommended.
+
 Any property defined as part of the core regulator
 binding, defined in regulator.txt, can also be used.
 However a fixed voltage regulator is expected to have the
@@ -26,7 +30,7 @@ Example:
 		regulator-name = "fixed-supply";
 		regulator-min-microvolt = <1800000>;
 		regulator-max-microvolt = <1800000>;
-		gpio = <&gpio1 16 0>;
+		gpios = <&gpio1 16 0>;
 		startup-delay-us = <70000>;
 		enable-active-high;
 		regulator-boot-on;
-- 
2.17.1


             reply	other threads:[~2018-10-04  9:07 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-04  9:06 Linus Walleij [this message]
2018-10-04 10:50 ` [PATCH] regulator: fixed: Use more standard GPIO binding Mark Brown
2018-10-04 11:32   ` Linus Walleij
2018-10-04 13:54     ` Mark Brown
2018-10-05 20:17       ` Rob Herring
2018-10-07 21:00         ` Linus Walleij

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=20181004090654.32233-1-linus.walleij@linaro.org \
    --to=linus.walleij@linaro.org \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=leonard.crestez@nxp.com \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.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;
as well as URLs for NNTP newsgroup(s).