From mboxrd@z Thu Jan 1 00:00:00 1970 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 39C41EB64DD for ; Thu, 3 Aug 2023 04:57:53 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231347AbjHCE5u (ORCPT ); Thu, 3 Aug 2023 00:57:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44136 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229697AbjHCE5t (ORCPT ); Thu, 3 Aug 2023 00:57:49 -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 AD3C6E42 for ; Wed, 2 Aug 2023 21:57:48 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 39EA861BD2 for ; Thu, 3 Aug 2023 04:57:48 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 1FDE8C433C8; Thu, 3 Aug 2023 04:57:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1691038667; bh=yew0nIIdv5+4cZdHKECsN2/+DIEEPUIsBer6rmfZnuQ=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=sZfGRrT+SOUTRe8tt6a0byCjSYAkLQ+OIBSAyZzxMVkpnzuynGE8YsPTu+xOyZP3p hkrqR15pNZOVnRaV16erWiKaDOt3iftzNWAsvwre5cpPlHOV/32O3b34tn2Q0jAsMi 3qnKBtOyc3rf6Ic9LW6SsmRxyZ/Qvj7qBXdAhgxwA3JQtLT+2xgdNpY4RqaJzamb9Y n3tWEy9MblzCaO1VK9Lh+ZHNgggafqeuPyZC6T9AsInpj5qaYybmFYqvQ/60+sa+XJ VTxNePln3pYzM2GfdrrYh2aoY/rvWSbVOYGQnllU0XZdMeU9lCYZZB0A7c15eIir9f 21jGc3tjyvxSQ== From: Kalle Valo To: Ryder Lee Cc: Felix Fietkau , , Lorenzo Bianconi , Shayne Chen , Evelyn Tsai , Subject: Re: [PATCH] wifi: mt76: mt7915: enable BSS_CHANGED_MU_GROUPS support References: Date: Thu, 03 Aug 2023 07:58:07 +0300 In-Reply-To: (Ryder Lee's message of "Thu, 3 Aug 2023 02:49:44 +0800") Message-ID: <87bkfozpr4.fsf@kernel.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Ryder Lee writes: > The Group ID Management frame is an Action frame of category VHT. > It is transmitted by the AP to assign or change the user position > of a STA for one or more group IDs. > > Also, sniffer can use a given group id to monitor STA that belongs > to that group. > > Notify underlying driver of changes via BSS_CHANGED_MU_GROUPS. > > Signed-off-by: Ryder Lee > Change-Id: I3d2f5508a2b6eb7c929c3997c31a9285713c8bea No Change-Id, please. > --- a/drivers/net/wireless/mediatek/mt76/mt7915/main.c > +++ b/drivers/net/wireless/mediatek/mt76/mt7915/main.c > @@ -593,6 +593,34 @@ mt7915_update_bss_color(struct ieee80211_hw *hw, > } > } > > +static void > +mt7915_update_mu_group(struct ieee80211_hw *hw, struct ieee80211_vif *vif, > + struct ieee80211_bss_conf *info) > +{ > + struct mt7915_phy *phy = mt7915_hw_phy(hw); > + struct mt7915_dev *dev = mt7915_hw_dev(hw); > + u8 i, band = phy->mt76->band_idx; > + u32 *mu; > + > + mu = (u32 *)info->mu_group.membership; Is this safe on big endian? > + for (i = 0; i < WLAN_MEMBERSHIP_LEN / sizeof(*mu); i++) { > + if (is_mt7916(&dev->mt76)) > + mt76_wr(dev, MT_WF_PHY_RX_GID_TAB_VLD_MT7916(band, i), > + mu[i]); > + else > + mt76_wr(dev, MT_WF_PHY_RX_GID_TAB_VLD(band, i), mu[i]); > + } > + > + mu = (u32 *)info->mu_group.position; And this? -- https://patchwork.kernel.org/project/linux-wireless/list/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches