From a66d1d9f871cff22ef0b754db1769cd9c67400b9 Mon Sep 17 00:00:00 2001 From: Paul Donahue Date: Tue, 10 Dec 2024 15:27:21 -0800 Subject: [PATCH 1/2] Fix typos --- src/ext-debug-triggers.adoc | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/ext-debug-triggers.adoc b/src/ext-debug-triggers.adoc index d77f608..2abf7ed 100644 --- a/src/ext-debug-triggers.adoc +++ b/src/ext-debug-triggers.adoc @@ -3,7 +3,7 @@ The RISC-V Sdtrig extension cite:[debug_v1_0] allows machine-mode software to directly configure debug triggers which in-turn allows native (or hosted) debugging in machine-mode without any external debugger. Unfortunately, the debug triggers are only accessible to -the machine-mode. +machine-mode. The SBI debug trigger extension defines a SBI based abstraction to provide native debugging for supervisor-mode software such that it is: @@ -38,7 +38,7 @@ trigger called `trig_state` which is encoded as shown in <= `trig_max`. |=== @@ -348,7 +348,7 @@ The possible error codes returned in `sbiret.error` are shown in |=== | Error code | Description | SBI_SUCCESS | Triggers enabled successfully. -| SBI_ERR_INVALID_PARAM | One of the debug trigger with index `trig_idx` in the specified +| SBI_ERR_INVALID_PARAM | One of the debug triggers with index `trig_idx` in the specified set of debug triggers either not mapped to any HW debug trigger OR has `trig_idx` >= `trig_max`. |=== @@ -376,7 +376,7 @@ The possible error codes returned in `sbiret.error` are shown in |=== | Error code | Description | SBI_SUCCESS | Triggers disabled successfully. -| SBI_ERR_INVALID_PARAM | One of the debug trigger with index `trig_idx` in the specified +| SBI_ERR_INVALID_PARAM | One of the debug triggers with index `trig_idx` in the specified set of debug triggers either not mapped to any HW debug trigger OR has `trig_idx` >= `trig_max`. |=== From 539c368cf39cc1df3afccac50566cd3b9b7b16c8 Mon Sep 17 00:00:00 2001 From: Paul Donahue Date: Tue, 10 Dec 2024 15:28:07 -0800 Subject: [PATCH 2/2] Clarify that all harts don't have one trig_max. Each has a separate trig_max. --- src/ext-debug-triggers.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ext-debug-triggers.adoc b/src/ext-debug-triggers.adoc index 2abf7ed..3d61c02 100644 --- a/src/ext-debug-triggers.adoc +++ b/src/ext-debug-triggers.adoc @@ -11,7 +11,7 @@ for supervisor-mode software such that it is: . Suitable for the rich operating systems and hypervisors running in supervisor-mode. . Allows Guest (VS-mode) and Hypervisor (HS-mode) to share debug triggers on a hart. -All harts on a RISC-V platform have a fixed number of debug triggers which is referred +Each hart on a RISC-V platform has a fixed number of debug triggers which is referred to as `trig_max` in this SBI extension. Each debug trigger is assigned a logical index called `trig_idx` by the SBI implementation where `-1 < trig_idx < trig_max`.