summaryrefslogtreecommitdiff
blob: b8510de7c28d4be8714668739c7dbfa3e36fb317 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
diff --git a/net/ieee80211.h b/net/ieee80211.h
--- a/net/ieee80211.h
+++ b/net/ieee80211.h
@@ -29,6 +29,21 @@
 #include <linux/kernel.h>	/* ARRAY_SIZE */
 #include <linux/wireless.h>
 
+#if WIRELESS_EXT < 18
+#define IW_QUAL_QUAL_UPDATED    0x01    /* Value was updated since last read */
+#define IW_QUAL_LEVEL_UPDATED   0x02
+#define IW_QUAL_NOISE_UPDATED   0x04
+#define IW_QUAL_ALL_UPDATED     0x07
+#define IW_QUAL_QUAL_INVALID    0x10    /* Driver doesn't provide value */
+#define IW_QUAL_LEVEL_INVALID   0x20
+#define IW_QUAL_NOISE_INVALID   0x40
+#define IW_QUAL_ALL_INVALID     0x70
+#endif
+
+#if WIRELESS_EXT < 19
+#define IW_QUAL_DBM             0x08    /* Level + Noise are dBm */
+#endif
+
 #define IEEE80211_VERSION "1.1.5"
 
 #define IEEE80211_DATA_LEN		2304
diff --git a/ieee80211_crypt_tkip.c b/ieee80211_crypt_tkip.c
--- a/ieee80211_crypt_tkip.c
+++ b/ieee80211_crypt_tkip.c
@@ -555,6 +555,7 @@ static void ieee80211_michael_mic_failur
 					  struct ieee80211_hdr_4addr *hdr,
 					  int keyidx)
 {
+#if WIRELESS_EXT >= 18
 	union iwreq_data wrqu;
 	struct iw_michaelmicfailure ev;
 
@@ -570,6 +571,7 @@ static void ieee80211_michael_mic_failur
 	memset(&wrqu, 0, sizeof(wrqu));
 	wrqu.data.length = sizeof(ev);
 	wireless_send_event(dev, IWEVMICHAELMICFAILURE, &wrqu, (char *)&ev);
+#endif
 }
 
 static int ieee80211_michael_mic_verify(struct sk_buff *skb, int keyidx,
diff --git a/ieee80211_wx.c b/ieee80211_wx.c
--- a/ieee80211_wx.c
+++ b/ieee80211_wx.c
@@ -488,6 +488,7 @@ int ieee80211_wx_get_encode(struct ieee8
 	return 0;
 }
 
+#if WIRELESS_EXT >= 18
 int ieee80211_wx_set_encodeext(struct ieee80211_device *ieee,
 			       struct iw_request_info *info,
 			       union iwreq_data *wrqu, char *extra)
@@ -721,6 +722,7 @@ int ieee80211_wx_get_encodeext(struct ie
 
 EXPORT_SYMBOL(ieee80211_wx_set_encodeext);
 EXPORT_SYMBOL(ieee80211_wx_get_encodeext);
+#endif
 
 EXPORT_SYMBOL(ieee80211_wx_get_scan);
 EXPORT_SYMBOL(ieee80211_wx_set_encode);