[U-Boot] Support of device-tree for PowerPC platform: Query

Prabhakar Kushwaha prabhakar.kushwaha at nxp.com
Thu Jun 28 05:47:06 UTC 2018


Hi Simon,


> -----Original Message-----
> From: sjg at google.com [mailto:sjg at google.com] On Behalf Of Simon Glass
> Sent: Thursday, June 28, 2018 3:36 AM
> To: York Sun <york.sun at nxp.com>
> Cc: Prabhakar Kushwaha <prabhakar.kushwaha at nxp.com>; u-
> boot at lists.denx.de; Poonam Aggrwal <poonam.aggrwal at nxp.com>; Jagdish
> Gediya <jagdish.gediya at nxp.com>
> Subject: Re: Support of device-tree for PowerPC platform: Query
> 
> Hi,
> 
> On 27 June 2018 at 08:06, York Sun <york.sun at nxp.com> wrote:
> >
> > +Simon
> >
> > On 06/27/2018 01:05 AM, Prabhakar Kushwaha wrote:
> > > Hi All,
> > >
> > > We are trying to add support of device-tree for PowerPC platforms. As
> per our analysis following 2 options can be used.
> > >
> > > a) CONFIG_OF_SEPARATE
> > > b) CONFIG_OF_EMBED
> > >
> > > In PowerPC platforms, reset_vector is always expected at the **last**
> address of flash.
> > > U-boot binary has reset_vector at last followed by __bss sections(not
> present in binary) and must be programmed in such a way that reset_vecrot
> lie at **last** address of flash.
> > >
> > > Hence dtb cannot be appended at last of  u-boot binary.
> > >
> > > So there looks to be following 2 possible solutions
> > > a) Use CONFIG_OF_SEPARATE and append dtb at start of u-boot binary.
> This require change in flash map because u-boot start address needs to
> shifted (due to reset_vector requirements).
> > >      Exiting offset of env and fman ucode also needs shifting. This approach
> requires modification in almost all existing PowerPC platform to adhere to
> new **modified** flash map.
> > >
> > > b) Use CONFIG_OF_EMBED and embed dtb inside u-boot. This way no
> change in exiting flash map. But its usage is being discouraged as per
> doc/README.fdt-control.
> > >
> >
> > Clearly putting dtb at the very end doesn't work, neither last 4KB. I
> > think we either use CONFIG_OF_EMBED (many boards use this way), or try
> > "fdtcontroladdr".
> 
> 
> I discourage CONFIG_OF_EMBED - it is a debug feature. I'm not sure if you
> have other options though.
> 
> Can the DT perhaps go before U-Boot in the flash? We would need a way to
> find it though.
> 

Thanks for the direction.

We will be following approach "a" with updated flash map.
We will allocate 1MB for uboot in flash. Out which 64K for DTB and 960KB for u-boot for future increase.

We will also update location of env and fman ucode for NXP platforms. 

--pk


--pk


More information about the U-Boot mailing list