diff options
| author | Adrian Chadd <adrian@FreeBSD.org> | 2020-05-21 03:53:45 +0000 |
|---|---|---|
| committer | Adrian Chadd <adrian@FreeBSD.org> | 2020-05-21 03:53:45 +0000 |
| commit | 8af1445957d479ac48dff629c28c68ca679cab49 (patch) | |
| tree | 7dbe4500bab5642c33097421dd0f5b35a48f406a /sys/dev/ath | |
| parent | c0f34ded0b059b1c1fd9943684368cf87e08bff0 (diff) | |
Notes
Diffstat (limited to 'sys/dev/ath')
| -rw-r--r-- | sys/dev/ath/ath_rate/sample/sample.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/sys/dev/ath/ath_rate/sample/sample.c b/sys/dev/ath/ath_rate/sample/sample.c index 870e35033ca7d..d142ca2c34d66 100644 --- a/sys/dev/ath/ath_rate/sample/sample.c +++ b/sys/dev/ath/ath_rate/sample/sample.c @@ -165,6 +165,11 @@ static int ath_rate_sample_max_4ms_framelen[4][32] = { * MCS rate in the transmit schedule. * * Returns -1 if it's a legacy rate or no MRR. + * + * XXX TODO: this needs to be limited by the RTS/CTS AR5416 8KB bug limit! + * (by checking rts/cts flags and applying sc_rts_aggr_limit) + * + * XXX TODO: apply per-node max-ampdu size and driver ampdu size limits too. */ static int ath_rate_sample_find_min_pktlength(struct ath_softc *sc, @@ -693,6 +698,17 @@ ath_rate_findrate(struct ath_softc *sc, struct ath_node *an, if (sn->static_rix != -1) { rix = sn->static_rix; *try0 = ATH_TXMAXTRY; + + /* + * Ensure we limit max packet length here too! + */ + max_pkt_len = ath_rate_sample_find_min_pktlength(sc, an, + sn->static_rix, + is_aggr); + if (max_pkt_len > 0) { + *maxpktlen = frameLen = MIN(frameLen, max_pkt_len); + size_bin = size_to_bin(frameLen); + } goto done; } |
