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

Fix missing parametrization of H-extension in CSR register file #50

Closed
wants to merge 1 commit into from

Conversation

ezelioli
Copy link

The write logic of some FPU CSRs is unconditionally relying on virtualization specific signals.

For me this caused OpenSBI >=0.9 to hang due to an unexpected invalid instruction exception when trying to set the FCSR register to zero. The error is triggered only if you disable the Hypervisor extension. I did not observe this issue when synthesizing for FPGA (on Cheshire platform, GenesysII target), it only triggered in simulation using Questasim 2022.3.

Note that this issue does not appear upstream in the version that was merged into master. Not sure if we are planning further rebasing on upstream after merging of Hypervisor extension. It can still be worth to patch in my opinion since it prevents Linux boot.

@ezelioli ezelioli requested a review from niwis as a code owner April 22, 2024 20:27
@niwis
Copy link
Collaborator

niwis commented Apr 23, 2024

Thank you @ezelioli! This sounds nasty. I think it is already being handled in #43, can you confirm? Didn't think it would prevent Linux boot...

@ezelioli
Copy link
Author

Thank you @ezelioli! This sounds nasty. I think it is already being handled in #43, can you confirm? Didn't think it would prevent Linux boot...

Yes, I confirm it is the same problem.
Sorry for the double PR :)

@niwis
Copy link
Collaborator

niwis commented Apr 23, 2024

No worries! Merged in #51.

@niwis niwis closed this Apr 23, 2024
@niwis niwis deleted the ezelioli/rvh-fix branch April 23, 2024 13:50
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