Received: by 2002:a05:7412:251c:b0:e2:908c:2ebd with SMTP id w28csp1308951rda; Mon, 23 Oct 2023 08:42:39 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFuuRt3E2kS1vN4tMCMpO9aE+lKhk19U6MVUQ4jQKxOigU1vkAWkJ2MM7jGSGrYlWeqOMqI X-Received: by 2002:a05:6a20:a110:b0:17b:9675:23fa with SMTP id q16-20020a056a20a11000b0017b967523famr15864494pzk.24.1698075759556; Mon, 23 Oct 2023 08:42:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698075759; cv=none; d=google.com; s=arc-20160816; b=OEPfRQJVoDcIbI09tD2rX8fH+oezW35GcHuiUf7nh1DBghpB5vTcdS3dhNWWnOpEWk c3UoYYHlKPtCTuaa0crfcK1m+58CAOLn4gjRM0l3pbyYp8ogl0PSoLNz73+zySXXKZpw c9R7lb5twFDpF4huSm5MlClpcVAoGa6An8emveiJyA7qMyZnp/1X3pLR4436wifOVv/Q QWyRA9n9UEWIT9LYZe9aDp1wOM4QLWI+N7gKGJAApl4b+SUIOMqSmfw7cMpTdHlnBd2f W7uTuGNwUcKkdw5rxBygASK8UVvplSAacrdGQjVULMqd9LzYlf925uou9FKXPQ7aMIKv bfJQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=OODFBrWD2YdHLIMaPxgPkoQe+YPeSqhhGASu78652zg=; fh=v3dOfuOAnI8WFKYqUeZ+0g4wDuhfewuLkZmMqWANXmc=; b=OgwHaUGjpKy6JkhtERfGVyEwq6u3ZiOnLj1pD7Yqy9onmjdhCmIujTseUlDKTHcJ0E Zh6kueqLhn29XTwyiP4WKbyryEzfjmUXhpIXCBuErn3m46olihqEryqX4Oeyfra0UYI8 43CM22AO5T3/F5cO53wRpl4NQIGsz3ozxfwHUHhnEElAxJ6VzH/c5awHnTBJ7YGI3feW gVEkjDShlYZOW5yztmP6wqO1wAK1tmCAJup2YG6Ilw6JSc64DPgqqC3z66sH6ztQ4tNa B3STz9RrIWoV+ONN0suZTrP9hW3IKFk9nBBBUb2CU83jhk/coqACvmE5T7M5Nc+8VjXV KtTQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=W2HWmiKr; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com Return-Path: Received: from agentk.vger.email (agentk.vger.email. [2620:137:e000::3:2]) by mx.google.com with ESMTPS id ck26-20020a056a02091a00b005859e8c7c2dsi6436038pgb.639.2023.10.23.08.42.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 23 Oct 2023 08:42:39 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) client-ip=2620:137:e000::3:2; Authentication-Results: mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=W2HWmiKr; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id D69FB805B9DD; Mon, 23 Oct 2023 08:42:26 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231163AbjJWPmO (ORCPT + 52 others); Mon, 23 Oct 2023 11:42:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48766 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229657AbjJWPmL (ORCPT ); Mon, 23 Oct 2023 11:42:11 -0400 Received: from mailgw01.mediatek.com (unknown [60.244.123.138]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EC94BDC for ; Mon, 23 Oct 2023 08:42:05 -0700 (PDT) X-UUID: b52c27da71ba11eea33bb35ae8d461a2-20231023 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=OODFBrWD2YdHLIMaPxgPkoQe+YPeSqhhGASu78652zg=; b=W2HWmiKrLYJ7W+WjaS270EreIMEbWYP3zGjHMlE/igWgCDbSHK9JtAy57wIZPyOvbD0fd01TTFO9BaATQBXdJLT73+G1eKF5FP8tyIng7jWWLS96/0B4SVQV3r1SEJGACgCfterrk7sqBKF6ZB+RaT6lotkKrhJjwRE/zLlorB8=; X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.32,REQID:b7bb17ab-bff9-4a3a-8a2c-50edd088d737,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:5f78ec9,CLOUDID:01ac37d7-04a0-4e50-8742-3543eab8cb8e,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: b52c27da71ba11eea33bb35ae8d461a2-20231023 Received: from mtkmbs11n2.mediatek.inc [(172.21.101.187)] by mailgw01.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 144748767; Mon, 23 Oct 2023 23:42:01 +0800 Received: from mtkmbs13n2.mediatek.inc (172.21.101.108) by MTKMBS14N2.mediatek.inc (172.21.101.76) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.26; Mon, 23 Oct 2023 23:41:59 +0800 Received: from mtksdccf07.mediatek.inc (172.21.84.99) by mtkmbs13n2.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.2.1118.26 via Frontend Transport; Mon, 23 Oct 2023 23:41:59 +0800 From: Shayne Chen To: Felix Fietkau CC: linux-wireless , Lorenzo Bianconi , Ryder Lee , Evelyn Tsai , Bo Jiao , linux-mediatek , MeiChia Chiu , Shayne Chen Subject: [PATCH 11/11] wifi: mt76: mt7996: fix rate usage of inband discovery frames Date: Mon, 23 Oct 2023 23:38:54 +0800 Message-ID: <20231023153854.10708-11-shayne.chen@mediatek.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20231023153854.10708-1-shayne.chen@mediatek.com> References: <20231023153854.10708-1-shayne.chen@mediatek.com> MIME-Version: 1.0 Content-Type: text/plain X-TM-AS-Product-Ver: SMEX-14.0.0.3152-9.1.1006-23728.005 X-TM-AS-Result: No-10--3.857400-8.000000 X-TMASE-MatchedRID: QMK8gM4dfEOj5TZ/mbDRqrMjW/sniEQKojQrbrPpzzq4a2U7iYmMbv0u b/xgdoFf+etC/vPQiRhheBLULo49bD1LciJB3541G/6vWz3PVrSagpdUd+Iwz/+am84b5ALEZvo +mFW19mB8RMc7UuMnj3BZiwYVxkeSBrU1duOq6zSeAiCmPx4NwBnUJ0Ek6yhjxEHRux+uk8jfhP 1xgyx3DLX67zmwfnIojpOpZQAlogVF/CBR0YUfMNJx+dUsVfZouzCP7pXpkh9Ssk6o+9mChgfDo rUSdKNUlrDDSgfqZQtKjZa1IyFrko6H7DI0GsVcMmI24qiENwrMpIbcl3IoA+q1XYAYw09qIdY9 jOi4lTI= X-TM-AS-User-Approved-Sender: No X-TM-AS-User-Blocked-Sender: No X-TMASE-Result: 10--3.857400-8.000000 X-TMASE-Version: SMEX-14.0.0.3152-9.1.1006-23728.005 X-TM-SNTS-SMTP: 06F67D7FD363C0CC59242D01E0DA41E3C3CEF3B002C2B77ADF322782365BAAB22000:8 X-MTK: N X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,UNPARSEABLE_RELAY autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Mon, 23 Oct 2023 08:42:27 -0700 (PDT) From: MeiChia Chiu For UBPR and FILS frames, the BSS_CHANGED_BEACON flag will also be set, which causes those frames to use the beacon rate in TX descriptors. Adjust the statement to fix this issue. Fixes: 98686cd21624 ("wifi: mt76: mt7996: add driver for MediaTek Wi-Fi 7 (802.11be) devices") Signed-off-by: MeiChia Chiu Signed-off-by: Shayne Chen --- drivers/net/wireless/mediatek/mt76/mt7996/mac.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/wireless/mediatek/mt76/mt7996/mac.c b/drivers/net/wireless/mediatek/mt76/mt7996/mac.c index f0dc47f56358..71ae8e263221 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7996/mac.c +++ b/drivers/net/wireless/mediatek/mt76/mt7996/mac.c @@ -860,10 +860,10 @@ void mt7996_mac_write_txwi(struct mt7996_dev *dev, __le32 *txwi, struct mt76_vif *mvif; u16 tx_count = 15; u32 val; - bool beacon = !!(changed & (BSS_CHANGED_BEACON | - BSS_CHANGED_BEACON_ENABLED)); bool inband_disc = !!(changed & (BSS_CHANGED_UNSOL_BCAST_PROBE_RESP | BSS_CHANGED_FILS_DISCOVERY)); + bool beacon = !!(changed & (BSS_CHANGED_BEACON | + BSS_CHANGED_BEACON_ENABLED)) && (!inband_disc); mvif = vif ? (struct mt76_vif *)vif->drv_priv : NULL; if (mvif) { -- 2.39.2