summaryrefslogtreecommitdiff
path: root/drivers/staging/rtl8187se/ieee80211/ieee80211.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/staging/rtl8187se/ieee80211/ieee80211.h')
-rw-r--r--drivers/staging/rtl8187se/ieee80211/ieee80211.h140
1 files changed, 2 insertions, 138 deletions
diff --git a/drivers/staging/rtl8187se/ieee80211/ieee80211.h b/drivers/staging/rtl8187se/ieee80211/ieee80211.h
index 58336080ad50..0a5e7158d66b 100644
--- a/drivers/staging/rtl8187se/ieee80211/ieee80211.h
+++ b/drivers/staging/rtl8187se/ieee80211/ieee80211.h
@@ -29,10 +29,7 @@
#include <linux/jiffies.h>
#include <linux/timer.h>
#include <linux/sched.h>
-
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,13))
#include <linux/wireless.h>
-#endif
/*
#ifndef bool
@@ -47,19 +44,12 @@
#define false 0
#endif
*/
-#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,20))
-#ifndef bool
-typedef enum{false = 0, true} bool;
-#endif
-#endif
-//#ifdef JOHN_HWSEC
+
#define KEY_TYPE_NA 0x0
#define KEY_TYPE_WEP40 0x1
#define KEY_TYPE_TKIP 0x2
#define KEY_TYPE_CCMP 0x4
#define KEY_TYPE_WEP104 0x5
-//#endif
-
#define aSifsTime 10
@@ -112,58 +102,6 @@ typedef enum{false = 0, true} bool;
#define IEEE_CRYPT_ALG_NAME_LEN 16
-#if (LINUX_VERSION_CODE > KERNEL_VERSION(2,6,10))
-#define ieee80211_wx_get_scan ieee80211_wx_get_scan_rtl
-#define ieee80211_wx_set_encode ieee80211_wx_set_encode_rtl
-#define ieee80211_wx_get_encode ieee80211_wx_get_encode_rtl
-////////////////////////////////
-// added for kernel conflict under FC5
-#define ieee80211_wx_get_name ieee80211_wx_get_name_rtl
-#define free_ieee80211 free_ieee80211_rtl
-#define alloc_ieee80211 alloc_ieee80211_rtl
-///////////////////////////////
-#endif
-//error in ubuntu2.6.22,so add these
-#define ieee80211_wake_queue ieee80211_wake_queue_rtl
-#define ieee80211_stop_queue ieee80211_stop_queue_rtl
-
-#define ieee80211_rx ieee80211_rx_rtl
-
-#define ieee80211_register_crypto_ops ieee80211_register_crypto_ops_rtl
-#define ieee80211_unregister_crypto_ops ieee80211_unregister_crypto_ops_rtl
-#define ieee80211_get_crypto_ops ieee80211_get_crypto_ops_rtl
-#define ieee80211_crypt_deinit_entries ieee80211_crypt_deinit_entries_rtl
-#define ieee80211_crypt_deinit_handler ieee80211_crypt_deinit_handler_rtl
-#define ieee80211_crypt_delayed_deinit ieee80211_crypt_delayed_deinit_rtl
-
-#define ieee80211_txb_free ieee80211_txb_free_rtl
-#define ieee80211_wx_get_essid ieee80211_wx_get_essid_rtl
-#define ieee80211_wx_set_essid ieee80211_wx_set_essid_rtl
-#define ieee80211_wx_set_rate ieee80211_wx_set_rate_rtl
-#define ieee80211_wx_get_rate ieee80211_wx_get_rate_rtl
-#define ieee80211_wx_set_wap ieee80211_wx_set_wap_rtl
-#define ieee80211_wx_get_wap ieee80211_wx_get_wap_rtl
-#define ieee80211_wx_set_mode ieee80211_wx_set_mode_rtl
-#define ieee80211_wx_get_mode ieee80211_wx_get_mode_rtl
-#define ieee80211_wx_set_scan ieee80211_wx_set_scan_rtl
-#define ieee80211_wx_get_freq ieee80211_wx_get_freq_rtl
-#define ieee80211_wx_set_freq ieee80211_wx_set_freq_rtl
-#define ieee80211_wx_set_rawtx ieee80211_wx_set_rawtx_rtl
-#define ieee80211_wx_set_power ieee80211_wx_set_power_rtl
-#define ieee80211_wx_get_power ieee80211_wx_get_power_rtl
-#define ieee80211_wlan_frequencies ieee80211_wlan_frequencies_rtl
-#define ieee80211_softmac_stop_protocol ieee80211_softmac_stop_protocol_rtl
-#define ieee80211_softmac_start_protocol ieee80211_softmac_start_protocol_rtl
-#define ieee80211_start_protocol ieee80211_start_protocol_rtl
-#define ieee80211_stop_protocol ieee80211_stop_protocol_rtl
-#define ieee80211_rx_mgt ieee80211_rx_mgt_rtl
-
-#define ieee80211_wx_set_auth ieee80211_wx_set_auth_rtl
-//by amy for ps
-#define notify_wx_assoc_event notify_wx_assoc_event_rtl
-#define ieee80211_stop_send_beacons ieee80211_stop_send_beacons_rtl
-#define ieee80211_disassociate ieee80211_disassociate_rtl
-#define ieee80211_start_scan ieee80211_start_scan_rtl
//by amy for ps
typedef struct ieee_param {
u32 cmd;
@@ -196,32 +134,8 @@ typedef struct 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
-#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,9))
-#define MSECS(t) (1000 * ((t) / HZ) + 1000 * ((t) % HZ) / HZ)
-static inline unsigned long msleep_interruptible_rtl(unsigned int msecs)
-{
- unsigned long timeout = MSECS(msecs) + 1;
-
- while (timeout) {
- set_current_state(TASK_UNINTERRUPTIBLE);
- timeout = schedule_timeout(timeout);
- }
- return timeout;
-}
-#else
#define MSECS(t) msecs_to_jiffies(t)
#define msleep_interruptible_rtl msleep_interruptible
-#endif
#define IEEE80211_DATA_LEN 2304
/* Maximum size for the MA-UNITDATA primitive, 802.11 standard section
@@ -780,7 +694,6 @@ struct ieee80211_header_data {
#define MFIE_TYPE_RATES_EX 50
#define MFIE_TYPE_GENERIC 221
-#ifdef ENABLE_DOT11D
typedef enum
{
COUNTRY_CODE_FCC = 0,
@@ -795,7 +708,6 @@ typedef enum
COUNTRY_CODE_GLOBAL_DOMAIN = 9,
COUNTRY_CODE_WORLD_WIDE_13_INDEX = 10
}country_code_type_t;
-#endif
struct ieee80211_info_element_hdr {
u8 id;
@@ -1044,13 +956,9 @@ struct ieee80211_network {
//by amy 080312
u8 HighestOperaRate;
//by amy 080312
-#ifdef THOMAS_TURBO
u8 Turbo_Enable;//enable turbo mode, added by thomas
-#endif
-#ifdef ENABLE_DOT11D
u16 CountryIeLen;
u8 CountryIeBuf[MAX_IE_LEN];
-#endif
};
enum ieee80211_state {
@@ -1097,22 +1005,6 @@ enum ieee80211_state {
#define MAC_FMT "%02x:%02x:%02x:%02x:%02x:%02x"
#define MAC_ARG(x) ((u8*)(x))[0],((u8*)(x))[1],((u8*)(x))[2],((u8*)(x))[3],((u8*)(x))[4],((u8*)(x))[5]
-
-#if (LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,11))
-extern inline int is_multicast_ether_addr(const u8 *addr)
-{
- return ((addr[0] != 0xff) && (0x01 & addr[0]));
-}
-#endif
-
-#if (LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,13))
-extern inline int is_broadcast_ether_addr(const u8 *addr)
-{
- return ((addr[0] == 0xff) && (addr[1] == 0xff) && (addr[2] == 0xff) && \
- (addr[3] == 0xff) && (addr[4] == 0xff) && (addr[5] == 0xff));
-}
-#endif
-
#define CFG_IEEE80211_RESERVE_FCS (1<<0)
#define CFG_IEEE80211_COMPUTE_FCS (1<<1)
@@ -1207,18 +1099,12 @@ struct ieee80211_device {
*/
short sync_scan_hurryup;
-#ifdef ENABLE_DOT11D
void * pDot11dInfo;
bool bGlobalDomain;
// For Liteon Ch12~13 passive scan
u8 MinPassiveChnlNum;
u8 IbssStartChnl;
-#else
- /* map of allowed channels. 0 is dummy */
- // FIXME: remeber to default to a basic channel plan depending of the PHY type
- int channel_map[MAX_CHANNEL_NUMBER+1];
-#endif
int rate; /* current rate */
int basic_rate;
@@ -1313,7 +1199,6 @@ struct ieee80211_device {
unsigned long NumRxOkTotal;
unsigned long NumRxUnicast;//YJ,add,080828,for keep alive
bool bHwRadioOff;
-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,20)
struct delayed_work softmac_scan_wq;
struct delayed_work associate_retry_wq;
struct delayed_work hw_wakeup_wq;
@@ -1329,24 +1214,7 @@ struct ieee80211_device {
//Added for RF power on power off by lizhaoming 080512
struct delayed_work GPIOChangeRFWorkItem;
-#else
- struct work_struct start_ibss_wq;
- struct work_struct softmac_scan_wq;
- struct work_struct associate_retry_wq;
- struct work_struct hw_wakeup_wq;
- struct work_struct hw_sleep_wq;
- struct work_struct watch_dog_wq;
- struct work_struct sw_antenna_wq;
-//by amy for rate adaptive 080312
- struct work_struct rate_adapter_wq;
-//by amy for rate adaptive
- struct work_struct hw_dig_wq;
- struct work_struct tx_pw_wq;
-
-//Added for RF power on power off by lizhaoming 080512
- struct work_struct GPIOChangeRFWorkItem;
-#endif
struct workqueue_struct *wq;
/* Callback functions */
@@ -1690,12 +1558,8 @@ extern int ieee80211_wx_set_freq(struct ieee80211_device *ieee, struct iw_reques
extern int ieee80211_wx_get_freq(struct ieee80211_device *ieee, struct iw_request_info *a,
union iwreq_data *wrqu, char *b);
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,20))
+
extern void ieee80211_wx_sync_scan_wq(struct work_struct *work);
-#else
- extern void ieee80211_wx_sync_scan_wq(struct ieee80211_device *ieee);
-#endif
-//extern void ieee80211_wx_sync_scan_wq(struct ieee80211_device *ieee);
extern int ieee80211_wx_set_rawtx(struct ieee80211_device *ieee,
struct iw_request_info *info,