Preface
Introduction
RISC-V Hardware Platform Terminology
RISC-V Privileged Software Stack Terminology
Privilege Levels
Debug Mode
Control and Status Registers (CSRs)
CSR Address Mapping Conventions
CSR Listing
CSR Field Specifications
Machine-Level ISA, version 1.10
Machine-Level CSRs
Machine ISA Register misa
Machine Vendor ID Register mvendorid
Machine Architecture ID Register marchid
Machine Implementation ID Register mimpid
Hart ID Register mhartid
Machine Status Register (mstatus)
Privilege and Global Interrupt-Enable Stack in mstatus register
Base ISA Control in mstatus Register
Memory Privilege in mstatus Register
Virtualization Support in mstatus Register
Extension Context Status in mstatus Register
Machine Trap-Vector Base-Address Register (mtvec)
Machine Trap Delegation Registers (medeleg and mideleg)
Machine Interrupt Registers (mip and mie)
Machine Timer Registers (mtime and mtimecmp)
Hardware Performance Monitor
Counter-Enable Registers ([m|h|s]counteren)
Machine Scratch Register (mscratch)
Machine Exception Program Counter (mepc)
Machine Cause Register (mcause)
Machine Trap Value (mtval) Register
Machine-Mode Privileged Instructions
Environment Call and Breakpoint
Trap-Return Instructions
Wait for Interrupt
Reset
Non-Maskable Interrupts
Physical Memory Attributes
Main Memory versus I/O versus Empty Regions
Supported Access Type PMAs
Atomicity PMAs
Memory-Ordering PMAs
Coherence and Cacheability PMAs
Idempotency PMAs
Physical Memory Protection
Physical Memory Protection CSRs
Supervisor-Level ISA, Version 1.10
Supervisor CSRs
Supervisor Status Register (sstatus)
Base ISA Control in sstatus Register
Memory Privilege in sstatus Register
Supervisor Trap Vector Base Address Register (stvec)
Supervisor Interrupt Registers (sip and sie)
Supervisor Timers and Performance Counters
Counter-Enable Register (scounteren)
Supervisor Scratch Register (sscratch)
Supervisor Exception Program Counter (sepc)
Supervisor Cause Register (scause)
Supervisor Trap Value (stval) Register
Supervisor Address Translation and Protection (satp) Register
Supervisor Instructions
Supervisor Memory-Management Fence Instruction
Sv32: Page-Based 32-bit Virtual-Memory Systems
Addressing and Memory Protection
Virtual Address Translation Process
Sv39: Page-Based 39-bit Virtual-Memory System
Addressing and Memory Protection
Sv48: Page-Based 48-bit Virtual-Memory System
Addressing and Memory Protection
Hypervisor Extensions, Version 0.0
RISC-V Privileged Instruction Set Listings
Platform-Level Interrupt Controller (PLIC)
PLIC Overview
Interrupt Sources
Local Interrupt Sources
Global Interrupt Sources
Interrupt Targets and Hart Contexts
Interrupt Gateways
Interrupt Identifiers (IDs)
Interrupt Priorities
Interrupt Enables
Interrupt Priority Thresholds
Interrupt Notifications
Interrupt Claims
Interrupt Completion
Interrupt Flow
PLIC Core Specification
Controlling Access to the PLIC
Machine Configuration Description
Configuration String Search Procedure
History
Research Funding at UC Berkeley