diff options
author | Guido Guenther <agx@sigxcpu.org> | 2007-01-10 12:42:44 +0100 |
---|---|---|
committer | Guido Guenther <agx@bogon.sigxcpu.org> | 2007-01-10 12:42:44 +0100 |
commit | b32e135ba4476e748d27939869f9f2b4afefdc53 (patch) | |
tree | 82aedaf20d709a8ab2a971e2e9e98113f7dda43f | |
parent | c403f4d39f6b4c5b28dcd2ea66a6c23fdabf116a (diff) |
remove support for wireless extensions < 21
bump supported wireless extension to 21
-rw-r--r-- | at76c503.c | 49 |
1 files changed, 4 insertions, 45 deletions
@@ -51,21 +51,6 @@ #include "at76c503.h" -#if WIRELESS_EXT < 17 -#define IW_QUAL_QUAL_UPDATED 0x01 -#define IW_QUAL_LEVEL_UPDATED 0x02 -#define IW_QUAL_NOISE_UPDATED 0x04 -#define IW_QUAL_QUAL_INVALID 0x10 -#define IW_QUAL_LEVEL_INVALID 0x20 -#define IW_QUAL_NOISE_INVALID 0x40 -#endif - -#if WIRELESS_EXT < 19 -#define IW_QUAL_ALL_UPDATED 0x07 -#define IW_QUAL_DBM 0x08 -#define IW_QUAL_ALL_INVALID 0x70 -#endif - /* timeout in seconds for the usb_control_msg in get_cmd_status * and set_card_command */ @@ -83,7 +68,7 @@ #define set_eth_hdr(s,p) (s)->mac.raw=(unsigned char *)(p) /* wireless extension level this source currently supports */ -#define WIRELESS_EXT_SUPPORTED 16 +#define WIRELESS_EXT_SUPPORTED 21 #ifndef USB_ASYNC_UNLINK #ifdef URB_ASYNC_UNLINK @@ -4529,9 +4514,7 @@ static void at76c503_tx_timeout(struct net_device *netdev) if (!dev) return; warn("%s: tx timeout.", netdev->name); -#if WIRELESS_EXT < 17 - dev->write_urb->transfer_flags |= USB_ASYNC_UNLINK; -#endif + usb_unlink_urb(dev->write_urb); dev->stats.tx_errors++; } @@ -5253,9 +5236,7 @@ static int at76c503_iw_handler_set_scan(struct net_device *netdev, struct at76c503 *dev = (struct at76c503*)netdev->priv; unsigned long flags; int ret = 0; -#if WIRELESS_EXT > 19 struct iw_scan_req *req = NULL; -#endif dbg(DBG_IOCTL, "%s: SIOCSIWSCAN", netdev->name); @@ -5294,7 +5275,6 @@ static int at76c503_iw_handler_set_scan(struct net_device *netdev, netif_stop_queue(dev->netdev); } // Try to do passive or active scan if WE asks as. -#if WIRELESS_EXT > 19 if (wrqu->data.length && wrqu->data.length == sizeof(struct iw_scan_req)) { req = (struct iw_scan_req *)extra; @@ -5320,7 +5300,6 @@ static int at76c503_iw_handler_set_scan(struct net_device *netdev, } UNLOCK_ISTATE() } -#endif // change to scanning state NEW_STATE(dev, SCANNING); @@ -5460,22 +5439,11 @@ static int at76c503_iw_handler_set_essid(struct net_device *netdev, dbg(DBG_IOCTL, "%s: SIOCSIWESSID - %s", netdev->name, extra); - if (data->flags) - { + if (data->flags) { memcpy(dev->essid, extra, data->length); dev->essid_size = data->length; -#if WIRELESS_EXT < 21 - /* For historic reasons, the SSID length used to include one - * extra character, C string nul termination, even though SSID is - * really an octet string that should not be presented as a C - * string. WE-21 changes this to explicitly require the length - * _not_ to include nul termination, but for WE < 21, decrement - * the length count here to remove the nul termination. */ - dev->essid_size = max(dev->essid_size - 1, 0); -#endif } - else - { + else { /* Use any SSID */ dev->essid_size = 0; } @@ -6236,12 +6204,7 @@ static const struct iw_handler_def at76c503_handler_def = .standard = (iw_handler *) at76c503_handlers, .private = (iw_handler *) at76c503_priv_handlers, .private_args = (struct iw_priv_args *) at76c503_priv_args, -#if WIRELESS_EXT > 16 .get_wireless_stats = at76c503_get_wireless_stats, -#endif -#if WIRELESS_EXT == 15 || WIRELESS_EXT == 16 - .spy_offset = offsetof(struct at76c503, spy_data), -#endif }; @@ -6582,13 +6545,9 @@ static int init_new_device(struct at76c503 *dev) netdev->get_stats = at76c503_get_stats; netdev->ethtool_ops = &at76c503_ethtool_ops; -#if WIRELESS_EXT > 16 /* Add pointers to enable iwspy support. */ dev->wireless_data.spy_data = &dev->spy_data; netdev->wireless_data = &dev->wireless_data; -#else /* WIRELESS_EXT > 16 */ - netdev->get_wireless_stats = at76c503_get_wireless_stats; -#endif /* WIRELESS_EXT > 16 */ netdev->hard_start_xmit = at76c503_tx; netdev->tx_timeout = at76c503_tx_timeout; |