Firmware SMP boot bug
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 45/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- c
- Domain
- embedded-iot
Research direction
Start with fw_base.S and compare the cold-boot-hart lottery changes in commit 8151105af5e4bd5d2a17fe0babd6cff3b36496fb. Trace how _boot_status and _relocate_lottery are read and written by boot and non-boot harts. Done means a non-boot hart cannot be left waiting forever after relocation while boot-stage status remains correct.
Written by the indexing model from the issue text.
Description
The cold-boot-hart lottery in fw_base.S has recently been modified by using the _boot_status variable instead of the _relocate_lottery variable. This introduces a data race since the _boot_status variable is also written by the cold-boot hart to indicate the current boot stage without waiting for the other cores to have completed the lottery. If a non-boot hart enters the lottery when the boot-hart has already completed relocation _boot_status is overwritten and the non-boot hart is stuck forever in _wait_for_boot_hart.
The change has been introduced in this commit.
- Dominant language
- C
- Stars
- 1.6k
- Forks
- 734
- PR merge metrics
- No merged PRs in 30d
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from riscv-software-src/opensbi
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
riscv-software-src/opensbi#425 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
riscv-software-src/opensbi#424 · 1 comment ·
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
riscv-software-src/opensbi#439 ·
-
sbi_trap_redirect() does not clear SPELP when the interrupted context had no landing pad expectedOpen
Difficulty 3/5 1-2 days Newbie friendliness 67/100
riscv-software-src/opensbi#438 ·
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
riscv-software-src/opensbi#436 · 3 comments ·
All issues in riscv-software-src/opensbi
Similar issues
-
area/docdb kind/failing-test priority/medium status/awaiting-triage
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
yugabyte/yugabyte-db#39462 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
libreswan/libreswan#3185 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Maintainers usually reply within 3 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
-
category:port-update
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 2 days