devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bjorn Andersson <bjorn.andersson@linaro.org>
To: Arnd Bergmann <arnd@arndb.de>
Cc: Bhushan Shah <bshah@kde.org>, Andy Gross <andy.gross@linaro.org>,
	David Brown <david.brown@linaro.org>,
	Rob Herring <robh+dt@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Russell King <linux@armlinux.org.uk>,
	linux-arm-msm <linux-arm-msm@vger.kernel.org>,
	"open list:ARM/QUALCOMM SUPPORT" <linux-soc@vger.kernel.org>,
	devicetree@vger.kernel.org
Subject: Re: [PATCH 2/3] ARM: dts: msm8974-hammerhead: Add regulator nodes for hammerhead
Date: Mon, 18 Jul 2016 10:11:55 -0700	[thread overview]
Message-ID: <20160718171155.GE13516@tuxbot> (raw)
In-Reply-To: <1957086.XgnIUz2uOJ@wuerfel>

On Mon 18 Jul 00:44 PDT 2016, Arnd Bergmann wrote:

> On Sunday, July 17, 2016 8:44:01 PM CEST Bjorn Andersson wrote:
> > On Sun, Jul 17, 2016 at 8:34 PM, Bhushan Shah <bshah@kde.org> wrote:
> > > On Sun, Jul 17, 2016 at 09:21:48PM +0200, Arnd Bergmann wrote:
> > >> On Sunday, July 17, 2016 4:22:07 PM CEST Bhushan Shah wrote:
> > >> > +
> > >> > +       smd {
> > >> > +               rpm {
> > >> > +                       rpm_requests {
> > >> > +                               pm8841-regulators {
> > >> > +                                       s1 {
> > >> > +                                               regulator-min-microvolt = <675000>;
> > >> > +                                               regulator-max-microvolt = <1050000>;
> > >> > +                                       };
> > >>
> > >> Maybe add a label at either the rpm_requests or the pm8841-regulators
> > >> node so you can add properties in the leaf nodes withoutout having to
> > >> specify the whole path?
> > >
> > > Sure, I will adjust patch.
> > 
> > Please don't. After running into several cases where this would end us
> > up in having a multitude of nodes each describing just a snippet of
> > each level we decided not to do so in the general case for the
> > Qualcomm boards.
> > 
> > There are a few where we apparently ended up doing so anyways, but for
> > all other cases of regulators we express the full tree in the dts, so
> > please follow that so we don't mix the styles too much.
> 
> Ok, then how about this instead:
> 
> /smd/rpm/rpm_requests/pm8841-regulators {

The problem I have with this is that in the dtsi we have properties and
other nodes under each one of these, hence we end up with completely
different overall structure depending on if I look in the dtsi or the
dts.

The problem I have with it in the dts is that we have properties and
nodes under "smd" and "rpm_requests". So siblings are no longer grouped
together.


I have a hard time finding my way through flattened trees, often spread out
over multiple files, that I need to puzzle together in my head. Perhaps
there are better ways to keep this comprehensible, without maintaining
the structure.

> 	s1 {
> 		regulator-min-microvolt = <675000>;
> 		regulator-max-microvolt = <1050000>;
> 	};
> 
> 	...
> };
> 
> That avoids the ridiculous intendation level but uses no labels.
> 

I do share your dislike of the indentation level.


I do have a few other concerns about style and scalability in other
places. How about we follow how I've done this in the other files for
now (i.e.  keep the structure of the patch as is) and sit down at LAS16
to discuss what to do about this?

Regards,
Bjorn

  reply	other threads:[~2016-07-18 17:11 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-17 10:52 [PATCH 0/3] Initial support for LG Nexus 5 phone (hammerhead) Bhushan Shah
2016-07-17 10:52 ` [PATCH 1/3] ARM: dts: qcom: Add initial DTS for LG Nexus 5 Phone Bhushan Shah
2016-07-18 17:19   ` Bjorn Andersson
2016-07-17 10:52 ` [PATCH 2/3] ARM: dts: msm8974-hammerhead: Add regulator nodes for hammerhead Bhushan Shah
2016-07-17 19:21   ` Arnd Bergmann
2016-07-18  3:34     ` Bhushan Shah
2016-07-18  3:44       ` Bjorn Andersson
     [not found]         ` <CAOCOHw5MNN9QAea1gJobpEHpn1S0=CTA3mEHzd+dVhv-GShYdg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2016-07-18  7:44           ` Arnd Bergmann
2016-07-18 17:11             ` Bjorn Andersson [this message]
2016-07-18 19:12               ` Arnd Bergmann
2016-07-18 17:38   ` Bjorn Andersson
2016-07-17 10:52 ` [PATCH 3/3] ARM: dts: msm8974-hammerhead: Introduce gpio-keys nodes Bhushan Shah
     [not found]   ` <20160717105208.9596-4-bshah-RoXCvvDuEio@public.gmane.org>
2016-07-18 17:39     ` Bjorn Andersson

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=20160718171155.GE13516@tuxbot \
    --to=bjorn.andersson@linaro.org \
    --cc=andy.gross@linaro.org \
    --cc=arnd@arndb.de \
    --cc=bshah@kde.org \
    --cc=david.brown@linaro.org \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-soc@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=mark.rutland@arm.com \
    --cc=robh+dt@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).