From patchwork Thu Jan 6 06:20:56 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Chiu X-Patchwork-Id: 530667 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6FD71C433F5 for ; Thu, 6 Jan 2022 06:21:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234718AbiAFGV3 (ORCPT ); Thu, 6 Jan 2022 01:21:29 -0500 Received: from mailgw01.mediatek.com ([60.244.123.138]:36112 "EHLO mailgw01.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S229890AbiAFGV3 (ORCPT ); Thu, 6 Jan 2022 01:21:29 -0500 X-UUID: 3a897a5a89024a19952a4fd16c3b0af9-20220106 X-UUID: 3a897a5a89024a19952a4fd16c3b0af9-20220106 Received: from mtkcas10.mediatek.inc [(172.21.101.39)] by mailgw01.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-SHA384 256/256) with ESMTP id 1075290722; Thu, 06 Jan 2022 14:21:26 +0800 Received: from mtkcas10.mediatek.inc (172.21.101.39) by mtkmbs10n1.mediatek.inc (172.21.101.34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.2.792.15; Thu, 6 Jan 2022 14:21:25 +0800 Received: from mtksdccf07.mediatek.inc (172.21.84.99) by mtkcas10.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Thu, 6 Jan 2022 14:21:25 +0800 From: Peter Chiu To: Felix Fietkau CC: Lorenzo Bianconi , Ryder Lee , Evelyn Tsai , Shayne Chen , Deren Wu , , , "Peter Chiu" Subject: [PATCH 1/2] mt76: mt7915: fix ht mcs in mt7915_mac_add_txs_skb() Date: Thu, 6 Jan 2022 14:20:56 +0800 Message-ID: <20220106062057.14981-1-chui-hao.chiu@mediatek.com> X-Mailer: git-send-email 2.18.0 MIME-Version: 1.0 X-MTK: N Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org The mcs value of HT mode reported by mt7915_mac_add_txs_skb() has already been converted to the expected format. Fixes: 9908d98ae72cd ("mt76: mt7915: report tx rate directly from tx status") Signed-off-by: Peter Chiu --- drivers/net/wireless/mediatek/mt76/mt7915/mac.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/net/wireless/mediatek/mt76/mt7915/mac.c b/drivers/net/wireless/mediatek/mt76/mt7915/mac.c index a6770fd40b34..5368a3e276c7 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7915/mac.c +++ b/drivers/net/wireless/mediatek/mt76/mt7915/mac.c @@ -1568,7 +1568,6 @@ mt7915_mac_add_txs_skb(struct mt7915_dev *dev, struct mt76_wcid *wcid, int pid, break; case MT_PHY_TYPE_HT: case MT_PHY_TYPE_HT_GF: - rate.mcs += (rate.nss - 1) * 8; if (rate.mcs > 31) goto out; From patchwork Thu Jan 6 06:20:57 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Chiu X-Patchwork-Id: 530451 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0A508C433EF for ; Thu, 6 Jan 2022 06:21:32 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234728AbiAFGVb (ORCPT ); Thu, 6 Jan 2022 01:21:31 -0500 Received: from mailgw02.mediatek.com ([210.61.82.184]:40108 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S229890AbiAFGVa (ORCPT ); Thu, 6 Jan 2022 01:21:30 -0500 X-UUID: 319448747c2145d7a74f31e3f11373b4-20220106 X-UUID: 319448747c2145d7a74f31e3f11373b4-20220106 Received: from mtkmbs10n2.mediatek.inc [(172.21.101.183)] by mailgw02.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 1157554274; Thu, 06 Jan 2022 14:21:26 +0800 Received: from mtkcas10.mediatek.inc (172.21.101.39) by mtkmbs10n2.mediatek.inc (172.21.101.183) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.2.792.3; Thu, 6 Jan 2022 14:21:25 +0800 Received: from mtksdccf07.mediatek.inc (172.21.84.99) by mtkcas10.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Thu, 6 Jan 2022 14:21:25 +0800 From: Peter Chiu To: Felix Fietkau CC: Lorenzo Bianconi , Ryder Lee , Evelyn Tsai , Shayne Chen , Deren Wu , , , "Peter Chiu" Subject: [PATCH 2/2] mt76: mt7921: fix ht mcs in mt7921_mac_add_txs_skb() Date: Thu, 6 Jan 2022 14:20:57 +0800 Message-ID: <20220106062057.14981-2-chui-hao.chiu@mediatek.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20220106062057.14981-1-chui-hao.chiu@mediatek.com> References: <20220106062057.14981-1-chui-hao.chiu@mediatek.com> MIME-Version: 1.0 X-MTK: N Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org The mcs value of HT mode reported by mt7921_mac_add_txs_skb() has already been converted to the expected format. Fixes: 970ab80ef9f63 ("mt76: mt7921: report tx rate directly from tx status") Signed-off-by: Peter Chiu --- drivers/net/wireless/mediatek/mt76/mt7921/mac.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/net/wireless/mediatek/mt76/mt7921/mac.c b/drivers/net/wireless/mediatek/mt76/mt7921/mac.c index 0744f6e42ba3..cc070180fdc0 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7921/mac.c +++ b/drivers/net/wireless/mediatek/mt76/mt7921/mac.c @@ -1092,7 +1092,6 @@ mt7921_mac_add_txs_skb(struct mt7921_dev *dev, struct mt76_wcid *wcid, int pid, break; case MT_PHY_TYPE_HT: case MT_PHY_TYPE_HT_GF: - rate.mcs += (rate.nss - 1) * 8; if (rate.mcs > 31) goto out;