Registers

Summary

NameOffsetLengthDescription
acc.INTR_STATE0x04Interrupt State Register
acc.INTR_ENABLE0x44Interrupt Enable Register
acc.INTR_TEST0x84Interrupt Test Register
acc.ALERT_TEST0xc4Alert Test Register
acc.CMD0x104Command Register
acc.CTRL0x144Control Register
acc.STATUS0x184Status Register
acc.ERR_BITS0x1c4Operation Result Register
acc.FATAL_ALERT_CAUSE0x204Fatal Alert Cause Register
acc.INSN_CNT0x244Instruction Count Register
acc.LOAD_CHECKSUM0x284A 32-bit CRC checksum of data written to memory
acc.IMEM0x800032768Instruction Memory Access
acc.DMEM0x1800031744Data Memory Access

INTR_STATE

Interrupt State Register

  • Offset: 0x0
  • Reset default: 0x0
  • Reset mask: 0x1

Fields

{"reg": [{"name": "done", "bits": 1, "attr": ["rw1c"], "rotate": -90}, {"bits": 31}], "config": {"lanes": 1, "fontsize": 10, "vspace": 80}}
BitsTypeResetNameDescription
31:1Reserved
0rw1c0x0doneACC has completed the operation.

INTR_ENABLE

Interrupt Enable Register

  • Offset: 0x4
  • Reset default: 0x0
  • Reset mask: 0x1

Fields

{"reg": [{"name": "done", "bits": 1, "attr": ["rw"], "rotate": -90}, {"bits": 31}], "config": {"lanes": 1, "fontsize": 10, "vspace": 80}}
BitsTypeResetNameDescription
31:1Reserved
0rw0x0doneEnable interrupt when INTR_STATE.done is set.

INTR_TEST

Interrupt Test Register

  • Offset: 0x8
  • Reset default: 0x0
  • Reset mask: 0x1

Fields

{"reg": [{"name": "done", "bits": 1, "attr": ["wo"], "rotate": -90}, {"bits": 31}], "config": {"lanes": 1, "fontsize": 10, "vspace": 80}}
BitsTypeResetNameDescription
31:1Reserved
0wo0x0doneWrite 1 to force INTR_STATE.done to 1.

ALERT_TEST

Alert Test Register

  • Offset: 0xc
  • Reset default: 0x0
  • Reset mask: 0x3

Fields

{"reg": [{"name": "fatal", "bits": 1, "attr": ["wo"], "rotate": -90}, {"name": "recov", "bits": 1, "attr": ["wo"], "rotate": -90}, {"bits": 30}], "config": {"lanes": 1, "fontsize": 10, "vspace": 80}}
BitsTypeResetNameDescription
31:2Reserved
1wo0x0recovWrite 1 to trigger one alert event of this kind.
0wo0x0fatalWrite 1 to trigger one alert event of this kind.

CMD

Command Register

A command initiates an ACC operation. While performing the operation, ACC is busy; the STATUS register reflects that.

All operations signal their completion by raising the done interrupt; alternatively, software may poll the STATUS register.

Writes are ignored if ACC is not idle. Unrecognized commands are ignored.

  • Offset: 0x10
  • Reset default: 0x0
  • Reset mask: 0xff

Fields

{"reg": [{"name": "cmd", "bits": 8, "attr": ["wo"], "rotate": 0}, {"bits": 24}], "config": {"lanes": 1, "fontsize": 10, "vspace": 80}}
BitsTypeResetName
31:8Reserved
7:0wo0x0cmd

CMD . cmd

The operation to perform.

ValueNameDescription
0xd8EXECUTEStarts the execution of the program stored in the instruction memory, starting at address zero.
0xc3SEC_WIPE_DMEMSecurely removes all contents from the data memory.
0x1eSEC_WIPE_IMEMSecurely removes all contents from the instruction memory.

CTRL

Control Register

  • Offset: 0x14
  • Reset default: 0x0
  • Reset mask: 0x1

Fields

{"reg": [{"name": "software_errs_fatal", "bits": 1, "attr": ["rw"], "rotate": -90}, {"bits": 31}], "config": {"lanes": 1, "fontsize": 10, "vspace": 210}}
BitsTypeResetNameDescription
31:1Reserved
0rw0x0software_errs_fatalControls the reaction to software errors. When set software errors produce fatal errors, rather than recoverable errors. Writes are ignored if ACC is not idle.

