devicetree-spec.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Gibson <david-xT8FGy+AXnRB3Ne2BGzF6laj5H9X9Tb+@public.gmane.org>
To: Cyril Novikov <cnovikov-wte42BQEg7M@public.gmane.org>
Cc: devicetree-spec-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: Virtualization difficulty -- phandles
Date: Mon, 24 Jul 2017 16:14:54 +1000	[thread overview]
Message-ID: <20170724061454.GL17228@umbus.fritz.box> (raw)
In-Reply-To: <okukd4$i1o$1@blaine.gmane.org>

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

On Fri, Jul 21, 2017 at 09:24:35PM -0700, Cyril Novikov wrote:
> On 7/18/2017 8:40 PM, David Gibson wrote:
> 
> > Well, I don't want to invent a new encoding if we can possibly avoid
> > it.  The current encoding used for overlay generation looks like this
> > 
> > / {
> > 	target: node@0 {
> > 	};
> > 	node@1 {
> > 		ref = <&target>;
> > 	};
> > 	__local_fixups__ = {
> > 		node@1 {
> > 			ref = <0>;
> > 		};
> > 	};
> > };
> > 
> > Basically, __local_fixups__  has a subtree which paralells the main
> > tree.  Each property found under __local_fixups__ is a list of offsets
> > at which phandle references appear in the corresponding property in
> > the main tree.
> > 
> > That seems like it would survive most likely bootloader
> > transformations as well, I think.
> > 
> > > Even if they do, like I said in my reply to David, we don't strive to
> > > achieve a full automation, so it's probably tolerable. Oh well, we've missed
> > > some dependencies. It's still better than what we have now.
> > 
> > Ok.  I'm tentatively convinced that it's worth adding a switch to dtc
> > to generate __local_fixups__even for a non-plugin source.
> > 
> > Next step is for someone to propose a concrete patch.
> 
> Do you mean a patch to the DTC utility or a patch to the Devicetree
> Specification?

I was meaning a patch to dtc.  Exactly what's mean by the "Devicetree
Specification" is a bit unclear.  There's the spec of the flattened
encoding, the spec of what goes in the tree (i.e. the collected
bindings).  And then there's the spec of formats using the flattened
tree format to encode something that's not a traditional device tree
(though it might be related), like FIT and overlays.

> I suppose we want this specced, so that alternative
> incompatible implementations do not appear?

Well sort of, but it's not clear where to put it.  This is basically a
new option to make dtc add "overlay style" __local_fixups__
information to a non-overlay.  Does that belong in the overlay spec
(such as it is) or somewhere else.

> The engineer looking at it told
> me it's only a few lines change for the DTC.

Maybe a little more than that to make something polished, but not
complex, no.

-- 
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: 833 bytes --]

  reply	other threads:[~2017-07-24  6:14 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-12  6:15 Virtualization difficulty -- phandles Cyril Novikov
2017-07-12 17:10 ` Florian Fainelli
     [not found]   ` <180baf3e-9e7b-c791-3be2-81d807b14759-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2017-07-13  4:23     ` Cyril Novikov
2017-07-13 16:47       ` Florian Fainelli
     [not found]         ` <4594fc97-9b9f-267e-ee8e-8cbe89341fe7-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2017-07-16  5:35           ` David Gibson
     [not found]             ` <20170716053548.GL17539-K0bRW+63XPQe6aEkudXLsA@public.gmane.org>
2017-07-18  1:37               ` Cyril Novikov
2017-07-19  3:30                 ` David Gibson
2017-07-24 17:09               ` Frank Rowand
     [not found]                 ` <597629DC.5060800-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2017-07-25  7:50                   ` David Gibson
     [not found]                     ` <20170725075034.GD8978-K0bRW+63XPQe6aEkudXLsA@public.gmane.org>
2017-07-27 20:58                       ` Frank Rowand
     [not found]                         ` <597A53E1.4010002-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2017-07-27 21:59                           ` Pantelis Antoniou
2017-07-28  4:25                           ` David Gibson
2017-07-14 10:58 ` Mark Rutland
2017-07-18  1:47   ` Cyril Novikov
2017-07-19  3:40     ` David Gibson
     [not found]       ` <20170719034029.GT3140-K0bRW+63XPQe6aEkudXLsA@public.gmane.org>
2017-07-22  4:24         ` Cyril Novikov
2017-07-24  6:14           ` David Gibson [this message]
2017-07-24 16:27 ` Frank Rowand
     [not found]   ` <59762000.7000302-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2017-07-24 23:00     ` Cyril Novikov

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=20170724061454.GL17228@umbus.fritz.box \
    --to=david-xt8fgy+axnrb3ne2bgzf6laj5h9x9tb+@public.gmane.org \
    --cc=cnovikov-wte42BQEg7M@public.gmane.org \
    --cc=devicetree-spec-u79uwXL29TY76Z2rM5mHXA@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).