mirror of
https://github.com/AsahiLinux/m1n1
synced 2024-11-25 08:00:17 +00:00
kboot: Reserve secondary CPU stacks
The secondary CPU may potentially use the stack after leaving WFE. Signed-off-by: Nick Chan <towinchenmi@gmail.com>
This commit is contained in:
parent
5bb8f04bdf
commit
5b8cfd1e7c
1 changed files with 8 additions and 0 deletions
|
@ -408,6 +408,14 @@ static int dt_set_cpus(void)
|
|||
cpu++;
|
||||
node = next;
|
||||
continue;
|
||||
} else {
|
||||
printf("FDT: Reserving stack for CPU %d 0x%lx\n", cpu, (uint64_t)secondary_stacks[cpu]);
|
||||
fdt_add_mem_rsv(dt, (uint64_t)secondary_stacks[cpu], SECONDARY_STACK_SIZE);
|
||||
if (has_el3()) {
|
||||
printf("FDT: Reserving EL3 stack for CPU %d 0x%lx\n", cpu,
|
||||
(uint64_t)secondary_stacks_el3[cpu]);
|
||||
fdt_add_mem_rsv(dt, (uint64_t)secondary_stacks_el3[cpu], SECONDARY_STACK_SIZE);
|
||||
}
|
||||
}
|
||||
|
||||
u64 mpidr = smp_get_mpidr(cpu);
|
||||
|
|
Loading…
Reference in a new issue