Repository navigation
Conversation
…ifetime_us) Two opt-in TX knobs, both off by default: - tx.data_on_be: DATA frames use the BE queue (QSEL 0) and its LOW bulk-OUT endpoint instead of MGMT (0x12, HIGH). A USB-aggregated URB never mixes DATA with other frames. - tx.ac_lifetime_us: the MAC drops a frame still queued after this long, retry chain included (REG_LIFETIME_EN 0x0426 bits 0..3, REG_PKT_LIFE_TIME 0x04C0, 256 us units). Without them an injected frame on MGMT retries until the retry limit no matter how old it is, so a peer that stops ACKing leaves seconds of stale frames queued. Scope: Jaguar1 on the RTL8812A with three bulk-OUT endpoints, the only part measured. The 8814A, 8821A and two-endpoint parts log that the knobs are not applied. src/AcTxQueue.h holds the register arithmetic, pinned by tests/ac_tx_queue_selftest.cpp. Measured, one 8812AU -> MT7612U, ch 100, near field, 500 fps of 1400 B at MCS4, retry 16, a peer that never ACKs: delivered age max 3.3 s stock, 68.8 ms at 68000 us, 21.0 ms at 20000 us (so the unit is 256 us; the vendor header names 128). Saturated MCS2, interleaved: stock 9.5 / 10.6 / 10.9 Mbit/s, knobs off 10.1 / 10.7, knobs on 11.6 / 11.8.
build_tx_block set BMC to a constant 1. The firmware echoes the bit into the CCX TX report (TxReport::bmc), so every unicast frame's report read as a group frame and a reader filtering group reports saw none. On the RTL8812A, BMC now follows addr1's group bit. The MAC takes its ACK decision from addr1 either way: delivery and retries were unchanged, and unicast reports appeared (0 -> about 7,000 per 7 s saturated run). The 8814A and 8821A keep the constant 1: they share this code but were not measured. This changes behaviour with no knob set, for RTL8812A users of TX reports.
Extends the RTL8812A AC lifetime (previous commit) to the RTL8822B and adds tx.be_fast_retry. - tx.data_on_be: DATA on BE (QSEL 0) and the LOW bulk-OUT endpoint; the endpoint follows the descriptor QSEL through the 3-endpoint TXDMA_PQ_MAP (BE/BK -> LOW, VI/VO -> NORMAL, the rest -> HIGH). A USB-aggregated URB never mixes DATA with other frames. - tx.ac_lifetime_us: the same halmac lifetime registers. - tx.be_fast_retry (new): clears the BE EDCA TXOP and pulls CWmax down to CWmin (REG_EDCA_BE_PARAM 0x0508), so a BE retry chain re-airs back to back as MGMT's does instead of doubling the window to 1023 slots. Jaguar1 logs that it ignores it: on the RTL8812A it cut saturated throughput. Scope: the 8822B with three bulk-OUT endpoints. The 8821C shares the code, was not measured, and logs that the knobs are not applied. Measured, one RTL8812BU -> MT7612U, ch 100, near field, 500 fps of 1400 B at MCS4, retry 16, a peer that never ACKs: delivered age max 1.18 s stock master and with the knobs off, 68.8 ms at 68000 us and 20.8 ms at 20000 us with all three on. Saturated MCS2 steady state 14.1-14.2 Mbit/s stock and knobs off, 13.0 with the knobs on.
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.
Draft, stacked on #600. This branch carries #600's two commits; the new work is the last commit,
06fcade(Jaguar2). It will be rebased after #600 merges.What
tx.data_on_beandtx.ac_lifetime_us.tx.be_fast_retry:REG_EDCA_BE_PARAM0x0508; AIFS and CWmin kept).All knobs default off. With them off, descriptors, endpoints and registers are unchanged.
Scope: only what we could verify
Evidence
One RTL8812BU sends to an MT7612U on channel 100, near field. Every arm ran on this branch. "Stock" is master
df65991.Peer hears but never ACKs (500 fps of 1400 B at MCS4, retry 16, 10 s):
ac_lifetime_us=68000ac_lifetime_us=20000Saturated MCS2, 7 s, interleaved, steady state:
Counterpart: with the knobs on, saturated throughput is about 8 % lower. The lifetime drops frames that queue past it, which is the point of the bound.
ctest: 94/94.
Not in this PR (for the maintainer)
TxQueueMap.h), so only the lifetime and fast retry would apply.🤖 Generated with Claude Code