Could the DTS experts look at this?

Grant Likely grant.likely at secretlab.ca
Wed Feb 13 06:03:30 EST 2008


On Feb 12, 2008 11:52 AM, Scott Wood <scottwood at freescale.com> wrote:
> On Mon, Feb 11, 2008 at 07:41:07PM -0500, Sean MacLennan wrote:
> > David Gibson wrote:
> > > Err.. now I'm doubly confused.  Initially I thought you'd need to
> > > change the size part of reg somewhere, but your description above just
> > > convinced me you didn't (because you were essentially just shifting a
> > > 4M map up into the high rather than low 4M of the 64M space).  Now
> > > you're saying you do..
> > >
> > If you tell the mtd driver that the flash is 64M, when it is really 4M,
> > it goes oops. So you do have to get the size right in the reg field.
>
> It'd be nice if we could pass in a flag to tell it not to try to find
> additional consecutive chips in the mapping...  It's a shame to have
> probable chips, and still have to know how big they are anyway.

That is the job of the boot loader or wrapper.  The whole concept of
the device tree is that by the time it gets to the kernel it is an
accurate representation of the hardware; not a list of things which
might or might not be present.

I see two choices here;
1. have a different .dts variant for each board config (or a .dts with
macros that can generate different .dtb variants)
2. make the boot code massage the tree so it is accurate before it
gets to the kernel.

Either way, the mtd driver must be able to trust that the dt is
correct and complete.

g.

-- 
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.



More information about the Linuxppc-dev mailing list