Skip to content

Commit d5fd7ff

Browse files
authored
List hardware-error exceptions in relevant tval text (riscv#2138)
1 parent b1d0256 commit d5fd7ff

File tree

2 files changed

+10
-6
lines changed

2 files changed

+10
-6
lines changed

src/machine.adoc

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1985,7 +1985,8 @@ If the hardware platform specifies that no exceptions set `mtval`
19851985
to a nonzero value, then `mtval` is read-only zero.
19861986

19871987
If `mtval` is written with a nonzero value when a breakpoint,
1988-
address-misaligned, access-fault, or page-fault exception occurs on an
1988+
address-misaligned, access-fault, page-fault, or hardware-error exception
1989+
occurs on an
19891990
instruction fetch, load, or store, then `mtval` will contain the
19901991
faulting virtual address.
19911992

@@ -2000,12 +2001,13 @@ include::images/bytefield/mtvalreg.edn[]
20002001

20012002

20022003
If `mtval` is written with a nonzero value when a misaligned load or
2003-
store causes an access-fault or page-fault exception, then `mtval` will
2004+
store causes an access-fault, page-fault, or hardware-error exception,
2005+
then `mtval` will
20042006
contain the virtual address of the portion of the access that caused the
20052007
fault.
20062008

20072009
If `mtval` is written with a nonzero value when an instruction
2008-
access-fault or page-fault exception occurs on a hart with
2010+
access-fault, page-fault, or hardware-error exception occurs on a hart with
20092011
variable-length instructions, then `mtval` will contain the virtual
20102012
address of the portion of the instruction that caused the fault, while
20112013
`mepc` will point to the beginning of the instruction.

src/supervisor.adoc

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -668,7 +668,8 @@ exhibit either behavior, depending on the underlying event that caused the
668668
exception.
669669

670670
If `stval` is written with a nonzero value when a breakpoint,
671-
address-misaligned, access-fault, or page-fault exception occurs on an
671+
address-misaligned, access-fault, page-fault, or hardware-error exception
672+
occurs on an
672673
instruction fetch, load, or store, then `stval` will contain the
673674
faulting virtual address.
674675

@@ -677,12 +678,13 @@ faulting virtual address.
677678
include::images/bytefield/stvalreg.edn[]
678679

679680
If `stval` is written with a nonzero value when a misaligned load or
680-
store causes an access-fault or page-fault exception, then `stval` will
681+
store causes an access-fault, page-fault, or hardware-error exception,
682+
then `stval` will
681683
contain the virtual address of the portion of the access that caused the
682684
fault.
683685

684686
If `stval` is written with a nonzero value when an instruction
685-
access-fault or page-fault exception occurs on a system with
687+
access-fault, page-fault, or hardware-error exception occurs on a hart with
686688
variable-length instructions, then `stval` will contain the virtual
687689
address of the portion of the instruction that caused the fault, while
688690
`sepc` will point to the beginning of the instruction.

0 commit comments

Comments
 (0)