Skip to content

Commit

Permalink
nl80211: allow installing keys for a meshif
Browse files Browse the repository at this point in the history
Signed-off-by: Thomas Pedersen <[email protected]>
Signed-off-by: Javier Cardona <[email protected]>
Signed-off-by: John W. Linville <[email protected]>
  • Loading branch information
twpedersen authored and linvjw committed May 11, 2011
1 parent 9c3990a commit ff973af
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 4 additions & 1 deletion net/mac80211/cfg.c
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,10 @@ static int ieee80211_add_key(struct wiphy *wiphy, struct net_device *dev,
mutex_lock(&sdata->local->sta_mtx);

if (mac_addr) {
sta = sta_info_get_bss(sdata, mac_addr);
if (ieee80211_vif_is_mesh(&sdata->vif))
sta = sta_info_get(sdata, mac_addr);
else
sta = sta_info_get_bss(sdata, mac_addr);
if (!sta) {
ieee80211_key_free(sdata->local, key);
err = -ENOENT;
Expand Down
1 change: 1 addition & 0 deletions net/wireless/nl80211.c
Original file line number Diff line number Diff line change
Expand Up @@ -545,6 +545,7 @@ static int nl80211_key_allowed(struct wireless_dev *wdev)
case NL80211_IFTYPE_AP:
case NL80211_IFTYPE_AP_VLAN:
case NL80211_IFTYPE_P2P_GO:
case NL80211_IFTYPE_MESH_POINT:
break;
case NL80211_IFTYPE_ADHOC:
if (!wdev->current_bss)
Expand Down

0 comments on commit ff973af

Please sign in to comment.