hstatus
Attributes
Defining Extension |
|
||||
---|---|---|---|---|---|
CSR Address |
0x600 |
||||
Length |
|
||||
Privilege Mode |
S |
Field Summary
Name | Location | Type | Reset Value | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
33:32 |
|
|
|||||||||||
22 |
RW |
UNDEFINED_LEGAL |
|||||||||||
21 |
RW |
UNDEFINED_LEGAL |
|||||||||||
20 |
RW |
UNDEFINED_LEGAL |
|||||||||||
17:12 |
|
UNDEFINED_LEGAL |
|||||||||||
9 |
RW |
UNDEFINED_LEGAL |
|||||||||||
8 |
RW |
UNDEFINED_LEGAL |
|||||||||||
7 |
RW |
UNDEFINED_LEGAL |
|||||||||||
6 |
RW |
UNDEFINED_LEGAL |
|||||||||||
5 |
|
|
Software write
This CSR may store a value that is different from what software attempts to write.
When a software write occurs (e.g., through csrrw), the following determines the written value:
VSXL = if (CSR[mstatus].SXL < csr_value.VSXL) { # cannot set VSXLEN less than SXLEN return UNDEFINED_LEGAL_DETERMINISTIC; } else if ((csr_value.VSXL & 0b10) != 0) { # MSB of VSXL represents XLEN > 64, which isn't legal return UNDEFINED_LEGAL_DETERMINISTIC; } else { return csr_value.VSXL; } VTSR = csr_value.VTSR VTW = csr_value.VTW VTVM = csr_value.VTVM VGEIN = if (csr_value.VGEIN <= NUM_EXTERNAL_GUEST_INTERRUPTS) { return csr_value.VGEIN; } else { return ILLEGAL_WLRL; } HU = csr_value.HU SPVP = csr_value.SPVP SPV = csr_value.SPV GVA = csr_value.GVA VSBE = csr_value.VSBE