Skip to content

[src] Fix IBI ACK bug - #161

Closed
clayton8 wants to merge 2 commits into
chipsalliance:v1p5from
clayton8:ckuchta-fix-ibi-ack-issue-rx
Closed

clayton8 wants to merge 2 commits into
chipsalliance:v1p5from
clayton8:ckuchta-fix-ibi-ack-issue-rx

Conversation

@clayton8

@clayton8 clayton8 commented Mar 2, 2026

Copy link
Copy Markdown
Collaborator

When we do the following test sequence:

  1. IBI queued
  2. (before bus AVAIL) Controller initiates CCC
  3. I3C-Core sees "start" and transitions into RxFByteArb state

During this state both bus_rx_flow and bus_tx_flow are executing. If the I3C-Core wins arbitrations it transitions using the bus_tx_rsp_i.done signal into the IbiReadAck and will wait here to detect the ACK from the controller.

The problem is that that bus_rx_flow's DONE is flopped while the bus_tx_flow "DONE" is combinational and this causes the i3c_target_fsm to see a "stale" DONE from bus_rx_flow and if the I3C-Core's target address ends with a "1" the FSM sees "NACK" and immediately transitions into WaitRestart instead of properly waiting for the Controller's ACK/NACK

Remove invalid TB workaround.

Clayton Kuchta added 2 commits March 2, 2026 13:38
When we do the following test sequence:

1. IBI queued
2. (before bus AVAIL) Controller initiates CCC
3. I3C-Core sees "start" and transitions into RxFByteArb state

During this state both bus_rx_flow and bus_tx_flow are executing.
If the I3C-Core wins arbitrations it transitions using the
bus_tx_rsp_i.done signal into the IbiReadAck and will wait here to
detect the ACK from the controller.

The problem is that that bus_rx_flow's DONE is flopped while the bus_tx_flow
"DONE" is combinational and this causes the i3c_target_fsm to see a "stale"
DONE from bus_rx_flow and if the I3C-Core's target address ends with a "1"
the FSM sees "NACK" and immediately transitions into WaitRestart instead of
properly waiting for the Controller's ACK/NACK

Remove invalid TB workaround.
Two IBI tests had incorrect FW recovery sequences after retry
exhaustion. HW does NOT auto-flush descriptor_ibi on IbiFailureRetry;
FW must explicitly issue IBI_QUEUE_RST to clear stale data.

test_ibi_multiple_arb_losses:
- Add IBI_QUEUE_RST before IBI_RETRY_CTR_RST + fresh IBI queue
- Add missing teardown()

test_ibi_flush_from_idle_interrupt_flood:
- Rewrite to verify correct HW behavior: descriptor_ibi stays in
  WriteMdb after retry exhaustion (state 3, not Idle)
- Verify InhibitRetry prevents ibi_status_we_o flood (0 pulses)
- Test FW recovery: IBI_QUEUE_RST + IBI_RETRY_CTR_RST + fresh IBI
@clayton8

clayton8 commented Mar 3, 2026

Copy link
Copy Markdown
Collaborator Author

#162 is a better solution

@clayton8 clayton8 closed this Mar 3, 2026
@clayton8
clayton8 deleted the ckuchta-fix-ibi-ack-issue-rx branch March 3, 2026 23:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant