mac80211: add boilerplate code for start / stop NAN
This code doesn't do much besides allowing to start and stop the vif. Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Ayala Beker <ayala.beker@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:

committed by
Johannes Berg

parent
cb3b7d8765
commit
708d50edb1
@@ -327,6 +327,9 @@ static int ieee80211_check_queues(struct ieee80211_sub_if_data *sdata,
|
||||
int n_queues = sdata->local->hw.queues;
|
||||
int i;
|
||||
|
||||
if (iftype == NL80211_IFTYPE_NAN)
|
||||
return 0;
|
||||
|
||||
if (iftype != NL80211_IFTYPE_P2P_DEVICE) {
|
||||
for (i = 0; i < IEEE80211_NUM_ACS; i++) {
|
||||
if (WARN_ON_ONCE(sdata->vif.hw_queue[i] ==
|
||||
@@ -647,7 +650,8 @@ int ieee80211_do_open(struct wireless_dev *wdev, bool coming_up)
|
||||
local->fif_probe_req++;
|
||||
}
|
||||
|
||||
if (sdata->vif.type != NL80211_IFTYPE_P2P_DEVICE)
|
||||
if (sdata->vif.type != NL80211_IFTYPE_P2P_DEVICE &&
|
||||
sdata->vif.type != NL80211_IFTYPE_NAN)
|
||||
changed |= ieee80211_reset_erp_info(sdata);
|
||||
ieee80211_bss_info_change_notify(sdata, changed);
|
||||
|
||||
@@ -1726,7 +1730,7 @@ int ieee80211_if_add(struct ieee80211_local *local, const char *name,
|
||||
|
||||
ASSERT_RTNL();
|
||||
|
||||
if (type == NL80211_IFTYPE_P2P_DEVICE) {
|
||||
if (type == NL80211_IFTYPE_P2P_DEVICE || type == NL80211_IFTYPE_NAN) {
|
||||
struct wireless_dev *wdev;
|
||||
|
||||
sdata = kzalloc(sizeof(*sdata) + local->hw.vif_data_size,
|
||||
|
Reference in New Issue
Block a user