Loading include/uapi/linux/nl80211.h +3 −1 Original line number Original line Diff line number Diff line Loading @@ -3856,6 +3856,8 @@ enum nl80211_ap_sme_features { * @NL80211_FEATURE_CELL_BASE_REG_HINTS: This driver has been tested * @NL80211_FEATURE_CELL_BASE_REG_HINTS: This driver has been tested * to work properly to suppport receiving regulatory hints from * to work properly to suppport receiving regulatory hints from * cellular base stations. * cellular base stations. * @NL80211_FEATURE_P2P_DEVICE_NEEDS_CHANNEL: (no longer available, only * here to reserve the value for API/ABI compatibility) * @NL80211_FEATURE_SAE: This driver supports simultaneous authentication of * @NL80211_FEATURE_SAE: This driver supports simultaneous authentication of * equals (SAE) with user space SME (NL80211_CMD_AUTHENTICATE) in station * equals (SAE) with user space SME (NL80211_CMD_AUTHENTICATE) in station * mode * mode Loading Loading @@ -3897,7 +3899,7 @@ enum nl80211_feature_flags { NL80211_FEATURE_HT_IBSS = 1 << 1, NL80211_FEATURE_HT_IBSS = 1 << 1, NL80211_FEATURE_INACTIVITY_TIMER = 1 << 2, NL80211_FEATURE_INACTIVITY_TIMER = 1 << 2, NL80211_FEATURE_CELL_BASE_REG_HINTS = 1 << 3, NL80211_FEATURE_CELL_BASE_REG_HINTS = 1 << 3, /* bit 4 is reserved - don't use */ NL80211_FEATURE_P2P_DEVICE_NEEDS_CHANNEL = 1 << 4, NL80211_FEATURE_SAE = 1 << 5, NL80211_FEATURE_SAE = 1 << 5, NL80211_FEATURE_LOW_PRIORITY_SCAN = 1 << 6, NL80211_FEATURE_LOW_PRIORITY_SCAN = 1 << 6, NL80211_FEATURE_SCAN_FLUSH = 1 << 7, NL80211_FEATURE_SCAN_FLUSH = 1 << 7, Loading net/mac80211/ieee80211_i.h +1 −0 Original line number Original line Diff line number Diff line Loading @@ -317,6 +317,7 @@ struct ieee80211_roc_work { bool started, abort, hw_begun, notified; bool started, abort, hw_begun, notified; bool to_be_freed; bool to_be_freed; bool on_channel; unsigned long hw_start_time; unsigned long hw_start_time; Loading net/mac80211/mlme.c +13 −7 Original line number Original line Diff line number Diff line Loading @@ -3598,17 +3598,23 @@ void ieee80211_mgd_quiesce(struct ieee80211_sub_if_data *sdata) sdata_lock(sdata); sdata_lock(sdata); if (ifmgd->auth_data) { if (ifmgd->auth_data || ifmgd->assoc_data) { const u8 *bssid = ifmgd->auth_data ? ifmgd->auth_data->bss->bssid : ifmgd->assoc_data->bss->bssid; /* /* * If we are trying to authenticate while suspending, cfg80211 * If we are trying to authenticate / associate while suspending, * won't know and won't actually abort those attempts, thus we * cfg80211 won't know and won't actually abort those attempts, * need to do that ourselves. * thus we need to do that ourselves. */ */ ieee80211_send_deauth_disassoc(sdata, ieee80211_send_deauth_disassoc(sdata, bssid, ifmgd->auth_data->bss->bssid, IEEE80211_STYPE_DEAUTH, IEEE80211_STYPE_DEAUTH, WLAN_REASON_DEAUTH_LEAVING, WLAN_REASON_DEAUTH_LEAVING, false, frame_buf); false, frame_buf); if (ifmgd->assoc_data) ieee80211_destroy_assoc_data(sdata, false); if (ifmgd->auth_data) ieee80211_destroy_auth_data(sdata, false); ieee80211_destroy_auth_data(sdata, false); cfg80211_tx_mlme_mgmt(sdata->dev, frame_buf, cfg80211_tx_mlme_mgmt(sdata->dev, frame_buf, IEEE80211_DEAUTH_FRAME_LEN); IEEE80211_DEAUTH_FRAME_LEN); Loading net/mac80211/offchannel.c +20 −7 Original line number Original line Diff line number Diff line Loading @@ -333,7 +333,7 @@ void ieee80211_sw_roc_work(struct work_struct *work) container_of(work, struct ieee80211_roc_work, work.work); container_of(work, struct ieee80211_roc_work, work.work); struct ieee80211_sub_if_data *sdata = roc->sdata; struct ieee80211_sub_if_data *sdata = roc->sdata; struct ieee80211_local *local = sdata->local; struct ieee80211_local *local = sdata->local; bool started; bool started, on_channel; mutex_lock(&local->mtx); mutex_lock(&local->mtx); Loading @@ -354,14 +354,26 @@ void ieee80211_sw_roc_work(struct work_struct *work) if (!roc->started) { if (!roc->started) { struct ieee80211_roc_work *dep; struct ieee80211_roc_work *dep; /* start this ROC */ WARN_ON(local->use_chanctx); ieee80211_offchannel_stop_vifs(local); /* If actually operating on the desired channel (with at least * 20 MHz channel width) don't stop all the operations but still * treat it as though the ROC operation started properly, so * other ROC operations won't interfere with this one. */ roc->on_channel = roc->chan == local->_oper_chandef.chan && local->_oper_chandef.width != NL80211_CHAN_WIDTH_5 && local->_oper_chandef.width != NL80211_CHAN_WIDTH_10; /* switch channel etc */ /* start this ROC */ ieee80211_recalc_idle(local); ieee80211_recalc_idle(local); if (!roc->on_channel) { ieee80211_offchannel_stop_vifs(local); local->tmp_channel = roc->chan; local->tmp_channel = roc->chan; ieee80211_hw_config(local, 0); ieee80211_hw_config(local, 0); } /* tell userspace or send frame */ /* tell userspace or send frame */ ieee80211_handle_roc_started(roc); ieee80211_handle_roc_started(roc); Loading @@ -380,9 +392,10 @@ void ieee80211_sw_roc_work(struct work_struct *work) finish: finish: list_del(&roc->list); list_del(&roc->list); started = roc->started; started = roc->started; on_channel = roc->on_channel; ieee80211_roc_notify_destroy(roc, !roc->abort); ieee80211_roc_notify_destroy(roc, !roc->abort); if (started) { if (started && !on_channel) { ieee80211_flush_queues(local, NULL); ieee80211_flush_queues(local, NULL); local->tmp_channel = NULL; local->tmp_channel = NULL; Loading Loading
include/uapi/linux/nl80211.h +3 −1 Original line number Original line Diff line number Diff line Loading @@ -3856,6 +3856,8 @@ enum nl80211_ap_sme_features { * @NL80211_FEATURE_CELL_BASE_REG_HINTS: This driver has been tested * @NL80211_FEATURE_CELL_BASE_REG_HINTS: This driver has been tested * to work properly to suppport receiving regulatory hints from * to work properly to suppport receiving regulatory hints from * cellular base stations. * cellular base stations. * @NL80211_FEATURE_P2P_DEVICE_NEEDS_CHANNEL: (no longer available, only * here to reserve the value for API/ABI compatibility) * @NL80211_FEATURE_SAE: This driver supports simultaneous authentication of * @NL80211_FEATURE_SAE: This driver supports simultaneous authentication of * equals (SAE) with user space SME (NL80211_CMD_AUTHENTICATE) in station * equals (SAE) with user space SME (NL80211_CMD_AUTHENTICATE) in station * mode * mode Loading Loading @@ -3897,7 +3899,7 @@ enum nl80211_feature_flags { NL80211_FEATURE_HT_IBSS = 1 << 1, NL80211_FEATURE_HT_IBSS = 1 << 1, NL80211_FEATURE_INACTIVITY_TIMER = 1 << 2, NL80211_FEATURE_INACTIVITY_TIMER = 1 << 2, NL80211_FEATURE_CELL_BASE_REG_HINTS = 1 << 3, NL80211_FEATURE_CELL_BASE_REG_HINTS = 1 << 3, /* bit 4 is reserved - don't use */ NL80211_FEATURE_P2P_DEVICE_NEEDS_CHANNEL = 1 << 4, NL80211_FEATURE_SAE = 1 << 5, NL80211_FEATURE_SAE = 1 << 5, NL80211_FEATURE_LOW_PRIORITY_SCAN = 1 << 6, NL80211_FEATURE_LOW_PRIORITY_SCAN = 1 << 6, NL80211_FEATURE_SCAN_FLUSH = 1 << 7, NL80211_FEATURE_SCAN_FLUSH = 1 << 7, Loading
net/mac80211/ieee80211_i.h +1 −0 Original line number Original line Diff line number Diff line Loading @@ -317,6 +317,7 @@ struct ieee80211_roc_work { bool started, abort, hw_begun, notified; bool started, abort, hw_begun, notified; bool to_be_freed; bool to_be_freed; bool on_channel; unsigned long hw_start_time; unsigned long hw_start_time; Loading
net/mac80211/mlme.c +13 −7 Original line number Original line Diff line number Diff line Loading @@ -3598,17 +3598,23 @@ void ieee80211_mgd_quiesce(struct ieee80211_sub_if_data *sdata) sdata_lock(sdata); sdata_lock(sdata); if (ifmgd->auth_data) { if (ifmgd->auth_data || ifmgd->assoc_data) { const u8 *bssid = ifmgd->auth_data ? ifmgd->auth_data->bss->bssid : ifmgd->assoc_data->bss->bssid; /* /* * If we are trying to authenticate while suspending, cfg80211 * If we are trying to authenticate / associate while suspending, * won't know and won't actually abort those attempts, thus we * cfg80211 won't know and won't actually abort those attempts, * need to do that ourselves. * thus we need to do that ourselves. */ */ ieee80211_send_deauth_disassoc(sdata, ieee80211_send_deauth_disassoc(sdata, bssid, ifmgd->auth_data->bss->bssid, IEEE80211_STYPE_DEAUTH, IEEE80211_STYPE_DEAUTH, WLAN_REASON_DEAUTH_LEAVING, WLAN_REASON_DEAUTH_LEAVING, false, frame_buf); false, frame_buf); if (ifmgd->assoc_data) ieee80211_destroy_assoc_data(sdata, false); if (ifmgd->auth_data) ieee80211_destroy_auth_data(sdata, false); ieee80211_destroy_auth_data(sdata, false); cfg80211_tx_mlme_mgmt(sdata->dev, frame_buf, cfg80211_tx_mlme_mgmt(sdata->dev, frame_buf, IEEE80211_DEAUTH_FRAME_LEN); IEEE80211_DEAUTH_FRAME_LEN); Loading
net/mac80211/offchannel.c +20 −7 Original line number Original line Diff line number Diff line Loading @@ -333,7 +333,7 @@ void ieee80211_sw_roc_work(struct work_struct *work) container_of(work, struct ieee80211_roc_work, work.work); container_of(work, struct ieee80211_roc_work, work.work); struct ieee80211_sub_if_data *sdata = roc->sdata; struct ieee80211_sub_if_data *sdata = roc->sdata; struct ieee80211_local *local = sdata->local; struct ieee80211_local *local = sdata->local; bool started; bool started, on_channel; mutex_lock(&local->mtx); mutex_lock(&local->mtx); Loading @@ -354,14 +354,26 @@ void ieee80211_sw_roc_work(struct work_struct *work) if (!roc->started) { if (!roc->started) { struct ieee80211_roc_work *dep; struct ieee80211_roc_work *dep; /* start this ROC */ WARN_ON(local->use_chanctx); ieee80211_offchannel_stop_vifs(local); /* If actually operating on the desired channel (with at least * 20 MHz channel width) don't stop all the operations but still * treat it as though the ROC operation started properly, so * other ROC operations won't interfere with this one. */ roc->on_channel = roc->chan == local->_oper_chandef.chan && local->_oper_chandef.width != NL80211_CHAN_WIDTH_5 && local->_oper_chandef.width != NL80211_CHAN_WIDTH_10; /* switch channel etc */ /* start this ROC */ ieee80211_recalc_idle(local); ieee80211_recalc_idle(local); if (!roc->on_channel) { ieee80211_offchannel_stop_vifs(local); local->tmp_channel = roc->chan; local->tmp_channel = roc->chan; ieee80211_hw_config(local, 0); ieee80211_hw_config(local, 0); } /* tell userspace or send frame */ /* tell userspace or send frame */ ieee80211_handle_roc_started(roc); ieee80211_handle_roc_started(roc); Loading @@ -380,9 +392,10 @@ void ieee80211_sw_roc_work(struct work_struct *work) finish: finish: list_del(&roc->list); list_del(&roc->list); started = roc->started; started = roc->started; on_channel = roc->on_channel; ieee80211_roc_notify_destroy(roc, !roc->abort); ieee80211_roc_notify_destroy(roc, !roc->abort); if (started) { if (started && !on_channel) { ieee80211_flush_queues(local, NULL); ieee80211_flush_queues(local, NULL); local->tmp_channel = NULL; local->tmp_channel = NULL; Loading