From: Tomasz Figa <tomasz.figa@gmail.com>
To: Jon Loeliger <jdl@jdl.com>
Cc: "Chaiken, Alison" <Alison_Chaiken@mentor.com>,
Grant Likely <grant.likely@secretlab.ca>,
Wolfram Sang <w.sang@pengutronix.de>,
Mark Rutland <mark.rutland@arm.com>,
Stephen Warren <swarren@wwwdotorg.org>,
Ian Campbell <ian.campbell@citrix.com>,
Pawel Moll <pawel.moll@arm.com>,
"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
Rob Herring <rob.herring@calxeda.com>,
Olof Johansson <olof@lixom.net>,
Mark Brown <broonie@opensource.wolfsonmicro.com>,
Linus Walleij <linus.walleij@linaro.org>
Subject: Re: The future of DT binding maintainership
Date: Mon, 22 Jul 2013 23:57:56 +0200 [thread overview]
Message-ID: <1687020.5ErE9ecltl@flatron> (raw)
In-Reply-To: <E1V1Nkn-00072x-Df@jdl.com>
On Monday 22 of July 2013 16:34:49 Jon Loeliger wrote:
> > > Is there a schema out there in the wild that exemplifies what you
> > > mean?
> >
> > Not really. The format of schemas is currently in design stage. I'm
> > currently rethinking some details of what I have in my mind. Give me
> > some more time and I will post an RFC to the ML with all that written
> > down.
> ...and...
I meant a bit longer "more time". It's late here and it's almost time to
go to bed.
I need to look a bit inside dtc to see what is already there, but expect
results rather later this week.
> > > The schema-check idea reminds me of the W3C HTML validators:
> > > http://validator.w3.org/
> > >
> > > Since device-tree source looks a bit like XML (or maybe more like
> > > JSON), will be the schemas be similar in spirit to DTDs, and is it
> > > helpful to think of the validator in this spirit? Or will the
> > > checker be more like "gcc -Wall", since it will be invoked by a
> > > compiler?
> >
> > My idea is to implement compile time verification in dtc, so I guess
> > it
> > will be more like the latter. Since dts is what dtc can already parse,
> > my plan is to keep the schemas in spirit to dts, just
> > modifying/extending it to allow specifying bindings with them, rather
> > than static values.
> >
> > Best regards,
> > Tomasz
>
> It is possible to add some-damn XML DTD parsing and
> rule glomming even in DTC if that is what is wanted.
IMHO it's more natural to describe device tree bindings using dts-like
format, if not just because of tools already existing, then at least from
readability point of view.
> I think it will be more an issue of expressability.
> That is, how can the desired style of rules be most
> eloquently expressed, internalized and applied?
>
> That will be the current challenge first.
Yes, it will and it is already.
There is no problem with simple rules, such as required or optional
properties with predefined names, this is pretty obvious.
Things start to become fun when you get to bindings like regulators or
clocks, when part of the binding is defined on generic level (-supply,
clocks, clock-names properties) and remaining part is specific to device
(XXX in XXX-supply, count and order of clocks and clock-names, strings
allowed in clock-names property). This kind of inheritance is likely to be
the biggest troublemaker.
Best regards,
Tomasz
next prev parent reply other threads:[~2013-07-22 21:58 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CACxGe6vtJPbbqwpH8Th5S36Hx50f39j1P4OpLb-Um9xQie6Lng@mail.gmail.com>
2013-07-20 3:46 ` The future of DT binding maintainership Grant Likely
2013-07-20 13:49 ` Tomasz Figa
2013-07-22 19:59 ` Chaiken, Alison
2013-07-22 20:09 ` Tomasz Figa
2013-07-22 21:34 ` Jon Loeliger
2013-07-22 21:57 ` Tomasz Figa [this message]
2013-07-23 15:55 ` Stephen Warren
2013-07-24 20:28 ` Grant Likely
2013-07-24 20:26 ` Grant Likely
2013-07-23 15:52 ` Stephen Warren
2013-07-24 14:11 ` Grant Likely
2013-07-25 7:47 ` David Lang
2013-07-25 17:46 ` Stephen Warren
2013-07-21 10:49 ` David Gibson
2013-07-25 20:17 ` Rob Herring
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=1687020.5ErE9ecltl@flatron \
--to=tomasz.figa@gmail.com \
--cc=Alison_Chaiken@mentor.com \
--cc=broonie@opensource.wolfsonmicro.com \
--cc=devicetree@vger.kernel.org \
--cc=grant.likely@secretlab.ca \
--cc=ian.campbell@citrix.com \
--cc=jdl@jdl.com \
--cc=linus.walleij@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=olof@lixom.net \
--cc=pawel.moll@arm.com \
--cc=rob.herring@calxeda.com \
--cc=swarren@wwwdotorg.org \
--cc=w.sang@pengutronix.de \
/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).