Re: [PATCH 1/2] dt-bindings: serial: Convert generic bindings to json-schema

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Rob,

On Wed, Mar 4, 2020 at 3:03 PM Rob Herring <robh+dt@xxxxxxxxxx> wrote:
> On Tue, Mar 3, 2020 at 7:43 AM Geert Uytterhoeven
> <geert+renesas@xxxxxxxxx> wrote:
> > Convert the generic serial interface Device Tree binding documentation
> > to json-schema.
> >
> > Signed-off-by: Geert Uytterhoeven <geert+renesas@xxxxxxxxx>

> > +  cts-gpios:
> > +    description:
> > +      Must contain a GPIO specifier, referring to the GPIO pin to be used as
> > +      the UART's CTS line.

> > +  rts-gpios:
> > +    description:
> > +      Must contain a GPIO specifier, referring to the GPIO pin to be used as
> > +      the UART's RTS line.
> > +
> > +  uart-has-rtscts:
> > +    $ref: /schemas/types.yaml#/definitions/flag
> > +    description:
> > +      The presence of this property indicates that the UART has dedicated lines
> > +      for RTS/CTS hardware flow control, and that they are available for use
> > +      (wired and enabled by pinmux configuration).  This depends on both the
> > +      UART hardware and the board wiring.
> > +      Note that this property is mutually-exclusive with "cts-gpios" and
> > +      "rts-gpios" above, unless support is provided to switch between modes
> > +      dynamically.
>
> This can be expressed as:
>
> oneOf:
>   - {} # None of the properties present
>   - required:
>       - uart-has-rtscts
>   - anyOf:
>       - required:
>           - cts-gpios
>       - required:
>           - rts-gpios
>
> Or probably more clearly:
>
> if:
>   required:
>     - uart-has-rtscts
> then:
>   properties:
>     rts-gpios: false
>     cts-gpios: false
>
> (Untested)

Thanks. Note that when adding this, the note above must be removed.

>
> > +
> > +examples:
>
> Personally, I'd just drop examples from schemas that aren't complete.

OK.


Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds



[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux PPP]     [Linux FS]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Linmodem]     [Device Mapper]     [Linux Kernel for ARM]

  Powered by Linux