diff options
author | Palmer Dabbelt <palmer@dabbelt.com> | 2017-11-02 15:44:15 -0700 |
---|---|---|
committer | Palmer Dabbelt <palmer@dabbelt.com> | 2017-11-02 15:45:26 -0700 |
commit | 9204785053e9a488b8990f9f98ff8f05c71fd0d5 (patch) | |
tree | d87d05b64a66af9a542a7d88e98f53d7ff17d33d /machine/minit.c | |
parent | 220b1bee10d9399864131cd1dbe5037714237f03 (diff) | |
download | riscv-pk-9204785053e9a488b8990f9f98ff8f05c71fd0d5.zip riscv-pk-9204785053e9a488b8990f9f98ff8f05c71fd0d5.tar.gz riscv-pk-9204785053e9a488b8990f9f98ff8f05c71fd0d5.tar.bz2 |
Detect harts that can't boot Linux instead of hard-coding them
This checks to see if a hart can't boot Linux by looking for a
compatible "mmu-type" field. If the hart can't boot Linux, then bbl
masks it off.
Diffstat (limited to 'machine/minit.c')
-rw-r--r-- | machine/minit.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/machine/minit.c b/machine/minit.c index 187bef7..8ce96b1 100644 --- a/machine/minit.c +++ b/machine/minit.c @@ -6,6 +6,7 @@ #include "uart.h" #include "finisher.h" #include "platform_interface.h" +#include "disabled_hart_mask.h" #include <string.h> #include <limits.h> @@ -125,7 +126,7 @@ static void hart_plic_init() static void wake_harts() { for (int hart = 0; hart < MAX_HARTS; ++hart) - if ((((~platform__disabled_hart_mask & hart_mask) >> hart) & 1)) + if ((((~disabled_hart_mask & hart_mask) >> hart) & 1)) *OTHER_HLS(hart)->ipi = 1; // wakeup the hart } |