All of lore.kernel.org
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: linux-wireless@vger.kernel.org
Cc: quic_vikram@quicinc.com, quic_alokad@quicinc.com,
	quic_jiad@quicinc.com, quic_periyasa@quicinc.com,
	quic_msinada@quicinc.com, quic_srirrama@quicinc.com,
	ilan.peer@intel.com,
	Mordechay Goodstein <mordechay.goodstein@intel.com>
Subject: [PATCH v2 05/19] ieee80211: add EHT 1K aggregation definitions
Date: Thu, 10 Feb 2022 20:19:54 +0100	[thread overview]
Message-ID: <20220210201853.807ba413f994.I0ee2554c94e89abc7a752b0f7cc7fd79c273efea@changeid> (raw)
In-Reply-To: <20220210192008.188166-1-johannes@sipsolutions.net>

From: Mordechay Goodstein <mordechay.goodstein@intel.com>

We add the fields for parsing extended ADDBA request/respond,
and new max 1K aggregation for limit ADDBA request/respond.

Adjust drivers to use the proper macro, IEEE80211_MAX_AMPDU_BUF ->
IEEE80211_MAX_AMPDU_BUF_HE.

Signed-off-by: Mordechay Goodstein <mordechay.goodstein@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
 drivers/net/wireless/ath/ath11k/mac.c            | 2 +-
 drivers/net/wireless/intel/iwlwifi/mvm/ops.c     | 4 ++--
 drivers/net/wireless/mediatek/mt76/mt7915/init.c | 4 ++--
 include/linux/ieee80211.h                        | 6 +++++-
 net/mac80211/agg-rx.c                            | 2 +-
 5 files changed, 11 insertions(+), 7 deletions(-)

diff --git a/drivers/net/wireless/ath/ath11k/mac.c b/drivers/net/wireless/ath/ath11k/mac.c
index 90fcd6adf2d5..bd40f4c1183a 100644
--- a/drivers/net/wireless/ath/ath11k/mac.c
+++ b/drivers/net/wireless/ath/ath11k/mac.c
@@ -8448,7 +8448,7 @@ static int __ath11k_mac_register(struct ath11k *ar)
 	ar->hw->queues = ATH11K_HW_MAX_QUEUES;
 	ar->hw->wiphy->tx_queue_len = ATH11K_QUEUE_LEN;
 	ar->hw->offchannel_tx_hw_queue = ATH11K_HW_MAX_QUEUES - 1;
