Re: [RFC] Introducing yamldt, a yaml to dtb compiler

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Thu, Jul 27, 2017 at 09:12:40PM -0500, Rob Herring wrote:
> On Thu, Jul 27, 2017 at 7:51 PM, Tom Rini <trini@xxxxxxxxxxxx> wrote:
> > On Thu, Jul 27, 2017 at 06:00:00PM -0500, Rob Herring wrote:
> >> On Thu, Jul 27, 2017 at 4:46 PM, Pantelis Antoniou
> >> <pantelis.antoniou@xxxxxxxxxxxx> wrote:
> >> > Hi Frank,
> >> >
> >> > On Thu, 2017-07-27 at 13:22 -0700, Frank Rowand wrote:
> >> >> Hi Pantelis,
> >> >>
> >> >> Keep in mind one of the reasons Linus says he is very direct is to
> >> >> avoid leading a developer on, so that they don't waste a lot of time
> >> >> trying to resolve the maintainer's issues instead of realizing that
> >> >> the maintainer is saying "no". Please read my current answer as being
> >> >> "no, not likely to ever be accepted", not "no, not in the current form".
> >> >>
> >> >> My first reaction is: no, this is not a good idea for the Linux kernel.
> >> >>
> >> >
> >> > This has nothing to do with the kernel. It spits out valid DTBs that the
> >> > kernel (or anything else) may use.
> >>
> >> Let me rephrase Frank's statement: this is not a good idea for the
> >> main repository of dts files.
> >>
> >> But sure, DTS is already not the only source of DTBs. It comes from
> >> firmware on Power systems.
> >
> > Yes, but unless they're generated from something other than a (at the
> > time) normal DTS, that's not a good example, IMHO.
> 
> They aren't. I'm talking about IBM systems. The firmware has its own
> representation and flattens that to a DTB is how I understand it.

That's correct.  To elaborate a bit, for a partition under PowerVM,
there's a real IEEE1275 Open Firmware which generates a "live" device
tree.  Early boot code in the kernel flattens that to dtb to pass it
to later boot (this was actually the very first use of dtb, before
anyone thought about directly creating them).

Under KVM it's a bit more complicated, there's still an IEEE1275
implementation (SLOF) and a "live" tree, but it builds that tree based
largely on a dtb supplied by qemu.  qemu does build that directly
using libfdt and it's own knowledge of the virtual hardware; there's
no dts.

For bare metal boots the firmware (OPAL) supplies a dtb to the kernel,
I believe.  I suspect that's essentially built from scratch (probably
using libfdt), although it's possible it has some core piece that's
precompiled from dts.

There are other "real" OF machines out there, though they're not that
common.  There are the old (powerpc) Macs, and Sun Sparc servers.  At
least some versions of the OLPC used OF on x86.

-- 
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: signature.asc
Description: PGP signature


[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux