Search Linux Wireless

Re: [PATCH v5 06/11] wifi: ath12k: prepare EHT peer assoc parameters

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 7/26/2023 6:40 AM, Aloka Dixit wrote:
[...]
+
+static void ath12k_peer_assoc_h_eht(struct ath12k *ar,
+				    struct ieee80211_vif *vif,
+				    struct ieee80211_sta *sta,
+				    struct ath12k_wmi_peer_assoc_arg *arg)
+{
+	const struct ieee80211_sta_eht_cap *eht_cap = &sta->deflink.eht_cap;
+	const struct ieee80211_sta_he_cap *he_cap = &sta->deflink.he_cap;
[...]
+	default:
+		if ((he_cap->he_cap_elem.phy_cap_info[0] &
+		     (IEEE80211_HE_PHY_CAP0_CHANNEL_WIDTH_SET_40MHZ_IN_2G |
+		      IEEE80211_HE_PHY_CAP0_CHANNEL_WIDTH_SET_40MHZ_80MHZ_IN_5G |
+		      IEEE80211_HE_PHY_CAP0_CHANNEL_WIDTH_SET_160MHZ_IN_5G |
+		      IEEE80211_HE_PHY_CAP0_CHANNEL_WIDTH_SET_80PLUS80_MHZ_IN_5G)) == 0) {
+			const struct ieee80211_eht_mcs_nss_supp_20mhz_only *bw_20 =
+					&eht_cap->eht_mcs_nss_supp.only_20mhz;
+
This is the IEs of my AP below, then it will still entered into this branch for my ath12k station mode. sta->deflink.eht_cap and sta->deflink.he_cap is copied from peer remote, for ath12k station mode, peer remote is the AP. The field only_20mhz is only valid when the IEs is from a station which only support
20 MHz.

I think the flag from_ap should be added here as well as function ieee80211_eht_mcs_nss_size().

Please correct me if wrong.

Ext Tag: HE Capabilities (IEEE Std 802.11ax/D3.0)
    Tag Number: Element ID Extension (255)
    Ext Tag length: 29
    Ext Tag Number: HE Capabilities (IEEE Std 802.11ax/D3.0) (35)
    HE MAC Capabilities Information: 0x10401a08010d
    HE Phy Capabilities Information
        .... ...0 = Reserved: 0x0
        0000 000. = Channel Width Set: 0x00
            .... ..0. = 40MHz in 2.4GHz band: Not supported
            .... .0.. = 40 & 80MHz in the 5GHz or 6GHz band: Not supported
            .... 0... = 160MHz in the 5GHz or 6GHz band: Not supported
            ...0 .... = 160/80+80MHz in the 5GHz or 6GHz band: Not supported
            ..0. .... = 242 tone RUs in the 2.4GHz band: Not supported
            .0.. .... = 242 tone RUs in the 5GHz or 6GHz band: Not supported
            0... .... = Reserved: 0x0
        Bits 8 to 23: 0x4063
        Bits 24 to 39: 0x1f88
        Bits 40 to 55: 0x8141
        Bits 56 to 71: 0x111c
        Bits 72 to 87: 0x0008
    Supported HE-MCS and NSS Set
    PPE Thresholds

Ext Tag: EHT Capabilities (IEEE Std 802.11be/D2.0)
    Tag Number: Element ID Extension (255)
    Ext Tag length: 15
    Ext Tag Number: EHT Capabilities (IEEE Std 802.11be/D2.0) (108)
    EHT MAC Capabilities Information: 0x0000
    EHT PHY Capabilities Information
    Supported EHT-MCS and NSS Set
        EHT-MCS Map (BW <= 80MHz): 0x222222
            .... .... .... .... .... 0010 = Rx Max Nss That Supports EHT-MCS 0-9: 2             .... .... .... .... 0010 .... = Tx Max Nss That Supports EHT-MCS 0-9: 2             .... .... .... 0010 .... .... = Rx Max Nss That Supports EHT-MCS 10-11: 2             .... .... 0010 .... .... .... = Tx Max Nss That Supports EHT-MCS 10-11: 2             .... 0010 .... .... .... .... = Rx Max Nss That Supports EHT-MCS 12-13: 2             0010 .... .... .... .... .... = Tx Max Nss That Supports EHT-MCS 12-13: 2
    EHT PPE Thresholds: <MISSING>

+			ath12k_mac_set_eht_mcs(bw_20->rx_tx_mcs7_max_nss,
+					       bw_20->rx_tx_mcs9_max_nss,
+					       bw_20->rx_tx_mcs11_max_nss,
+					       bw_20->rx_tx_mcs13_max_nss,
+					       &rx_mcs[WMI_EHTCAP_TXRX_MCS_NSS_IDX_80],
+					       &tx_mcs[WMI_EHTCAP_TXRX_MCS_NSS_IDX_80]);
+		} else {
+			bw = &eht_cap->eht_mcs_nss_supp.bw._80;
+			ath12k_mac_set_eht_mcs(bw->rx_tx_mcs9_max_nss,
+					       bw->rx_tx_mcs9_max_nss,
+					       bw->rx_tx_mcs11_max_nss,
+					       bw->rx_tx_mcs13_max_nss,
+					       &rx_mcs[WMI_EHTCAP_TXRX_MCS_NSS_IDX_80],
+					       &tx_mcs[WMI_EHTCAP_TXRX_MCS_NSS_IDX_80]);
+		}
+
+		arg->peer_eht_mcs_count++;
+		break;
+	}
+}
+
[...]



[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux