improve RISC-V multi core boot - #132
Draft
axel-h wants to merge 12 commits into
Draft
Conversation
axel-h
commented
Nov 13, 2021
Member
- add much more comments
- fix SBI HSM register naming quirk
- Ensure DTB is always passed to primary core boot
- check SBI HSM error when bringing up secondary harts
- Stop wrong boot hart via HSM if possible
- unify stack definitions for all cores
- add multicore helper functions
- Drop variable hsm_exists, pass information as parameter
- Print more log messages
axel-h
force-pushed
the
patch-axel-7
branch
5 times, most recently
from
November 16, 2021 04:23
ff35350 to
7c43455
Compare
axel-h
force-pushed
the
patch-axel-7
branch
5 times, most recently
from
February 6, 2022 21:49
09be73e to
12c88f1
Compare
axel-h
marked this pull request as draft
February 6, 2022 21:59
axel-h
force-pushed
the
patch-axel-7
branch
7 times, most recently
from
February 7, 2022 01:53
e773b34 to
a3ffa7c
Compare
axel-h
force-pushed
the
patch-axel-7
branch
3 times, most recently
from
February 18, 2022 05:01
a0204aa to
8eec928
Compare
axel-h
force-pushed
the
patch-axel-7
branch
3 times, most recently
from
March 1, 2022 17:26
d238b57 to
e097abf
Compare
Contributor
|
@axel-h thanks for the changes. I just want to double check if there are any bugs fixed in the PR. |
yyshen
reviewed
Dec 2, 2023
| int mutex = 0; | ||
| int core_ready[CONFIG_MAX_NUM_NODES] = { 0 }; | ||
|
|
||
| static void acquire_multicore_lock(void) |
Contributor
There was a problem hiding this comment.
Given that this is used inside this file only, maybe smp_lock and smp_unlock are shorter. just a suggestion.
yyshen
reviewed
Dec 2, 2023
| __atomic_store_n(&mutex, 0, __ATOMIC_RELEASE); | ||
| } | ||
|
|
||
| static void set_secondary_cores_go(void) |
yyshen
reviewed
Dec 2, 2023
|
|
||
| _start1: /* a0 must hold current hard ID passed by bootloader */ | ||
| /* a1 must hold dtb address passed by bootloader */ | ||
| /*----------------------------------------------------------------------------*/ |
yyshen
reviewed
Dec 2, 2023
Contributor
There was a problem hiding this comment.
so this basically has no code logic changes? In this case, maybe we should state it in the commit message clearly.
yyshen
reviewed
Dec 2, 2023
| } | ||
|
|
||
| #if CONFIG_MAX_NUM_NODES > 1 | ||
|
|
Contributor
There was a problem hiding this comment.
why are the additional empty lines?
axel-h
force-pushed
the
patch-axel-7
branch
5 times, most recently
from
July 15, 2025 15:51
1533fd2 to
ac4d384
Compare
Signed-off-by: Axel Heider <axelheider@gmx.de>
Signed-off-by: Axel Heider <axelheider@gmx.de>
Signed-off-by: Axel Heider <axelheider@gmx.de>
Signed-off-by: Axel Heider <axelheider@gmx.de>
Signed-off-by: Axel Heider <axelheider@gmx.de>
Use wrapper function to Improve code readability. Signed-off-by: Axel Heider <axelheider@gmx.de>
Signed-off-by: Axel Heider <axelheider@gmx.de>
Signed-off-by: Axel Heider <axelheider@gmx.de>
This also makes the comment about a1 correct again. Signed-off-by: Axel Heider <axelheider@gmx.de>
hart ID and custom argument is passed when starting a secondary hart. Signed-off-by: Axel Heider <axelheider@gmx.de>
Signed-off-by: Axel Heider <axelheider@gmx.de>
Signed-off-by: Axel Heider <axelheider@gmx.de>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.