blob: aa0efc4e1061ed9fac8c38b022711dfe2542970a [file] [log] [blame]
developer8e5fecd2023-05-30 11:58:00 +08001From 22ffda45e657edd08380a24b3615d8e924775af8 Mon Sep 17 00:00:00 2001
2From: MeiChia Chiu <meichia.chiu@mediatek.com>
3Date: Wed, 24 May 2023 22:35:54 +0800
4Subject: [PATCH] wifi: mt76: mt7915: remove BW160 support
5
6Remove BW160 capability in mt7915.
7---
8 mt7915/init.c | 24 +++++-------------------
9 1 file changed, 5 insertions(+), 19 deletions(-)
10
11diff --git a/mt7915/init.c b/mt7915/init.c
12index 8eacf34..527cbac 100644
13--- a/mt7915/init.c
14+++ b/mt7915/init.c
15@@ -416,12 +416,6 @@ mt7915_init_wiphy(struct mt7915_phy *phy)
16 vht_cap->cap |=
17 IEEE80211_VHT_CAP_MAX_MPDU_LENGTH_7991 |
18 IEEE80211_VHT_CAP_MAX_A_MPDU_LENGTH_EXPONENT_MASK;
19-
20- if (!dev->dbdc_support)
21- vht_cap->cap |=
22- IEEE80211_VHT_CAP_SHORT_GI_160 |
23- IEEE80211_VHT_CAP_SUPP_CHAN_WIDTH_160MHZ |
24- FIELD_PREP(IEEE80211_VHT_CAP_EXT_NSS_BW_MASK, 1);
25 } else {
26 vht_cap->cap |=
27 IEEE80211_VHT_CAP_MAX_MPDU_LENGTH_11454 |
28@@ -870,12 +864,9 @@ mt7915_set_stream_he_txbf_caps(struct mt7915_phy *phy,
29 int sts = hweight8(phy->mt76->chainmask);
30 u8 c, sts_160 = sts;
31
32- /* Can do 1/2 of STS in 160Mhz mode for mt7915 */
33+ /* mt7915 doesn't support bw160 */
34 if (is_mt7915(&dev->mt76)) {
35- if (!dev->dbdc_support)
36- sts_160 /= 2;
37- else
38- sts_160 = 0;
39+ sts_160 = 0;
40 }
41
42 #ifdef CONFIG_MAC80211_MESH
43@@ -956,15 +947,10 @@ mt7915_init_he_caps(struct mt7915_phy *phy, enum nl80211_band band,
44 int i, idx = 0, nss = hweight8(phy->mt76->antenna_mask);
45 u16 mcs_map = 0;
46 u16 mcs_map_160 = 0;
47- u8 nss_160;
48+ u8 nss_160 = nss;
49
50- if (!is_mt7915(&dev->mt76))
51- nss_160 = nss;
52- else if (!dev->dbdc_support)
53- /* Can do 1/2 of NSS streams in 160Mhz mode for mt7915 */
54- nss_160 = nss / 2;
55- else
56- /* Can't do 160MHz with mt7915 dbdc */
57+ /* Can't do 160MHz with mt7915 */
58+ if (is_mt7915(&dev->mt76))
59 nss_160 = 0;
60
61 for (i = 0; i < 8; i++) {
62--
632.39.0
64