-	ar->hw->max_rx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF;
+	ar->hw->max_rx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF_HE;
 
 	ar->hw->vif_data_size = sizeof(struct ath11k_vif);
 	ar->hw->sta_data_size = sizeof(struct ath11k_sta);
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/ops.c b/drivers/net/wireless/intel/iwlwifi/mvm/ops.c
index 87630d38dc52..5da9d98043fd 100644
--- a/drivers/net/wireless/intel/iwlwifi/mvm/ops.c
+++ b/drivers/net/wireless/intel/iwlwifi/mvm/ops.c
@@ -1077,12 +1077,12 @@ iwl_op_mode_mvm_start(struct iwl_trans *trans, const struct iwl_cfg *cfg,
 	if (!hw)
 		return NULL;
 
-	hw->max_rx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF;
+	hw->max_rx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF_HE;
 
 	if (cfg->max_tx_agg_size)
 		hw->max_tx_aggregation_subframes = cfg->max_tx_agg_size;
 	else
-		hw->max_tx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF;
+		hw->max_tx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF_HE;
 
 	op_mode = hw->priv;
 
diff --git a/drivers/net/wireless/mediatek/mt76/mt7915/init.c b/drivers/net/wireless/mediatek/mt76/mt7915/init.c
index d054cdecd5f7..7ab1091693a2 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7915/init.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7915/init.c
@@ -309,8 +309,8 @@ mt7915_init_wiphy(struct ieee80211_hw *hw)
 	struct wiphy *wiphy = hw->wiphy;
 
 	hw->queues = 4;
-	hw->max_rx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF;
-	hw->max_tx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF;
+	hw->max_rx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF_HE;
+	hw->max_tx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF_HE;
 	hw->netdev_features = NETIF_F_RXCSUM;
 
 	hw->radiotap_timestamp.units_pos =
diff --git a/include/linux/ieee80211.h b/include/linux/ieee80211.h
index f5ed001ea557..72bd76a768e0 100644
--- a/include/linux/ieee80211.h
+++ b/include/linux/ieee80211.h
@@ -1024,6 +1024,8 @@ struct ieee80211_tpc_report_ie {
 #define IEEE80211_ADDBA_EXT_FRAG_LEVEL_MASK	GENMASK(2, 1)
 #define IEEE80211_ADDBA_EXT_FRAG_LEVEL_SHIFT	1
 #define IEEE80211_ADDBA_EXT_NO_FRAG		BIT(0)
+#define IEEE80211_ADDBA_EXT_BUF_SIZE_MASK	GENMASK(7, 5)
+#define IEEE80211_ADDBA_EXT_BUF_SIZE_SHIFT	10
 
 struct ieee80211_addba_ext_ie {
 	u8 data;
@@ -1698,10 +1700,12 @@ struct ieee80211_ht_operation {
  * A-MPDU buffer sizes
  * According to HT size varies from 8 to 64 frames
  * HE adds the ability to have up to 256 frames.
+ * EHT adds the ability to have up to 1K frames.
  */
 #define IEEE80211_MIN_AMPDU_BUF		0x8
 #define IEEE80211_MAX_AMPDU_BUF_HT	0x40
-#define IEEE80211_MAX_AMPDU_BUF		0x100
+#define IEEE80211_MAX_AMPDU_BUF_HE	0x100
+#define IEEE80211_MAX_AMPDU_BUF_EHT	0x400
 
 
 /* Spatial Multiplexing Power Save Modes (for capability) */
diff --git a/net/mac80211/agg-rx.c b/net/mac80211/agg-rx.c
index 7d2925bb966e..0d2bab9d351c 100644
--- a/net/mac80211/agg-rx.c
+++ b/net/mac80211/agg-rx.c
@@ -310,7 +310,7 @@ void ___ieee80211_start_rx_ba_session(struct sta_info *sta,
 	}
 
 	if (sta->sta.he_cap.has_he)
-		max_buf_size = IEEE80211_MAX_AMPDU_BUF;
+		max_buf_size = IEEE80211_MAX_AMPDU_BUF_HE;
 	else
 		max_buf_size = IEEE80211_MAX_AMPDU_BUF_HT;
 
-- 
2.34.1


  parent reply	other threads:[~2022-02-10 19:20 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-10 19:19 [PATCH v2 00/19] initial EHT support Johannes Berg
2022-02-10 19:19 ` [PATCH v2 01/19] mac80211_hwsim: check TX and STA bandwidth Johannes Berg
2022-02-10 19:19 ` [PATCH v2 02/19] mac80211_hwsim: don't shadow a global variable Johannes Berg
2022-02-10 19:19 ` [PATCH v2 03/19] mac80211_hwsim: Add custom regulatory for 6GHz Johannes Berg
2022-02-10 19:19 ` [PATCH v2 04/19] ieee80211: Add EHT (802.11be) definitions Johannes Berg
2022-02-10 20:08   ` Johannes Berg
2022-02-10 19:19 ` Johannes Berg [this message]
2022-02-10 19:19 ` [PATCH v2 06/19] cfg80211: Add data structures to capture EHT capabilities Johannes Berg
2022-02-11 17:37   ` Aloka Dixit (QUIC)
2022-02-11 19:03     ` Johannes Berg
2022-02-14 15:55       ` Aloka Dixit (QUIC)
2022-02-15  7:28         ` Kalle Valo
2022-02-10 19:19 ` [PATCH v2 07/19] cfg80211: Add support for EHT 320 MHz channel width Johannes Berg
2022-02-10 19:19 ` [PATCH v2 08/19] nl80211: add EHT MCS support Johannes Berg
2022-02-10 19:19 ` [PATCH v2 09/19] nl80211: add support for 320MHz channel limitation Johannes Berg
2022-02-10 19:19 ` [PATCH v2 10/19] cfg80211: add NO-EHT flag to regulatory Johannes Berg
2022-02-10 19:20 ` [PATCH v2 11/19] cfg80211: Support configuration of station EHT capabilities Johannes Berg
2022-02-10 19:20 ` [PATCH v2 12/19] mac80211: Support parsing EHT elements Johannes Berg
2022-02-10 19:20 ` [PATCH v2 13/19] mac80211: Add initial support for EHT and 320 MHz channels Johannes Berg
2022-02-10 19:20 ` [PATCH v2 14/19] mac80211: Add EHT capabilities to association/probe request Johannes Berg
2022-02-10 19:20 ` [PATCH v2 15/19] mac80211: Handle station association response with EHT Johannes Berg
2022-02-10 19:20 ` [PATCH v2 16/19] mac80211: Add support for storing station EHT capabilities Johannes Berg
2022-02-10 19:20 ` [PATCH v2 17/19] mac80211: calculate max RX NSS for EHT mode Johannes Berg
2022-02-10 19:20 ` [PATCH v2 18/19] mac80211: parse AddBA request with extended AddBA element Johannes Berg
2022-02-10 19:20 ` [PATCH v2 19/19] mac80211_hwsim: Advertise support for EHT capabilities Johannes Berg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220210201853.807ba413f994.I0ee2554c94e89abc7a752b0f7cc7fd79c273efea@changeid \
    --to=johannes@sipsolutions.net \
    --cc=ilan.peer@intel.com \
    --cc=linux-wireless@vger.kernel.org \
    --cc=mordechay.goodstein@intel.com \
    --cc=quic_alokad@quicinc.com \
    --cc=quic_jiad@quicinc.com \
    --cc=quic_msinada@quicinc.com \
    --cc=quic_periyasa@quicinc.com \
    --cc=quic_srirrama@quicinc.com \
    --cc=quic_vikram@quicinc.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.