Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp807215ybl; Fri, 6 Dec 2019 06:34:44 -0800 (PST) X-Google-Smtp-Source: APXvYqytXxJlCJgcm4B4vdZCvol71uhU3vwqlsfAaW/VnkdwjOTgO9wiV8JOlMdXGloecEgWhsw7 X-Received: by 2002:a9d:6a4c:: with SMTP id h12mr11328204otn.81.1575642883990; Fri, 06 Dec 2019 06:34:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1575642883; cv=none; d=google.com; s=arc-20160816; b=K3UA8+3G/dXwBhp/7OUeoOPz45vW12jQSVX6BW9E0lyIii6n0ySulF3/WLPzh6h02L bTBLx/6E13g6eG3RzwozI8wadh7Vr3h7surGuEAz8C+P6XUGlskTTJvj++BqAdNyCwSo NNkdMqDhq4NhABrxSs1kWqj/ScX4fyd4QyryHK6MW/AGVDZ+rVsgdNoCBqqZfGo25BDA rN7jm70R3Osj+D+JuAvl6aeZ81D4wH5d6s5DMrFU7Gm4sAN71setJqSSGPrrhf9LqFgX twqc50wELhzfTl94eZw6dgWzk/ZJpiP9dnG2Iu3TPgLZ1huerjumrBDfKn2HMqrlsu1J qa2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=N0ZTR8FX3aSSiXE+TdPeIJ3HAgDa5CXsqVe88GUb6qo=; b=OzGfiH1PX2LX5JCngei78gdCwiCuTBUc6cL9QMTyJOO8W9JeKjrl7WGA4/ZjnuniAS a2vbvHLPmwTqhoHAIfqiKAwVdd0/lA0SoJLizA/qo6eFKL3FRqDoeyU8Uk3oGy0vc47q /ELHcQdHRnZ24BdY79mQEe6xDblDKmOEi0Ui0wtF2FX9YCCiNed7psP177bFfEXFoy7E wzKv3BgNLn0uos55M9+nRqPE0Po8zD/VXvJ7WrXxRbXHdoVhsbUB60iqiFXK24326AUP XNQPKeECDx7qav7MesjniOzn/7XtAsRrgQH+9k+sZczAjxJX/f+LSVMr/snhg1Ji771t ZtIw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j204si6940269oif.253.2019.12.06.06.34.32; Fri, 06 Dec 2019 06:34:43 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726268AbfLFOeH (ORCPT + 99 others); Fri, 6 Dec 2019 09:34:07 -0500 Received: from nbd.name ([46.4.11.11]:36396 "EHLO nbd.name" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726214AbfLFOeH (ORCPT ); Fri, 6 Dec 2019 09:34:07 -0500 Received: from tmo-101-57.customers.d1-online.com ([80.187.101.57] helo=bertha.datto.lan) by ds12 with esmtpa (Exim 4.89) (envelope-from ) id 1idEgF-0004Lm-17; Fri, 06 Dec 2019 15:34:03 +0100 From: John Crispin To: Johannes Berg , Kalle Valo Cc: linux-wireless@vger.kernel.org, ath11k@lists.infradead.org, John Crispin Subject: [PATCH 1/7] mac80211: add a struct for holding BSS color settings Date: Fri, 6 Dec 2019 15:33:55 +0100 Message-Id: <20191206143401.4080-1-john@phrozen.org> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Right now we only track the actual color but not the other bits contained within the he_oper field. Fix this by creating a new struct to hold all of the info. Signed-off-by: John Crispin --- include/net/cfg80211.h | 15 +++++++++++++++ include/net/mac80211.h | 2 ++ 2 files changed, 17 insertions(+) diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h index 8140c4837122..e395ef48af83 100644 --- a/include/net/cfg80211.h +++ b/include/net/cfg80211.h @@ -259,6 +259,19 @@ struct ieee80211_he_obss_pd { u8 max_offset; }; +/** + * struct ieee80211_he_bss_color - AP settings for BSS coloring + * + * @color: the current color. + * @disabled: is the feature disabled. + * @partial: define the AID equation. + */ +struct ieee80211_he_bss_color { + u8 color; + bool disabled; + bool partial; +}; + /** * struct ieee80211_sta_ht_cap - STA's HT capabilities * @@ -910,6 +923,7 @@ enum cfg80211_ap_settings_flags { * @twt_responder: Enable Target Wait Time * @flags: flags, as defined in enum cfg80211_ap_settings_flags * @he_obss_pd: OBSS Packet Detection settings + * @he_bss_color: BSS Color settings */ struct cfg80211_ap_settings { struct cfg80211_chan_def chandef; @@ -938,6 +952,7 @@ struct cfg80211_ap_settings { bool twt_responder; u32 flags; struct ieee80211_he_obss_pd he_obss_pd; + struct ieee80211_he_bss_color he_bss_color; }; /** diff --git a/include/net/mac80211.h b/include/net/mac80211.h index 6781d4637557..16a5525ddab1 100644 --- a/include/net/mac80211.h +++ b/include/net/mac80211.h @@ -604,6 +604,7 @@ struct ieee80211_ftm_responder_params { * in order to discover all the nontransmitted BSSIDs in the set. * @he_operation: HE operation information of the AP we are connected to * @he_obss_pd: OBSS Packet Detection parameters. + * @he_bss_color: BSS coloring settings, if BSS supports HE */ struct ieee80211_bss_conf { const u8 *bssid; @@ -667,6 +668,7 @@ struct ieee80211_bss_conf { u8 profile_periodicity; struct ieee80211_he_operation he_operation; struct ieee80211_he_obss_pd he_obss_pd; + struct ieee80211_he_bss_color he_bss_color; }; /** -- 2.20.1