Skip to content
Commit b6bb561e authored by Andrew Jones's avatar Andrew Jones
Browse files

riscv: Fix secondary_entry



The last few instructions of secondary_entry had the right concept,
but were the totally wrong implementation. Without setting ra, then,
when the boot function doesn't stay in an infinite loop, like
do_idle() would, we'd go off into the weeds when trying to return
from it. Make sure we set ra to come back to where we can then call
do_idle() instead. The bug was found by inspection since nobody is
calling smp_boot_secondary() with anything other than do_idle() at
this time.

Fixes: 9c92b28e ("riscv: Add SMP support")
Signed-off-by: default avatarAndrew Jones <andrew.jones@linux.dev>
parent d4827ec0
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment