All of lore.kernel.org
 help / color / mirror / Atom feed
From: s.hauer@pengutronix.de (Sascha Hauer)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM i.MX dts: Consistently add labels to devicenodes
Date: Thu, 15 Nov 2012 14:30:34 +0100	[thread overview]
Message-ID: <20121115133034.GD10369@pengutronix.de> (raw)
In-Reply-To: <20121115134831.GA2546@S2100-06.ap.freescale.net>

On Thu, Nov 15, 2012 at 09:48:33PM +0800, Shawn Guo wrote:
> On Thu, Nov 15, 2012 at 09:31:52AM +0100, Sascha Hauer wrote:
> > Having labels before each node allows board bindings to reference
> > to nodes by using the &nodename {} notation.
> 
> I can understand this part.
> 
> > This way boards do not
> > have to resemble the whole devicetree layout. Due to less indention
> > needed the board files also get better readability.
> 
> I do not understand it.  Don't we have to always maintain the device
> tree layout defined by <soc>.dtsi in <board>.dts, do we?

Have a look at for example arch/arm/boot/dts/omap5-evm.dts, it is
written like this:

...

&mmc1 {
        vmmc-supply = <&vmmcsd_fixed>;
        bus-width = <4>;
};

&mmc2 {
        vmmc-supply = <&vmmcsd_fixed>;
        bus-width = <8>;
        ti,non-removable;
};

&mmc3 {
        bus-width = <4>;
        ti,non-removable;
};

...

I've written some board dts from scratch yesterday and this is much
easier to write (and I think also easier to read as I don't have to
care about the tree layout when writing a dts).

Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

  reply	other threads:[~2012-11-15 13:30 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-15  8:31 [PATCH] ARM i.MX dts: Consistently add labels to devicenodes Sascha Hauer
2012-11-15 13:48 ` Shawn Guo
2012-11-15 13:30   ` Sascha Hauer [this message]
2012-11-15 14:10     ` Shawn Guo

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=20121115133034.GD10369@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=linux-arm-kernel@lists.infradead.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.