aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorAbhijeet Kolekar <abhijeet.kolekar@intel.com>2008-06-11 21:47:16 -0400
committerJohn W. Linville <linville@tuxdriver.com>2008-06-13 16:14:53 -0400
commit5c5f9664d5284d8542062fed39e1f19b80db7aa5 (patch)
tree8758c907137a22b4af2402683fbf9d7b7be2e939 /net
parente6340361f9c70e84312caed98c6e058ac6234e9b (diff)
mac80211 : fix for iwconfig in ad-hoc mode
The patch checks interface status, if it is in IBSS_JOINED mode show cell id it is associated with. Signed-off-by: Abhijeet Kolekar <abhijeet.kolekar@intel.com> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net')
-rw-r--r--net/mac80211/wext.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/mac80211/wext.c b/net/mac80211/wext.c
index a8bb8e31b1ec..6106cb79060c 100644
--- a/net/mac80211/wext.c
+++ b/net/mac80211/wext.c
@@ -496,7 +496,8 @@ static int ieee80211_ioctl_giwap(struct net_device *dev,
496 sdata = IEEE80211_DEV_TO_SUB_IF(dev); 496 sdata = IEEE80211_DEV_TO_SUB_IF(dev);
497 if (sdata->vif.type == IEEE80211_IF_TYPE_STA || 497 if (sdata->vif.type == IEEE80211_IF_TYPE_STA ||
498 sdata->vif.type == IEEE80211_IF_TYPE_IBSS) { 498 sdata->vif.type == IEEE80211_IF_TYPE_IBSS) {
499 if (sdata->u.sta.state == IEEE80211_ASSOCIATED) { 499 if (sdata->u.sta.state == IEEE80211_ASSOCIATED ||
500 sdata->u.sta.state == IEEE80211_IBSS_JOINED) {
500 ap_addr->sa_family = ARPHRD_ETHER; 501 ap_addr->sa_family = ARPHRD_ETHER;
501 memcpy(&ap_addr->sa_data, sdata->u.sta.bssid, ETH_ALEN); 502 memcpy(&ap_addr->sa_data, sdata->u.sta.bssid, ETH_ALEN);
502 return 0; 503 return 0;