]> git.baikalelectronics.ru Git - uboot.git/commit
spl: fix assignment of board info to global data
authorYork Sun <york.sun@nxp.com>
Thu, 28 Sep 2017 15:42:10 +0000 (08:42 -0700)
committerYork Sun <york.sun@nxp.com>
Mon, 9 Oct 2017 15:48:44 +0000 (08:48 -0700)
commit6b0048abc16ca16febf21887ae85382222fe8c7a
tree7b43d3ec735d65b01a05e9f84f422f49929d570a
parentc5fb7d88f7ee66fb317cba2232aa191b73af88df
spl: fix assignment of board info to global data

Commit 6f39dab98665 ("spl: reorder the assignment of board info to
global data") intended to move assignment of board info earlier,
into board_init_r(). However, function preload_console_init() is
called either from spl_board_init() or from board_init_f(). For the
latter case, the board info assignment is much earlier than proposed
board_init_r(). Create a new function to fill gd->bd and call this
function when needed.

Signed-off-by: York Sun <york.sun@nxp.com>
CC: Lokesh Vutla <lokeshvutla@ti.com>
CC: Ravi Babu <ravibabu@ti.com>
CC: Lukasz Majewski <lukma@denx.de>
CC: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
arch/arm/cpu/armv8/fsl-layerscape/spl.c
common/spl/spl.c
include/spl.h