AMBA AXI · Module 17
Stuck VALID / Stuck READY
Diagnose an AXI channel hung on VALID or READY — the two stuck signatures, the decisive question of which side is waiting on which, the combinational VALID-depends-on-READY deadlock, the cross-channel dependency hang, and the systematic waveform-reading method that localizes a stuck handshake to its root cause.
Module 17 turns from building and verifying to debugging — diagnosing the failures the previous modules surface. The most common AXI failure is a hung channel: a handshake that never completes, with VALID or READY stuck and traffic frozen. It's also the most misdiagnosed, because the symptom (one signal stuck high) rarely sits at the cause (often the other side, or another channel entirely). This chapter teaches the systematic diagnosis: read the two stuck signatures, ask the one decisive question — which side is waiting on which? — and trace it to the real root cause, whether a combinational VALID-on-READY loop, a producer that never asserts VALID, a consumer that never asserts READY, or a cross-channel dependency. Get the method right and a hung bus, the scariest-looking failure, becomes one of the fastest to localize.
1. The Two Stuck Signatures
A stuck handshake presents in one of two ways, and naming which you're looking at is the first step. Stuck-VALID: a channel's VALID is asserted and stays high forever — the producer has data but the consumer never accepts it (READY never comes). Stuck-READY-low (or never-VALID): READY is low or VALID never asserts — nothing is offered or nothing is accepted. The transfer condition VALID && READY never becomes true, so the channel is frozen.
2. The Decisive Question: Who Waits on Whom?
The key to diagnosis is that AXI's handshake is asymmetric in dependency: READY is allowed to depend on VALID (a consumer may wait to see a request before asserting it can accept), but VALID must never depend combinationally on READY. So a stuck channel reduces to one question — which side is legitimately waiting, and which side has the bug?
3. The Combinational-Loop Deadlock
The classic fatal bug is the combinational loop: the slave asserts READY only when it sees VALID (legal), and the master asserts VALID only when it sees READY (illegal). Each waits for the other in the same cycle and neither ever moves. The waveform signature is unmistakable — both signals sit low forever with valid intent on both sides.
Combinational VALID-on-READY deadlock
8 cyclesThis is why the rule from Chapter 3.5 exists: VALID (and its payload) must be driven independently of READY. When debugging, if both signals are stuck low and each side claims it's "ready," look for the combinational dependency — it's the most common deadlock and the assertion a_*_progress / formal independence check from 16.2 catches it.
4. The Cross-Channel Dependency Hang
A subtler hang has nothing wrong with the stuck channel itself — it's frozen because another channel is blocked, and the protocol's dependency rules chain them. For example, a write B response can't be issued until the W data completes; if W is stuck (say its WREADY never comes because a downstream buffer is full), then B never comes either, and a naive look at the B channel sees "stuck" with the cause one or more channels away. Diagnosis must follow the dependency chain backward to the channel that's originally blocked.
// Debug instrumentation: per-channel "stuck" detection with a timeout watchdog.
// Flags a channel whose VALID has been high without READY for too long.
always_ff @(posedge aclk) begin
if (!aresetn) stuck_cnt <= 0;
else if (awvalid && !awready) stuck_cnt <= stuck_cnt + 1;
else stuck_cnt <= 0;
if (stuck_cnt > STUCK_LIMIT)
$error("AW stuck: VALID high, READY low for %0d cycles", stuck_cnt);
end
// Repeat per channel; the FIRST channel to trip points nearest the root cause.The watchdog per channel is the practical tool: when a hang occurs, the channel whose stuck-timer trips first (or the one furthest back in the dependency chain) is nearest the root cause — the others are downstream victims waiting on it.
Viewed as a tiny state machine, a healthy handshake cycles WAIT → OFFER → TRANSFER; a hang is the machine stuck in OFFER, looping on itself because the completion condition never arrives:
5. Common Misconceptions
6. Debugging Insight
7. Verification Insight
8. Interview Questions
9. Summary
A stuck AXI handshake — the most common and most misdiagnosed failure — presents in two signatures: stuck-VALID (VALID high, READY never comes → suspect the consumer) and never-VALID / stuck-READY-low (nothing offered or accepted → suspect the producer), with the transfer condition VALID && READY never satisfied. Diagnosis hinges on the decisive question — who waits on whom — answered by the protocol's dependency asymmetry: READY may legally depend on VALID, but VALID must never depend combinationally on READY. The classic fatal bug is the combinational loop (master holds VALID until READY, slave holds READY until VALID — both stuck low forever), fixed by driving VALID independently. A subtler cross-channel hang freezes a channel because another it depends on is blocked (e.g. B waits on a stuck W, which waits on a full buffer), requiring you to trace the dependency chain backward to the originally-blocked point.
The systematic method: signature → who-waits-on-whom → dependency direction → backward through channels → backpressure source. Because a stuck handshake is a liveness failure (a silent freeze with no error event), the discipline is to make it visible and localized with per-channel stuck-watchdogs (the first to trip is nearest the root) and the liveness/independence assertions from 16.2 (with combinational independence proven formally). The protocol's dependency graph turns a single blockage into a system-wide hang, so the real skill is finding the root of the dependency graph and checking for cycles — the stuck signals are mostly propagation. Next, we diagnose a related burst hang with a distinct cause: a missing WLAST/RLAST.
10. What Comes Next
You can now diagnose a hung handshake; next, a burst that hangs for a different reason:
- 17.2 — Missing LAST (coming next) — diagnosing a burst that never asserts
WLAST/RLAST, so the burst never ends and the response never comes — a hang with a beat-count root cause rather than a handshake one.
Previous: 16.9 — Using AXI VIP. Related: 3.5 — Handshake Dependency & Deadlock Rules for the dependency asymmetry this diagnosis rests on, 3.3 — Backpressure & Stalls for legal vs. stuck READY, and 16.2 — AXI Assertions (SVA) for the liveness assertions that catch a hang.