[U-Boot] [RFC PATCH 06/20] sandbox: Allow board_init_f() and board_init_r() to return

Simon Glass sjg at chromium.org
Fri Sep 23 17:55:11 CEST 2011


Hi Mike,

On Sat, Sep 17, 2011 at 5:05 PM, Mike Frysinger <vapier at gentoo.org> wrote:
> On Saturday, September 17, 2011 12:48:45 Simon Glass wrote:
>> Since the sandbox architecture doesn't do relocation, we prefer to call
>> board_init_r() explicitly when board_init_f() returns. Similarly we
>> prefer to call main_loop() when board_init_r returns.
>
> NAK; i dont see how sandbox is special.  just do what i do in Blackfin's
> board.c:
>        board_init_f calls board_init_r
>        board_init_r does while (1) main_loop()

I have done as you say for now, but this isn't great. It means that
the only way back to the top level (say to run another test) is to use
setjmp/longjmp. But I will deal with this issue when it actually comes
up.

Regards,
Simon

> -mike
>


More information about the U-Boot mailing list