devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd-r2nGTMty4D4@public.gmane.org>
To: Stefan Wahren <info-saaNCTdWVBT7BZbvpMY5sg@public.gmane.org>
Cc: kernelnewbies-7JyXY6prKcjpASu1u0TL5ti2O/JbrIOy@public.gmane.org,
	"devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
	<devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
	"Jörg Krause"
	<joerg.krause-L1vi/lXTdtsfGbAt6QbQcg@public.gmane.org>,
	"Shawn Guo" <shawnguo-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	"Sascha Hauer" <kernel-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
Subject: Re: strange dtc errors after adding sram node
Date: Sat, 23 Apr 2016 10:24:22 +0200	[thread overview]
Message-ID: <5929251.U2lOfbMTgH@wuerfel> (raw)
In-Reply-To: <571B283F.8010707-saaNCTdWVBT7BZbvpMY5sg@public.gmane.org>

On Saturday 23 April 2016 09:46:07 Stefan Wahren wrote:
> -       ahb@80080000 {
> +       ahb@00000000 {
>                 compatible = "simple-bus";
>                 #address-cells = <1>;
>                 #size-cells = <1>;
> -               reg = <0x80080000 0x80000>;
> +               reg = <0x00000000 0x20000>, <0x80080000 0x80000>;
>                 ranges;
> 
> +               ocram: sram@00000000 {
> +                       compatible = "mmio-sram";
> +                       reg = <0x00000000 0x20000>;
> +               };
> +
>                 usb0: usb@80080000 {
>                         compatible = "fsl,imx28-usb", "fsl,imx27-usb";
>                         reg = <0x80080000 0x10000>;

Something odd about this is that you have duplicated addresses:
The sram node has the same "reg" property as the "ahb" node, 
and also the  existing address (0x80080000) overlaps with that of
the usb node.

The registers of a device should generally be non-overlapping
with registers of other devices.

Further, the binding of "simple-bus" doesn't specify any particular
register layout for its internal register set.

My best guess is that the author of the original dts file confused
the 'reg' property of the ahb node with a 'ranges' property that should
list which address range gets translated into what child addresses.

I don't see how that could lead to the dtc error you get, but it's
probably worth fixing anyway.

	Arnd
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

      parent reply	other threads:[~2016-04-23  8:24 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-23  7:46 strange dtc errors after adding sram node Stefan Wahren
     [not found] ` <571B283F.8010707-saaNCTdWVBT7BZbvpMY5sg@public.gmane.org>
2016-04-23  8:18   ` Jörg Krause
     [not found]     ` <1461399514.2205.20.camel-L1vi/lXTdtsfGbAt6QbQcg@public.gmane.org>
2016-04-23 10:33       ` Jörg Krause
     [not found]         ` <1461407589.1986.3.camel-L1vi/lXTdtsfGbAt6QbQcg@public.gmane.org>
2016-04-25  6:04           ` Stefan Wahren
     [not found]             ` <571DB385.9010305-saaNCTdWVBT7BZbvpMY5sg@public.gmane.org>
2016-04-25 13:06               ` Arnd Bergmann
2016-04-27 20:16                 ` Stefan Wahren
     [not found]                   ` <57211E2A.5060807-saaNCTdWVBT7BZbvpMY5sg@public.gmane.org>
2016-04-27 20:20                     ` Arnd Bergmann
2016-04-23  8:24   ` Arnd Bergmann [this message]

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=5929251.U2lOfbMTgH@wuerfel \
    --to=arnd-r2ngtmty4d4@public.gmane.org \
    --cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=info-saaNCTdWVBT7BZbvpMY5sg@public.gmane.org \
    --cc=joerg.krause-L1vi/lXTdtsfGbAt6QbQcg@public.gmane.org \
    --cc=kernel-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org \
    --cc=kernelnewbies-7JyXY6prKcjpASu1u0TL5ti2O/JbrIOy@public.gmane.org \
    --cc=shawnguo-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.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).