| 554c73c0 | 11-Feb-2017 |
Masahiro Yamada <yamada.masahiro@socionext.com> |
flash: compile common/flash.c iif CONFIG_MTD_NO_FLASH is enabled
The whole of common/flash.c is guarded by #if defined() ... #endif. Move the conditional to common/Makefile.
Signed-off-by: Masahiro
flash: compile common/flash.c iif CONFIG_MTD_NO_FLASH is enabled
The whole of common/flash.c is guarded by #if defined() ... #endif. Move the conditional to common/Makefile.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
show more ...
|
| 6bda55a3 | 16-Jan-2017 |
Simon Glass <sjg@chromium.org> |
x86: Do relocation before clearing BSS
The BSS region may overlap with relocations. If we clear BSS we will overwrite the start of the relocation area. This doesn't matter when running from SPI flas
x86: Do relocation before clearing BSS
The BSS region may overlap with relocations. If we clear BSS we will overwrite the start of the relocation area. This doesn't matter when running from SPI flash, since it is read-only. But when relocating 64-bit U-Boot from one place in RAM to another, relocation will fail because some of its relocations have been zeroed.
To fix this, put the ELF fixup call before the BSS clearing call.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
show more ...
|
| fb92308b | 16-Jan-2017 |
Simon Glass <sjg@chromium.org> |
x86: board_r: Set the global data pointer after relocation
Since 'gd' is just a normal variable on 64-bit x86, it is relocated by the time we get to board_init_r(). The old 'gd' variable is passed i
x86: board_r: Set the global data pointer after relocation
Since 'gd' is just a normal variable on 64-bit x86, it is relocated by the time we get to board_init_r(). The old 'gd' variable is passed in as parameter to board_init_r(), presumably for this situation.
Assign it on 64-bit x86 so that gd points to the correct data.
Options to improve this: - Make gd a fixed register and remove the board_init_r() parameter - Make all archs use this board_init_r() parameter
The second has a TODO in the code. The first has a TODO in a future commit ('x86: Support global_data on x86_64')
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
show more ...
|
| 4acff452 | 16-Jan-2017 |
Simon Glass <sjg@chromium.org> |
board_f/r: Use static const for the init sequences
These tables should be declared static const. Unfortunately the table in board_r is updated on machines with manual relocation.
Update them.
Sign
board_f/r: Use static const for the init sequences
These tables should be declared static const. Unfortunately the table in board_r is updated on machines with manual relocation.
Update them.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
show more ...
|
| a7044900 | 16-Jan-2017 |
Simon Glass <sjg@chromium.org> |
spl: spi: Add a debug message if loading fails
This currently fails silently. Add a debug message to aid debugging.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gma
spl: spi: Add a debug message if loading fails
This currently fails silently. Add a debug message to aid debugging.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
show more ...
|
| 7b74c4b6 | 20-Jan-2017 |
Masahiro Yamada <yamada.masahiro@socionext.com> |
Revert "armv8: release slave cores from CPU_RELEASE_ADDR"
This reverts commit 8c36e99f211104fd7dcbf0669a35a47ce5e154f5.
There is misunderstanding in commit 8c36e99f2111 ("armv8: release slave cores
Revert "armv8: release slave cores from CPU_RELEASE_ADDR"
This reverts commit 8c36e99f211104fd7dcbf0669a35a47ce5e154f5.
There is misunderstanding in commit 8c36e99f2111 ("armv8: release slave cores from CPU_RELEASE_ADDR"). How to bring the slave cores into U-Boot proper is platform-specific. So, it should be cared in SoC/board files instead of common/spl/spl.c. As you see SPL is the acronym of Secondary Program Loader, there is generally something that runs before SPL (the First one is usually Boot ROM).
How to wake up slave cores from the Boot ROM is really SoC specific. So, the intention for the spin table support is to bring the slave cores into U-Boot proper in an SoC specific manner. (this must be done after relocation. see below.)
If you bring the slaves into SPL, it is SoC own code responsibility to transfer them to U-Boot proper. The Spin Table defines the interface between a boot-loader and Linux kernel. It is unrelated to the interface between SPL and U-Boot proper.
One more thing is missing in the commit; spl_image->entry_point points to the entry address of U-Boot *before* relocation. U-Boot relocates itself between board_init_f() and board_init_r(). This means the master CPU sees the different copy of the spin code than the slave CPUs enter. The spin_table_update_dt() protects the code *after* relocation. As a result, the slave CPUs spin in unprotected code, which leads to unstable behavior.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Reviewed-by: Simon Glass <sjg@chromium.org>
show more ...
|
| b3d2861e | 27-Jan-2017 |
Andrew F. Davis <afd@ti.com> |
spl: Remove overwrite of relocated malloc limit
spl_init on some boards is called after stack and heap relocation, on some platforms spl_relocate_stack_gd is called to handle setting the limit to it
spl: Remove overwrite of relocated malloc limit
spl_init on some boards is called after stack and heap relocation, on some platforms spl_relocate_stack_gd is called to handle setting the limit to its value CONFIG_SPL_STACK_R_MALLOC_SIMPLE_LEN when simple SPL malloc is enabled during relocation. spl_init should then not re-assign the old pre-relocation limit when this is defined.
Signed-off-by: Andrew F. Davis <afd@ti.com> Reviewed-by: Tom Rini <trini@konsulko.com>
show more ...
|