RE: [U-Boot-Users] lib_xxxx and board.c concept

Hi,
Although lib__xxx would indicate a generic/common set of cpu
architecture specific functions,
the board.c file actually contains board related initialization
functions.
Wouldn't these functions better live in the board specific directories
?
The ppc4xx uses #define CONFIG_BOARD_EARLY_INIT_F 1 /* Call board_early_init_f(lash) */ #define CONFIG_MISC_INIT_R 1 /* Call misc_init_r(am) */
When these are defined, these functions are called from you board specific files.
There is a long text in board.c explaining that now there is an array
of functions to be
called during startup/initialization, but the functions included are
still listed
in board.c - so any >board specific function would (still) have to be
selected using ifdef's.
Now it seems I need to change the existing board.c file for the
architecture I'm dealing
with (microblaze), which means I could potentially break the existing
(suzaku) code that's already there.
Take a look at the solution as in lib_ppc, and implement the same for you microblaze board?
Regards, martijn

In message 7826EB01AD927140A1DCF898FE63325D3D848D@ExchangeSrv.Prodrive.nl you wrote:
The ppc4xx uses #define CONFIG_BOARD_EARLY_INIT_F 1 /* Call board_early_init_f(lash) */ #define CONFIG_MISC_INIT_R 1 /* Call misc_init_r(am) */
This is in no way specific to the AMCC 4xx processors.
Take a look at the solution as in lib_ppc, and implement the same for you microblaze board?
...where it makes sense.
Best regards,
Wolfgang Denk
participants (2)
-
Martijn de Gouw
-
Wolfgang Denk