Skip to content

Conversation

@ayosher
Copy link
Collaborator

@ayosher ayosher commented Apr 2, 2025

Add support for Smdbltrp (MDT bit) and MPRV bit

@ayosher ayosher requested a review from dhower-qc as a code owner April 2, 2025 11:09
Copy link
Collaborator

@ThinkOpenly ThinkOpenly left a comment

Choose a reason for hiding this comment

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

One area of this project we're trying to improve is the commit messages. I'd appreciate it (and it would certainly help me review an area with which I'm not familiar) if the commit message included:

  • description of the issue with the current code
  • explanation of what was changed, and how that fixes the issue

…t) and MPRV bit

Before his fix IDL code reset mstatus.MPRV bit only in case if S mode
is implemented for both mret and mnret. This seems wrong, since spec
states that MPRV should be reset by both mret and mnret for case when
mode processor is returning is different from Machine mode (2b'11).
As well, Smdbltrp spec requires that such case (returning to non-machine
mode), the mnret instruction should reset MDT bit.
According to the spec mnret instruction should set mnstatus.NMIE=1.
Also, mnret should use mnstatus.MNPP bit field for previous mode
storage.

Signed-off-by: Albert Yosher <[email protected]>
…i and Smdbltrp extensions documentation

Signed-off-by: Albert Yosher <[email protected]>
@ayosher
Copy link
Collaborator Author

ayosher commented Apr 3, 2025

@ThinkOpenly , Please review updated changes and approve them if you thing that I did the requested changes.

@dhower-qc dhower-qc added this pull request to the merge queue Apr 8, 2025
Merged via the queue into main with commit 2d33a6d Apr 8, 2025
14 checks passed
@dhower-qc dhower-qc deleted the fix_mret_mnret branch April 8, 2025 14:06
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.

4 participants