Skip to main content

Module engine

Module engine 

Source
Expand description

The verifier card kernel: VERIFY_UNITS verify units, HBM, registers.

Status: interface only. The ports, the register map and the HBM layout below are fixed so the host tools can be written against them; the kernel body is being built (see super).

§Ports

PortDirectionCarries
s_axi_controlAXI4-Lite slavethe registers below
m_axi_records{u}AXI4 read masterunit u’s records
m_axi_verdicts{u}AXI4 write masterunit u’s verdict bytes

Both of unit u’s ports reach the same 1 GiB HBM group, HBM[4u:4u+3].

§HBM layout per unit

  • records{u}: count records of RECORD_BYTES, back to back, from a 4 KiB-aligned address.
  • verdicts{u}: count verdict bytes in record order, from a 64-byte aligned address, padded to whole 64-byte beats. The host zero-fills it; a written verdict always has bit 7 set.

Every unit verifies the same count records. The host gives each unit whole batches (all 128 records of a batch in a row), so a unit asks the Ed25519 core for at most one certificate check per 128 records.

§Register map (32-bit words)

OffsetNameAccess
0x000AP_CTRL: bit 0 ap_start, 1 ap_done (clear on read), 2 ap_idle, 3 ap_readyRW
0x004GIERW
0x008IER bit 0RW
0x00cISR bit 0 (write 1 to toggle)RW
0x010 + 0x10·uarg records{u} (u64)W
0x018 + 0x10·uarg verdicts{u} (u64)W
0x090arg count: records per unit (u32)W
0x098 + 4wargs key0..key7: trusted Ed25519 public key, bytes 4w..4w+4 little endianW
0x200MAGIC = MAGIC (“DSV1”)R
0x204ABI = ABI_VERSIONR
0x208SHAPE: units bits 0..8, lanes 8..12, log2 contexts 12..16, table mask 16..28R
0x20cFAULT: bit 0 read error, 1 write error, 2 Ed25519 core error, 3 key rejectedR
0x210/0x214TICKS lo (snapshots hi) / hiR
0x218/0x21cSTART_TICK lo/hiR
0x220/0x224DONE_TICK lo/hi: the last verdict write acknowledgedR
0x228/0x22cKEY_TICK lo/hi: the trusted key finished loadingR
0x230VALID: records verified valid, all unitsR
0x234CERT_CHECKS: Ed25519 verifications issuedR
0x238CERT_FAILS: Ed25519 verifications that failedR
0x240 + 4uRETIRED[u]: verdicts produced by unit uR

Arguments are accepted only while idle; a finished kernel stays done until reset (one run per reset), exactly as in crate::engine. The run is timed from START_TICK to DONE_TICK, which includes loading the trusted key into the Ed25519 core.

Structs§

ArItem
A read address on its way to HBM.
AwItem
A write address on its way to HBM.
BItem
A write response on its way back to a unit.
ClusterInput
Cluster inputs: the kernel’s plus the Ed25519 core’s outputs.
ClusterOutput
Cluster outputs: the kernel’s plus the Ed25519 core’s inputs.
EdCommand
What the cluster asks of the Ed25519 verify core.
EdStatus
What the cluster sees of the Ed25519 verify core.
RItem
A read beat on its way back to a unit.
UnitControl
What the cluster tells a unit (static during a run, latency tolerant).
UnitStatus
What a unit reports (counters, latency tolerant).
VerifyArgs
Host arguments.
VerifyCluster
Everything of the kernel except the Ed25519 core.
VerifyEngine
The verifier card kernel: VerifyCluster plus the Ed25519 verify core.
VerifyEngineInput
Kernel inputs.
VerifyEngineOutput
Kernel outputs.
WItem
A write beat on its way to HBM.

Constants§

ABI_VERSION
Register-map version of the verifier kernel.
ARG_COUNT
Offset of arg count.
ARG_KEY
Offset of arg key0; word w’s is + 4w.
ARG_RECORDS
Offset of arg records0; unit u’s is + 0x10·u.
ARG_VERDICTS
Offset of arg verdicts0; unit u’s is + 0x10·u.
MAGIC
MAGIC register value (“DSV1” in little-endian ASCII).
REG_ABI
Offset of ABI.
REG_CERT_CHECKS
Offset of CERT_CHECKS.
REG_CERT_FAILS
Offset of CERT_FAILS.
REG_DONE_TICK
Offset of DONE_TICK lo.
REG_FAULT
Offset of FAULT.
REG_KEY_TICK
Offset of KEY_TICK lo.
REG_MAGIC
Offset of MAGIC.
REG_RETIRED
Offset of RETIRED[0]; unit u’s is + 4u.
REG_SHAPE
Offset of SHAPE.
REG_START_TICK
Offset of START_TICK lo.
REG_TICKS
Offset of TICKS lo.
REG_VALID
Offset of VALID.

Functions§

verify_cluster_kernel
The cluster’s logic.
verify_engine_kernel
Wires the cluster to the Ed25519 core.
words64_kernel
Eight little-endian 64-bit words of 64 bytes.

Type Aliases§

CertCore
The Ed25519 verify core of the kernel: one verify machine, its own SHA-512 ring, one scalar ring (1,1,1,0), sized for one certificate check per 128 DSig verifications.