AXI Bus Protocol
Overview
The AXI (Advanced eXtensible Interface) bus protocol is a point-to-point on-chip interconnect standard used to connect processing elements to memory and control resources. In the TaPaFuzz framework, AXI is used to wire the CVA5 RISC-V core to the BRAM-based instruction, data, and result memories, as well as to provide PE control and optional DRAM access.
AXI in the TaPaFuzz Processing Element
The Fuzzer Processing Element (PE) in TaPaFuzz exposes two AXI slave ports and one optional AXI master port [1]:
- S_AXI_CTRL: enables PE control, e.g., reset and restart, and provides status information on request.
- S_AXI_BRAM: allows writing into the PE's instruction, data, and fuzzing-result memories.
- Optional M_AXI master port: when connected to an AXI-DRAM controller, it replaces or extends the BRAM-based instruction and data memories needed for larger, possibly non-IoT, targets.
The CVA5 RISC-V processor connects to downstream memory via an AXI4 memory bus, with the AXI Reset Wrapper shim module placed between the core and this AXI4 bus [2].
Transaction Model
AXI uses independent VALID/READY handshake channels for write address, write data, write response, read address, and read data phases. Transactions consist of bursts composed of multiple beats. The AXI Reset Wrapper maintains counters for in-flight requests and the remaining number of beats in a write transaction, and keeps a registered copy of each handshake from the core [2].
Reset Behavior and the AXI Reset Wrapper
A naive core reset could leave outstanding AXI transactions incomplete, which can lock up the downstream bus. To prevent this, the AXI Reset Wrapper shim intervenes on a synchronous local core reset by [2]:
- Stabilizing pending handshakes from the core using the registered copies until accepted by the bus, to match the AXI specification.
- Completing outstanding write bursts by sending write beats with all bytes disabled (wstrb ← 0) matching each outstanding burst's length.
- Waiting for response handshakes — final read beats and write responses — to arrive from the bus before notifying the fuzzing controller that the bus is stable and the core reset can be released.
While the core operates normally, the wrapper combinationally passes through the AXI signals and keeps a registered copy of each handshake from the core [2].
Stalling and Overflow Protection
The wrapper stalls write handshakes only if the burst-length FIFO or an in-flight access counter would overflow. For the CVA5 core, such stalling does not occur in practice because the core sends all write beats before starting the next burst [2].
Portability Assumptions Beyond the AXI Standard
The shim module is designed to be portable across different cores or other AXI components and makes only a few assumptions beyond the AXI standard [2]:
- The core never issues handshakes for write beats (data) before the write burst request (address, length).
- No more than a configurable number of in-flight read requests (default 15) are sent by the core and accepted by the downstream bus.
Role in the System
- TaPaFuzz (Tool) — uses the AXI bus protocol as the interconnect backbone for its Fuzzer Processing Elements, enabling memory and control access for RISC-V IoT graybox fuzzing.
- AXI Reset Wrapper (Code Artifact) — implements a shim that completes in-flight AXI4 transactions on core reset to keep the bus stable.
References
- Meisel, D. Volz, C. Spang, D. Tran, A. Koch, "TaPaFuzz - An FPGA-Accelerated Framework for RISC-V IoT Graybox Fuzzing," 2023 DASIP workshop. https://www.esa.informatik.tu-darmstadt.de/assets/publications/materials/2023/2023_DASIP_FM.pdf