From patchwork Fri Dec 29 02:00:00 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mingyen Hsieh X-Patchwork-Id: 13506277 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E3643C3DA6E for ; Fri, 29 Dec 2023 02:10:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Type:MIME-Version: References:In-Reply-To:Message-ID:Date:Subject:CC:To:From:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=zDWDn9oBv1U+3xvwbXPmm8vBhm6pjyap2Yx2ddY1yCs=; b=au3b46HLmC/d8PFDxMY67Uz0xW w2miepb+HzWEAk1DdkMiMeuF2nBsz0w16BH/gFwiqfKggefz2nN2y6oUXNm+xCeCSlyJUjht15fqM +ftEfjYVWR54TjQ3Ug6lrVrlYCMV+8mDtlnyxH9xIEV67nMtfx7qqKyMh8M/couKHTLgXS26fbXfB GBWwFwvKe7Y7/6+HRrsnWwFhVrbJ198xQxWGw+/T7ABr3TF7yDCUSU8lEQ/cd7OyyZZzNfs5k6bmY UmmOikxNItuQloBOeEj/mDucLR1xhfBcPvRKuxwCNjxy+RbcA2NmlvrgAkhYzF5HxY47cNtCYMhaa bwqIbY1A==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1rJ2KT-00053M-00; Fri, 29 Dec 2023 02:10:29 +0000 Received: from mailgw02.mediatek.com ([216.200.240.185]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1rJ2KQ-000532-1o for linux-mediatek@lists.infradead.org; Fri, 29 Dec 2023 02:10:27 +0000 X-UUID: 6967c6eca5ef11ee9a662f17bb45267e-20231228 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:CC:To:From; bh=zDWDn9oBv1U+3xvwbXPmm8vBhm6pjyap2Yx2ddY1yCs=; b=KnBdZQR2/1Uk7XrXBlcMDyDW8M5gT7ocT9iB91Z3S4RCcfMeLxqbzPfSx7JX6du6mL7lAlZD5hHgdd58GXzahU2aF3WSg7drGgd+xr0vbiedFMZCJu30aiZbWl+1DrXwu20OGH2tMGVCotJpYfs69T4dds+BvZFvM0M5JlbYAvg=; X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.35,REQID:ecb51173-6498-450f-a350-0a46ce96d379,IP:0,U RL:0,TC:0,Content:0,EDM:0,RT:0,SF:0,FILE:0,BULK:0,RULE:Release_Ham,ACTION: release,TS:0 X-CID-META: VersionHash:5d391d7,CLOUDID:b05d4882-8d4f-477b-89d2-1e3bdbef96d1,B ulkID:nil,BulkQuantity:0,Recheck:0,SF:102,TC:nil,Content:0,EDM:-3,IP:nil,U RL:0,File:nil,Bulk:nil,QS:nil,BEC:nil,COL:0,OSI:0,OSA:0,AV:0,LES:1,SPR:NO, DKR:0,DKP:0,BRR:0,BRE:0 X-CID-BVR: 0 X-CID-BAS: 0,_,0,_ X-CID-FACTOR: TF_CID_SPAM_SNR X-UUID: 6967c6eca5ef11ee9a662f17bb45267e-20231228 Received: from mtkmbs11n1.mediatek.inc [(172.21.101.185)] by mailgw02.mediatek.com (envelope-from ) (musrelay.mediatek.com ESMTP with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 1680827508; Thu, 28 Dec 2023 19:10:17 -0700 Received: from mtkmbs11n1.mediatek.inc (172.21.101.185) by mtkmbs13n2.mediatek.inc (172.21.101.108) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.26; Fri, 29 Dec 2023 10:00:15 +0800 Received: from mtksdccf07.mediatek.inc (172.21.84.99) by mtkmbs11n1.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.2.1118.26 via Frontend Transport; Fri, 29 Dec 2023 10:00:15 +0800 From: Mingyen Hsieh To: , CC: , , , , , , , , , , , , , , Ming Yen Hsieh Subject: [PATCH v1 01/10] wifi: mt76: mt7925: fix connect to 80211b mode fail in 2Ghz band Date: Fri, 29 Dec 2023 10:00:00 +0800 Message-ID: <20231229020009.12385-2-mingyen.hsieh@mediatek.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20231229020009.12385-1-mingyen.hsieh@mediatek.com> References: <20231229020009.12385-1-mingyen.hsieh@mediatek.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231228_181026_612934_48802090 X-CRM114-Status: UNSURE ( 8.99 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+linux-mediatek=archiver.kernel.org@lists.infradead.org From: Ming Yen Hsieh Driver should setting correct phy mode to firmware when in legacy mode. Fixes: c948b5da6bbe ("wifi: mt76: mt7925: add Mediatek Wi-Fi7 driver for mt7925 chips") Signed-off-by: Ming Yen Hsieh --- drivers/net/wireless/mediatek/mt76/mt7925/mcu.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/net/wireless/mediatek/mt76/mt7925/mcu.c b/drivers/net/wireless/mediatek/mt76/mt7925/mcu.c index c5fd7116929b..1fc9ecb96bc4 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7925/mcu.c +++ b/drivers/net/wireless/mediatek/mt76/mt7925/mcu.c @@ -1460,12 +1460,10 @@ mt7925_mcu_sta_phy_tlv(struct sk_buff *skb, struct tlv *tlv; u8 af = 0, mm = 0; - if (!sta->deflink.ht_cap.ht_supported && !sta->deflink.he_6ghz_capa.capa) - return; - tlv = mt76_connac_mcu_add_tlv(skb, STA_REC_PHY, sizeof(*phy)); phy = (struct sta_rec_phy *)tlv; phy->phy_type = mt76_connac_get_phy_mode_v2(mvif->phy->mt76, vif, chandef->chan->band, sta); + phy->basic_rate = cpu_to_le16((u16)vif->bss_conf.basic_rates); if (sta->deflink.ht_cap.ht_supported) { af = sta->deflink.ht_cap.ampdu_factor; mm = sta->deflink.ht_cap.ampdu_density;