aboutsummaryrefslogtreecommitdiff
path: root/bbl
diff options
context:
space:
mode:
authorHesham Almatary <Hesham.Almatary@cl.cam.ac.uk>2018-05-14 17:11:33 +0100
committerHesham Almatary <Hesham.Almatary@cl.cam.ac.uk>2018-07-12 10:58:55 +0100
commit72672f9a393e10e5444f733cba287a9744cd4033 (patch)
tree34ebae81163c3b0039959b763076e3abada606d7 /bbl
parent2d85b4c38e216f8e9ceea595b87a999f2bf5d9df (diff)
downloadriscv-pk-72672f9a393e10e5444f733cba287a9744cd4033.zip
riscv-pk-72672f9a393e10e5444f733cba287a9744cd4033.tar.gz
riscv-pk-72672f9a393e10e5444f733cba287a9744cd4033.tar.bz2
bbl: boot payload in machine mode when --enable-boot-machine is passed
Diffstat (limited to 'bbl')
-rw-r--r--bbl/bbl.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/bbl/bbl.c b/bbl/bbl.c
index 6363d0a..08e44af 100644
--- a/bbl/bbl.c
+++ b/bbl/bbl.c
@@ -58,7 +58,11 @@ void boot_other_hart(uintptr_t unused __attribute__((unused)))
}
}
+#ifdef BBL_BOOT_MACHINE
+ enter_machine_mode(entry, hartid, dtb_output());
+#else /* Run bbl in supervisor mode */
enter_supervisor_mode(entry, hartid, dtb_output());
+#endif
}
void boot_loader(uintptr_t dtb)