STATUS

Status Register

  • Offset: 0x18
  • Reset default: 0x4
  • Reset mask: 0xff

Fields

{"reg": [{"name": "status", "bits": 8, "attr": ["ro"], "rotate": 0}, {"bits": 24}], "config": {"lanes": 1, "fontsize": 10, "vspace": 80}}
BitsTypeResetName
31:8Reserved
7:0ro0x4status

STATUS . status

Indicates the current operational state ACC is in.

All BUSY values represent an operation started by a write to the CMD register.

ValueNameDescription
0x00IDLEACC is idle: it is not performing any action.
0x01BUSY_EXECUTEACC is busy executing software.
0x02BUSY_SEC_WIPE_DMEMACC is busy securely wiping the data memory.
0x03BUSY_SEC_WIPE_IMEMACC is busy securely wiping the instruction memory.
0x04BUSY_SEC_WIPE_INTACC is busy securely wiping the internal state.
0xFFLOCKEDACC is locked as reaction to a fatal error, and must be reset to unlock it again. See also the section “Reaction to Fatal Errors”.

ERR_BITS

Operation Result Register

Describes the errors detected during an operation.

Refer to the “List of Errors” section for a detailed description of the errors.

The host CPU can clear this register when ACC is not running, by writing any value. Write attempts while ACC is running are ignored.

  • Offset: 0x1c
  • Reset default: 0x0
  • Reset mask: 0x1ff01ff

Fields

