/* This functions processes TLV buffer for a pending BSS Join command. * * Activate 11h functionality in the firmware if the spectrum management * capability bit is found in the network we are joining. Also, necessary * TLVs are set based on requested network's 11h capability.
*/ void mwifiex_11h_process_join(struct mwifiex_private *priv, u8 **buffer, struct mwifiex_bssdescriptor *bss_desc)
{ if (bss_desc->sensed_11h) { /* Activate 11h functions in firmware, turns on capability * bit
*/
mwifiex_11h_activate(priv, true);
priv->state_11h.is_11h_active = true;
bss_desc->cap_info_bitmap |= WLAN_CAPABILITY_SPECTRUM_MGMT;
mwifiex_11h_process_infra_join(priv, buffer, bss_desc);
} else { /* Deactivate 11h functions in the firmware */
mwifiex_11h_activate(priv, false);
priv->state_11h.is_11h_active = false;
bss_desc->cap_info_bitmap &= ~WLAN_CAPABILITY_SPECTRUM_MGMT;
}
}
/* This is DFS CAC work queue function. * This delayed work emits CAC finished event for cfg80211 if * CAC was started earlier.
*/ void mwifiex_dfs_cac_work_queue(struct work_struct *work)
{ struct cfg80211_chan_def chandef; struct delayed_work *delayed_work = to_delayed_work(work); struct mwifiex_private *priv =
container_of(delayed_work, struct mwifiex_private,
dfs_cac_work);
/* This function is to abort ongoing CAC upon stopping AP operations * or during unload.
*/ void mwifiex_abort_cac(struct mwifiex_private *priv)
{ if (priv->wdev.links[0].cac_started) { if (mwifiex_stop_radar_detection(priv, &priv->dfs_chandef))
mwifiex_dbg(priv->adapter, ERROR, "failed to stop CAC in FW\n");
mwifiex_dbg(priv->adapter, MSG, "Aborting delayed work for CAC.\n");
cancel_delayed_work_sync(&priv->dfs_cac_work);
cfg80211_cac_event(priv->netdev, &priv->dfs_chandef,
NL80211_RADAR_CAC_ABORTED, GFP_KERNEL,
0);
}
}
/* This function handles channel report event from FW during CAC period. * If radar is detected during CAC, driver indicates the same to cfg80211 * and also cancels ongoing delayed work.
*/ int mwifiex_11h_handle_chanrpt_ready(struct mwifiex_private *priv, struct sk_buff *skb)
{ struct host_cmd_ds_chan_rpt_event *rpt_event; struct mwifiex_ie_types_chan_rpt_data *rpt;
u16 event_len, tlv_len;
/* This is work queue function for channel switch handling. * This function takes care of updating new channel definitin to * bss config structure, restart AP and indicate channel switch success * to cfg80211.
*/ void mwifiex_dfs_chan_sw_work_queue(struct work_struct *work)
{ struct mwifiex_uap_bss_param *bss_cfg; struct delayed_work *delayed_work = to_delayed_work(work); struct mwifiex_private *priv =
container_of(delayed_work, struct mwifiex_private,
dfs_chan_sw_work);
bss_cfg = &priv->bss_cfg; if (!bss_cfg->beacon_period) {
mwifiex_dbg(priv->adapter, ERROR, "channel switch: AP already stopped\n"); return;
}
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.