aboutsummaryrefslogtreecommitdiff
path: root/bbl
diff options
context:
space:
mode:
authorWesley W. Terpstra <wesley@sifive.com>2017-03-22 14:35:13 -0700
committerWesley W. Terpstra <wesley@sifive.com>2017-03-22 14:35:13 -0700
commit23ab37ad78673166a8300584d177ace77fca5101 (patch)
tree1e6b9b16a5cc5768d1c91f6661a2ebfff61b2891 /bbl
parent316f85e9ae2f5d9dd0b33d3649a8256db0dfd29b (diff)
downloadriscv-pk-23ab37ad78673166a8300584d177ace77fca5101.zip
riscv-pk-23ab37ad78673166a8300584d177ace77fca5101.tar.gz
riscv-pk-23ab37ad78673166a8300584d177ace77fca5101.tar.bz2
SBI: a0+a1 hold hartid+dtb pointer between boot loader stagesfdt
Diffstat (limited to 'bbl')
-rw-r--r--bbl/bbl.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/bbl/bbl.c b/bbl/bbl.c
index 9553ddb..3550c9a 100644
--- a/bbl/bbl.c
+++ b/bbl/bbl.c
@@ -8,17 +8,17 @@
static const void* entry_point;
-void boot_other_hart()
+void boot_other_hart(uintptr_t dtb)
{
const void* entry;
do {
entry = entry_point;
mb();
} while (!entry);
- enter_supervisor_mode(entry, read_csr(mhartid), 0);
+ enter_supervisor_mode(entry, read_csr(mhartid), dtb);
}
-void boot_loader()
+void boot_loader(uintptr_t dtb)
{
extern char _payload_start;
#ifdef PK_ENABLE_LOGO
@@ -26,5 +26,5 @@ void boot_loader()
#endif
mb();
entry_point = &_payload_start;
- boot_other_hart();
+ boot_other_hart(dtb);
}