{"reg": [{"name": "bad_data_addr", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "bad_insn_addr", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "call_stack", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "illegal_insn", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "loop", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "key_invalid", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "rnd_rep_chk_fail", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "rnd_fips_chk_fail", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "kmac_recov_error", "bits": 1, "attr": ["rw"], "rotate": -90}, {"bits": 7}, {"name": "imem_intg_violation", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "dmem_intg_violation", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "reg_intg_violation", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "bus_intg_violation", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "bad_internal_state", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "illegal_bus_access", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "lifecycle_escalation", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "fatal_software", "bits": 1, "attr": ["rw"], "rotate": -90}, {"name": "kmac_fatal_error", "bits": 1, "attr": ["rw"], "rotate": -90}, {"bits": 7}], "config": {"lanes": 1, "fontsize": 10, "vspace": 220}}
BitsTypeResetNameDescription
31:25Reserved
24rw0x0kmac_fatal_errorA KMAC_FATAL_ERROR error was observed.“
23rw0x0fatal_softwareA FATAL_SOFTWARE error was observed.
22rw0x0lifecycle_escalationA LIFECYCLE_ESCALATION error was observed.
21rw0x0illegal_bus_accessAn ILLEGAL_BUS_ACCESS error was observed.
20rw0x0bad_internal_stateA BAD_INTERNAL_STATE error was observed.
19rw0x0bus_intg_violationA BUS_INTG_VIOLATION error was observed.
18rw0x0reg_intg_violationA REG_INTG_VIOLATION error was observed.
17rw0x0dmem_intg_violationA DMEM_INTG_VIOLATION error was observed.
16rw0x0imem_intg_violationA IMEM_INTG_VIOLATION error was observed.
15:9Reserved
8rw0x0kmac_recov_errorA “KMAC_RECOV_ERROR` recoverable error was observed.”
7rw0x0rnd_fips_chk_failAn RND_FIPS_CHK_FAIL error was observed.
6rw0x0rnd_rep_chk_failAn RND_REP_CHK_FAIL error was observed.
5rw0x0key_invalidA KEY_INVALID error was observed.
4rw0x0loopA LOOP error was observed.
3rw0x0illegal_insnAn ILLEGAL_INSN error was observed.
2rw0x0call_stackA CALL_STACK error was observed.
1rw0x0bad_insn_addrA BAD_INSN_ADDR error was observed.
0rw0x0bad_data_addrA BAD_DATA_ADDR error was observed.

FATAL_ALERT_CAUSE

Fatal Alert Cause Register

Describes any errors that led to a fatal alert. A fatal error puts ACC in locked state; the value of this register does not change until ACC is reset.

Refer to the “List of Errors” section for a detailed description of the errors.

  • Offset: 0x20
  • Reset default: 0x0
  • Reset mask: 0x1ff

Fields

{"reg": [{"name": "imem_intg_violation", "bits": 1, "attr": ["ro"], "rotate": -90}, {"name": "dmem_intg_violation", "bits": 1, "attr": ["ro"], "rotate": -90}, {"name": "reg_intg_violation", "bits": 1, "attr": ["ro"], "rotate": -90}, {"name": "bus_intg_violation", "bits": 1, "attr": ["ro"], "rotate": -90}, {"name": "bad_internal_state", "bits": 1, "attr": ["ro"], "rotate": -90}, {"name": "illegal_bus_access", "bits": 1, "attr": ["ro"], "rotate": -90}, {"name": "lifecycle_escalation", "bits": 1, "attr": ["ro"], "rotate": -90}, {"name": "fatal_software", "bits": 1, "attr": ["ro"], "rotate": -90}, {"name": "kmac_fatal_error", "bits": 1, "attr": ["ro"], "rotate": -90}, {"bits": 23}], "config": {"lanes": 1, "fontsize": 10, "vspace": 220}}
BitsTypeResetNameDescription
31:9Reserved
8ro0x0kmac_fatal_errorA KMAC_FATAL_ERROR error was observed.
7ro0x0fatal_softwareA FATAL_SOFTWARE error was observed.
6ro0x0lifecycle_escalationA LIFECYCLE_ESCALATION error was observed.
5ro0x0illegal_bus_accessA ILLEGAL_BUS_ACCESS error was observed.
4ro0x0bad_internal_stateA BAD_INTERNAL_STATE error was observed.
3ro0x0bus_intg_violationA BUS_INTG_VIOLATION error was observed.
2ro0x0reg_intg_violationA REG_INTG_VIOLATION error was observed.
1ro0x0dmem_intg_violationA DMEM_INTG_VIOLATION error was observed.
0ro0x0imem_intg_violationA IMEM_INTG_VIOLATION error was observed.

INSN_CNT

Instruction Count Register

Returns the number of instructions executed in the current or last operation. The counter saturates at 2^32-1 and is reset to 0 at the start of a new operation.

Only the EXECUTE operation counts instructions; for all other operations this register remains at 0. Instructions triggering an error do not count towards the total.

Always reads as 0 if ACC is locked.

The host CPU can clear this register when ACC is not running, by writing any value. Write attempts while ACC is running are ignored.

  • Offset: 0x24
  • Reset default: 0x0
  • Reset mask: 0xffffffff

Fields

{"reg": [{"name": "insn_cnt", "bits": 32, "attr": ["rw"], "rotate": 0}], "config": {"lanes": 1, "fontsize": 10, "vspace": 80}}
BitsTypeResetNameDescription
31:0rw0x0insn_cntThe number of executed instructions.

LOAD_CHECKSUM

A 32-bit CRC checksum of data written to memory

See the “Memory Load Integrity” section of the manual for full details.

  • Offset: 0x28
  • Reset default: 0x0
  • Reset mask: 0xffffffff

Fields

{"reg": [{"name": "checksum", "bits": 32, "attr": ["rw"], "rotate": 0}], "config": {"lanes": 1, "fontsize": 10, "vspace": 80}}
BitsTypeResetNameDescription
31:0rw0x0checksumChecksum accumulator

IMEM

Instruction Memory Access

The instruction memory may only be accessed through this window while ACC is idle.

If ACC is busy or locked, read accesses return 0 and write accesses are ignored. If ACC is busy, any access additionally triggers an ILLEGAL_BUS_ACCESS fatal error.

  • Word Aligned Offset Range: 0x8000to0xfffc
  • Size (words): 8192
  • Access: rw
  • Byte writes are not supported.

DMEM

Data Memory Access

The data memory may only be accessed through this window while ACC is idle.

If ACC is busy or locked, read accesses return 0 and write accesses are ignored. If ACC is busy, any access additionally triggers an ILLEGAL_BUS_ACCESS fatal error.

Note that DMEM is actually 4kiB in size, but only the first 3kiB of the memory is visible through this register interface.

  • Word Aligned Offset Range: 0x18000to0x1fbfc
  • Size (words): 7936
  • Access: rw
  • Byte writes are not supported.