Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp685607pxb; Tue, 5 Apr 2022 18:44:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzKXE1qa7Gi6u+gGIrkDAQS/6WfBekM2hk3icq9ptdnbNHJ6fmBVceDevJ7Kis1pko+wyy3 X-Received: by 2002:a17:906:d1c4:b0:6d5:83bb:f58a with SMTP id bs4-20020a170906d1c400b006d583bbf58amr6191723ejb.672.1649209384148; Tue, 05 Apr 2022 18:43:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649209384; cv=none; d=google.com; s=arc-20160816; b=mlj5dNMYffIdlKFqWqAXfs75JxS8POU4XP1+cjsp4cOMhKreM9fyM9ae5mwVwWfnyD JVS3I4DMdX1YFGKqja3JefX0C81A1Q2kUuG084tmxoN1rA0qHg6LZS2G4jJyaNP4+N9Q e+vjwnYcEpCwnZUkWRL71A4tvLMsL2g1AZi7YbboV1JuIrAsnMwOmqmC0LwktTWeSAdj n9Y/RPE6vJPvX/jpkqafUNsjJaHqj7S4LwUSlU0Wf3H44/liWRKrmdpoZpcJYRolw4Du NASuGLbkcS+wu/1W7c0QesO5r/qknlzm8Pw6u4fTfePCaUoEyAUMK0E8VpWmEGJqvzyi Aarg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=RJjDAaIlH+1pTR66/0e285efpC4YXH9w06e+VLoHhOY=; b=Qlb5VKqBEFE00IfecXkNrQ8lCLERoaUNrOfrXgLHMVoQmGQLSNruP2Zd6LDX0xsXWY hTzWf4iIZfj7nxInQkINx25OQs8py90fHpJljClZ/dh9UN3ar4wqAG6Uz4XBjkJAhbnt vsM4FjDnnWODqyslVRa+SkaqlLJSCABrzPURjRY8ZgwZMHxZITGKlOEWp5FqHRhL7AQT GqH/vc1Zj9vwCp8Ceo19XljKUI0HRLa4TStAzRny4FPssKQOlttAijR1hVbTaDhEIDdz /Tvb/PktpoQJaEumV/5mNe3IOmtJDH4M2bw6Z5qgh3YUN6rk/aec3/qJ+hNgZYTf9FTa isRA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=eQMNk2gB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h13-20020a50e10d000000b00418c2b5bef3si9721322edl.469.2022.04.05.18.42.34; Tue, 05 Apr 2022 18:43:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=eQMNk2gB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1384100AbiDEM1K (ORCPT + 99 others); Tue, 5 Apr 2022 08:27:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59118 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S245183AbiDEIyN (ORCPT ); Tue, 5 Apr 2022 04:54:13 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 32F9B2609; Tue, 5 Apr 2022 01:51:50 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id C63D961509; Tue, 5 Apr 2022 08:51:49 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id D33D2C385A0; Tue, 5 Apr 2022 08:51:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1649148709; bh=q0syxxaTH7xp2V/r98sFo2P+r4nVpI03Joft2BVr5xI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=eQMNk2gB2cejchGoDc8hBFcDxWG2pCWnF83gbI3CGXTCAzR2hWrqKeeGgtcPqij7j n7z/k4IUSUmmFZIhb045NCbMO0/oitMyY9Wimy1tHDQYxw/bwqXtyTKNg//NwmqQnn D4mw5bk36PHyXnJ2tpx1N7hTLe6Oa6MONYxuKh/U= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Lorenzo Bianconi , Felix Fietkau , Sasha Levin Subject: [PATCH 5.16 0453/1017] mt76: mt7915: use proper aid value in mt7915_mcu_sta_basic_tlv Date: Tue, 5 Apr 2022 09:22:46 +0200 Message-Id: <20220405070407.745073528@linuxfoundation.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220405070354.155796697@linuxfoundation.org> References: <20220405070354.155796697@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Lorenzo Bianconi [ Upstream commit abdb8bc94be4cf68aa71c9a8ee0bad9b3e6f52d3 ] Similar to mt7915_mcu_wtbl_generic_tlv, rely on vif->bss_conf.aid for aid in sta mode and not on sta->aid. Fixes: e57b7901469fc ("mt76: add mac80211 driver for MT7915 PCIe-based chipsets") Signed-off-by: Lorenzo Bianconi Signed-off-by: Felix Fietkau Signed-off-by: Sasha Levin --- drivers/net/wireless/mediatek/mt76/mt7915/mcu.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/net/wireless/mediatek/mt76/mt7915/mcu.c b/drivers/net/wireless/mediatek/mt76/mt7915/mcu.c index 8cdf689b383e..abc798536a81 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7915/mcu.c +++ b/drivers/net/wireless/mediatek/mt76/mt7915/mcu.c @@ -1321,12 +1321,15 @@ mt7915_mcu_sta_basic_tlv(struct sk_buff *skb, struct ieee80211_vif *vif, case NL80211_IFTYPE_MESH_POINT: case NL80211_IFTYPE_AP: basic->conn_type = cpu_to_le32(CONNECTION_INFRA_STA); + basic->aid = cpu_to_le16(sta->aid); break; case NL80211_IFTYPE_STATION: basic->conn_type = cpu_to_le32(CONNECTION_INFRA_AP); + basic->aid = cpu_to_le16(vif->bss_conf.aid); break; case NL80211_IFTYPE_ADHOC: basic->conn_type = cpu_to_le32(CONNECTION_IBSS_ADHOC); + basic->aid = cpu_to_le16(sta->aid); break; default: WARN_ON(1); @@ -1334,7 +1337,6 @@ mt7915_mcu_sta_basic_tlv(struct sk_buff *skb, struct ieee80211_vif *vif, } memcpy(basic->peer_addr, sta->addr, ETH_ALEN); - basic->aid = cpu_to_le16(sta->aid); basic->qos = sta->wme; } -- 2.34.1