[U-Boot] [PATCH 3/3] Consolidate arch-specific mem_malloc_init() implementations
Wolfgang Denk
wd at denx.de
Sat Aug 22 13:54:16 CEST 2009
Dear Jean-Christophe PLAGNIOL-VILLARD,
In message <20090822085428.GA11950 at game.jcrosoft.org> you wrote:
>
> > common/dlmalloc.c | 15 +++++++++++++++
> > include/malloc.h | 2 ++
> > lib_arm/board.c | 10 ----------
> > lib_avr32/board.c | 15 ++-------------
> > lib_blackfin/board.c | 9 ---------
> > lib_m68k/board.c | 14 +-------------
> > lib_microblaze/board.c | 20 +++++---------------
> > lib_mips/board.c | 14 +-------------
> > lib_nios/board.c | 14 ++------------
> > lib_nios2/board.c | 14 ++------------
> > lib_ppc/board.c | 14 +-------------
> > lib_sh/board.c | 9 ---------
> > lib_sparc/board.c | 21 +--------------------
> > 13 files changed, 32 insertions(+), 139 deletions(-)
> >
> > diff --git a/common/dlmalloc.c b/common/dlmalloc.c
> > index f3bced4..241db8c 100644
> > --- a/common/dlmalloc.c
> > +++ b/common/dlmalloc.c
> > @@ -1520,6 +1520,21 @@ void *sbrk(ptrdiff_t increment)
> > return (void *)old;
> > }
> >
> > +#ifndef CONFIG_X86
> could we have a generic name (not arch)
> CONFIG_GENERIC_MALLOC_INIT
That would mean you have to touch N board configurations. To me it
sounds as if this was not per-board choice, but an architecture-
specific decision. And a CONFIG_* name seems wrong (it should be
CONFIG_SYS_* at least).
> and then define it in the configs/arch.h
What is configs/arch.h? There is no such file, and the name does not
make sense to me.
Best regards,
Wolfgang Denk
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Star Trek Lives!
More information about the U-Boot
mailing list