devicetree-compiler.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Gibson <david-xT8FGy+AXnRB3Ne2BGzF6laj5H9X9Tb+@public.gmane.org>
To: Ian Campbell <ijc-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org>
Cc: devicetree-compiler-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: Warnings do include offending filename
Date: Tue, 31 Jan 2017 10:49:32 +1100	[thread overview]
Message-ID: <20170130234932.GB14879@umbus.fritz.box> (raw)
In-Reply-To: <1485767585.7612.23.camel-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org>

[-- Attachment #1: Type: text/plain, Size: 2532 bytes --]

On Mon, Jan 30, 2017 at 09:13:05AM +0000, Ian Campbell wrote:
> Hello,
> 
> I wasn't sure how/where to make a wishlist bug report, so I hope this
> will suffice, am happy to be pointed in a different direction though.
> 
> I recently[0] stumbled over around 1,000 of these:
>     Warning (unit_address_vs_reg): Node /soc has a reg or ranges property, but no unit name
>     Warning (unit_address_vs_reg): Node /soc/main-oscillator has a reg or ranges property, but no unit name
>     Warning (unit_address_vs_reg): Node /soc has a reg or ranges property, but no unit name
>     Warning (unit_address_vs_reg): Node /soc has a reg or ranges property, but no unit name
>     Warning (unit_address_vs_reg): Node /soc/main-oscillator has a reg or ranges property, but no unit name
>     Warning (unit_address_vs_reg): Node /soc has a reg or ranges property, but no unit name
>     Warning (unit_address_vs_reg): Node /soc/main-oscillator has a reg or ranges property, but no unit name
> 
> When building the split device tree repo[1] from the Linux source
> (essential it's a build of every single dts in the kernel source).
> 
> The cause of the warning is an issue which needs to be fixed but I
> thought I would mention that it would be very useful (I expect) if dtc
> would include the offending file in warnings (like e.g. gcc would), not
> just because of the number of *.dtb being built here but also due to
> #include and /include/ of .dtsi files.

Right, having the filenames - and line numbers - there would certainly
be helpful.  Unfortunately, it's not at all trivial to implement.  As
someone said in a different thread, these checks take place (and have
to) after the tree is completely parsed and we no longer have source
locations readily to hand.

It might be possible to attach (optional) srcpos * markers to each
node and property in the live tree.  However, that runs into other
complications: when using dts includes nodes can be merges of
information from several different dtsi files.  So, a node can be
composed of information from several non-contiguous chunks of source
from different files.  It's not clear what should be printed in that
case.

If you can see a reasonable way to do this, I'd love to see patches
for it, but I certainly don't have time to tackle it myself.

-- 
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

  parent reply	other threads:[~2017-01-30 23:49 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-30  9:13 Warnings do include offending filename Ian Campbell
     [not found] ` <1485767585.7612.23.camel-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org>
2017-01-30 10:48   ` Ian Campbell
2017-01-30 23:49   ` David Gibson [this message]
     [not found]     ` <20170130234932.GB14879-K0bRW+63XPQe6aEkudXLsA@public.gmane.org>
2017-01-31  8:24       ` Ian Campbell
     [not found]         ` <1485851088.7612.32.camel-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org>
2017-02-01  0:16           ` David Gibson
     [not found]             ` <20170201001654.GB30639-K0bRW+63XPQe6aEkudXLsA@public.gmane.org>
2017-02-01  1:00               ` David Gibson
     [not found]                 ` <20170201010004.GG30639-K0bRW+63XPQe6aEkudXLsA@public.gmane.org>
2017-02-01  7:34                   ` Ian Campbell
     [not found]                     ` <1485934446.7612.36.camel-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org>
2017-02-02  5:05                       ` David Gibson
     [not found]                         ` <20170202050553.GF13219-K0bRW+63XPQe6aEkudXLsA@public.gmane.org>
2017-02-03 19:44                           ` Ian Campbell
     [not found]                             ` <1486151046.7612.44.camel-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org>
2017-02-10  4:11                               ` David Gibson
2017-02-19 16:00                                 ` Ian Campbell
     [not found]                                   ` <1487520043.7612.59.camel-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org>
2017-02-23  3:42                                     ` David Gibson
     [not found]                                       ` <20170223034219.GG12577-K0bRW+63XPQe6aEkudXLsA@public.gmane.org>
2017-02-23  8:44                                         ` Ian Campbell
     [not found]                                           ` <1487839440.7612.76.camel-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org>
2017-02-23  9:13                                             ` David Gibson

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=20170130234932.GB14879@umbus.fritz.box \
    --to=david-xt8fgy+axnrb3ne2bgzf6laj5h9x9tb+@public.gmane.org \
    --cc=devicetree-compiler-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=ijc-KcIKpvwj1kUDXYZnReoRVg@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).