Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 162540
b: refs/heads/master
c: 96a51d0
h: refs/heads/master
v: v3
  • Loading branch information
Greg Kroah-Hartman committed Sep 15, 2009
1 parent e95b7b0 commit 08105be
Show file tree
Hide file tree
Showing 9 changed files with 2 additions and 503 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 19bebc5217c0798a16b56c18609e0f52db6b0924
refs/heads/master: 96a51d06ccaeb2ca7e23d9e7b9b91c4a45471841
117 changes: 1 addition & 116 deletions trunk/drivers/staging/rtl8192e/ieee80211.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,7 @@
#include <linux/kernel.h> /* ARRAY_SIZE */
#include <linux/version.h>
#include <linux/module.h>
#if (LINUX_VERSION_CODE > KERNEL_VERSION(2,5,0))
#include <linux/jiffies.h>
#else
#include <linux/jffs.h>
#include <linux/tqueue.h>
#endif
#include <linux/timer.h>
#include <linux/sched.h>

Expand All @@ -43,12 +38,6 @@
#include "ieee80211/rtl819x_BA.h"
#include "ieee80211/rtl819x_TS.h"

#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,20))
#ifndef bool
typedef enum{false = 0, true} bool;
#endif
#endif

#ifndef IW_MODE_MONITOR
#define IW_MODE_MONITOR 6
#endif
Expand All @@ -57,25 +46,6 @@ typedef enum{false = 0, true} bool;
#define IWEVCUSTOM 0x8c02
#endif

#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0))
#ifndef __bitwise
#define __bitwise __attribute__((bitwise))
#endif
typedef __u16 __le16;
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,4,27))
struct iw_spy_data{
/* --- Standard spy support --- */
int spy_number;
u_char spy_address[IW_MAX_SPY][ETH_ALEN];
struct iw_quality spy_stat[IW_MAX_SPY];
/* --- Enhanced spy support (event) */
struct iw_quality spy_thr_low; /* Low threshold */
struct iw_quality spy_thr_high; /* High threshold */
u_char spy_thr_under[IW_MAX_SPY];
};
#endif
#endif

#ifndef container_of
/**
* container_of - cast a member of a structure out to the containing structure
Expand Down Expand Up @@ -425,46 +395,8 @@ typedef struct ieee_param {
#define IW_QUAL_NOISE_UPDATED 0x4
#endif

#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0))
static inline void tq_init(struct tq_struct * task, void(*func)(void *), void *data)
{
task->routine = func;
task->data = data;
//task->next = NULL;
INIT_LIST_HEAD(&task->list);
task->sync = 0;
}
#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)
#define MSECS(t) (HZ * ((t) / 1000) + (HZ * ((t) % 1000)) / 1000)
static inline unsigned long msleep_interruptible_rsl(unsigned int msecs)
{
unsigned long timeout = MSECS(msecs) + 1;

while (timeout) {
set_current_state(TASK_INTERRUPTIBLE);
timeout = schedule_timeout(timeout);
}
return timeout;
}
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,4,31))
static inline void msleep(unsigned int msecs)
{
unsigned long timeout = MSECS(msecs) + 1;

while (timeout) {
set_current_state(TASK_UNINTERRUPTIBLE);
timeout = schedule_timeout(timeout);
}
}
#endif
#else
#define MSECS(t) msecs_to_jiffies(t)
#define msleep_interruptible_rsl msleep_interruptible
#endif

#define IEEE80211_DATA_LEN 2304
/* Maximum size for the MA-UNITDATA primitive, 802.11 standard section
Expand Down Expand Up @@ -1736,21 +1668,6 @@ enum ieee80211_state {
#define IEEE80211_52GHZ_CHANNELS (IEEE80211_52GHZ_MAX_CHANNEL - \
IEEE80211_52GHZ_MIN_CHANNEL + 1)

#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

typedef struct tx_pending_t{
int frag;
struct ieee80211_txb *txb;
Expand Down Expand Up @@ -1827,11 +1744,7 @@ typedef struct _RT_POWER_SAVE_CONTROL
bool bIPSModeBackup;
bool bSwRfProcessing;
RT_RF_POWER_STATE eInactivePowerState;
#if LINUX_VERSION_CODE > KERNEL_VERSION(2,5,0)
struct work_struct InactivePsWorkItem;
#else
struct tq_struct InactivePsWorkItem;
#endif
struct timer_list InactivePsTimer;

// Return point for join action
Expand Down Expand Up @@ -2198,36 +2111,16 @@ struct ieee80211_device {

/* used if IEEE_SOFTMAC_BEACONS is set */
struct timer_list beacon_timer;
#if LINUX_VERSION_CODE > KERNEL_VERSION(2,5,0)

struct work_struct associate_complete_wq;
struct work_struct associate_procedure_wq;
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,20)
struct delayed_work softmac_scan_wq;
struct delayed_work associate_retry_wq;
struct delayed_work start_ibss_wq;
struct delayed_work hw_wakeup_wq;
struct delayed_work hw_sleep_wq;
#else
struct work_struct softmac_scan_wq;
struct work_struct associate_retry_wq;
struct work_struct start_ibss_wq;
struct work_struct hw_wakeup_wq;
struct work_struct hw_sleep_wq;
#endif
struct work_struct wx_sync_scan_wq;
struct workqueue_struct *wq;
#else
/* used for periodly scan */
struct timer_list scan_timer;

