|
| 1 | +# Copyright (c) Katherine Hsu |
| 2 | +# SPDX-License-Identifier: BSD-3-Clause-Clear |
| 3 | + |
| 4 | +# yaml-language-server: $schema=../../../schemas/csr_schema.json |
| 5 | + |
| 6 | +$schema: "csr_schema.json#" |
| 7 | +kind: csr |
| 8 | +name: tdata1 |
| 9 | +long_name: Trigger Data 1 |
| 10 | +address: 0x7A1 |
| 11 | +priv_mode: M |
| 12 | +length: XLEN |
| 13 | +writable: true |
| 14 | +description: | |
| 15 | + This register provides access to the trigger selected by `tselect`. |
| 16 | + The reset values listed here apply to every underlying trigger. |
| 17 | +
|
| 18 | + This register is optional if no triggers are implemented. |
| 19 | + Writing 0 to this register must result in a trigger that is disabled. |
| 20 | + If this trigger supports multiple types, then the hardware should disable it |
| 21 | + by changing type to 15. |
| 22 | +
|
| 23 | +definedBy: Sdtrig |
| 24 | +fields: |
| 25 | + TYPE: |
| 26 | + location_rv32: 31-28 |
| 27 | + location_rv64: 63-60 |
| 28 | + type: RW |
| 29 | + description: | |
| 30 | + 0 (none):: There is no trigger at this `tselect`. |
| 31 | + 1 (legacy):: The trigger is a legacy SiFive address match trigger. These should not be implemented and aren’t further documented here. |
| 32 | + 2 (mcontrol):: The trigger is an address/data match trigger. The remaining bits in this register act as described in `mcontrol`. |
| 33 | + 3 (icount):: The trigger is an instruction count trigger. The remaining bits in this register act as described in `icount`. |
| 34 | + 4 (itrigger):: The trigger is an interrupt trigger. The remaining bits in this register act as described in `itrigger`. |
| 35 | + 5 (etrigger):: The trigger is an exception trigger. The remaining bits in this register act as described in `etrigger`. |
| 36 | + 6 (mcontrol6):: The trigger is an address/data match trigger. The remaining bits in this register act as described in `mcontrol6`. This is similar to a type 2 trigger, but provides additional functionality and should be used instead of type 2 in newer implementations. |
| 37 | + 7 (tmexttrigger):: The trigger is a trigger source external to the TM. The remaining bits in this register act as described in `tmexttrigger`. |
| 38 | + 12—14 (custom):: These trigger types are available for non-standard use. |
| 39 | + 15 (disabled):: This trigger is disabled. In this state, `tdata2` and `tdata3` can be written with any value that is supported for any of the types this trigger implements. The remaining bits in this register, except for `DMODE`, are ignored. |
| 40 | +
|
| 41 | + Other values are reserved for future use. |
| 42 | + reset_value: UNDEFINED_LEGAL |
| 43 | + DMODE: |
| 44 | + location_rv32: 27 |
| 45 | + location_rv64: 59 |
| 46 | + type: RW |
| 47 | + description: | |
| 48 | + If type is 0, then this bit is hard-wired to 0. |
| 49 | +
|
| 50 | + 0 (both): Both Debug and M-mode can write the `tdata` registers at the selected `tselect`. |
| 51 | + 1 (dmode): Only Debug Mode can write the `tdata` registers at the selected `tselect`. Writes from other modes are ignored. |
| 52 | +
|
| 53 | + This bit is only writable from Debug Mode. In ordinary |
| 54 | + use, external debuggers will always set this bit when |
| 55 | + configuring a trigger. When clearing this bit, debuggers |
| 56 | + should also set the action field (whose location depends on |
| 57 | + type) to something other than 1. |
| 58 | + reset_value: 0 |
| 59 | + DATA: |
| 60 | + location_rv32: 26-0 |
| 61 | + location_rv64: 58-0 |
| 62 | + type: RW |
| 63 | + description: | |
| 64 | + If type is 0, then this field is hard-wired to 0. |
| 65 | + Trigger-specific data. |
| 66 | + reset_value: UNDEFINED_LEGAL |
0 commit comments