Skip to content

Commit

Permalink
mt76: mt7915: fix bit fields for HT rate idx
Browse files Browse the repository at this point in the history
[ Upstream commit 47f1c08 ]

The bit fields of tx rate idx should be 6 bits, otherwise it might be
incorrect in HT mode.
For VHT/HE rates, only 4 bits are actually used by rate idx, the other
2 bits are used for other functions.

Fixes: c31d94a ("mt76: mt7915: fix tx rate related fields in tx descriptor")
Signed-off-by: Shayne Chen <shayne.chen@mediatek.com>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
csyuanc authored and gregkh committed Nov 17, 2021
1 parent b7282c7 commit d2697e6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/net/wireless/mediatek/mt76/mt7915/mac.h
Expand Up @@ -272,7 +272,8 @@ enum tx_mcu_port_q_idx {
#define MT_TX_RATE_MODE GENMASK(9, 6)
#define MT_TX_RATE_SU_EXT_TONE BIT(5)
#define MT_TX_RATE_DCM BIT(4)
#define MT_TX_RATE_IDX GENMASK(3, 0)
/* VHT/HE only use bits 0-3 */
#define MT_TX_RATE_IDX GENMASK(5, 0)

#define MT_TXP_MAX_BUF_NUM 6

Expand Down

0 comments on commit d2697e6

Please sign in to comment.