[U-Boot] [PATCH 2/3 V3] Make board_init_f under nand_boot.c a weak function

Sughosh Ganu urwithsughosh at gmail.com
Wed Oct 27 07:58:09 CEST 2010


hi Scott,

On Tue Oct 26, 2010 at 02:07:06PM -0500, Scott Wood wrote:
> On Tue, 26 Oct 2010 23:27:44 +0530
> Sughosh Ganu <urwithsughosh at gmail.com> wrote:
> 
> >  
> >  #if defined(CONFIG_ARM) && !defined(CONFIG_SYS_ARM_WITHOUT_RELOC)
> > -void board_init_f (ulong bootflag)
> > +void __board_init_f(ulong bootflag)
> >  {
> > -	relocate_code (CONFIG_SYS_TEXT_BASE - TOTAL_MALLOC_LEN, NULL,
> > -		       CONFIG_SYS_TEXT_BASE);
> > +	relocate_code(CONFIG_SYS_TEXT_BASE - TOTAL_MALLOC_LEN, NULL,
> > +			CONFIG_SYS_TEXT_BASE);
> >  }
> > +void board_init_f(ulong bootflag)__attribute__((weak,
> > +						 alias("__board_init_f")));
> >  #endif
> >  
> >  /*
> 
> Eventually all boards should just provide their own board_init_f,
> which could just consist of a call to a common board init helper
> function.  Or possibly a preprocessor define could be used to indicate
> that the common function should be used.


  I had prososed that in my previous mail. I see that smdk6400 is the
  only arm board using this. I think we can make this change to move
  the board_init_f to the respective board directory right away. The
  change should not impact any other boards. If fine with you, i will
  respin my patch accordingly.

-sughosh


More information about the U-Boot mailing list