[U-Boot] [PATCH 6/7] arm: ls102xa: Add SD boot support for LS1021AQDS board

Huan Wang alison.wang at freescale.com
Thu Sep 25 08:45:00 CEST 2014


Hi, Albert,

> On Mon, 22 Sep 2014 06:46:20 +0000, Huan Wang
> <alison.wang at freescale.com> wrote:
> 
> > Hi, Albert,
> >
> > > > On Thu, 18 Sep 2014 13:47:18 +0800, Alison Wang
> > > > <b18965 at freescale.com>
> > > > wrote:
> > > >
> > > > > +
> > > > > +     . = ALIGN(4);
> > > > > +     .u_boot_list : {
> > > > > +             KEEP(*(SORT(.u_boot_list*_i2c_*)));
> > > > > +     }
> > > >
> > > > IS this required? And if it is, could it not be added to the
> > > > arch/arm/cpu/u-boot-spl.lds file? This way you would not need an
> > > > .lds file at all.
> > > >
> > > > [Alison Wang] Yes, it is required.
> > >
> > > Ok -- what for? :)
> > [Alison Wang] In SPL part, DDR is initialized by reading SPD through
> I2C interface.
> > For I2C, ll_entry_count() is called, and it returns the number of
> > elements of a linker-generated array placed into subsection of
> > .u_boot_list section specified by _list argument. So I need to add
> this to make I2C work in SPL.
> 
> Understood. So your SPL code uses I2C, and for I2C, you need a linker
> list. But then:
> 
> > > > I would like to add it in arch/arm/cpu/u-boot-spl.lds. I was not
> > > > sure adding it in arch/arm/cpu/u-boot-spl.lds is acceptable or
> not.
> > >
> > > (assuming the reason why it is needed is valid) If it causes no
> > > change to boards which do not use it right now (and I mean 'no
> > > change' ad 'binary identical') then this is acceptable. Make sure
> > > you check the binary invariance and that you mention it in the
> commit.
> > >
> > [Alison Wang] It will cause the binary is not identical for other
> board.
> 
> Is this a prediction or an actual observation of compared builds with
> and without the I2C linker liste addition to the generic SPL .lds?

[Alison Wang] I use mx31pdk as example. I compared the binaries with and
Without the I2C linker list in arch/arm/cpu/u-boot-spl.lds. The binaries
are not identical.
> 
> > I think
> > it may be not good to add in arch/arm/cpu/u-boot-spl.lds. What's your
> opinion about it?
> 
> If there are SPLs which use I2C linker lists *and* the generic .lds and
> build without an error, then this should be fixed, because it means the
> build process should complain when an input section is not mapped to an
> output section.
> 
> (and that should be fixed even though in this case, adding the I2C
> linker lists in the .lds would 'fix' the build, but they would actually
> paper over the real issue of sections being mapped without control)
> 

Best Regards,
Alison Wang


More information about the U-Boot mailing list