Commit | Line | Data |
---|---|---|
f0706e82 JB |
1 | /* |
2 | * Copyright 2002-2005, Instant802 Networks, Inc. | |
3 | * Copyright 2005-2006, Devicescape Software, Inc. | |
4 | * | |
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 | */ | |
9 | ||
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> | |
21 | ||
22 | #include <net/mac80211.h> | |
23 | #include "ieee80211_i.h" | |
2c8dccc7 JB |
24 | #include "led.h" |
25 | #include "rate.h" | |
f0706e82 JB |
26 | #include "wpa.h" |
27 | #include "aes_ccm.h" | |
f0706e82 | 28 | |
b708e610 | 29 | |
f0706e82 | 30 | |
f0706e82 JB |
31 | /* Structures to export the Wireless Handlers */ |
32 | ||
33 | static const iw_handler ieee80211_handler[] = | |
34 | { | |
35 | (iw_handler) NULL, /* SIOCSIWCOMMIT */ | |
fee52678 | 36 | (iw_handler) cfg80211_wext_giwname, /* SIOCGIWNAME */ |
f0706e82 JB |
37 | (iw_handler) NULL, /* SIOCSIWNWID */ |
38 | (iw_handler) NULL, /* SIOCGIWNWID */ | |
0e82ffe3 JB |
39 | (iw_handler) cfg80211_wext_siwfreq, /* SIOCSIWFREQ */ |
40 | (iw_handler) cfg80211_wext_giwfreq, /* SIOCGIWFREQ */ | |
e60c7744 JB |
41 | (iw_handler) cfg80211_wext_siwmode, /* SIOCSIWMODE */ |
42 | (iw_handler) cfg80211_wext_giwmode, /* SIOCGIWMODE */ | |
f0706e82 JB |
43 | (iw_handler) NULL, /* SIOCSIWSENS */ |
44 | (iw_handler) NULL, /* SIOCGIWSENS */ | |
45 | (iw_handler) NULL /* not used */, /* SIOCSIWRANGE */ | |
4aa188e1 | 46 | (iw_handler) cfg80211_wext_giwrange, /* SIOCGIWRANGE */ |
f0706e82 JB |
47 | (iw_handler) NULL /* not used */, /* SIOCSIWPRIV */ |
48 | (iw_handler) NULL /* kernel code */, /* SIOCGIWPRIV */ | |
49 | (iw_handler) NULL /* not used */, /* SIOCSIWSTATS */ | |
50 | (iw_handler) NULL /* kernel code */, /* SIOCGIWSTATS */ | |
5d4ecd93 JB |
51 | (iw_handler) NULL, /* SIOCSIWSPY */ |
52 | (iw_handler) NULL, /* SIOCGIWSPY */ | |
53 | (iw_handler) NULL, /* SIOCSIWTHRSPY */ | |
54 | (iw_handler) NULL, /* SIOCGIWTHRSPY */ | |
562e4822 JB |
55 | (iw_handler) cfg80211_wext_siwap, /* SIOCSIWAP */ |
56 | (iw_handler) cfg80211_wext_giwap, /* SIOCGIWAP */ | |
691597cb | 57 | (iw_handler) cfg80211_wext_siwmlme, /* SIOCSIWMLME */ |
f0706e82 | 58 | (iw_handler) NULL, /* SIOCGIWAPLIST */ |
2a519311 JB |
59 | (iw_handler) cfg80211_wext_siwscan, /* SIOCSIWSCAN */ |
60 | (iw_handler) cfg80211_wext_giwscan, /* SIOCGIWSCAN */ | |
1f9298f9 JB |
61 | (iw_handler) cfg80211_wext_siwessid, /* SIOCSIWESSID */ |
62 | (iw_handler) cfg80211_wext_giwessid, /* SIOCGIWESSID */ | |
f0706e82 JB |
63 | (iw_handler) NULL, /* SIOCSIWNICKN */ |
64 | (iw_handler) NULL, /* SIOCGIWNICKN */ | |
65 | (iw_handler) NULL, /* -- hole -- */ | |
66 | (iw_handler) NULL, /* -- hole -- */ | |
9930380f JB |
67 | (iw_handler) cfg80211_wext_siwrate, /* SIOCSIWRATE */ |
68 | (iw_handler) cfg80211_wext_giwrate, /* SIOCGIWRATE */ | |
b9a5f8ca JM |
69 | (iw_handler) cfg80211_wext_siwrts, /* SIOCSIWRTS */ |
70 | (iw_handler) cfg80211_wext_giwrts, /* SIOCGIWRTS */ | |
71 | (iw_handler) cfg80211_wext_siwfrag, /* SIOCSIWFRAG */ | |
72 | (iw_handler) cfg80211_wext_giwfrag, /* SIOCGIWFRAG */ | |
7643a2c3 JB |
73 | (iw_handler) cfg80211_wext_siwtxpower, /* SIOCSIWTXPOW */ |
74 | (iw_handler) cfg80211_wext_giwtxpower, /* SIOCGIWTXPOW */ | |
b9a5f8ca JM |
75 | (iw_handler) cfg80211_wext_siwretry, /* SIOCSIWRETRY */ |
76 | (iw_handler) cfg80211_wext_giwretry, /* SIOCGIWRETRY */ | |
08645126 JB |
77 | (iw_handler) cfg80211_wext_siwencode, /* SIOCSIWENCODE */ |
78 | (iw_handler) cfg80211_wext_giwencode, /* SIOCGIWENCODE */ | |
bc92afd9 JB |
79 | (iw_handler) cfg80211_wext_siwpower, /* SIOCSIWPOWER */ |
80 | (iw_handler) cfg80211_wext_giwpower, /* SIOCGIWPOWER */ | |
f0706e82 JB |
81 | (iw_handler) NULL, /* -- hole -- */ |
82 | (iw_handler) NULL, /* -- hole -- */ | |
f2129354 | 83 | (iw_handler) cfg80211_wext_siwgenie, /* SIOCSIWGENIE */ |
f0706e82 | 84 | (iw_handler) NULL, /* SIOCGIWGENIE */ |
f2129354 JB |
85 | (iw_handler) cfg80211_wext_siwauth, /* SIOCSIWAUTH */ |
86 | (iw_handler) cfg80211_wext_giwauth, /* SIOCGIWAUTH */ | |
08645126 | 87 | (iw_handler) cfg80211_wext_siwencodeext, /* SIOCSIWENCODEEXT */ |
f0706e82 JB |
88 | (iw_handler) NULL, /* SIOCGIWENCODEEXT */ |
89 | (iw_handler) NULL, /* SIOCSIWPMKSA */ | |
90 | (iw_handler) NULL, /* -- hole -- */ | |
91 | }; | |
92 | ||
f0706e82 JB |
93 | const struct iw_handler_def ieee80211_iw_handler_def = |
94 | { | |
95 | .num_standard = ARRAY_SIZE(ieee80211_handler), | |
f0706e82 | 96 | .standard = (iw_handler *) ieee80211_handler, |
8990646d | 97 | .get_wireless_stats = cfg80211_wireless_stats, |
f0706e82 | 98 | }; |