Fix AxiStreamDmaV2Read byte-count handling and expand DMA v2 regression coverage#1388
Fix AxiStreamDmaV2Read byte-count handling and expand DMA v2 regression coverage#1388ruck314 merged 10 commits intopre-releasefrom
Conversation
- Added a new `genTKeep` function to handle `slv` input for terminal mask generation in `AxiStreamPkg.vhd`. - Updated `AxiStreamDmaV2Read` to utilize the new `genTKeep` function, improving the handling of read sizes. - Modified the test for `AxiStreamDmaV2Read` to cover both aligned 4-byte reads and short 3-byte terminal beats, ensuring accurate payload and descriptor checks. - Resolved known issues with `CONV_INTEGER` assertions in simulation, stabilizing the read path functionality.
There was a problem hiding this comment.
Pull request overview
This PR fixes a GHDL/runtime failure in the AXI-stream DMA v2 read path by avoiding problematic wide CONV_INTEGER conversions and by generating terminal-beat tKeep/tStrb masks directly from the byte-count slv. It also expands the DMA v2 cocotb regressions to cover additional read/write/mux/FIFO behaviors and removes the prior “expected failure” posture for the v2 read test.
Changes:
- Fix DMA v2 read terminal-beat masking by switching to a new
genTKeep(bytes : slv)overload and remove dependency on wide-slv-to-integer conversion inAxiStreamDmaV2Read. - Bound
totalBytesconversions inAxiPkg.getAxiLen*to avoid GHDL/std_logic_arithCONV_INTEGERfailures. - Expand and restructure DMA v2 Python/cocotb regression coverage across read, write, write-mux arbitration, and integrated FIFO register/pause-threshold behaviors.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
axi/axi-stream/rtl/AxiStreamPkg.vhd |
Adds genTKeep(bytes : slv) overload to generate keep masks without integer conversion. |
axi/dma/rtl/v2/AxiStreamDmaV2Read.vhd |
Uses the new genTKeep(slv) overload for terminal-beat tKeep/tStrb. |
axi/axi4/rtl/AxiPkg.vhd |
Bounds CONV_INTEGER conversions to burst-window slices to avoid GHDL failures. |
tests/axi/dma/test_AxiStreamDmaV2Read.py |
Converts read test from xfail smoke to passing aligned + short-terminal-beat cases and customizes sim build per case. |
tests/axi/dma/test_AxiStreamDmaV2Write.py |
Expands write regression to include single-frame and multi-burst scenarios with AW acceptance monitoring. |
tests/axi/dma/test_AxiStreamDmaV2WriteMux.py |
Adds mux arbitration ordering tests (descriptor-first, simultaneous, data-first) and expands parameter sweep. |
tests/axi/dma/test_AxiStreamDmaV2Fifo.py |
Expands FIFO bench to validate integrated register map and pause-threshold behavior. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Rename _build_vhdl_sources/_merge_vhdl_sources in tests/common/regression_utils.py to drop the underscore prefix so test modules can import them without reaching across a private-name boundary.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 8 out of 8 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Description
Fix the
AxiStreamDmaV2ReadGHDL/runtime failure by bounding the AXI byte-countCONV_INTEGERpaths and by generating terminal-beattKeep/tStrbmasks directly fromslvbyte counts. This also expands theaxi/dma/rtl/v2/regression split so the read, write, mux, and FIFO benches each own a distinct behavior surface without excessive overlap.Details
genTKeep(bytes : slv)overload inaxi/axi-stream/rtl/AxiStreamPkg.vhdand use it fromaxi/dma/rtl/v2/AxiStreamDmaV2Read.vhdso short terminal beats no longer depend on wide-slvto integer conversion.totalBytesconversions inaxi/axi4/rtl/AxiPkg.vhdto the burst-size window to avoid the GHDL/std_logic_arithCONV_INTEGERfailure that was abortingAxiStreamDmaV2Read.tests/axi/dma/test_AxiStreamDmaV2Read.pyfrom the prior expected-failure smoke into passing aligned and short-terminal-beat cases that check payload,tKeep,tDest,tId, observabletUser, and descriptor return behavior.tests/axi/dma/test_AxiStreamDmaV2Write.pyto cover both a stable single-frame write and a multi-burst write with accepted-AW address monitoring.tests/axi/dma/test_AxiStreamDmaV2WriteMux.pyto cover descriptor-first, simultaneous-launch, and in-flight data-first arbitration cases, including theACK_WAIT_BVALID_Gpath.tests/axi/dma/test_AxiStreamDmaV2Fifo.pyto cover the integrated FIFO register map and pause-threshold behavior against the live write-buffer count.AxiStreamDmaV2Readfrom the expected-open list and to document the currentv2DMA bench ownership split.Related