[U-Boot] arch/powerpc/lib/board.c:get_effective_memsize() for 4GB+ systems
Robert Thorhuus
robert.thorhuus at ericsson.com
Thu Sep 20 22:24:26 CEST 2012
> -----Original Message-----
> From: Kumar Gala [mailto:galak at kernel.crashing.org]
> Sent: den 20 september 2012 19:27
> To: Robert Thorhuus
> Cc: u-boot at lists.denx.de
> Subject: Re: [U-Boot]
> arch/powerpc/lib/board.c:get_effective_memsize() for 4GB+ systems
>
>
> On Sep 19, 2012, at 10:28 AM, Robert Thorhuus wrote:
>
> > Hello!
> >
> > I'm having problem with my U-Boot for a PowerPC system. I
> think the root cause is that the function
> get_effective_memsize() (in file arch/powerpc/lib/board.c) returns 0.
> >
> > ulong get_effective_memsize(void)
> > {
> > #ifndef CONFIG_VERY_BIG_RAM
> > return gd->ram_size;
> > #else
> > /* limit stack to what we can reasonable map */
> > return ((gd->ram_size > CONFIG_MAX_MEM_MAPPED) ?
> > CONFIG_MAX_MEM_MAPPED : gd->ram_size); #endif }
> >
> > Since the system have 24GB of RAM I have fiddled around so
> both CONFIG_MAX_MEM_MAPPED is actually 24GB and also
> gd->ram_size is 24GB.
> >
> > Is it just me who have completely missed how U-Boot works or what?
>
> What kinda of PPC system is this?
>
> You probably don't want to change CONFIG_MAX_MEM_MAPPED. The
> idea is this is how much of your 24GB is directly accessible
> by u-boot. For large mem systems this is usually 2GB.
>
> - k
>
Thanks for the answer Kumar!
I'm using 64 bit mpc85xx cores.
Mapping the whole memory from the beginning was of course just an initial thought.
But for me it looks like the code is just not able to deal with more than 3.99GB mapped. U-Boot will not be able to be relocated.
BR
Robert
More information about the U-Boot
mailing list