Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update entry.S #201

Open
wants to merge 1 commit into
base: riscv
Choose a base branch
from
Open

Conversation

Abhinavpatel00
Copy link

corrected the typo here

# Read the hardware thread ID ('mhartid') into register 'a1'.
csrr a1, mhartid

# Increment the hardware thread ID by 1 to avoid a stack overlap issue.
addi a1, a1, 1

# Calculate the new stack pointer value:
# sp = stack0 + ((hartid + 1) * 4096)
mul a0, a0, a1
add sp, sp, a0

corrected the typo here


    # Read the hardware thread ID ('mhartid') into register 'a1'.
    csrr a1, mhartid

    # Increment the hardware thread ID by 1 to avoid a stack overlap issue.
    addi a1, a1, 1

    # Calculate the new stack pointer value:
    # sp = stack0 + ((hartid + 1) * 4096)
    mul a0, a0, a1
    add sp, sp, a0
Copy link

@echtwerner echtwerner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change is similar to the request made in PR #252.

@maintainer, if you do not wish to acknowledge this PR because it goes against one of the objectives of the learning experience, it would be appreciated if you could close this PR to keep the repository clear and focused.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants