CSR Bit Fields

RISC-V seed CSR Register

Address 0x015Privilege Always M-mode; conditional U/S/HS access via mseccfg USEED/SSEEDAccess Read-write access (write value ignored) / 32User-level Zkr entropy CSR

seed (0x015) is Zkr's 32-bit unprivileged entropy-source CSR; results are polled only with a read-write CSR instruction.

Field Map

Understand seed By Bit Fields

4 key fields
31:30

OPST

Poll result

Status: BIST=00, WAIT=01, ES16=10, DEAD=11.

OPST (bits 31:30) — Status: BIST=00, WAIT=01, ES16=10, DEAD=11.

What This Field Controls

  • - Status: BIST=00, WAIT=01, ES16=10, DEAD=11.

Common Values

This field is better understood together with surrounding context than as a fixed memorized enumeration.

Open Official Manual
29:24

Reserved

Reserved

Reserved for future RISC-V specification use; an implementation may safely return zeros.

Reserved (bits 29:24) — Reserved for future RISC-V specification use; an implementation may safely return zeros.

What This Field Controls

  • - Reserved for future RISC-V specification use; an implementation may safely return zeros.

Common Values

This field is better understood together with surrounding context than as a fixed memorized enumeration.

Open Official Manual
23:16

Custom

Custom

Designated for custom and experimental use; an implementation may safely return zeros.

Custom (bits 23:16) — Designated for custom and experimental use; an implementation may safely return zeros.

What This Field Controls

  • - Designated for custom and experimental use; an implementation may safely return zeros.

Common Values

This field is better understood together with surrounding context than as a fixed memorized enumeration.

Open Official Manual
15:0

entropy

Poll result

Contains 16 bits of randomness only when OPST=ES16; it must be zero in other states.

entropy (bits 15:0) — Contains 16 bits of randomness only when OPST=ES16; it must be zero in other states.

What This Field Controls

  • - Contains 16 bits of randomness only when OPST=ES16; it must be zero in other states.

Common Values

This field is better understood together with surrounding context than as a fixed memorized enumeration.

Open Official Manual

What To Check First When Reading This CSR

  • - Read-only CSRRS/CSRRC forms (rs1=x0), including their immediate forms, raise an illegal-instruction exception.
  • - Outside M-mode, access must be explicitly granted; otherwise access raises an illegal-instruction exception.

Risk Checks Before Writing

  • - Any permitted CSR access ignores its write value; the write signals polling and flushing.
  • - Do not treat entropy as ordinary saved CSR state: successful polling is wipe-on-read.

Put It Back Into A Real Flow

1

Poll with csrrw rd, seed, x0.

2

Use entropy[15:0] only when OPST=ES16; otherwise retry or handle the reported state.