Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 66785
b: refs/heads/master
c: fb1c1cd
h: refs/heads/master
i:
  66783: 757c446
v: v3
  • Loading branch information
Johannes Berg authored and David S. Miller committed Oct 10, 2007
1 parent 77337ae commit e994412
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: af1a90da397f071d7ee893145a1e7b2124689376
refs/heads/master: fb1c1cd6c5a8988b14c5c6c0dfe55542df3a34c6
7 changes: 7 additions & 0 deletions trunk/net/mac80211/ieee80211.c
Original file line number Diff line number Diff line change
Expand Up @@ -344,6 +344,13 @@ static int ieee80211_open(struct net_device *dev)
if (!sdata->u.vlan.ap)
return -ENOLINK;
break;
case IEEE80211_IF_TYPE_AP:
case IEEE80211_IF_TYPE_MGMT:
case IEEE80211_IF_TYPE_STA:
case IEEE80211_IF_TYPE_MNTR:
case IEEE80211_IF_TYPE_IBSS:
/* no special treatment */
break;
}

if (local->open_count == 0) {
Expand Down
2 changes: 1 addition & 1 deletion trunk/net/mac80211/ieee80211_i.h
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ struct ieee80211_if_sta {
#define IEEE80211_SDATA_SHORT_PREAMBLE BIT(3)
struct ieee80211_sub_if_data {
struct list_head list;
unsigned int type;
enum ieee80211_if_types type;

struct wireless_dev wdev;

Expand Down
3 changes: 3 additions & 0 deletions trunk/net/mac80211/ieee80211_iface.c
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,9 @@ void ieee80211_if_reinit(struct net_device *dev)
ieee80211_if_sdata_deinit(sdata);

switch (sdata->type) {
case IEEE80211_IF_TYPE_MGMT:
/* nothing to do */
break;
case IEEE80211_IF_TYPE_AP: {
/* Remove all virtual interfaces that use this BSS
* as their sdata->bss */
Expand Down
8 changes: 8 additions & 0 deletions trunk/net/mac80211/rx.c
Original file line number Diff line number Diff line change
Expand Up @@ -1425,6 +1425,7 @@ static int prepare_for_handlers(struct ieee80211_sub_if_data *sdata,
rx->sta = ieee80211_ibss_add_sta(sdata->dev, rx->skb,
bssid, hdr->addr2);
break;
case IEEE80211_IF_TYPE_VLAN:
case IEEE80211_IF_TYPE_AP:
if (!bssid) {
if (compare_ether_addr(sdata->dev->dev_addr,
Expand All @@ -1449,6 +1450,13 @@ static int prepare_for_handlers(struct ieee80211_sub_if_data *sdata,
if (compare_ether_addr(sdata->u.wds.remote_addr, hdr->addr2))
return 0;
break;
case IEEE80211_IF_TYPE_MNTR:
/* take everything */
break;
case IEEE80211_IF_TYPE_MGMT:
/* should never get here */
WARN_ON(1);
break;
}

return 1;
Expand Down

0 comments on commit e994412

Please sign in to comment.