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

how to clear stip bit in Smode #322

Closed
dangerblue opened this issue Dec 27, 2018 · 1 comment
Closed

how to clear stip bit in Smode #322

dangerblue opened this issue Dec 27, 2018 · 1 comment

Comments

@dangerblue
Copy link

Hi,
As in the description of stip, the Smode timer interrupt pending bit can only be set and clear by Mmode. In a linux system, the S mode timer interrupt will be delegate to S mode, but Smode does not have the permission clear the stip, that would make the system stuck in the timer interrupt servive program. so, what's the consideration of not giving the write permission to S mode

@aswaterman
Copy link
Member

In the normal use case, the timer-interrupt handler will schedule a new timer interrupt, which should clear STIP. In all other cases, it should suffice to clear STIE instead. You can see this thread for a more thorough discussion: riscv-software-src/riscv-pk#108

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

No branches or pull requests

2 participants