[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAMuHMdUWehGyUAq07P3U4U+JNLQaJ=4vbPghOMar39k8fQDf5Q@mail.gmail.com>
Date: Tue, 6 Oct 2020 09:07:07 +0200
From: Geert Uytterhoeven <geert@...ux-m68k.org>
To: Mateusz Holenko <mholenko@...micro.com>
Cc: Rob Herring <robh+dt@...nel.org>,
Mark Rutland <mark.rutland@....com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Jiri Slaby <jslaby@...e.com>,
"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS"
<devicetree@...r.kernel.org>,
"open list:SERIAL DRIVERS" <linux-serial@...r.kernel.org>,
Stafford Horne <shorne@...il.com>,
Karol Gugala <kgugala@...micro.com>,
Mauro Carvalho Chehab <mchehab+samsung@...nel.org>,
"David S. Miller" <davem@...emloft.net>,
"Paul E. McKenney" <paulmck@...ux.ibm.com>,
Filip Kokosinski <fkokosinski@...micro.com>,
Pawel Czarnecki <pczarnecki@...ernships.antmicro.com>,
Joel Stanley <joel@....id.au>,
Jonathan Cameron <Jonathan.Cameron@...wei.com>,
Maxime Ripard <mripard@...nel.org>,
Shawn Guo <shawnguo@...nel.org>,
Heiko Stuebner <heiko@...ech.de>,
Sam Ravnborg <sam@...nborg.org>,
Icenowy Zheng <icenowy@...c.io>,
Laurent Pinchart <laurent.pinchart@...asonboard.com>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
"Gabriel L. Somlo" <gsomlo@...il.com>
Subject: Re: [PATCH v11 4/5] dt-bindings: serial: document LiteUART bindings
Hi Mateusz,
On Tue, Oct 6, 2020 at 9:01 AM Mateusz Holenko <mholenko@...micro.com> wrote:
> On Fri, Sep 25, 2020 at 3:16 PM Geert Uytterhoeven <geert@...ux-m68k.org> wrote:
> > On Wed, Sep 23, 2020 at 12:10 PM Mateusz Holenko <mholenko@...micro.com> wrote:
> > > From: Filip Kokosinski <fkokosinski@...micro.com>
> > >
> > > Add documentation for LiteUART devicetree bindings.
> > >
> > > Signed-off-by: Filip Kokosinski <fkokosinski@...micro.com>
> > > Signed-off-by: Mateusz Holenko <mholenko@...micro.com>
> > > Reviewed-by: Rob Herring <robh@...nel.org>
> > > --- /dev/null
> > > +++ b/Documentation/devicetree/bindings/serial/litex,liteuart.yaml
> > > +properties:
> > > + compatible:
> > > + const: litex,liteuart
> >
> > Have you already decided how to handle future LiteUART variants that add
> > new features (e.g. CTS/RTS, DMA)?
>
> We were thinking of adding KConfig options, like
>
> [ ] LiteUART serial port support
> < > LiteUART DMA support
>
> and using ifdefs in the code.
That is the driver part, not the DT part.
If enabled, the driver still needs to know if the feature is present and
to be used, or not.
> The other option could be to extend LiteX itself so that the UART core
> provides information about its configuration via the capabilities register.
> That way the driver could configure itself automatically at runtime.
>
> This is, however, not decided yet.
A capabilities register sounds good to me.
That means everything is handled automatically by the driver
However, it does mean the DT schema checker cannot validate the
use of optional DT properties related to optional features, if any.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@...ux-m68k.org
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
Powered by blists - more mailing lists