mirror of
https://git.codelinaro.org/clo/qsdk/oss/boot/u-boot-2016.git
synced 2025-12-10 07:44:53 +01:00
runmulticore: disable console prints during cpu bringup
Printing on console while executing multi core command causes a race condition in serial driver and results in data abort. Disable serial console briefly during secondary cpu bring up to overcome the race condition and data abort exception. Signed-off-by: Sivaprakash Murugesan <sivaprak@codeaurora.org> Change-Id: I6b3cda3bd828cbcaf8e766f243f8137ab496a805
This commit is contained in:
parent
cf7ac0ed01
commit
6ea54bd348
2 changed files with 13 additions and 0 deletions
|
|
@ -58,6 +58,16 @@ asmlinkage void secondary_core_entry(char *argv, int *cmd_complete,
|
|||
bring_secondary_core_down(state);
|
||||
}
|
||||
|
||||
static void disable_console(void)
|
||||
{
|
||||
gd->flags |= GD_FLG_SILENT | GD_FLG_DISABLE_CONSOLE;
|
||||
}
|
||||
|
||||
static void enable_console(void)
|
||||
{
|
||||
gd->flags &= ~(GD_FLG_SILENT | GD_FLG_DISABLE_CONSOLE);
|
||||
}
|
||||
|
||||
int do_runmulticore(cmd_tbl_t *cmdtp,
|
||||
int flag, int argc, char *const argv[])
|
||||
{
|
||||
|
|
@ -109,6 +119,7 @@ int do_runmulticore(cmd_tbl_t *cmdtp,
|
|||
for (i = 1; i < argc; i++) {
|
||||
printf("Scheduling Core %d\n", i);
|
||||
delay = 0;
|
||||
disable_console();
|
||||
ret = bring_sec_core_up(i, (unsigned int)secondary_cpu_init,
|
||||
(unsigned int)&(core[i - 1]));
|
||||
if (ret) {
|
||||
|
|
@ -121,6 +132,7 @@ int do_runmulticore(cmd_tbl_t *cmdtp,
|
|||
if (!(core[i - 1].cpu_up)) {
|
||||
panic("Can't bringup core %d\n",i);
|
||||
}
|
||||
enable_console();
|
||||
|
||||
core_status |= (BIT(i - 1));
|
||||
core_on_status |= (BIT(i - 1));
|
||||
|
|
|
|||
|
|
@ -344,6 +344,7 @@ extern loff_t board_env_size;
|
|||
#define CONFIG_CMD_RUN
|
||||
#define CONFIG_ARMV7_PSCI
|
||||
#undef CONFIG_IPQ_ROOTFS_AUTH
|
||||
#define CONFIG_SILENT_CONSOLE
|
||||
|
||||
#endif /* _IPQCDP_H */
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue