mt76: backport changed IEEE80211_MAX_AMPDU_BUF define

This commit is contained in:
coolsnowwolf 2022-11-15 00:34:58 +08:00
parent ddf2366cf4
commit 2c52782fd1

View File

@ -19,17 +19,14 @@ diff --git a/mt7915/init.c b/mt7915/init.c
index 489f6e77..1813370a 100644
--- a/mt7915/init.c
+++ b/mt7915/init.c
@@ -327,8 +327,13 @@ mt7915_init_wiphy(struct ieee80211_hw *hw)
@@ -327,8 +327,8 @@ mt7915_init_wiphy(struct ieee80211_hw *hw)
struct mt7915_dev *dev = phy->dev;
hw->queues = 4;
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(5, 15, 61))
- hw->max_rx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF_HE;
- hw->max_tx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF_HE;
+ hw->max_rx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF;
+ hw->max_tx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF;
+#else
hw->max_rx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF_HE;
hw->max_tx_aggregation_subframes = IEEE80211_MAX_AMPDU_BUF_HE;
+#endif
hw->netdev_features = NETIF_F_RXCSUM;
hw->radiotap_timestamp.units_pos =