Lines Matching full:nss

179 static int ath10k_mac_get_max_vht_mcs_map(u16 mcs_map, int nss)  in ath10k_mac_get_max_vht_mcs_map()  argument
181 switch ((mcs_map >> (2 * nss)) & 0x3) { in ath10k_mac_get_max_vht_mcs_map()
192 int nss; in ath10k_mac_max_ht_nss() local
194 for (nss = IEEE80211_HT_MCS_MASK_LEN - 1; nss >= 0; nss--) in ath10k_mac_max_ht_nss()
195 if (ht_mcs_mask[nss]) in ath10k_mac_max_ht_nss()
196 return nss + 1; in ath10k_mac_max_ht_nss()
204 int nss; in ath10k_mac_max_vht_nss() local
206 for (nss = NL80211_VHT_NSS_MAX - 1; nss >= 0; nss--) in ath10k_mac_max_vht_nss()
207 if (vht_mcs_mask[nss]) in ath10k_mac_max_vht_nss()
208 return nss + 1; in ath10k_mac_max_vht_nss()
2282 int nss; in ath10k_peer_assoc_h_ht_masked() local
2284 for (nss = 0; nss < IEEE80211_HT_MCS_MASK_LEN; nss++) in ath10k_peer_assoc_h_ht_masked()
2285 if (ht_mcs_mask[nss]) in ath10k_peer_assoc_h_ht_masked()
2294 int nss; in ath10k_peer_assoc_h_vht_masked() local
2296 for (nss = 0; nss < NL80211_VHT_NSS_MAX; nss++) in ath10k_peer_assoc_h_vht_masked()
2297 if (vht_mcs_mask[nss]) in ath10k_peer_assoc_h_vht_masked()
2404 ath10k_dbg(ar, ATH10K_DBG_MAC, "mac ht peer %pM mcs cnt %d nss %d\n", in ath10k_peer_assoc_h_ht()
2483 int nss; in ath10k_peer_assoc_h_vht_limit() local
2487 for (nss = 0; nss < NL80211_VHT_NSS_MAX; nss++) { in ath10k_peer_assoc_h_vht_limit()
2488 mcs_map = ath10k_mac_get_max_vht_mcs_map(tx_mcs_set, nss) & in ath10k_peer_assoc_h_vht_limit()
2489 vht_mcs_limit[nss]; in ath10k_peer_assoc_h_vht_limit()
2522 tx_mcs_set &= ~(0x3 << (nss * 2)); in ath10k_peer_assoc_h_vht_limit()
2523 tx_mcs_set |= mcs << (nss * 2); in ath10k_peer_assoc_h_vht_limit()
2531 u32 nss; in get_160mhz_nss_from_maxrate() local
2535 nss = 1; in get_160mhz_nss_from_maxrate()
2538 nss = 2; in get_160mhz_nss_from_maxrate()
2541 nss = 3; /* not support MCS9 from spec*/ in get_160mhz_nss_from_maxrate()
2544 nss = 4; in get_160mhz_nss_from_maxrate()
2547 nss = 1; in get_160mhz_nss_from_maxrate()
2550 return nss; in get_160mhz_nss_from_maxrate()
2606 /* Calculate peer NSS capability from VHT capabilities if STA in ath10k_peer_assoc_h_vht()
2627 /* Configure bandwidth-NSS mapping to FW in ath10k_peer_assoc_h_vht()
4919 * a restricted NSS for 160 or 80+80 vs what it can do for 80Mhz. Give in ath10k_create_vht_cap()
5748 u16 nss = get_nss_from_chainmask(ar->cfg_tx_chainmask); in ath10k_add_interface() local
5750 vdev_param = ar->wmi.vdev_param->nss; in ath10k_add_interface()
5752 nss); in ath10k_add_interface()
5754 ath10k_warn(ar, "failed to set vdev %i chainmask 0x%x, nss %i: %d\n", in ath10k_add_interface()
5755 arvif->vdev_id, ar->cfg_tx_chainmask, nss, in ath10k_add_interface()
6735 u32 changed, bw, nss, smps; in ath10k_sta_rc_update_wk() local
6756 nss = arsta->nss; in ath10k_sta_rc_update_wk()
6763 nss = max_t(u32, 1, nss); in ath10k_sta_rc_update_wk()
6764 nss = min(nss, max(ath10k_mac_max_ht_nss(ht_mcs_mask), in ath10k_sta_rc_update_wk()
6790 ath10k_dbg(ar, ATH10K_DBG_STA, "mac update sta %pM nss %d\n", in ath10k_sta_rc_update_wk()
6791 sta->addr, nss); in ath10k_sta_rc_update_wk()
6794 ar->wmi.peer_param->nss, nss); in ath10k_sta_rc_update_wk()
6796 ath10k_warn(ar, "failed to update STA %pM nss %d: %d\n", in ath10k_sta_rc_update_wk()
6797 sta->addr, nss, err); in ath10k_sta_rc_update_wk()
6925 u8 *rate, u8 *nss, bool vht_only) in ath10k_mac_bitrate_mask_get_single_rate() argument
6950 *nss = 1; in ath10k_mac_bitrate_mask_get_single_rate()
6952 (*nss - 1) << 4 | in ath10k_mac_bitrate_mask_get_single_rate()
6960 *nss = i + 1; in ath10k_mac_bitrate_mask_get_single_rate()
6962 (*nss - 1) << 4 | in ath10k_mac_bitrate_mask_get_single_rate()
6972 *nss = i + 1; in ath10k_mac_bitrate_mask_get_single_rate()
6974 (*nss - 1) << 4 | in ath10k_mac_bitrate_mask_get_single_rate()
6986 u32 rate_ctrl_flag, u8 nss) in ath10k_mac_validate_rate_mask() argument
6991 if (nss > sta->deflink.rx_nss) { in ath10k_mac_validate_rate_mask()
6992 ath10k_warn(ar, "Invalid nss field, configured %u limit %u\n", in ath10k_mac_validate_rate_mask()
6993 nss, sta->deflink.rx_nss); in ath10k_mac_validate_rate_mask()
7027 u8 nss, rate; in ath10k_mac_tid_bitrate_config() local
7047 &rate, &nss, false); in ath10k_mac_tid_bitrate_config()
7056 if (sta && ath10k_mac_validate_rate_mask(ar, sta, *rate_ctrl_flag, nss)) in ath10k_mac_tid_bitrate_config()
7345 u8 nss; in ath10k_sta_tid_cfg_wk() local
7401 nss = ATH10K_HW_NSS(arvif->rate_code[i]); in ath10k_sta_tid_cfg_wk()
7404 nss); in ath10k_sta_tid_cfg_wk()
8229 int *nss) in ath10k_mac_bitrate_mask_get_single_nss() argument
8269 *nss = fls(ht_nss_mask); in ath10k_mac_bitrate_mask_get_single_nss()
8275 u8 rate, u8 nss, u8 sgi, u8 ldpc) in ath10k_mac_set_fixed_rate_params() argument
8283 ath10k_dbg(ar, ATH10K_DBG_MAC, "mac set fixed rate params vdev %i rate 0x%02x nss %u sgi %u\n", in ath10k_mac_set_fixed_rate_params()
8284 arvif->vdev_id, rate, nss, sgi); in ath10k_mac_set_fixed_rate_params()
8294 vdev_param = ar->wmi.vdev_param->nss; in ath10k_mac_set_fixed_rate_params()
8295 ret = ath10k_wmi_vdev_set_param(ar, arvif->vdev_id, vdev_param, nss); in ath10k_mac_set_fixed_rate_params()
8297 ath10k_warn(ar, "failed to set nss param %d: %d\n", nss, ret); in ath10k_mac_set_fixed_rate_params()
8421 u8 nss; in ath10k_mac_op_set_bitrate_mask() local
8455 &rate, &nss, in ath10k_mac_op_set_bitrate_mask()
8465 nss = single_nss; in ath10k_mac_op_set_bitrate_mask()
8468 nss = min(ar->num_rf_chains, in ath10k_mac_op_set_bitrate_mask()
8512 ret = ath10k_mac_set_fixed_rate_params(arvif, rate, nss, sgi, ldpc); in ath10k_mac_op_set_bitrate_mask()
8547 "mac sta rc update for %pM changed %08x bw %d nss %d smps %d\n", in ath10k_sta_rc_update()
8579 arsta->nss = sta->deflink.rx_nss; in ath10k_sta_rc_update()
9106 /* HT MCS parameters with Nss = 1 */
9119 /* HT MCS parameters with Nss = 2 */
9132 /* MCS parameters with Nss = 1 */
9147 /*MCS parameters with Nss = 2 */
9162 static void ath10k_mac_get_rate_flags_ht(struct ath10k *ar, u32 rate, u8 nss, u8 mcs, in ath10k_mac_get_rate_flags_ht() argument
9184 ((nss == 1) ? &supported_ht_mcs_rate_nss1 : in ath10k_mac_get_rate_flags_ht()
9203 ath10k_warn(ar, "invalid ht params rate %d 100kbps nss %d mcs %d", in ath10k_mac_get_rate_flags_ht()
9204 rate, nss, mcs); in ath10k_mac_get_rate_flags_ht()
9208 static void ath10k_mac_get_rate_flags_vht(struct ath10k *ar, u32 rate, u8 nss, u8 mcs, in ath10k_mac_get_rate_flags_vht() argument
9220 ((nss == 1) ? &supported_vht_mcs_rate_nss1 : in ath10k_mac_get_rate_flags_vht()
9239 ath10k_warn(ar, "invalid vht params rate %d 100kbps nss %d mcs %d", in ath10k_mac_get_rate_flags_vht()
9240 rate, nss, mcs); in ath10k_mac_get_rate_flags_vht()
9245 enum ath10k_phy_mode mode, u8 nss, u8 mcs, in ath10k_mac_get_rate_flags() argument
9250 ath10k_mac_get_rate_flags_ht(ar, rate, nss, mcs, flags, bw); in ath10k_mac_get_rate_flags()
9253 ath10k_mac_get_rate_flags_vht(ar, rate, nss, mcs, flags, bw); in ath10k_mac_get_rate_flags()
9262 u8 nss = WMI_TLV_GET_HW_RC_NSS_V1(rate_code) + 1; in ath10k_mac_parse_bitrate() local
9274 ath10k_mac_get_rate_flags(ar, bitrate_kbps / 100, mode, nss, mcs, &flags, &bw); in ath10k_mac_parse_bitrate()
9277 "mac parse bitrate preamble %d mode %d nss %d mcs %d flags %x bw %d\n", in ath10k_mac_parse_bitrate()
9278 preamble, mode, nss, mcs, flags, bw); in ath10k_mac_parse_bitrate()
9283 rate->nss = nss; in ath10k_mac_parse_bitrate()
9363 if (arsta->txrate.legacy || arsta->txrate.nss) { in ath10k_sta_statistics()
9368 sinfo->txrate.nss = arsta->txrate.nss; in ath10k_sta_statistics()