dma-mapping: ia64: add CONFIG_DMA_API_DEBUG support
[linux-2.6/linux-acpi-2.6/ibm-acpi-2.6.git] / net / mac80211 / wext.c
blobd2d81b103341472613d8dabe14c3fda20c21c01b
1 /*
2 * Copyright 2002-2005, Instant802 Networks, Inc.
3 * Copyright 2005-2006, Devicescape Software, Inc.
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 2 as
7 * published by the Free Software Foundation.
8 */
10 #include <linux/module.h>
11 #include <linux/init.h>
12 #include <linux/netdevice.h>
13 #include <linux/types.h>
14 #include <linux/slab.h>
15 #include <linux/skbuff.h>
16 #include <linux/etherdevice.h>
17 #include <linux/if_arp.h>
18 #include <linux/wireless.h>
19 #include <net/iw_handler.h>
20 #include <asm/uaccess.h>
22 #include <net/mac80211.h>
23 #include "ieee80211_i.h"
24 #include "led.h"
25 #include "rate.h"
26 #include "wpa.h"
27 #include "aes_ccm.h"
30 static int ieee80211_ioctl_siwgenie(struct net_device *dev,
31 struct iw_request_info *info,
32 struct iw_point *data, char *extra)
34 struct ieee80211_sub_if_data *sdata;
36 sdata = IEEE80211_DEV_TO_SUB_IF(dev);
38 if (sdata->vif.type == NL80211_IFTYPE_STATION) {
39 int ret = ieee80211_sta_set_extra_ie(sdata, extra, data->length);
40 if (ret && ret != -EALREADY)
41 return ret;
42 sdata->u.mgd.flags &= ~IEEE80211_STA_AUTO_BSSID_SEL;
43 sdata->u.mgd.flags &= ~IEEE80211_STA_EXT_SME;
44 sdata->u.mgd.flags &= ~IEEE80211_STA_CONTROL_PORT;
45 if (ret != -EALREADY)
46 ieee80211_sta_req_auth(sdata);
47 return 0;
50 return -EOPNOTSUPP;
53 static int ieee80211_ioctl_siwfreq(struct net_device *dev,
54 struct iw_request_info *info,
55 struct iw_freq *freq, char *extra)
57 struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
59 if (sdata->vif.type == NL80211_IFTYPE_ADHOC)
60 return cfg80211_ibss_wext_siwfreq(dev, info, freq, extra);
61 else if (sdata->vif.type == NL80211_IFTYPE_STATION)
62 sdata->u.mgd.flags &= ~IEEE80211_STA_AUTO_CHANNEL_SEL;
64 /* freq->e == 0: freq->m = channel; otherwise freq = m * 10^e */
65 if (freq->e == 0) {
66 if (freq->m < 0) {
67 if (sdata->vif.type == NL80211_IFTYPE_STATION)
68 sdata->u.mgd.flags |=
69 IEEE80211_STA_AUTO_CHANNEL_SEL;
70 return 0;
71 } else
72 return ieee80211_set_freq(sdata,
73 ieee80211_channel_to_frequency(freq->m));
74 } else {
75 int i, div = 1000000;
76 for (i = 0; i < freq->e; i++)
77 div /= 10;
78 if (div > 0)
79 return ieee80211_set_freq(sdata, freq->m / div);
80 else
81 return -EINVAL;
86 static int ieee80211_ioctl_giwfreq(struct net_device *dev,
87 struct iw_request_info *info,
88 struct iw_freq *freq, char *extra)
90 struct ieee80211_local *local = wdev_priv(dev->ieee80211_ptr);
91 struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
93 if (sdata->vif.type == NL80211_IFTYPE_ADHOC)
94 return cfg80211_ibss_wext_giwfreq(dev, info, freq, extra);
96 freq->m = local->oper_channel->center_freq;
97 freq->e = 6;
99 return 0;
103 static int ieee80211_ioctl_siwessid(struct net_device *dev,
104 struct iw_request_info *info,
105 struct iw_point *data, char *ssid)
107 struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
108 size_t len = data->length;
109 int ret;
111 if (sdata->vif.type == NL80211_IFTYPE_ADHOC)
112 return cfg80211_ibss_wext_siwessid(dev, info, data, ssid);
114 /* iwconfig uses nul termination in SSID.. */
115 if (len > 0 && ssid[len - 1] == '\0')
116 len--;
118 if (sdata->vif.type == NL80211_IFTYPE_STATION) {
119 if (data->flags)
120 sdata->u.mgd.flags &= ~IEEE80211_STA_AUTO_SSID_SEL;
121 else
122 sdata->u.mgd.flags |= IEEE80211_STA_AUTO_SSID_SEL;
124 ret = ieee80211_sta_set_ssid(sdata, ssid, len);
125 if (ret)
126 return ret;
128 sdata->u.mgd.flags &= ~IEEE80211_STA_EXT_SME;
129 sdata->u.mgd.flags &= ~IEEE80211_STA_CONTROL_PORT;
130 ieee80211_sta_req_auth(sdata);
131 return 0;
134 return -EOPNOTSUPP;
138 static int ieee80211_ioctl_giwessid(struct net_device *dev,
139 struct iw_request_info *info,
140 struct iw_point *data, char *ssid)
142 size_t len;
143 struct ieee80211_sub_if_data *sdata;
145 sdata = IEEE80211_DEV_TO_SUB_IF(dev);
147 if (sdata->vif.type == NL80211_IFTYPE_ADHOC)
148 return cfg80211_ibss_wext_giwessid(dev, info, data, ssid);
150 if (sdata->vif.type == NL80211_IFTYPE_STATION) {
151 int res = ieee80211_sta_get_ssid(sdata, ssid, &len);
152 if (res == 0) {
153 data->length = len;
154 data->flags = 1;
155 } else
156 data->flags = 0;
157 return res;
160 return -EOPNOTSUPP;
164 static int ieee80211_ioctl_siwap(struct net_device *dev,
165 struct iw_request_info *info,
166 struct sockaddr *ap_addr, char *extra)
168 struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
170 if (sdata->vif.type == NL80211_IFTYPE_ADHOC)
171 return cfg80211_ibss_wext_siwap(dev, info, ap_addr, extra);
173 if (sdata->vif.type == NL80211_IFTYPE_STATION) {
174 int ret;
176 if (is_zero_ether_addr((u8 *) &ap_addr->sa_data))
177 sdata->u.mgd.flags |= IEEE80211_STA_AUTO_BSSID_SEL |
178 IEEE80211_STA_AUTO_CHANNEL_SEL;
179 else if (is_broadcast_ether_addr((u8 *) &ap_addr->sa_data))
180 sdata->u.mgd.flags |= IEEE80211_STA_AUTO_BSSID_SEL;
181 else
182 sdata->u.mgd.flags &= ~IEEE80211_STA_AUTO_BSSID_SEL;
183 ret = ieee80211_sta_set_bssid(sdata, (u8 *) &ap_addr->sa_data);
184 if (ret)
185 return ret;
186 sdata->u.mgd.flags &= ~IEEE80211_STA_EXT_SME;
187 sdata->u.mgd.flags &= ~IEEE80211_STA_CONTROL_PORT;
188 ieee80211_sta_req_auth(sdata);
189 return 0;
190 } else if (sdata->vif.type == NL80211_IFTYPE_WDS) {
192 * If it is necessary to update the WDS peer address
193 * while the interface is running, then we need to do
194 * more work here, namely if it is running we need to
195 * add a new and remove the old STA entry, this is
196 * normally handled by _open() and _stop().
198 if (netif_running(dev))
199 return -EBUSY;
201 memcpy(&sdata->u.wds.remote_addr, (u8 *) &ap_addr->sa_data,
202 ETH_ALEN);
204 return 0;
207 return -EOPNOTSUPP;
211 static int ieee80211_ioctl_giwap(struct net_device *dev,
212 struct iw_request_info *info,
213 struct sockaddr *ap_addr, char *extra)
215 struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
217 if (sdata->vif.type == NL80211_IFTYPE_ADHOC)
218 return cfg80211_ibss_wext_giwap(dev, info, ap_addr, extra);
220 if (sdata->vif.type == NL80211_IFTYPE_STATION) {
221 if (sdata->u.mgd.state == IEEE80211_STA_MLME_ASSOCIATED) {
222 ap_addr->sa_family = ARPHRD_ETHER;
223 memcpy(&ap_addr->sa_data, sdata->u.mgd.bssid, ETH_ALEN);
224 } else
225 memset(&ap_addr->sa_data, 0, ETH_ALEN);
226 return 0;
227 } else if (sdata->vif.type == NL80211_IFTYPE_WDS) {
228 ap_addr->sa_family = ARPHRD_ETHER;
229 memcpy(&ap_addr->sa_data, sdata->u.wds.remote_addr, ETH_ALEN);
230 return 0;
233 return -EOPNOTSUPP;
237 static int ieee80211_ioctl_siwrate(struct net_device *dev,
238 struct iw_request_info *info,
239 struct iw_param *rate, char *extra)
241 struct ieee80211_local *local = wdev_priv(dev->ieee80211_ptr);
242 int i, err = -EINVAL;
243 u32 target_rate = rate->value / 100000;
244 struct ieee80211_sub_if_data *sdata;
245 struct ieee80211_supported_band *sband;
247 sdata = IEEE80211_DEV_TO_SUB_IF(dev);
249 sband = local->hw.wiphy->bands[local->hw.conf.channel->band];
251 /* target_rate = -1, rate->fixed = 0 means auto only, so use all rates
252 * target_rate = X, rate->fixed = 1 means only rate X
253 * target_rate = X, rate->fixed = 0 means all rates <= X */
254 sdata->max_ratectrl_rateidx = -1;
255 sdata->force_unicast_rateidx = -1;
256 if (rate->value < 0)
257 return 0;
259 for (i=0; i< sband->n_bitrates; i++) {
260 struct ieee80211_rate *brate = &sband->bitrates[i];
261 int this_rate = brate->bitrate;
263 if (target_rate == this_rate) {
264 sdata->max_ratectrl_rateidx = i;
265 if (rate->fixed)
266 sdata->force_unicast_rateidx = i;
267 err = 0;
268 break;
271 return err;
274 static int ieee80211_ioctl_giwrate(struct net_device *dev,
275 struct iw_request_info *info,
276 struct iw_param *rate, char *extra)
278 struct ieee80211_local *local = wdev_priv(dev->ieee80211_ptr);
279 struct sta_info *sta;
280 struct ieee80211_sub_if_data *sdata;
281 struct ieee80211_supported_band *sband;
283 sdata = IEEE80211_DEV_TO_SUB_IF(dev);
285 if (sdata->vif.type != NL80211_IFTYPE_STATION)
286 return -EOPNOTSUPP;
288 sband = local->hw.wiphy->bands[local->hw.conf.channel->band];
290 rcu_read_lock();
292 sta = sta_info_get(local, sdata->u.mgd.bssid);
294 if (sta && !(sta->last_tx_rate.flags & IEEE80211_TX_RC_MCS))
295 rate->value = sband->bitrates[sta->last_tx_rate.idx].bitrate;
296 else
297 rate->value = 0;
299 rcu_read_unlock();
301 if (!sta)
302 return -ENODEV;
304 rate->value *= 100000;
306 return 0;
309 static int ieee80211_ioctl_siwpower(struct net_device *dev,
310 struct iw_request_info *info,
311 struct iw_param *wrq,
312 char *extra)
314 struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
315 struct ieee80211_local *local = wdev_priv(dev->ieee80211_ptr);
316 struct ieee80211_conf *conf = &local->hw.conf;
317 int timeout = 0;
318 bool ps;
320 if (!(local->hw.flags & IEEE80211_HW_SUPPORTS_PS))
321 return -EOPNOTSUPP;
323 if (sdata->vif.type != NL80211_IFTYPE_STATION)
324 return -EINVAL;
326 if (wrq->disabled) {
327 ps = false;
328 timeout = 0;
329 goto set;
332 switch (wrq->flags & IW_POWER_MODE) {
333 case IW_POWER_ON: /* If not specified */
334 case IW_POWER_MODE: /* If set all mask */
335 case IW_POWER_ALL_R: /* If explicitely state all */
336 ps = true;
337 break;
338 default: /* Otherwise we ignore */
339 return -EINVAL;
342 if (wrq->flags & ~(IW_POWER_MODE | IW_POWER_TIMEOUT))
343 return -EINVAL;
345 if (wrq->flags & IW_POWER_TIMEOUT)
346 timeout = wrq->value / 1000;
348 set:
349 if (ps == sdata->u.mgd.powersave && timeout == conf->dynamic_ps_timeout)
350 return 0;
352 sdata->u.mgd.powersave = ps;
353 conf->dynamic_ps_timeout = timeout;
355 if (local->hw.flags & IEEE80211_HW_SUPPORTS_DYNAMIC_PS)
356 ieee80211_hw_config(local, IEEE80211_CONF_CHANGE_PS);
358 ieee80211_recalc_ps(local, -1);
360 return 0;
363 static int ieee80211_ioctl_giwpower(struct net_device *dev,
364 struct iw_request_info *info,
365 union iwreq_data *wrqu,
366 char *extra)
368 struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
370 wrqu->power.disabled = !sdata->u.mgd.powersave;
372 return 0;
375 static int ieee80211_ioctl_siwauth(struct net_device *dev,
376 struct iw_request_info *info,
377 struct iw_param *data, char *extra)
379 struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
380 int ret = 0;
382 switch (data->flags & IW_AUTH_INDEX) {
383 case IW_AUTH_WPA_VERSION:
384 case IW_AUTH_CIPHER_GROUP:
385 case IW_AUTH_WPA_ENABLED:
386 case IW_AUTH_RX_UNENCRYPTED_EAPOL:
387 case IW_AUTH_KEY_MGMT:
388 case IW_AUTH_CIPHER_GROUP_MGMT:
389 break;
390 case IW_AUTH_CIPHER_PAIRWISE:
391 if (sdata->vif.type == NL80211_IFTYPE_STATION) {
392 if (data->value & (IW_AUTH_CIPHER_WEP40 |
393 IW_AUTH_CIPHER_WEP104 | IW_AUTH_CIPHER_TKIP))
394 sdata->u.mgd.flags |=
395 IEEE80211_STA_TKIP_WEP_USED;
396 else
397 sdata->u.mgd.flags &=
398 ~IEEE80211_STA_TKIP_WEP_USED;
400 break;
401 case IW_AUTH_DROP_UNENCRYPTED:
402 sdata->drop_unencrypted = !!data->value;
403 break;
404 case IW_AUTH_PRIVACY_INVOKED:
405 if (sdata->vif.type != NL80211_IFTYPE_STATION)
406 ret = -EINVAL;
407 else {
408 sdata->u.mgd.flags &= ~IEEE80211_STA_PRIVACY_INVOKED;
410 * Privacy invoked by wpa_supplicant, store the
411 * value and allow associating to a protected
412 * network without having a key up front.
414 if (data->value)
415 sdata->u.mgd.flags |=
416 IEEE80211_STA_PRIVACY_INVOKED;
418 break;
419 case IW_AUTH_80211_AUTH_ALG:
420 if (sdata->vif.type == NL80211_IFTYPE_STATION)
421 sdata->u.mgd.auth_algs = data->value;
422 else
423 ret = -EOPNOTSUPP;
424 break;
425 case IW_AUTH_MFP:
426 if (!(sdata->local->hw.flags & IEEE80211_HW_MFP_CAPABLE)) {
427 ret = -EOPNOTSUPP;
428 break;
430 if (sdata->vif.type == NL80211_IFTYPE_STATION) {
431 switch (data->value) {
432 case IW_AUTH_MFP_DISABLED:
433 sdata->u.mgd.mfp = IEEE80211_MFP_DISABLED;
434 break;
435 case IW_AUTH_MFP_OPTIONAL:
436 sdata->u.mgd.mfp = IEEE80211_MFP_OPTIONAL;
437 break;
438 case IW_AUTH_MFP_REQUIRED:
439 sdata->u.mgd.mfp = IEEE80211_MFP_REQUIRED;
440 break;
441 default:
442 ret = -EINVAL;
444 } else
445 ret = -EOPNOTSUPP;
446 break;
447 default:
448 ret = -EOPNOTSUPP;
449 break;
451 return ret;
454 /* Get wireless statistics. Called by /proc/net/wireless and by SIOCGIWSTATS */
455 static struct iw_statistics *ieee80211_get_wireless_stats(struct net_device *dev)
457 struct ieee80211_local *local = wdev_priv(dev->ieee80211_ptr);
458 struct iw_statistics *wstats = &local->wstats;
459 struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
460 struct sta_info *sta = NULL;
462 rcu_read_lock();
464 if (sdata->vif.type == NL80211_IFTYPE_STATION)
465 sta = sta_info_get(local, sdata->u.mgd.bssid);
467 if (!sta) {
468 wstats->discard.fragment = 0;
469 wstats->discard.misc = 0;
470 wstats->qual.qual = 0;
471 wstats->qual.level = 0;
472 wstats->qual.noise = 0;
473 wstats->qual.updated = IW_QUAL_ALL_INVALID;
474 } else {
475 wstats->qual.updated = 0;
477 * mirror what cfg80211 does for iwrange/scan results,
478 * otherwise userspace gets confused.
480 if (local->hw.flags & (IEEE80211_HW_SIGNAL_UNSPEC |
481 IEEE80211_HW_SIGNAL_DBM)) {
482 wstats->qual.updated |= IW_QUAL_LEVEL_UPDATED;
483 wstats->qual.updated |= IW_QUAL_QUAL_UPDATED;
484 } else {
485 wstats->qual.updated |= IW_QUAL_LEVEL_INVALID;
486 wstats->qual.updated |= IW_QUAL_QUAL_INVALID;
489 if (local->hw.flags & IEEE80211_HW_SIGNAL_UNSPEC) {
490 wstats->qual.level = sta->last_signal;
491 wstats->qual.qual = sta->last_signal;
492 } else if (local->hw.flags & IEEE80211_HW_SIGNAL_DBM) {
493 int sig = sta->last_signal;
495 wstats->qual.updated |= IW_QUAL_DBM;
496 wstats->qual.level = sig;
497 if (sig < -110)
498 sig = -110;
499 else if (sig > -40)
500 sig = -40;
501 wstats->qual.qual = sig + 110;
504 if (local->hw.flags & IEEE80211_HW_NOISE_DBM) {
506 * This assumes that if driver reports noise, it also
507 * reports signal in dBm.
509 wstats->qual.noise = sta->last_noise;
510 wstats->qual.updated |= IW_QUAL_NOISE_UPDATED;
511 } else {
512 wstats->qual.updated |= IW_QUAL_NOISE_INVALID;
516 rcu_read_unlock();
518 return wstats;
521 static int ieee80211_ioctl_giwauth(struct net_device *dev,
522 struct iw_request_info *info,
523 struct iw_param *data, char *extra)
525 struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
526 int ret = 0;
528 switch (data->flags & IW_AUTH_INDEX) {
529 case IW_AUTH_80211_AUTH_ALG:
530 if (sdata->vif.type == NL80211_IFTYPE_STATION)
531 data->value = sdata->u.mgd.auth_algs;
532 else
533 ret = -EOPNOTSUPP;
534 break;
535 default:
536 ret = -EOPNOTSUPP;
537 break;
539 return ret;
543 /* Structures to export the Wireless Handlers */
545 static const iw_handler ieee80211_handler[] =
547 (iw_handler) NULL, /* SIOCSIWCOMMIT */
548 (iw_handler) cfg80211_wext_giwname, /* SIOCGIWNAME */
549 (iw_handler) NULL, /* SIOCSIWNWID */
550 (iw_handler) NULL, /* SIOCGIWNWID */
551 (iw_handler) ieee80211_ioctl_siwfreq, /* SIOCSIWFREQ */
552 (iw_handler) ieee80211_ioctl_giwfreq, /* SIOCGIWFREQ */
553 (iw_handler) cfg80211_wext_siwmode, /* SIOCSIWMODE */
554 (iw_handler) cfg80211_wext_giwmode, /* SIOCGIWMODE */
555 (iw_handler) NULL, /* SIOCSIWSENS */
556 (iw_handler) NULL, /* SIOCGIWSENS */
557 (iw_handler) NULL /* not used */, /* SIOCSIWRANGE */
558 (iw_handler) cfg80211_wext_giwrange, /* SIOCGIWRANGE */
559 (iw_handler) NULL /* not used */, /* SIOCSIWPRIV */
560 (iw_handler) NULL /* kernel code */, /* SIOCGIWPRIV */
561 (iw_handler) NULL /* not used */, /* SIOCSIWSTATS */
562 (iw_handler) NULL /* kernel code */, /* SIOCGIWSTATS */
563 (iw_handler) NULL, /* SIOCSIWSPY */
564 (iw_handler) NULL, /* SIOCGIWSPY */
565 (iw_handler) NULL, /* SIOCSIWTHRSPY */
566 (iw_handler) NULL, /* SIOCGIWTHRSPY */
567 (iw_handler) ieee80211_ioctl_siwap, /* SIOCSIWAP */
568 (iw_handler) ieee80211_ioctl_giwap, /* SIOCGIWAP */
569 (iw_handler) cfg80211_wext_siwmlme, /* SIOCSIWMLME */
570 (iw_handler) NULL, /* SIOCGIWAPLIST */
571 (iw_handler) cfg80211_wext_siwscan, /* SIOCSIWSCAN */
572 (iw_handler) cfg80211_wext_giwscan, /* SIOCGIWSCAN */
573 (iw_handler) ieee80211_ioctl_siwessid, /* SIOCSIWESSID */
574 (iw_handler) ieee80211_ioctl_giwessid, /* SIOCGIWESSID */
575 (iw_handler) NULL, /* SIOCSIWNICKN */
576 (iw_handler) NULL, /* SIOCGIWNICKN */
577 (iw_handler) NULL, /* -- hole -- */
578 (iw_handler) NULL, /* -- hole -- */
579 (iw_handler) ieee80211_ioctl_siwrate, /* SIOCSIWRATE */
580 (iw_handler) ieee80211_ioctl_giwrate, /* SIOCGIWRATE */
581 (iw_handler) cfg80211_wext_siwrts, /* SIOCSIWRTS */
582 (iw_handler) cfg80211_wext_giwrts, /* SIOCGIWRTS */
583 (iw_handler) cfg80211_wext_siwfrag, /* SIOCSIWFRAG */
584 (iw_handler) cfg80211_wext_giwfrag, /* SIOCGIWFRAG */
585 (iw_handler) cfg80211_wext_siwtxpower, /* SIOCSIWTXPOW */
586 (iw_handler) cfg80211_wext_giwtxpower, /* SIOCGIWTXPOW */
587 (iw_handler) cfg80211_wext_siwretry, /* SIOCSIWRETRY */
588 (iw_handler) cfg80211_wext_giwretry, /* SIOCGIWRETRY */
589 (iw_handler) cfg80211_wext_siwencode, /* SIOCSIWENCODE */
590 (iw_handler) cfg80211_wext_giwencode, /* SIOCGIWENCODE */
591 (iw_handler) ieee80211_ioctl_siwpower, /* SIOCSIWPOWER */
592 (iw_handler) ieee80211_ioctl_giwpower, /* SIOCGIWPOWER */
593 (iw_handler) NULL, /* -- hole -- */
594 (iw_handler) NULL, /* -- hole -- */
595 (iw_handler) ieee80211_ioctl_siwgenie, /* SIOCSIWGENIE */
596 (iw_handler) NULL, /* SIOCGIWGENIE */
597 (iw_handler) ieee80211_ioctl_siwauth, /* SIOCSIWAUTH */
598 (iw_handler) ieee80211_ioctl_giwauth, /* SIOCGIWAUTH */
599 (iw_handler) cfg80211_wext_siwencodeext, /* SIOCSIWENCODEEXT */
600 (iw_handler) NULL, /* SIOCGIWENCODEEXT */
601 (iw_handler) NULL, /* SIOCSIWPMKSA */
602 (iw_handler) NULL, /* -- hole -- */
605 const struct iw_handler_def ieee80211_iw_handler_def =
607 .num_standard = ARRAY_SIZE(ieee80211_handler),
608 .standard = (iw_handler *) ieee80211_handler,
609 .get_wireless_stats = ieee80211_get_wireless_stats,