Unverified Commit c22b105d authored by SLAMET RIANTO's avatar SLAMET RIANTO Committed by GitHub
Browse files

Fixes for illegal.S to support Bare-SMode and sbreak.S & scall.S to support CLIC mode. (#336)



illegal.S:
- After the test enters supervisor mode, check if paging is supported.
- If paging is NOT supported (i.e. Bare S-mode), jump to a new section of code that checks the following:
-- SFENCE.VMA causing illegal instruction trap regardless of TVM.
-- Access to SATP does not trap.
-- Jump to the same TSR check as regular S-mode
-- End test

sbreak.S & scall.S:
- Before checking for scause, check if the core is in CLIC-mode (mtvec[1]).
- If we're in CLIC-mode, mask off scause bits[(XLEN-1):8] before checing its value.
- Otherwise, don't mask off any scause bits as in the original test.

Co-authored-by: default avatarSlamet Rianto <slametr@gamma04.internal.sifive.com>
parent c9f43c16
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment