Commit e6c1ef6c authored by Joel Pelaez Jorge's avatar Joel Pelaez Jorge Committed by Greg Kroah-Hartman

Staging: rtl8192u: Remove old WIRELESS_EXT support

Remove support for building against ancient WIRELESS_EXT versions,
only leaving support for the current version: 22
Signed-off-by: default avatarJoel Pelaez Jorge <joelpelaez@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 244a0341
...@@ -354,12 +354,10 @@ enum _ReasonCode{ ...@@ -354,12 +354,10 @@ enum _ReasonCode{
#define ieee80211_wx_get_scan ieee80211_wx_get_scan_rsl #define ieee80211_wx_get_scan ieee80211_wx_get_scan_rsl
#define ieee80211_wx_set_encode ieee80211_wx_set_encode_rsl #define ieee80211_wx_set_encode ieee80211_wx_set_encode_rsl
#define ieee80211_wx_get_encode ieee80211_wx_get_encode_rsl #define ieee80211_wx_get_encode ieee80211_wx_get_encode_rsl
#if WIRELESS_EXT >= 18
#define ieee80211_wx_set_mlme ieee80211_wx_set_mlme_rsl #define ieee80211_wx_set_mlme ieee80211_wx_set_mlme_rsl
#define ieee80211_wx_set_auth ieee80211_wx_set_auth_rsl #define ieee80211_wx_set_auth ieee80211_wx_set_auth_rsl
#define ieee80211_wx_set_encode_ext ieee80211_wx_set_encode_ext_rsl #define ieee80211_wx_set_encode_ext ieee80211_wx_set_encode_ext_rsl
#define ieee80211_wx_get_encode_ext ieee80211_wx_get_encode_ext_rsl #define ieee80211_wx_get_encode_ext ieee80211_wx_get_encode_ext_rsl
#endif
typedef struct ieee_param { typedef struct ieee_param {
...@@ -392,16 +390,6 @@ typedef struct ieee_param { ...@@ -392,16 +390,6 @@ typedef struct ieee_param {
}ieee_param; }ieee_param;
#if WIRELESS_EXT < 17
#define IW_QUAL_QUAL_INVALID 0x10
#define IW_QUAL_LEVEL_INVALID 0x20
#define IW_QUAL_NOISE_INVALID 0x40
#define IW_QUAL_QUAL_UPDATED 0x1
#define IW_QUAL_LEVEL_UPDATED 0x2
#define IW_QUAL_NOISE_UPDATED 0x4
#endif
// linux under 2.6.9 release may not support it, so modify it for common use // linux under 2.6.9 release may not support it, so modify it for common use
#define MSECS(t) msecs_to_jiffies(t) #define MSECS(t) msecs_to_jiffies(t)
#define msleep_interruptible_rsl msleep_interruptible #define msleep_interruptible_rsl msleep_interruptible
...@@ -2398,7 +2386,6 @@ extern int ieee80211_wx_set_encode(struct ieee80211_device *ieee, ...@@ -2398,7 +2386,6 @@ extern int ieee80211_wx_set_encode(struct ieee80211_device *ieee,
extern int ieee80211_wx_get_encode(struct ieee80211_device *ieee, extern int ieee80211_wx_get_encode(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *key); union iwreq_data *wrqu, char *key);
#if WIRELESS_EXT >= 18
extern int ieee80211_wx_get_encode_ext(struct ieee80211_device *ieee, extern int ieee80211_wx_get_encode_ext(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra); union iwreq_data *wrqu, char *extra);
...@@ -2411,7 +2398,6 @@ extern int ieee80211_wx_set_auth(struct ieee80211_device *ieee, ...@@ -2411,7 +2398,6 @@ extern int ieee80211_wx_set_auth(struct ieee80211_device *ieee,
extern int ieee80211_wx_set_mlme(struct ieee80211_device *ieee, extern int ieee80211_wx_set_mlme(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra); union iwreq_data *wrqu, char *extra);
#endif
extern int ieee80211_wx_set_gen_ie(struct ieee80211_device *ieee, u8 *ie, size_t len); extern int ieee80211_wx_set_gen_ie(struct ieee80211_device *ieee, u8 *ie, size_t len);
/* ieee80211_softmac.c */ /* ieee80211_softmac.c */
......
...@@ -950,7 +950,6 @@ int ieee80211_rx(struct ieee80211_device *ieee, struct sk_buff *skb, ...@@ -950,7 +950,6 @@ int ieee80211_rx(struct ieee80211_device *ieee, struct sk_buff *skb,
//IEEE80211_DEBUG_DATA(IEEE80211_DL_DATA, skb->data, skb->len); //IEEE80211_DEBUG_DATA(IEEE80211_DL_DATA, skb->data, skb->len);
#ifdef NOT_YET #ifdef NOT_YET
#if WIRELESS_EXT > 15
/* Put this code here so that we avoid duplicating it in all /* Put this code here so that we avoid duplicating it in all
* Rx paths. - Jean II */ * Rx paths. - Jean II */
#ifdef IW_WIRELESS_SPY /* defined in iw_handler.h */ #ifdef IW_WIRELESS_SPY /* defined in iw_handler.h */
...@@ -964,18 +963,16 @@ int ieee80211_rx(struct ieee80211_device *ieee, struct sk_buff *skb, ...@@ -964,18 +963,16 @@ int ieee80211_rx(struct ieee80211_device *ieee, struct sk_buff *skb,
wireless_spy_update(dev, hdr->addr2, &wstats); wireless_spy_update(dev, hdr->addr2, &wstats);
} }
#endif /* IW_WIRELESS_SPY */ #endif /* IW_WIRELESS_SPY */
#endif /* WIRELESS_EXT > 15 */
hostap_update_rx_stats(local->ap, hdr, rx_stats); hostap_update_rx_stats(local->ap, hdr, rx_stats);
#endif #endif
#if WIRELESS_EXT > 15
if (ieee->iw_mode == IW_MODE_MONITOR) { if (ieee->iw_mode == IW_MODE_MONITOR) {
ieee80211_monitor_rx(ieee, skb, rx_stats); ieee80211_monitor_rx(ieee, skb, rx_stats);
stats->rx_packets++; stats->rx_packets++;
stats->rx_bytes += skb->len; stats->rx_bytes += skb->len;
return 1; return 1;
} }
#endif
if (ieee->host_decrypt) { if (ieee->host_decrypt) {
int idx = 0; int idx = 0;
if (skb->len >= hdrlen + 3) if (skb->len >= hdrlen + 3)
......
...@@ -194,7 +194,7 @@ static inline char *rtl819x_translate_scan(struct ieee80211_device *ieee, ...@@ -194,7 +194,7 @@ static inline char *rtl819x_translate_scan(struct ieee80211_device *ieee,
iwe.u.data.length = p - custom; iwe.u.data.length = p - custom;
if (iwe.u.data.length) if (iwe.u.data.length)
start = iwe_stream_add_point(info, start, stop, &iwe, custom); start = iwe_stream_add_point(info, start, stop, &iwe, custom);
#if (WIRELESS_EXT < 18)
if (ieee->wpa_enabled && network->wpa_ie_len){ if (ieee->wpa_enabled && network->wpa_ie_len){
char buf[MAX_WPA_IE_LEN * 2 + 30]; char buf[MAX_WPA_IE_LEN * 2 + 30];
// printk("WPA IE\n"); // printk("WPA IE\n");
...@@ -224,26 +224,6 @@ static inline char *rtl819x_translate_scan(struct ieee80211_device *ieee, ...@@ -224,26 +224,6 @@ static inline char *rtl819x_translate_scan(struct ieee80211_device *ieee,
iwe.u.data.length = strlen(buf); iwe.u.data.length = strlen(buf);
start = iwe_stream_add_point(info, start, stop, &iwe, buf); start = iwe_stream_add_point(info, start, stop, &iwe, buf);
} }
#else
memset(&iwe, 0, sizeof(iwe));
if (network->wpa_ie_len)
{
char buf[MAX_WPA_IE_LEN];
memcpy(buf, network->wpa_ie, network->wpa_ie_len);
iwe.cmd = IWEVGENIE;
iwe.u.data.length = network->wpa_ie_len;
start = iwe_stream_add_point(info, start, stop, &iwe, buf);
}
memset(&iwe, 0, sizeof(iwe));
if (network->rsn_ie_len)
{
char buf[MAX_WPA_IE_LEN];
memcpy(buf, network->rsn_ie, network->rsn_ie_len);
iwe.cmd = IWEVGENIE;
iwe.u.data.length = network->rsn_ie_len;
start = iwe_stream_add_point(info, start, stop, &iwe, buf);
}
#endif
/* Add EXTRA: Age to display seconds since last beacon/probe response /* Add EXTRA: Age to display seconds since last beacon/probe response
...@@ -525,7 +505,6 @@ int ieee80211_wx_get_encode(struct ieee80211_device *ieee, ...@@ -525,7 +505,6 @@ int ieee80211_wx_get_encode(struct ieee80211_device *ieee,
} }
EXPORT_SYMBOL(ieee80211_wx_get_encode); EXPORT_SYMBOL(ieee80211_wx_get_encode);
#if (WIRELESS_EXT >= 18)
int ieee80211_wx_set_encode_ext(struct ieee80211_device *ieee, int ieee80211_wx_set_encode_ext(struct ieee80211_device *ieee,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra) union iwreq_data *wrqu, char *extra)
...@@ -836,7 +815,6 @@ int ieee80211_wx_set_auth(struct ieee80211_device *ieee, ...@@ -836,7 +815,6 @@ int ieee80211_wx_set_auth(struct ieee80211_device *ieee,
return 0; return 0;
} }
EXPORT_SYMBOL(ieee80211_wx_set_auth); EXPORT_SYMBOL(ieee80211_wx_set_auth);
#endif
int ieee80211_wx_set_gen_ie(struct ieee80211_device *ieee, u8 *ie, size_t len) int ieee80211_wx_set_gen_ie(struct ieee80211_device *ieee, u8 *ie, size_t len)
{ {
......
...@@ -4978,12 +4978,8 @@ static int rtl8192_usb_probe(struct usb_interface *intf, ...@@ -4978,12 +4978,8 @@ static int rtl8192_usb_probe(struct usb_interface *intf,
dev->netdev_ops = &rtl8192_netdev_ops; dev->netdev_ops = &rtl8192_netdev_ops;
#if WIRELESS_EXT >= 12
#if WIRELESS_EXT < 17
dev->get_wireless_stats = r8192_get_wireless_stats;
#endif
dev->wireless_handlers = (struct iw_handler_def *) &r8192_wx_handlers_def; dev->wireless_handlers = (struct iw_handler_def *) &r8192_wx_handlers_def;
#endif
dev->type = ARPHRD_ETHER; dev->type = ARPHRD_ETHER;
dev->watchdog_timeo = HZ*3; //modified by john, 0805 dev->watchdog_timeo = HZ*3; //modified by john, 0805
......
...@@ -319,10 +319,8 @@ static int rtl8180_wx_get_range(struct net_device *dev, ...@@ -319,10 +319,8 @@ static int rtl8180_wx_get_range(struct net_device *dev,
} }
range->num_frequency = val; range->num_frequency = val;
range->num_channels = val; range->num_channels = val;
#if WIRELESS_EXT > 17
range->enc_capa = IW_ENC_CAPA_WPA|IW_ENC_CAPA_WPA2| range->enc_capa = IW_ENC_CAPA_WPA|IW_ENC_CAPA_WPA2|
IW_ENC_CAPA_CIPHER_TKIP|IW_ENC_CAPA_CIPHER_CCMP; IW_ENC_CAPA_CIPHER_TKIP|IW_ENC_CAPA_CIPHER_CCMP;
#endif
tmp->scan_capa = 0x01; tmp->scan_capa = 0x01;
return 0; return 0;
} }
...@@ -732,7 +730,6 @@ static int r8192_wx_set_sens(struct net_device *dev, ...@@ -732,7 +730,6 @@ static int r8192_wx_set_sens(struct net_device *dev,
return err; return err;
} }
#if (WIRELESS_EXT >= 18)
//hw security need to reorganized. //hw security need to reorganized.
static int r8192_wx_set_enc_ext(struct net_device *dev, static int r8192_wx_set_enc_ext(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
...@@ -842,7 +839,7 @@ static int r8192_wx_set_mlme(struct net_device *dev, ...@@ -842,7 +839,7 @@ static int r8192_wx_set_mlme(struct net_device *dev,
up(&priv->wx_sem); up(&priv->wx_sem);
return ret; return ret;
} }
#endif
static int r8192_wx_set_gen_ie(struct net_device *dev, static int r8192_wx_set_gen_ie(struct net_device *dev,
struct iw_request_info *info, struct iw_request_info *info,
union iwreq_data *data, char *extra) union iwreq_data *data, char *extra)
...@@ -890,11 +887,7 @@ static iw_handler r8192_wx_handlers[] = ...@@ -890,11 +887,7 @@ static iw_handler r8192_wx_handlers[] =
NULL, /* SIOCWIWTHRSPY */ NULL, /* SIOCWIWTHRSPY */
r8192_wx_set_wap, /* SIOCSIWAP */ r8192_wx_set_wap, /* SIOCSIWAP */
r8192_wx_get_wap, /* SIOCGIWAP */ r8192_wx_get_wap, /* SIOCGIWAP */
#if (WIRELESS_EXT >= 18)
r8192_wx_set_mlme, /* MLME-- */ r8192_wx_set_mlme, /* MLME-- */
#else
NULL,
#endif
dummy, /* SIOCGIWAPLIST -- deprecated */ dummy, /* SIOCGIWAPLIST -- deprecated */
r8192_wx_set_scan, /* SIOCSIWSCAN */ r8192_wx_set_scan, /* SIOCSIWSCAN */
r8192_wx_get_scan, /* SIOCGIWSCAN */ r8192_wx_get_scan, /* SIOCGIWSCAN */
...@@ -923,17 +916,10 @@ static iw_handler r8192_wx_handlers[] = ...@@ -923,17 +916,10 @@ static iw_handler r8192_wx_handlers[] =
r8192_wx_set_gen_ie,//NULL, /* SIOCSIWGENIE */ r8192_wx_set_gen_ie,//NULL, /* SIOCSIWGENIE */
NULL, /* SIOCSIWGENIE */ NULL, /* SIOCSIWGENIE */
#if (WIRELESS_EXT >= 18)
r8192_wx_set_auth,//NULL, /* SIOCSIWAUTH */ r8192_wx_set_auth,//NULL, /* SIOCSIWAUTH */
NULL,//r8192_wx_get_auth,//NULL, /* SIOCSIWAUTH */ NULL,//r8192_wx_get_auth,//NULL, /* SIOCSIWAUTH */
r8192_wx_set_enc_ext, /* SIOCSIWENCODEEXT */ r8192_wx_set_enc_ext, /* SIOCSIWENCODEEXT */
NULL,//r8192_wx_get_enc_ext,//NULL, /* SIOCSIWENCODEEXT */ NULL,//r8192_wx_get_enc_ext,//NULL, /* SIOCSIWENCODEEXT */
#else
NULL,
NULL,
NULL,
NULL,
#endif
NULL, /* SIOCSIWPMKSA */ NULL, /* SIOCSIWPMKSA */
NULL, /*---hole---*/ NULL, /*---hole---*/
...@@ -977,7 +963,6 @@ static iw_handler r8192_private_handler[] = { ...@@ -977,7 +963,6 @@ static iw_handler r8192_private_handler[] = {
r8192_wx_force_reset, r8192_wx_force_reset,
}; };
//#if WIRELESS_EXT >= 17
struct iw_statistics *r8192_get_wireless_stats(struct net_device *dev) struct iw_statistics *r8192_get_wireless_stats(struct net_device *dev)
{ {
struct r8192_priv *priv = ieee80211_priv(dev); struct r8192_priv *priv = ieee80211_priv(dev);
...@@ -1006,7 +991,6 @@ struct iw_statistics *r8192_get_wireless_stats(struct net_device *dev) ...@@ -1006,7 +991,6 @@ struct iw_statistics *r8192_get_wireless_stats(struct net_device *dev)
wstats->qual.updated = IW_QUAL_ALL_UPDATED| IW_QUAL_DBM; wstats->qual.updated = IW_QUAL_ALL_UPDATED| IW_QUAL_DBM;
return wstats; return wstats;
} }
//#endif
struct iw_handler_def r8192_wx_handlers_def={ struct iw_handler_def r8192_wx_handlers_def={
...@@ -1015,8 +999,6 @@ struct iw_handler_def r8192_wx_handlers_def={ ...@@ -1015,8 +999,6 @@ struct iw_handler_def r8192_wx_handlers_def={
.private = r8192_private_handler, .private = r8192_private_handler,
.num_private = ARRAY_SIZE(r8192_private_handler), .num_private = ARRAY_SIZE(r8192_private_handler),
.num_private_args = sizeof(r8192_private_args) / sizeof(struct iw_priv_args), .num_private_args = sizeof(r8192_private_args) / sizeof(struct iw_priv_args),
#if WIRELESS_EXT >= 17
.get_wireless_stats = r8192_get_wireless_stats, .get_wireless_stats = r8192_get_wireless_stats,
#endif
.private_args = (struct iw_priv_args *)r8192_private_args, .private_args = (struct iw_priv_args *)r8192_private_args,
}; };
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment