CSR Bit Fields

RISC-V mtopi CSR Register

Address 0xFB0Privilege MachineAccess MRO / MXLENMachine AIA, timer, and indirect interrupt CSRs

AIA machine top interrupt read-only report CSR for the highest-priority pending-and-enabled machine interrupt.

Bit Overview
bit 3 = only bit 3; bits 12..11 = bits 12 down to 11
MSBLSB
Reserved63:1MTOPI0MRO
Field Map

Understand mtopi By Bit Fields

1 key fields
MXLEN-1:0

MTOPI

MRO

mtopi fields as defined by AIA; detailed bit encoding follows the official AIA specification.

MTOPI (bits MXLEN-1:0) — mtopi fields as defined by AIA; detailed bit encoding follows the official AIA specification.

What This Field Controls

  • - mtopi fields as defined by AIA; detailed bit encoding follows the official AIA specification.

Common Values

mtopi report value
0No reportable interrupt

A read of mtopi returning 0 means there is no highest-priority pending-and-enabled machine interrupt currently reportable; nonzero values contain dynamic interrupt identity/priority information and should not be enumerated as fixed IDs.

Official Basis & Search Notes

AIA machine top interrupt read-only report CSR for the highest-priority pending-and-enabled machine interrupt.

The official AIA table lists mtopi at 0xFB0, with MRO access and MXLEN width.
mtopi reports the highest-priority pending-and-enabled interrupt for machine level.
This page avoids older generic trap/debug wording.

What To Check First When Reading This CSR

  • - Check mtopi address, access class, and width against the official AIA CSR table.
  • - Do not assign fixed meaning to reserved bits or unimplemented interrupt bits.

Risk Checks Before Writing

  • - mtopi is read-only; software should not write it.

Put It Back Into A Real Flow

1

Confirm that the hart implements AIA and the relevant component such as S-mode or IMSIC.

2

Read mtopi and interpret it according to the AIA definition for top interrupt.

3

Use only the listed official fields as portable facts; handle other bits according to the implementation and specification.

FAQ

Is mtopi a standard AIA CSR?

Yes. This page follows the address, access class, and width in the official AIA CSR table.

Can mtopi be written?

No. The official AIA table lists mtopi as MRO read-only; software should only read it and interpret the returned top-interrupt encoding.