The code was accidentally shifting register values down by tid % 32 instead of
(tid * field_size) % 32.
Cc: [email protected]
Fixes: a28bef561a5c ("mt76: mt7615: re-enable offloading of sequence number assignment")
Signed-off-by: Felix Fietkau <[email protected]>
---
drivers/net/wireless/mediatek/mt76/mt7615/mac.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/mac.c b/drivers/net/wireless/mediatek/mt76/mt7615/mac.c
index ad6c7d632eed..d6aae60c440d 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7615/mac.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7615/mac.c
@@ -1088,7 +1088,7 @@ u32 mt7615_mac_get_sta_tid_sn(struct mt7615_dev *dev, int wcid, u8 tid)
offset %= 32;
val = mt76_rr(dev, addr);
- val >>= (tid % 32);
+ val >>= offset;
if (offset > 20) {
addr += 4;
--
2.36.1
Felix Fietkau <[email protected]> writes:
> The code was accidentally shifting register values down by tid % 32 instead of
> (tid * field_size) % 32.
>
> Cc: [email protected]
> Fixes: a28bef561a5c ("mt76: mt7615: re-enable offloading of sequence number assignment")
> Signed-off-by: Felix Fietkau <[email protected]>
I assigned this to myself on patchwork and I'll queue this for v6.0.
--
https://patchwork.kernel.org/project/linux-wireless/list/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
Felix Fietkau <[email protected]> wrote:
> The code was accidentally shifting register values down by tid % 32 instead of
> (tid * field_size) % 32.
>
> Cc: [email protected]
> Fixes: a28bef561a5c ("mt76: mt7615: re-enable offloading of sequence number assignment")
> Signed-off-by: Felix Fietkau <[email protected]>
Patch applied to wireless.git, thanks.
c3a510e2b537 wifi: mt76: fix reading current per-tid starting sequence number for aggregation
--
https://patchwork.kernel.org/project/linux-wireless/patch/[email protected]/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches