a4091: clear FIFOs on CTEST8.CLF strobe#157
Open
codewiz wants to merge 1 commit into
Open
Conversation
A write to CTEST8 with the CLF bit (0x04) drains both the DMA FIFO (all four lanes) and the SCSI FIFO. The strobe is self-clearing, so the bit never latches in the register file. Mirrors the 53C710 behavior ported into Amiberry (qemuvga/lsi53c710.cpp). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Contributor
Author
|
@codex review |
Contributor
Author
|
Why were the checks canceled? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A write to the 53C710 CTEST8 register with the CLF bit (0x04) drains
both FIFOs: the DMA FIFO (all four lanes) and the SCSI FIFO. The bit is
a self-clearing strobe, so it never latches in the register file (the
read path already masks it off; this makes the stored value agree).
This matches the datasheet semantics and the equivalent behavior in the
53C710 model I ported into Amiberry's
qemuvga/lsi53c710.cpp. Note theAmiberry side only zeroes its SCSI FIFO count because its DMA FIFO uses
a separate byte-count model; here both FIFOs are explicit, so both are
cleared.
Adds
ctest8_clf_drains_both_fifos: fills every DMA lane and the SCSIFIFO, strobes CLF, then verifies CTEST1 reads all-lanes-empty, the
SSTAT2 count is zero, and the CLF bit reads back clear. All 17 a4091
tests pass.
🤖 Generated with Claude Code