/* Correctly allocated primary link in non-MLO mode */ if (!ieee80211_vif_is_mld(vif) &&
link_id == 0 && link == &mld_vif->deflink) continue;
if (vif->active_links & BIT(link_id)) continue;
/* Should not happen as link removal should always succeed */
WARN_ON(1); if (link != &mld_vif->deflink)
kfree_rcu(link, rcu_head);
RCU_INIT_POINTER(mld_vif->link[link_id], NULL);
}
/* This capability is the same for all bands, * so take it from one of them.
*/
sband = mld->hw->wiphy->bands[NL80211_BAND_2GHZ];
own_he_cap = ieee80211_get_he_iftype_cap_vif(sband, vif);
/* If we have MLO enabled, then the firmware needs to enable * address translation for the station(s) we add. That depends * on having EHT enabled in firmware, which in turn depends on * mac80211 in the code below. * However, mac80211 doesn't enable HE/EHT until it has parsed * the association response successfully, so just skip all that * and enable both when we have MLO.
*/ if (ieee80211_vif_is_mld(vif)) {
iwl_mld_set_he_support(mld, vif, cmd, cmd_ver); if (cmd_ver == 2)
cmd->wifi_gen_v2.eht_support = cpu_to_le32(1); else
cmd->wifi_gen.eht_support = 1; return;
}
for_each_vif_active_link(vif, link_conf, link_id) { if (!link_conf->he_support) continue;
iwl_mld_set_he_support(mld, vif, cmd, cmd_ver);
/* EHT, if supported, was already set above */ break;
}
}
/* We always want to hear MCAST frames, if we're not authorized yet, * we'll drop them.
*/
cmd->filter_flags |= cpu_to_le32(MAC_CFG_FILTER_ACCEPT_GRP);
/* Adding a MAC ctxt with is_assoc set is not allowed in fw * (and shouldn't happen)
*/ if (vif->cfg.assoc && action != FW_CTXT_ACTION_ADD) {
cmd->client.is_assoc = 1;
if (!iwl_mld_vif_from_mac80211(vif)->authorized)
cmd->client.data_policy |=
cpu_to_le16(COEX_HIGH_PRIORITY_ENABLE);
} else { /* Allow beacons to pass through as long as we are not * associated
*/
cmd->filter_flags |= cpu_to_le32(MAC_CFG_FILTER_ACCEPT_BEACON);
}
cmd->client.assoc_id = cpu_to_le16(vif->cfg.aid);
if (ieee80211_vif_is_mld(vif)) {
u16 esr_transition_timeout =
u16_get_bits(vif->cfg.eml_cap,
IEEE80211_EML_CAP_TRANSITION_TIMEOUT);
/* in AP mode, pass beacons from other APs (needed for ht protection). * When there're no any associated station, which means that we are not * TXing anyway, don't ask FW to pass beacons to prevent unnecessary * wake-ups.
*/ if (mld_vif->num_associated_stas)
cmd->filter_flags |= cpu_to_le32(MAC_CFG_FILTER_ACCEPT_BEACON);
}
/* This flag should be set to true when the P2P Device is * discoverable and there is at least a P2P GO. Setting * this flag will allow the P2P Device to be discoverable on other * channels in addition to its listen channel. * Note that this flag should not be set in other cases as it opens the * Rx filters on all MAC and increases the number of interrupts.
*/
ieee80211_iterate_active_interfaces(mld->hw,
IEEE80211_IFACE_ITER_RESUME_ALL,
iwl_mld_go_iterator, &go_active);
/* Override the filter flags to accept all management frames. This is * needed to support both P2P device discovery using probe requests and * P2P service discovery using action frames
*/
cmd->filter_flags = cpu_to_le32(MAC_CFG_FILTER_ACCEPT_CONTROL_AND_MGMT);
if (ext_disc)
cmd->p2p_dev.is_disc_extended = cpu_to_le32(1);
}
/* the firmware gives us the mac_id (and not the link_id), mac80211 * gets a vif and not a link, bottom line, this flow is not MLD ready * yet.
*/ if (WARN_ON(!vif) || ieee80211_vif_is_mld(vif)) return;
if (notif->csa_counter != IWL_PROBE_RESP_DATA_NO_CSA &&
notif->csa_counter >= 1)
ieee80211_beacon_set_cntdwn(vif, notif->csa_counter);
/* noa_attr contains 1 reserved byte, need to substruct it */
new_data->noa_len = sizeof(struct ieee80211_vendor_ie) + sizeof(new_data->notif.noa_attr) - 1;
/* * If it's a one time NoA, only one descriptor is needed, * adjust the length according to len_low.
*/ if (new_data->notif.noa_attr.len_low == sizeof(struct ieee80211_p2p_noa_desc) + 2)
new_data->noa_len -= sizeof(struct ieee80211_p2p_noa_desc);
/* * This capability manipulation isn't really ideal, but it's the * easiest choice - otherwise we'd have to do some major changes * in mac80211 to support this, which isn't worth it. This does * mean that userspace may have outdated information, but that's * actually not an issue at all.
*/
sband = mld->wiphy->bands[NL80211_BAND_2GHZ];
if (mld_vif->cca_40mhz_workaround == CCA_40_MHZ_WA_NONE) return;
/* Now we are just reconnecting with the new capabilities, * but remember to reset the capabilities when we disconnect for real
*/ if (mld_vif->cca_40mhz_workaround == CCA_40_MHZ_WA_RECONNECT) {
mld_vif->cca_40mhz_workaround = CCA_40_MHZ_WA_RESET; return;
}
/* Now cca_40mhz_workaround == CCA_40_MHZ_WA_RESET */
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.