struct tq_struct associate_complete_wq;
struct tq_struct associate_retry_wq;
struct tq_struct start_ibss_wq;
struct tq_struct associate_procedure_wq;
struct tq_struct softmac_scan_wq;
struct tq_struct wx_sync_scan_wq;

#endif
// Qos related. Added by Annie, 2005-11-01.
//STA_QOS StaQos;

Expand Down Expand Up @@ -2413,11 +2306,7 @@ struct ieee80211_device {

static inline void *ieee80211_priv(struct net_device *dev)
{
#if LINUX_VERSION_CODE > KERNEL_VERSION(2,5,0)
return ((struct ieee80211_device *)netdev_priv(dev))->priv;
#else
return ((struct ieee80211_device *)dev->priv)->priv;
#endif
}

extern inline int ieee80211_is_empty_essid(const char *essid, int essid_len)
Expand Down Expand Up @@ -2670,11 +2559,7 @@ extern int ieee80211_wx_get_freq(struct ieee80211_device *ieee, struct iw_reques
union iwreq_data *wrqu, char *b);

//extern void ieee80211_wx_sync_scan_wq(struct ieee80211_device *ieee);
#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 int ieee80211_wx_set_rawtx(struct ieee80211_device *ieee,
Expand Down
38 changes: 0 additions & 38 deletions trunk/drivers/staging/rtl8192e/r8192E.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,6 @@
#include <linux/random.h>
#include <linux/version.h>
#include <asm/io.h>
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,27))
#include <asm/semaphore.h>
#endif
#include "ieee80211.h"


Expand Down Expand Up @@ -1020,11 +1017,7 @@ typedef struct r8192_priv
spinlock_t irq_th_lock;
spinlock_t tx_lock;
spinlock_t rf_ps_lock;
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16))
struct semaphore mutex;
#else
struct mutex mutex;
#endif
spinlock_t rf_lock; //used to lock rf write operation added by wb
spinlock_t ps_lock;

Expand Down Expand Up @@ -1163,11 +1156,7 @@ typedef struct r8192_priv
/* modified by davad for Rx process */
struct sk_buff_head rx_queue;
struct sk_buff_head skb_queue;
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0))
struct tq_struct qos_activate;
#else
struct work_struct qos_activate;
#endif
short tx_urb_index;
atomic_t tx_pending[0x10];//UART_PRIORITY+1

Expand Down Expand Up @@ -1196,11 +1185,7 @@ typedef struct r8192_priv

struct ChnlAccessSetting ChannelAccessSetting;

#if LINUX_VERSION_CODE > KERNEL_VERSION(2,5,0)
struct work_struct reset_wq;
#else
struct tq_struct reset_wq;
#endif

/**********************************************************/
//for rtl819xPci
Expand Down Expand Up @@ -1379,32 +1364,13 @@ typedef struct r8192_priv
u8 InitialGainOperateType;

//define work item by amy 080526
#if LINUX_VERSION_CODE > KERNEL_VERSION(2,5,0)
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,20)
struct delayed_work update_beacon_wq;
struct delayed_work watch_dog_wq;
struct delayed_work txpower_tracking_wq;
struct delayed_work rfpath_check_wq;
struct delayed_work gpio_change_rf_wq;
struct delayed_work initialgain_operate_wq;
#else
struct work_struct update_beacon_wq;
struct work_struct watch_dog_wq;
struct work_struct txpower_tracking_wq;
struct work_struct rfpath_check_wq;
struct work_struct gpio_change_rf_wq;
struct work_struct initialgain_operate_wq;
#endif
struct workqueue_struct *priv_wq;
#else
struct tq_struct update_beacon_wq;
/* used for periodly scan */
struct tq_struct txpower_tracking_wq;
struct tq_struct rfpath_check_wq;
struct tq_struct watch_dog_wq;
struct tq_struct gpio_change_rf_wq;
struct tq_struct initialgain_operate_wq;
#endif
}r8192_priv;

// for rtl8187
Expand Down Expand Up @@ -1540,11 +1506,7 @@ void CamPrintDbgReg(struct net_device* dev);
extern void dm_cck_txpower_adjust(struct net_device *dev,bool binch14);
extern void firmware_init_param(struct net_device *dev);
extern RT_STATUS cmpk_message_handle_tx(struct net_device *dev, u8* codevirtualaddress, u32 packettype, u32 buffer_len);
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,20))
void rtl8192_hw_wakeup_wq (struct work_struct *work);
#else
void rtl8192_hw_wakeup_wq(struct net_device *dev);
#endif

short rtl8192_is_tx_queue_empty(struct net_device *dev);
#ifdef ENABLE_IPS
Expand Down
Loading

0 comments on commit 08105be

Please sign in to comment.