devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Alexandre Courbot <gnurou@gmail.com>
To: Benoit Parrot <bparrot@ti.com>
Cc: Linus Walleij <linus.walleij@linaro.org>,
	"linux-gpio@vger.kernel.org" <linux-gpio@vger.kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	Pantelis Antoniou <panto@antoniou-consulting.com>,
	Jiri Prchal <jiri.prchal@aksignal.cz>,
	Maxime Ripard <maxime.ripard@free-electrons.com>
Subject: Re: [Patch v2 2/2] gpio: Document GPIO hogging mechanism
Date: Tue, 2 Dec 2014 23:04:23 +0900	[thread overview]
Message-ID: <CAAVeFuK=AdL-kgaXzCVrF-ATPmS4xwC-sfbtQNcVLNAbXGULgQ@mail.gmail.com> (raw)
In-Reply-To: <20141201225747.GA24551@ti.com>

On Tue, Dec 2, 2014 at 7:57 AM, Benoit Parrot <bparrot@ti.com> wrote:
> Alexandre Courbot <gnurou@gmail.com> wrote on Fri [2014-Nov-28 16:31:19 +0900]:
>> On Fri, Nov 21, 2014 at 8:54 AM, Benoit Parrot <bparrot@ti.com> wrote:
>> > Add GPIO hogging documentation to gpio.txt
>> >
>> > Signed-off-by: Benoit Parrot <bparrot@ti.com>
>> > ---
>> > Changes since v1:
>> >  * Split the devicetree bindings documentation in its own patch.
>> >
>> >  Documentation/devicetree/bindings/gpio/gpio.txt | 25 +++++++++++++++++++++++++
>> >  1 file changed, 25 insertions(+)
>> >
>> > diff --git a/Documentation/devicetree/bindings/gpio/gpio.txt b/Documentation/devicetree/bindings/gpio/gpio.txt
>> > index 3fb8f53..82755e2 100644
>> > --- a/Documentation/devicetree/bindings/gpio/gpio.txt
>> > +++ b/Documentation/devicetree/bindings/gpio/gpio.txt
>> > @@ -103,6 +103,24 @@ Every GPIO controller node must contain both an empty "gpio-controller"
>> >  property, and a #gpio-cells integer property, which indicates the number of
>> >  cells in a gpio-specifier.
>> >
>> > +The GPIO chip may contain GPIO hog definitions. GPIO hogging is a mechanism
>> > +providing automatic GPIO request and configuration as part of the
>> > +gpio-controller's driver probe function.
>> > +
>> > +Each GPIO hog definition is represented as a child node of the GPIO controller.
>> > +Required properties:
>> > +- gpio-hog: a property specifying that this child node represent a gpio-hog.
>> > +- gpios: store the gpio information (id, flags, ...). Shall contain the
>> > +  number of cells specified in its parent node (GPIO controller node).
>> > +- input: a property specifying to set the GPIO direction as input.
>> > +- output-high: a property specifying to set the GPIO direction to output with
>> > +  the value high.
>> > +- output-low: a property specifying to set the GPIO direction to output with
>> > +  the value low.
>> > +
>> > +Optional properties:
>> > +- line-name: the GPIO label name. If not present the node name is used.
>> > +
>> >  Example of two SOC GPIO banks defined as gpio-controller nodes:
>> >
>> >         qe_pio_a: gpio-controller@1400 {
>> > @@ -110,6 +128,13 @@ Example of two SOC GPIO banks defined as gpio-controller nodes:
>> >                 reg = <0x1400 0x18>;
>> >                 gpio-controller;
>> >                 #gpio-cells = <2>;
>> > +
>> > +               line_b: line_b {
>>
>> Mmm what is the label used for? Can this node ever be referenced from
>> somewhere else?
>
> It's not used for anything else as far as I know other than as the line-name to be assigned to the gpio being hogged.
> I guess you agree with Linus and should make the line-name mandatory and remove the label altogether?
>
> I was trying to keep the verbosity to a minimum so as to have the possibilty to keep everything on a single line when possible.

It's just that when you see a label, you expect it to be referenced
somewhere, which is obviously not the case here. Just having

line_b {

would work just as well, wouldn't it?

      reply	other threads:[~2014-12-02 14:04 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-20 23:54 [Patch v2 0/2] gpio: add GPIO hogging mechanism Benoit Parrot
2014-11-20 23:54 ` [Patch v2 1/2] " Benoit Parrot
2014-11-28  7:30   ` Alexandre Courbot
2014-12-01 16:36     ` Maxime Ripard
2014-12-02  0:27       ` Benoit Parrot
2014-12-02 14:13       ` Alexandre Courbot
2014-12-02 14:29         ` Linus Walleij
2014-12-02 16:12           ` Maxime Ripard
2014-12-04 14:15             ` Alexandre Courbot
     [not found]               ` <CAAVeFu+Gms6ptyK6j1Zy_wWg+9URs+9zBu=pOiwiEERO=8NjNw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-12-04 14:27                 ` Pantelis Antoniou
2014-12-04 14:41                   ` Alexandre Courbot
2014-12-04 14:47                     ` Pantelis Antoniou
     [not found]                       ` <C9DBE2F0-A725-4D05-BEC6-F083F3F83B9F-wVdstyuyKrO8r51toPun2/C9HSW9iNxf@public.gmane.org>
2014-12-04 14:58                         ` Alexandre Courbot
2014-12-04 15:02                           ` Pantelis Antoniou
2014-12-04 15:10                             ` Alexandre Courbot
2014-12-04 15:22                               ` Pantelis Antoniou
     [not found]                                 ` <8717617A-56AE-495C-B873-0B2E3EA83060-wVdstyuyKrO8r51toPun2/C9HSW9iNxf@public.gmane.org>
2014-12-06 12:04                                   ` Alexandre Courbot
2014-12-04 14:27               ` Maxime Ripard
2014-12-04 14:49                 ` Alexandre Courbot
2014-12-05 10:24                   ` Maxime Ripard
2014-12-06 12:08                     ` Alexandre Courbot
2014-12-08 19:18                       ` Maxime Ripard
2014-12-04 14:52               ` Maxime Ripard
2014-12-04 15:00                 ` Alexandre Courbot
2015-01-12  9:40             ` Linus Walleij
2015-01-12 12:45               ` Mark Brown
2014-12-02  0:22     ` Benoit Parrot
     [not found]       ` <20141202002244.GB24551-l0cyMroinI0@public.gmane.org>
2014-12-02 14:10         ` Alexandre Courbot
     [not found]           ` <CAAVeFuJWPvdmO_KPXP2LrkAy4SQDZ+f7pvE6U8r7gPH+jE3Lrw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-12-02 14:28             ` Linus Walleij
2014-12-02 14:25         ` Linus Walleij
2014-11-20 23:54 ` [Patch v2 2/2] gpio: Document " Benoit Parrot
     [not found]   ` <1416527684-19017-3-git-send-email-bparrot-l0cyMroinI0@public.gmane.org>
2014-11-28  7:31     ` Alexandre Courbot
2014-12-01 22:57       ` Benoit Parrot
2014-12-02 14:04         ` Alexandre Courbot [this message]

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='CAAVeFuK=AdL-kgaXzCVrF-ATPmS4xwC-sfbtQNcVLNAbXGULgQ@mail.gmail.com' \
    --to=gnurou@gmail.com \
    --cc=bparrot@ti.com \
    --cc=devicetree@vger.kernel.org \
    --cc=jiri.prchal@aksignal.cz \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maxime.ripard@free-electrons.com \
    --cc=panto@antoniou-consulting.com \
    /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).