mirror of
https://github.com/lwfinger/rtl8188eu.git
synced 2024-11-21 12:03:40 +00:00
rtl8188eu: Fix checkpatch errors in include/*.h - part 3
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
parent
7120e63109
commit
8a46c9e7a5
13 changed files with 1082 additions and 1051 deletions
|
@ -58,19 +58,16 @@ enum _EFUSE_DEF_TYPE {
|
|||
#define EFUSE_MAX_HW_SIZE 512
|
||||
#define EFUSE_MAX_SECTION_BASE 16
|
||||
|
||||
#define EXT_HEADER(header) ((header & 0x1F ) == 0x0F)
|
||||
#define EXT_HEADER(header) ((header & 0x1F) == 0x0F)
|
||||
#define ALL_WORDS_DISABLED(wde) ((wde & 0x0F) == 0x0F)
|
||||
#define GET_HDR_OFFSET_2_0(header) ( (header & 0xE0) >> 5)
|
||||
#define GET_HDR_OFFSET_2_0(header) ((header & 0xE0) >> 5)
|
||||
|
||||
#define EFUSE_REPEAT_THRESHOLD_ 3
|
||||
|
||||
/* */
|
||||
/* The following is for BT Efuse definition */
|
||||
/* */
|
||||
/* The following is for BT Efuse definition */
|
||||
#define EFUSE_BT_MAX_MAP_LEN 1024
|
||||
#define EFUSE_MAX_BANK 4
|
||||
#define EFUSE_MAX_BT_BANK (EFUSE_MAX_BANK-1)
|
||||
/* */
|
||||
/*--------------------------Define Parameters-------------------------------*/
|
||||
#define EFUSE_MAX_WORD_UNIT 4
|
||||
|
||||
|
@ -84,22 +81,22 @@ struct pgpkt {
|
|||
|
||||
/*------------------------------Define structure----------------------------*/
|
||||
struct efuse_hal {
|
||||
u8 fakeEfuseBank;
|
||||
u8 fakeEfuseBank;
|
||||
u32 fakeEfuseUsedBytes;
|
||||
u8 fakeEfuseContent[EFUSE_MAX_HW_SIZE];
|
||||
u8 fakeEfuseInitMap[EFUSE_MAX_MAP_LEN];
|
||||
u8 fakeEfuseModifiedMap[EFUSE_MAX_MAP_LEN];
|
||||
u8 fakeEfuseContent[EFUSE_MAX_HW_SIZE];
|
||||
u8 fakeEfuseInitMap[EFUSE_MAX_MAP_LEN];
|
||||
u8 fakeEfuseModifiedMap[EFUSE_MAX_MAP_LEN];
|
||||
|
||||
u16 BTEfuseUsedBytes;
|
||||
u8 BTEfuseUsedPercentage;
|
||||
u8 BTEfuseContent[EFUSE_MAX_BT_BANK][EFUSE_MAX_HW_SIZE];
|
||||
u8 BTEfuseInitMap[EFUSE_BT_MAX_MAP_LEN];
|
||||
u8 BTEfuseModifiedMap[EFUSE_BT_MAX_MAP_LEN];
|
||||
u16 BTEfuseUsedBytes;
|
||||
u8 BTEfuseUsedPercentage;
|
||||
u8 BTEfuseContent[EFUSE_MAX_BT_BANK][EFUSE_MAX_HW_SIZE];
|
||||
u8 BTEfuseInitMap[EFUSE_BT_MAX_MAP_LEN];
|
||||
u8 BTEfuseModifiedMap[EFUSE_BT_MAX_MAP_LEN];
|
||||
|
||||
u16 fakeBTEfuseUsedBytes;
|
||||
u8 fakeBTEfuseContent[EFUSE_MAX_BT_BANK][EFUSE_MAX_HW_SIZE];
|
||||
u8 fakeBTEfuseInitMap[EFUSE_BT_MAX_MAP_LEN];
|
||||
u8 fakeBTEfuseModifiedMap[EFUSE_BT_MAX_MAP_LEN];
|
||||
u16 fakeBTEfuseUsedBytes;
|
||||
u8 fakeBTEfuseContent[EFUSE_MAX_BT_BANK][EFUSE_MAX_HW_SIZE];
|
||||
u8 fakeBTEfuseInitMap[EFUSE_BT_MAX_MAP_LEN];
|
||||
u8 fakeBTEfuseModifiedMap[EFUSE_BT_MAX_MAP_LEN];
|
||||
};
|
||||
|
||||
/*------------------------Export global variable----------------------------*/
|
||||
|
@ -120,29 +117,34 @@ extern u8 fakeBTEfuseInitMap[];
|
|||
extern u8 fakeBTEfuseModifiedMap[];
|
||||
/*------------------------Export global variable----------------------------*/
|
||||
|
||||
u8 efuse_GetCurrentSize(struct adapter * padapter, u16 *size);
|
||||
u16 efuse_GetMaxSize(struct adapter * padapter);
|
||||
u8 rtw_efuse_access(struct adapter * padapter, u8 bRead, u16 start_addr, u16 cnts, u8 *data);
|
||||
u8 rtw_efuse_map_read(struct adapter * padapter, u16 addr, u16 cnts, u8 *data);
|
||||
u8 rtw_efuse_map_write(struct adapter * padapter, u16 addr, u16 cnts, u8 *data);
|
||||
u8 rtw_BT_efuse_map_read(struct adapter * padapter, u16 addr, u16 cnts, u8 *data);
|
||||
u8 rtw_BT_efuse_map_write(struct adapter * padapter, u16 addr, u16 cnts, u8 *data);
|
||||
u8 efuse_GetCurrentSize(struct adapter *adapter, u16 *size);
|
||||
u16 efuse_GetMaxSize(struct adapter *adapter);
|
||||
u8 rtw_efuse_access(struct adapter *adapter, u8 read, u16 start_addr,
|
||||
u16 cnts, u8 *data);
|
||||
u8 rtw_efuse_map_read(struct adapter *adapter, u16 addr, u16 cnts, u8 *data);
|
||||
u8 rtw_efuse_map_write(struct adapter *adapter, u16 addr, u16 cnts, u8 *data);
|
||||
u8 rtw_BT_efuse_map_read(struct adapter *adapter, u16 addr,
|
||||
u16 cnts, u8 *data);
|
||||
u8 rtw_BT_efuse_map_write(struct adapter *adapter, u16 addr,
|
||||
u16 cnts, u8 *data);
|
||||
u16 Efuse_GetCurrentSize(struct adapter *adapter, u8 efusetype, bool test);
|
||||
u8 Efuse_CalculateWordCnts(u8 word_en);
|
||||
void ReadEFuseByte(struct adapter *adapter, u16 _offset, u8 *pbuf, bool test);
|
||||
void EFUSE_GetEfuseDefinition(struct adapter *adapt, u8 type, u8 type1,
|
||||
void *out, bool bPseudoTest);
|
||||
u8 efuse_OneByteRead(struct adapter *adapter, u16 addr, u8 *data, bool test);
|
||||
u8 efuse_OneByteWrite(struct adapter *adapter, u16 addr, u8 data, bool test);
|
||||
|
||||
u16 Efuse_GetCurrentSize(struct adapter * pAdapter, u8 efuseType, bool bPseudoTest);
|
||||
u8 Efuse_CalculateWordCnts(u8 word_en);
|
||||
void ReadEFuseByte(struct adapter * Adapter, u16 _offset, u8 *pbuf, bool bPseudoTest) ;
|
||||
void EFUSE_GetEfuseDefinition(struct adapter * pAdapter, u8 efuseType, u8 type, void *pOut, bool bPseudoTest);
|
||||
u8 efuse_OneByteRead(struct adapter * pAdapter, u16 addr, u8 *data, bool bPseudoTest);
|
||||
u8 efuse_OneByteWrite(struct adapter * pAdapter, u16 addr, u8 data, bool bPseudoTest);
|
||||
void Efuse_PowerSwitch(struct adapter *adapt,u8 bWrite,u8 PwrState);
|
||||
int Efuse_PgPacketRead(struct adapter *adapt, u8 offset, u8 *data, bool test);
|
||||
int Efuse_PgPacketWrite(struct adapter *adapter, u8 offset, u8 word, u8 *data,
|
||||
bool test);
|
||||
void efuse_WordEnableDataRead(u8 word_en, u8 *sourdata, u8 *targetdata);
|
||||
u8 Efuse_WordEnableDataWrite(struct adapter *adapter, u16 efuse_addr,
|
||||
u8 word_en, u8 *data, bool test);
|
||||
|
||||
void Efuse_PowerSwitch(struct adapter * pAdapter,u8 bWrite,u8 PwrState);
|
||||
int Efuse_PgPacketRead(struct adapter * pAdapter, u8 offset, u8 *data, bool bPseudoTest);
|
||||
int Efuse_PgPacketWrite(struct adapter * pAdapter, u8 offset, u8 word_en, u8 *data, bool bPseudoTest);
|
||||
void efuse_WordEnableDataRead(u8 word_en, u8 *sourdata, u8 *targetdata);
|
||||
u8 Efuse_WordEnableDataWrite(struct adapter * pAdapter, u16 efuse_addr, u8 word_en, u8 *data, bool bPseudoTest);
|
||||
|
||||
u8 EFUSE_Read1Byte(struct adapter * pAdapter, u16 Address);
|
||||
void EFUSE_ShadowMapUpdate(struct adapter * pAdapter, u8 efuseType, bool bPseudoTest);
|
||||
void EFUSE_ShadowRead(struct adapter * pAdapter, u8 Type, u16 Offset, u32 *Value);
|
||||
u8 EFUSE_Read1Byte(struct adapter *adapter, u16 address);
|
||||
void EFUSE_ShadowMapUpdate(struct adapter *adapter, u8 efusetype, bool test);
|
||||
void EFUSE_ShadowRead(struct adapter *adapt, u8 type, u16 offset, u32 *val);
|
||||
|
||||
#endif
|
||||
|
|
|
@ -23,11 +23,7 @@
|
|||
#include <osdep_service.h>
|
||||
|
||||
#include <wlan_bssdef.h>
|
||||
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,26))
|
||||
#include <asm/semaphore.h>
|
||||
#else
|
||||
#include <linux/semaphore.h>
|
||||
#endif
|
||||
#include <linux/sem.h>
|
||||
|
||||
/*
|
||||
|
@ -66,24 +62,21 @@ struct joinbss_event {
|
|||
/*
|
||||
Used to report a given STA has joinned the created BSS.
|
||||
It is used in AP/Ad-HoC(M) mode.
|
||||
|
||||
|
||||
*/
|
||||
|
||||
struct stassoc_event {
|
||||
unsigned char macaddr[6];
|
||||
unsigned char rsvd[2];
|
||||
int cam_id;
|
||||
|
||||
};
|
||||
|
||||
struct stadel_event {
|
||||
unsigned char macaddr[6];
|
||||
unsigned char rsvd[2]; /* for reason */
|
||||
int mac_id;
|
||||
unsigned char macaddr[6];
|
||||
unsigned char rsvd[2]; /* for reason */
|
||||
int mac_id;
|
||||
};
|
||||
|
||||
struct addba_event
|
||||
{
|
||||
struct addba_event {
|
||||
unsigned int tid;
|
||||
};
|
||||
|
||||
|
@ -96,17 +89,17 @@ struct fwevent {
|
|||
|
||||
#define C2HEVENT_SZ 32
|
||||
|
||||
struct event_node{
|
||||
struct event_node {
|
||||
unsigned char *node;
|
||||
unsigned char evt_code;
|
||||
unsigned short evt_sz;
|
||||
volatile int *caller_ff_tail;
|
||||
int *caller_ff_tail;
|
||||
int caller_ff_sz;
|
||||
};
|
||||
|
||||
struct c2hevent_queue {
|
||||
volatile int head;
|
||||
volatile int tail;
|
||||
int head;
|
||||
int tail;
|
||||
struct event_node nodes[C2HEVENT_SZ];
|
||||
unsigned char seq;
|
||||
};
|
||||
|
@ -114,10 +107,9 @@ struct c2hevent_queue {
|
|||
#define NETWORK_QUEUE_SZ 4
|
||||
|
||||
struct network_queue {
|
||||
volatile int head;
|
||||
volatile int tail;
|
||||
int head;
|
||||
int tail;
|
||||
struct wlan_bssid_ex networks[NETWORK_QUEUE_SZ];
|
||||
};
|
||||
|
||||
|
||||
#endif /* _WLANEVENT_H_ */
|
||||
|
|
|
@ -23,26 +23,22 @@
|
|||
#include <osdep_service.h>
|
||||
#include "wifi.h"
|
||||
|
||||
struct ht_priv
|
||||
{
|
||||
struct ht_priv {
|
||||
u32 ht_option;
|
||||
u32 ampdu_enable;/* for enable Tx A-MPDU */
|
||||
/* u8 baddbareq_issued[16]; */
|
||||
u32 tx_amsdu_enable;/* for enable Tx A-MSDU */
|
||||
u32 tx_amdsu_maxlen; /* 1: 8k, 0:4k ; default:8k, for tx */
|
||||
u32 rx_ampdu_maxlen; /* for rx reordering ctrl win_sz, updated when join_callback. */
|
||||
|
||||
u32 rx_ampdu_maxlen; /* for rx reordering ctrl win_sz,
|
||||
* updated when join_callback. */
|
||||
u8 bwmode;/* */
|
||||
u8 ch_offset;/* PRIME_CHNL_OFFSET */
|
||||
u8 sgi;/* short GI */
|
||||
|
||||
/* for processing Tx A-MPDU */
|
||||
u8 agg_enable_bitmap;
|
||||
/* u8 ADDBA_retry_count; */
|
||||
u8 candidate_tid_bitmap;
|
||||
|
||||
struct rtw_ieee80211_ht_cap ht_cap;
|
||||
|
||||
};
|
||||
|
||||
#endif /* _RTL871X_HT_H_ */
|
||||
|
|
429
include/rtw_io.h
429
include/rtw_io.h
|
@ -25,37 +25,39 @@
|
|||
#include <osdep_intf.h>
|
||||
|
||||
#include <asm/byteorder.h>
|
||||
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,26))
|
||||
#include <asm/semaphore.h>
|
||||
#else
|
||||
#include <linux/semaphore.h>
|
||||
#endif
|
||||
#include <linux/list.h>
|
||||
#include <linux/spinlock.h>
|
||||
#include <asm/atomic.h>
|
||||
#include <linux/atomic.h>
|
||||
|
||||
#include <linux/usb.h>
|
||||
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,21))
|
||||
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 21))
|
||||
#include <linux/usb_ch9.h>
|
||||
#else
|
||||
#include <linux/usb/ch9.h>
|
||||
#endif
|
||||
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,35))
|
||||
#define rtw_usb_buffer_alloc(dev, size, dma) usb_alloc_coherent((dev), (size), (in_interrupt() ? GFP_ATOMIC : GFP_KERNEL), (dma))
|
||||
#define rtw_usb_buffer_free(dev, size, addr, dma) usb_free_coherent((dev), (size), (addr), (dma))
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 35))
|
||||
#define rtw_usb_buffer_alloc(dev, size, dma) \
|
||||
usb_alloc_coherent((dev), (size), (in_interrupt() ? \
|
||||
GFP_ATOMIC : GFP_KERNEL), (dma))
|
||||
#define rtw_usb_buffer_free(dev, size, addr, dma) \
|
||||
usb_free_coherent((dev), (size), (addr), (dma))
|
||||
#else
|
||||
#define rtw_usb_buffer_alloc(dev, size, dma) usb_buffer_alloc((dev), (size), (in_interrupt() ? GFP_ATOMIC : GFP_KERNEL), (dma))
|
||||
#define rtw_usb_buffer_free(dev, size, addr, dma) usb_buffer_free((dev), (size), (addr), (dma))
|
||||
#define rtw_usb_buffer_alloc(dev, size, dma) \
|
||||
usb_buffer_alloc((dev), (size), (in_interrupt() ? \
|
||||
GFP_ATOMIC : GFP_KERNEL), (dma))
|
||||
#define rtw_usb_buffer_free(dev, size, addr, dma) \
|
||||
usb_buffer_free((dev), (size), (addr), (dma))
|
||||
#endif
|
||||
|
||||
#define NUM_IOREQ 8
|
||||
|
||||
#define MAX_PROT_SZ (64-16)
|
||||
|
||||
#define _IOREADY 0
|
||||
#define _IO_WAIT_COMPLETE 1
|
||||
#define _IO_WAIT_RSP 2
|
||||
#define _IOREADY 0
|
||||
#define _IO_WAIT_COMPLETE 1
|
||||
#define _IO_WAIT_RSP 2
|
||||
|
||||
/* IO COMMAND TYPE */
|
||||
#define _IOSZ_MASK_ (0x7F)
|
||||
|
@ -66,48 +68,42 @@
|
|||
#define _IO_HW_ BIT(11)
|
||||
#define _IO_WORD_ BIT(12)
|
||||
#define _IO_SYNC_ BIT(13)
|
||||
#define _IO_CMDMASK_ (0x1F80)
|
||||
|
||||
#define _IO_CMDMASK_ (0x1F80)
|
||||
|
||||
/*
|
||||
For prompt mode accessing, caller shall free io_req
|
||||
Otherwise, io_handler will free io_req
|
||||
*/
|
||||
|
||||
|
||||
|
||||
/* IO STATUS TYPE */
|
||||
#define _IO_ERR_ BIT(2)
|
||||
#define _IO_SUCCESS_ BIT(1)
|
||||
#define _IO_SUCCESS_ BIT(1)
|
||||
#define _IO_DONE_ BIT(0)
|
||||
|
||||
|
||||
#define IO_RD32 (_IO_SYNC_ | _IO_WORD_)
|
||||
#define IO_RD16 (_IO_SYNC_ | _IO_HW_)
|
||||
#define IO_RD8 (_IO_SYNC_ | _IO_BYTE_)
|
||||
|
||||
#define IO_RD32_ASYNC (_IO_WORD_)
|
||||
#define IO_RD16_ASYNC (_IO_HW_)
|
||||
#define IO_RD8_ASYNC (_IO_BYTE_)
|
||||
#define IO_RD32_ASYNC (_IO_WORD_)
|
||||
#define IO_RD16_ASYNC (_IO_HW_)
|
||||
#define IO_RD8_ASYNC (_IO_BYTE_)
|
||||
|
||||
#define IO_WR32 (_IO_WRITE_ | _IO_SYNC_ | _IO_WORD_)
|
||||
#define IO_WR16 (_IO_WRITE_ | _IO_SYNC_ | _IO_HW_)
|
||||
#define IO_WR8 (_IO_WRITE_ | _IO_SYNC_ | _IO_BYTE_)
|
||||
|
||||
#define IO_WR32_ASYNC (_IO_WRITE_ | _IO_WORD_)
|
||||
#define IO_WR16_ASYNC (_IO_WRITE_ | _IO_HW_)
|
||||
#define IO_WR8_ASYNC (_IO_WRITE_ | _IO_BYTE_)
|
||||
#define IO_WR32_ASYNC (_IO_WRITE_ | _IO_WORD_)
|
||||
#define IO_WR16_ASYNC (_IO_WRITE_ | _IO_HW_)
|
||||
#define IO_WR8_ASYNC (_IO_WRITE_ | _IO_BYTE_)
|
||||
|
||||
/*
|
||||
|
||||
Only Sync. burst accessing is provided.
|
||||
|
||||
*/
|
||||
|
||||
#define IO_WR_BURST(x) (_IO_WRITE_ | _IO_SYNC_ | _IO_BURST_ | ( (x) & _IOSZ_MASK_))
|
||||
#define IO_RD_BURST(x) (_IO_SYNC_ | _IO_BURST_ | ( (x) & _IOSZ_MASK_))
|
||||
|
||||
|
||||
#define IO_WR_BURST(x) \
|
||||
(_IO_WRITE_ | _IO_SYNC_ | _IO_BURST_ | ((x) & _IOSZ_MASK_))
|
||||
#define IO_RD_BURST(x) \
|
||||
(_IO_SYNC_ | _IO_BURST_ | ((x) & _IOSZ_MASK_))
|
||||
|
||||
/* below is for the intf_option bit defition... */
|
||||
|
||||
|
@ -118,61 +114,54 @@ struct intf_hdl;
|
|||
struct io_queue;
|
||||
|
||||
struct _io_ops {
|
||||
u8 (*_read8)(struct intf_hdl *pintfhdl, u32 addr);
|
||||
u16 (*_read16)(struct intf_hdl *pintfhdl, u32 addr);
|
||||
u32 (*_read32)(struct intf_hdl *pintfhdl, u32 addr);
|
||||
|
||||
int (*_write8)(struct intf_hdl *pintfhdl, u32 addr, u8 val);
|
||||
int (*_write16)(struct intf_hdl *pintfhdl, u32 addr, u16 val);
|
||||
int (*_write32)(struct intf_hdl *pintfhdl, u32 addr, u32 val);
|
||||
int (*_writeN)(struct intf_hdl *pintfhdl, u32 addr, u32 length, u8 *pdata);
|
||||
|
||||
int (*_write8_async)(struct intf_hdl *pintfhdl, u32 addr, u8 val);
|
||||
int (*_write16_async)(struct intf_hdl *pintfhdl, u32 addr, u16 val);
|
||||
int (*_write32_async)(struct intf_hdl *pintfhdl, u32 addr, u32 val);
|
||||
|
||||
void (*_read_mem)(struct intf_hdl *pintfhdl, u32 addr, u32 cnt, u8 *pmem);
|
||||
void (*_write_mem)(struct intf_hdl *pintfhdl, u32 addr, u32 cnt, u8 *pmem);
|
||||
|
||||
void (*_sync_irp_protocol_rw)(struct io_queue *pio_q);
|
||||
|
||||
u32 (*_read_interrupt)(struct intf_hdl *pintfhdl, u32 addr);
|
||||
|
||||
u32 (*_read_port)(struct intf_hdl *pintfhdl, u32 addr, u32 cnt, u8 *pmem);
|
||||
u32 (*_write_port)(struct intf_hdl *pintfhdl, u32 addr, u32 cnt, u8 *pmem);
|
||||
|
||||
u32 (*_write_scsi)(struct intf_hdl *pintfhdl,u32 cnt, u8 *pmem);
|
||||
|
||||
void (*_read_port_cancel)(struct intf_hdl *pintfhdl);
|
||||
void (*_write_port_cancel)(struct intf_hdl *pintfhdl);
|
||||
u8 (*_read8)(struct intf_hdl *pintfhdl, u32 addr);
|
||||
u16 (*_read16)(struct intf_hdl *pintfhdl, u32 addr);
|
||||
u32 (*_read32)(struct intf_hdl *pintfhdl, u32 addr);
|
||||
int (*_write8)(struct intf_hdl *pintfhdl, u32 addr, u8 val);
|
||||
int (*_write16)(struct intf_hdl *pintfhdl, u32 addr, u16 val);
|
||||
int (*_write32)(struct intf_hdl *pintfhdl, u32 addr, u32 val);
|
||||
int (*_writeN)(struct intf_hdl *pintfhdl, u32 addr, u32 length,
|
||||
u8 *pdata);
|
||||
int (*_write8_async)(struct intf_hdl *pintfhdl, u32 addr, u8 val);
|
||||
int (*_write16_async)(struct intf_hdl *pintfhdl, u32 addr, u16 val);
|
||||
int (*_write32_async)(struct intf_hdl *pintfhdl, u32 addr, u32 val);
|
||||
void (*_read_mem)(struct intf_hdl *pintfhdl, u32 addr, u32 cnt,
|
||||
u8 *pmem);
|
||||
void (*_write_mem)(struct intf_hdl *pintfhdl, u32 addr, u32 cnt,
|
||||
u8 *pmem);
|
||||
void (*_sync_irp_protocol_rw)(struct io_queue *pio_q);
|
||||
u32 (*_read_interrupt)(struct intf_hdl *pintfhdl, u32 addr);
|
||||
u32 (*_read_port)(struct intf_hdl *pintfhdl, u32 addr, u32 cnt,
|
||||
u8 *pmem);
|
||||
u32 (*_write_port)(struct intf_hdl *pintfhdl, u32 addr, u32 cnt,
|
||||
u8 *pmem);
|
||||
u32 (*_write_scsi)(struct intf_hdl *pintfhdl,u32 cnt, u8 *pmem);
|
||||
void (*_read_port_cancel)(struct intf_hdl *pintfhdl);
|
||||
void (*_write_port_cancel)(struct intf_hdl *pintfhdl);
|
||||
};
|
||||
|
||||
struct io_req {
|
||||
struct list_head list;
|
||||
u32 addr;
|
||||
volatile u32 val;
|
||||
u32 val;
|
||||
u32 command;
|
||||
u32 status;
|
||||
u8 *pbuf;
|
||||
struct semaphore sema;
|
||||
|
||||
void (*_async_io_callback)(struct adapter *padater, struct io_req *pio_req, u8 *cnxt);
|
||||
void (*_async_io_callback)(struct adapter *padater,
|
||||
struct io_req *pio_req, u8 *cnxt);
|
||||
u8 *cnxt;
|
||||
|
||||
};
|
||||
|
||||
struct intf_hdl {
|
||||
struct adapter *padapter;
|
||||
struct dvobj_priv *pintf_dev;/* pointer to &(padapter->dvobjpriv); */
|
||||
|
||||
struct dvobj_priv *pintf_dev;
|
||||
struct _io_ops io_ops;
|
||||
|
||||
};
|
||||
|
||||
struct reg_protocol_rd {
|
||||
|
||||
#ifdef __LITTLE_ENDIAN
|
||||
|
||||
/* DW1 */
|
||||
u32 NumOfTrans:4;
|
||||
u32 Reserved1:4;
|
||||
|
@ -192,236 +181,206 @@ struct reg_protocol_rd {
|
|||
/* DW4 */
|
||||
/* u32 Value; */
|
||||
#else
|
||||
|
||||
|
||||
/* DW1 */
|
||||
u32 Reserved1 :4;
|
||||
u32 NumOfTrans :4;
|
||||
|
||||
u32 Reserved2 :24;
|
||||
|
||||
u32 Reserved1:4;
|
||||
u32 NumOfTrans:4;
|
||||
u32 Reserved2:24;
|
||||
/* DW2 */
|
||||
u32 WriteEnable : 1;
|
||||
u32 ByteCount :7;
|
||||
|
||||
|
||||
u32 Reserved3 : 3;
|
||||
u32 Byte4Access : 1;
|
||||
|
||||
u32 Byte2Access : 1;
|
||||
u32 Byte1Access : 1;
|
||||
u32 BurstMode :1 ;
|
||||
u32 FixOrContinuous : 1;
|
||||
|
||||
u32 Reserved4 : 16;
|
||||
u32 WriteEnable:1;
|
||||
u32 ByteCount:7;
|
||||
u32 Reserved3:3;
|
||||
u32 Byte4Access:1;
|
||||
|
||||
u32 Byte2Access:1;
|
||||
u32 Byte1Access:1;
|
||||
u32 BurstMode:1;
|
||||
u32 FixOrContinuous:1;
|
||||
u32 Reserved4:16;
|
||||
/* DW3 */
|
||||
u32 BusAddress;
|
||||
u32 BusAddress;
|
||||
|
||||
/* DW4 */
|
||||
/* u32 Value; */
|
||||
|
||||
#endif
|
||||
|
||||
};
|
||||
|
||||
|
||||
struct reg_protocol_wt {
|
||||
|
||||
|
||||
#ifdef __LITTLE_ENDIAN
|
||||
|
||||
/* DW1 */
|
||||
u32 NumOfTrans:4;
|
||||
u32 Reserved1:4;
|
||||
u32 Reserved2:24;
|
||||
u32 NumOfTrans:4;
|
||||
u32 Reserved1:4;
|
||||
u32 Reserved2:24;
|
||||
/* DW2 */
|
||||
u32 ByteCount:7;
|
||||
u32 WriteEnable:1; /* 0:read, 1:write */
|
||||
u32 FixOrContinuous:1; /* 0:continuous, 1: Fix */
|
||||
u32 BurstMode:1;
|
||||
u32 Byte1Access:1;
|
||||
u32 Byte2Access:1;
|
||||
u32 Byte4Access:1;
|
||||
u32 Reserved3:3;
|
||||
u32 Reserved4:16;
|
||||
u32 ByteCount:7;
|
||||
u32 WriteEnable:1; /* 0:read, 1:write */
|
||||
u32 FixOrContinuous:1; /* 0:continuous, 1: Fix */
|
||||
u32 BurstMode:1;
|
||||
u32 Byte1Access:1;
|
||||
u32 Byte2Access:1;
|
||||
u32 Byte4Access:1;
|
||||
u32 Reserved3:3;
|
||||
u32 Reserved4:16;
|
||||
/* DW3 */
|
||||
u32 BusAddress;
|
||||
u32 BusAddress;
|
||||
/* DW4 */
|
||||
u32 Value;
|
||||
|
||||
u32 Value;
|
||||
#else
|
||||
/* DW1 */
|
||||
u32 Reserved1 :4;
|
||||
u32 NumOfTrans :4;
|
||||
|
||||
u32 Reserved2 :24;
|
||||
|
||||
u32 Reserved1 :4;
|
||||
u32 NumOfTrans:4;
|
||||
u32 Reserved2:24;
|
||||
/* DW2 */
|
||||
u32 WriteEnable : 1;
|
||||
u32 ByteCount :7;
|
||||
|
||||
u32 Reserved3 : 3;
|
||||
u32 Byte4Access : 1;
|
||||
|
||||
u32 Byte2Access : 1;
|
||||
u32 Byte1Access : 1;
|
||||
u32 BurstMode :1 ;
|
||||
u32 FixOrContinuous : 1;
|
||||
|
||||
u32 Reserved4 : 16;
|
||||
|
||||
u32 WriteEnable:1;
|
||||
u32 ByteCount:7;
|
||||
u32 Reserved3:3;
|
||||
u32 Byte4Access:1;
|
||||
u32 Byte2Access:1;
|
||||
u32 Byte1Access:1;
|
||||
u32 BurstMode:1;
|
||||
u32 FixOrContinuous:1;
|
||||
u32 Reserved4:16;
|
||||
/* DW3 */
|
||||
u32 BusAddress;
|
||||
|
||||
u32 BusAddress;
|
||||
/* DW4 */
|
||||
u32 Value;
|
||||
|
||||
u32 Value;
|
||||
#endif
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
||||
/*
|
||||
Below is the data structure used by _io_handler
|
||||
|
||||
*/
|
||||
|
||||
struct io_queue {
|
||||
spinlock_t lock;
|
||||
struct list_head free_ioreqs;
|
||||
struct list_head pending; /* The io_req list that will be served in the single protocol read/write. */
|
||||
struct list_head pending; /* The io_req list that will be served
|
||||
* in the single protocol read/write.*/
|
||||
struct list_head processing;
|
||||
u8 *free_ioreqs_buf; /* 4-byte aligned */
|
||||
u8 *pallocated_free_ioreqs_buf;
|
||||
struct intf_hdl intf;
|
||||
};
|
||||
|
||||
struct io_priv{
|
||||
|
||||
struct io_priv {
|
||||
struct adapter *padapter;
|
||||
|
||||
struct intf_hdl intf;
|
||||
|
||||
};
|
||||
|
||||
extern uint ioreq_flush(struct adapter *adapter, struct io_queue *ioqueue);
|
||||
extern void sync_ioreq_enqueue(struct io_req *preq,struct io_queue *ioqueue);
|
||||
extern uint sync_ioreq_flush(struct adapter *adapter, struct io_queue *ioqueue);
|
||||
uint ioreq_flush(struct adapter *adapter, struct io_queue *ioqueue);
|
||||
void sync_ioreq_enqueue(struct io_req *preq,struct io_queue *ioqueue);
|
||||
uint sync_ioreq_flush(struct adapter *adapter, struct io_queue *ioqueue);
|
||||
uint free_ioreq(struct io_req *preq, struct io_queue *pio_queue);
|
||||
struct io_req *alloc_ioreq(struct io_queue *pio_q);
|
||||
|
||||
uint register_intf_hdl(u8 *dev, struct intf_hdl *pintfhdl);
|
||||
void unregister_intf_hdl(struct intf_hdl *pintfhdl);
|
||||
|
||||
extern uint free_ioreq(struct io_req *preq, struct io_queue *pio_queue);
|
||||
extern struct io_req *alloc_ioreq(struct io_queue *pio_q);
|
||||
void _rtw_attrib_read(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
void _rtw_attrib_write(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
|
||||
extern uint register_intf_hdl(u8 *dev, struct intf_hdl *pintfhdl);
|
||||
extern void unregister_intf_hdl(struct intf_hdl *pintfhdl);
|
||||
u8 _rtw_read8(struct adapter *adapter, u32 addr);
|
||||
u16 _rtw_read16(struct adapter *adapter, u32 addr);
|
||||
u32 _rtw_read32(struct adapter *adapter, u32 addr);
|
||||
void _rtw_read_mem(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
void _rtw_read_port(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
void _rtw_read_port_cancel(struct adapter *adapter);
|
||||
|
||||
extern void _rtw_attrib_read(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
extern void _rtw_attrib_write(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
int _rtw_write8(struct adapter *adapter, u32 addr, u8 val);
|
||||
int _rtw_write16(struct adapter *adapter, u32 addr, u16 val);
|
||||
int _rtw_write32(struct adapter *adapter, u32 addr, u32 val);
|
||||
int _rtw_writeN(struct adapter *adapter, u32 addr, u32 length, u8 *pdata);
|
||||
|
||||
extern u8 _rtw_read8(struct adapter *adapter, u32 addr);
|
||||
extern u16 _rtw_read16(struct adapter *adapter, u32 addr);
|
||||
extern u32 _rtw_read32(struct adapter *adapter, u32 addr);
|
||||
extern void _rtw_read_mem(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
extern void _rtw_read_port(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
extern void _rtw_read_port_cancel(struct adapter *adapter);
|
||||
int _rtw_write8_async(struct adapter *adapter, u32 addr, u8 val);
|
||||
int _rtw_write16_async(struct adapter *adapter, u32 addr, u16 val);
|
||||
int _rtw_write32_async(struct adapter *adapter, u32 addr, u32 val);
|
||||
|
||||
|
||||
extern int _rtw_write8(struct adapter *adapter, u32 addr, u8 val);
|
||||
extern int _rtw_write16(struct adapter *adapter, u32 addr, u16 val);
|
||||
extern int _rtw_write32(struct adapter *adapter, u32 addr, u32 val);
|
||||
extern int _rtw_writeN(struct adapter *adapter, u32 addr, u32 length, u8 *pdata);
|
||||
|
||||
extern int _rtw_write8_async(struct adapter *adapter, u32 addr, u8 val);
|
||||
extern int _rtw_write16_async(struct adapter *adapter, u32 addr, u16 val);
|
||||
extern int _rtw_write32_async(struct adapter *adapter, u32 addr, u32 val);
|
||||
|
||||
extern void _rtw_write_mem(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
extern u32 _rtw_write_port(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
u32 _rtw_write_port_and_wait(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem, int timeout_ms);
|
||||
extern void _rtw_write_port_cancel(struct adapter *adapter);
|
||||
void _rtw_write_mem(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
u32 _rtw_write_port(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
u32 _rtw_write_port_and_wait(struct adapter *adapter, u32 addr, u32 cnt,
|
||||
u8 *pmem, int timeout_ms);
|
||||
void _rtw_write_port_cancel(struct adapter *adapter);
|
||||
|
||||
#define rtw_read8(adapter, addr) _rtw_read8((adapter), (addr))
|
||||
#define rtw_read16(adapter, addr) _rtw_read16((adapter), (addr))
|
||||
#define rtw_read32(adapter, addr) _rtw_read32((adapter), (addr))
|
||||
#define rtw_read_mem(adapter, addr, cnt, mem) _rtw_read_mem((adapter), (addr), (cnt), (mem))
|
||||
#define rtw_read_port(adapter, addr, cnt, mem) _rtw_read_port((adapter), (addr), (cnt), (mem))
|
||||
#define rtw_read_mem(adapter, addr, cnt, mem) \
|
||||
_rtw_read_mem((adapter), (addr), (cnt), (mem))
|
||||
#define rtw_read_port(adapter, addr, cnt, mem) \
|
||||
_rtw_read_port((adapter), (addr), (cnt), (mem))
|
||||
#define rtw_read_port_cancel(adapter) _rtw_read_port_cancel((adapter))
|
||||
|
||||
#define rtw_write8(adapter, addr, val) _rtw_write8((adapter), (addr), (val))
|
||||
#define rtw_write16(adapter, addr, val) _rtw_write16((adapter), (addr), (val))
|
||||
#define rtw_write32(adapter, addr, val) _rtw_write32((adapter), (addr), (val))
|
||||
#define rtw_writeN(adapter, addr, length, data) _rtw_writeN((adapter), (addr), (length), (data))
|
||||
|
||||
#define rtw_write8_async(adapter, addr, val) _rtw_write8_async((adapter), (addr), (val))
|
||||
#define rtw_write16_async(adapter, addr, val) _rtw_write16_async((adapter), (addr), (val))
|
||||
#define rtw_write32_async(adapter, addr, val) _rtw_write32_async((adapter), (addr), (val))
|
||||
|
||||
#define rtw_write_mem(adapter, addr, cnt, mem) _rtw_write_mem((adapter), (addr), (cnt), (mem))
|
||||
#define rtw_write_port(adapter, addr, cnt, mem) _rtw_write_port((adapter), (addr), (cnt), (mem))
|
||||
#define rtw_write_port_and_wait(adapter, addr, cnt, mem, timeout_ms) _rtw_write_port_and_wait((adapter), (addr), (cnt), (mem), (timeout_ms))
|
||||
#define rtw_write8(adapter, addr, val) \
|
||||
_rtw_write8((adapter), (addr), (val))
|
||||
#define rtw_write16(adapter, addr, val) \
|
||||
_rtw_write16((adapter), (addr), (val))
|
||||
#define rtw_write32(adapter, addr, val) \
|
||||
_rtw_write32((adapter), (addr), (val))
|
||||
#define rtw_writeN(adapter, addr, length, data) \
|
||||
_rtw_writeN((adapter), (addr), (length), (data))
|
||||
#define rtw_write8_async(adapter, addr, val) \
|
||||
_rtw_write8_async((adapter), (addr), (val))
|
||||
#define rtw_write16_async(adapter, addr, val) \
|
||||
_rtw_write16_async((adapter), (addr), (val))
|
||||
#define rtw_write32_async(adapter, addr, val) \
|
||||
_rtw_write32_async((adapter), (addr), (val))
|
||||
#define rtw_write_mem(adapter, addr, cnt, mem) \
|
||||
_rtw_write_mem((adapter), (addr), (cnt), (mem))
|
||||
#define rtw_write_port(adapter, addr, cnt, mem) \
|
||||
_rtw_write_port((adapter), (addr), (cnt), (mem))
|
||||
#define rtw_write_port_and_wait(adapter, addr, cnt, mem, timeout_ms) \
|
||||
_rtw_write_port_and_wait((adapter), (addr), (cnt), (mem), (timeout_ms))
|
||||
#define rtw_write_port_cancel(adapter) _rtw_write_port_cancel((adapter))
|
||||
|
||||
extern void rtw_write_scsi(struct adapter *adapter, u32 cnt, u8 *pmem);
|
||||
void rtw_write_scsi(struct adapter *adapter, u32 cnt, u8 *pmem);
|
||||
|
||||
/* ioreq */
|
||||
extern void ioreq_read8(struct adapter *adapter, u32 addr, u8 *pval);
|
||||
extern void ioreq_read16(struct adapter *adapter, u32 addr, u16 *pval);
|
||||
extern void ioreq_read32(struct adapter *adapter, u32 addr, u32 *pval);
|
||||
extern void ioreq_write8(struct adapter *adapter, u32 addr, u8 val);
|
||||
extern void ioreq_write16(struct adapter *adapter, u32 addr, u16 val);
|
||||
extern void ioreq_write32(struct adapter *adapter, u32 addr, u32 val);
|
||||
void ioreq_read8(struct adapter *adapter, u32 addr, u8 *pval);
|
||||
void ioreq_read16(struct adapter *adapter, u32 addr, u16 *pval);
|
||||
void ioreq_read32(struct adapter *adapter, u32 addr, u32 *pval);
|
||||
void ioreq_write8(struct adapter *adapter, u32 addr, u8 val);
|
||||
void ioreq_write16(struct adapter *adapter, u32 addr, u16 val);
|
||||
void ioreq_write32(struct adapter *adapter, u32 addr, u32 val);
|
||||
|
||||
uint async_read8(struct adapter *adapter, u32 addr, u8 *pbuff,
|
||||
void (*_async_io_callback)(struct adapter *padater,
|
||||
struct io_req *pio_req,
|
||||
u8 *cnxt), u8 *cnxt);
|
||||
uint async_read16(struct adapter *adapter, u32 addr, u8 *pbuff,
|
||||
void (*_async_io_callback)(struct adapter *padater,
|
||||
struct io_req *pio_req,
|
||||
u8 *cnxt), u8 *cnxt);
|
||||
uint async_read32(struct adapter *adapter, u32 addr, u8 *pbuff,
|
||||
void (*_async_io_callback)(struct adapter *padater,
|
||||
struct io_req *pio_req,
|
||||
u8 *cnxt), u8 *cnxt);
|
||||
|
||||
extern uint async_read8(struct adapter *adapter, u32 addr, u8 *pbuff,
|
||||
void (*_async_io_callback)(struct adapter *padater, struct io_req *pio_req, u8 *cnxt), u8 *cnxt);
|
||||
extern uint async_read16(struct adapter *adapter, u32 addr, u8 *pbuff,
|
||||
void (*_async_io_callback)(struct adapter *padater, struct io_req *pio_req, u8 *cnxt), u8 *cnxt);
|
||||
extern uint async_read32(struct adapter *adapter, u32 addr, u8 *pbuff,
|
||||
void (*_async_io_callback)(struct adapter *padater, struct io_req *pio_req, u8 *cnxt), u8 *cnxt);
|
||||
void async_read_mem(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
void async_read_port(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
|
||||
extern void async_read_mem(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
extern void async_read_port(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
void async_write8(struct adapter *adapter, u32 addr, u8 val,
|
||||
void (*_async_io_callback)(struct adapter *padater,
|
||||
struct io_req *pio_req,
|
||||
u8 *cnxt), u8 *cnxt);
|
||||
void async_write16(struct adapter *adapter, u32 addr, u16 val,
|
||||
void (*_async_io_callback)(struct adapter *padater,
|
||||
struct io_req *pio_req,
|
||||
u8 *cnxt), u8 *cnxt);
|
||||
void async_write32(struct adapter *adapter, u32 addr, u32 val,
|
||||
void (*_async_io_callback)(struct adapter *padater,
|
||||
struct io_req *pio_req,
|
||||
u8 *cnxt), u8 *cnxt);
|
||||
|
||||
extern void async_write8(struct adapter *adapter, u32 addr, u8 val,
|
||||
void (*_async_io_callback)(struct adapter *padater, struct io_req *pio_req, u8 *cnxt), u8 *cnxt);
|
||||
extern void async_write16(struct adapter *adapter, u32 addr, u16 val,
|
||||
void (*_async_io_callback)(struct adapter *padater, struct io_req *pio_req, u8 *cnxt), u8 *cnxt);
|
||||
extern void async_write32(struct adapter *adapter, u32 addr, u32 val,
|
||||
void (*_async_io_callback)(struct adapter *padater, struct io_req *pio_req, u8 *cnxt), u8 *cnxt);
|
||||
void async_write_mem(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
void async_write_port(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
|
||||
extern void async_write_mem(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
extern void async_write_port(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
|
||||
int rtw_init_io_priv(struct adapter *padapter,
|
||||
void (*set_intf_ops)(struct _io_ops *pops));
|
||||
|
||||
|
||||
int rtw_init_io_priv(struct adapter *padapter, void (*set_intf_ops)(struct _io_ops *pops));
|
||||
|
||||
|
||||
extern uint alloc_io_queue(struct adapter *adapter);
|
||||
extern void free_io_queue(struct adapter *adapter);
|
||||
extern void async_bus_io(struct io_queue *pio_q);
|
||||
extern void bus_sync_io(struct io_queue *pio_q);
|
||||
extern u32 _ioreq2rwmem(struct io_queue *pio_q);
|
||||
extern void dev_power_down(struct adapter * Adapter, u8 bpwrup);
|
||||
|
||||
/*
|
||||
#define RTL_R8(reg) rtw_read8(padapter, reg)
|
||||
#define RTL_R16(reg) rtw_read16(padapter, reg)
|
||||
#define RTL_R32(reg) rtw_read32(padapter, reg)
|
||||
#define RTL_W8(reg, val8) rtw_write8(padapter, reg, val8)
|
||||
#define RTL_W16(reg, val16) rtw_write16(padapter, reg, val16)
|
||||
#define RTL_W32(reg, val32) rtw_write32(padapter, reg, val32)
|
||||
*/
|
||||
|
||||
/*
|
||||
#define RTL_W8_ASYNC(reg, val8) rtw_write32_async(padapter, reg, val8)
|
||||
#define RTL_W16_ASYNC(reg, val16) rtw_write32_async(padapter, reg, val16)
|
||||
#define RTL_W32_ASYNC(reg, val32) rtw_write32_async(padapter, reg, val32)
|
||||
|
||||
#define RTL_WRITE_BB(reg, val32) phy_SetUsbBBReg(padapter, reg, val32)
|
||||
#define RTL_READ_BB(reg) phy_QueryUsbBBReg(padapter, reg)
|
||||
*/
|
||||
uint alloc_io_queue(struct adapter *adapter);
|
||||
void free_io_queue(struct adapter *adapter);
|
||||
void async_bus_io(struct io_queue *pio_q);
|
||||
void bus_sync_io(struct io_queue *pio_q);
|
||||
u32 _ioreq2rwmem(struct io_queue *pio_q);
|
||||
void dev_power_down(struct adapter * Adapter, u8 bpwrup);
|
||||
|
||||
#define PlatformEFIOWrite1Byte(_a,_b,_c) \
|
||||
rtw_write8(_a,_b,_c)
|
||||
|
|
|
@ -64,9 +64,9 @@
|
|||
#define OID_MP_SEG4 0xFF011100
|
||||
|
||||
#define DEBUG_OID(dbg, str) \
|
||||
if ((!dbg)) { \
|
||||
RT_TRACE(_module_rtl871x_ioctl_c_, _drv_info_, \
|
||||
("%s(%d): %s", __func__, __LINE__, str)); \
|
||||
if ((!dbg)) { \
|
||||
RT_TRACE(_module_rtl871x_ioctl_c_, _drv_info_, \
|
||||
("%s(%d): %s", __func__, __line__, str)); \
|
||||
}
|
||||
|
||||
enum oid_type {
|
||||
|
@ -83,8 +83,7 @@ struct oid_funs_node {
|
|||
int set_counter; /* count the number of set hits for this segment */
|
||||
};
|
||||
|
||||
struct oid_par_priv
|
||||
{
|
||||
struct oid_par_priv {
|
||||
void *adapter_context;
|
||||
NDIS_OID oid;
|
||||
void *information_buf;
|
||||
|
@ -96,13 +95,13 @@ struct oid_par_priv
|
|||
};
|
||||
|
||||
struct oid_obj_priv {
|
||||
unsigned char dbg; /* 0: without OID debug message 1: with OID debug message */
|
||||
unsigned char dbg; /* 0: without OID debug message
|
||||
* 1: with OID debug message */
|
||||
int (*oidfuns)(struct oid_par_priv *poid_par_priv);
|
||||
};
|
||||
|
||||
#if defined(_RTW_MP_IOCTL_C_)
|
||||
static int oid_null_function(struct oid_par_priv* poid_par_priv)
|
||||
{
|
||||
static int oid_null_function(struct oid_par_priv *poid_par_priv) {
|
||||
_func_enter_;
|
||||
_func_exit_;
|
||||
return NDIS_STATUS_SUCCESS;
|
||||
|
|
|
@ -24,59 +24,56 @@
|
|||
#include <drv_types.h>
|
||||
|
||||
/* oid_rtl_seg_01_01 ************** */
|
||||
int oid_rt_get_signal_quality_hdl(struct oid_par_priv* poid_par_priv);/* 84 */
|
||||
int oid_rt_get_small_packet_crc_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_middle_packet_crc_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_large_packet_crc_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_tx_retry_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_rx_retry_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_rx_total_packet_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_tx_beacon_ok_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_tx_beacon_err_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_signal_quality_hdl(struct oid_par_priv *poid_par_priv);/* 84 */
|
||||
int oid_rt_get_small_packet_crc_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_middle_packet_crc_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_large_packet_crc_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_tx_retry_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_rx_retry_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_rx_total_packet_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_tx_beacon_ok_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_tx_beacon_err_hdl(struct oid_par_priv *poid_par_priv);
|
||||
|
||||
int oid_rt_pro_set_fw_dig_state_hdl(struct oid_par_priv* poid_par_priv); /* 8a */
|
||||
int oid_rt_pro_set_fw_ra_state_hdl(struct oid_par_priv* poid_par_priv); /* 8b */
|
||||
int oid_rt_pro_set_fw_dig_state_hdl(struct oid_par_priv *poid_par_priv);/* 8a */
|
||||
int oid_rt_pro_set_fw_ra_state_hdl(struct oid_par_priv *poid_par_priv); /* 8b */
|
||||
|
||||
int oid_rt_get_rx_icv_err_hdl(struct oid_par_priv* poid_par_priv);/* 93 */
|
||||
int oid_rt_set_encryption_algorithm_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_preamble_mode_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_ap_ip_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_channelplan_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_set_channelplan_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_set_preamble_mode_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_set_bcn_intvl_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_dedicate_probe_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_total_tx_bytes_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_total_rx_bytes_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_current_tx_power_level_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_enc_key_mismatch_count_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_enc_key_match_count_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_channel_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_hardware_radio_off_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_key_mismatch_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_supported_wireless_mode_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_channel_list_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_scan_in_progress_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_forced_data_rate_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_wireless_mode_for_scan_list_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_bss_wireless_mode_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_scan_with_magic_packet_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_get_rx_icv_err_hdl(struct oid_par_priv *poid_par_priv);/* 93 */
|
||||
int oid_rt_set_encryption_algorithm_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_preamble_mode_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_ap_ip_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_channelplan_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_set_channelplan_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_set_preamble_mode_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_set_bcn_intvl_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_dedicate_probe_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_total_tx_bytes_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_total_rx_bytes_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_current_tx_power_level_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_enc_key_mismatch_count_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_enc_key_match_count_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_channel_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_hardware_radio_off_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_key_mismatch_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_supported_wireless_mode_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_channel_list_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_scan_in_progress_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_forced_data_rate_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_wireless_mode_for_scan_list_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_bss_wireless_mode_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_scan_with_magic_packet_hdl(struct oid_par_priv *poid_par_priv);
|
||||
|
||||
/* oid_rtl_seg_01_03 section start ************** */
|
||||
int oid_rt_ap_get_associated_station_list_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_ap_switch_into_ap_mode_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_ap_supported_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_ap_set_passphrase_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_ap_get_associated_station_list_hdl(struct oid_par_priv *priv);
|
||||
int oid_rt_ap_switch_into_ap_mode_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_ap_supported_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_ap_set_passphrase_hdl(struct oid_par_priv *poid_par_priv);
|
||||
|
||||
/* oid_rtl_seg_01_11 */
|
||||
int oid_rt_pro_rf_write_registry_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_pro_rf_read_registry_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_pro_rf_write_registry_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_rf_read_registry_hdl(struct oid_par_priv *poid_par_priv);
|
||||
|
||||
/* oid_rtl_seg_03_00 section start ************** */
|
||||
int oid_rt_get_connect_state_hdl(struct oid_par_priv* poid_par_priv);
|
||||
int oid_rt_set_default_key_id_hdl(struct oid_par_priv* poid_par_priv);
|
||||
|
||||
|
||||
|
||||
int oid_rt_get_connect_state_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_set_default_key_id_hdl(struct oid_par_priv *poid_par_priv);
|
||||
|
||||
#endif
|
||||
|
|
|
@ -25,20 +25,22 @@
|
|||
|
||||
typedef u8 NDIS_802_11_PMKID_VALUE[16];
|
||||
|
||||
u8 rtw_set_802_11_add_key(struct adapter * padapter, struct ndis_802_11_key * key);
|
||||
u8 rtw_set_802_11_authentication_mode(struct adapter *pdapter, enum ndis_802_11_auth_mode authmode);
|
||||
u8 rtw_set_802_11_bssid(struct adapter* padapter, u8 *bssid);
|
||||
u8 rtw_set_802_11_add_wep(struct adapter * padapter, struct ndis_802_11_wep * wep);
|
||||
u8 rtw_set_802_11_disassociate(struct adapter * padapter);
|
||||
u8 rtw_set_802_11_bssid_list_scan(struct adapter* padapter, struct ndis_802_11_ssid *pssid, int ssid_max_num);
|
||||
u8 rtw_set_802_11_infrastructure_mode(struct adapter * padapter, enum ndis_802_11_network_infra networktype);
|
||||
u8 rtw_set_802_11_remove_wep(struct adapter * padapter, u32 keyindex);
|
||||
u8 rtw_set_802_11_ssid(struct adapter * padapter, struct ndis_802_11_ssid * ssid);
|
||||
u8 rtw_set_802_11_remove_key(struct adapter * padapter, struct ndis_802_11_remove_key * key);
|
||||
|
||||
|
||||
u8 rtw_set_802_11_add_key(struct adapter *adapt, struct ndis_802_11_key *key);
|
||||
u8 rtw_set_802_11_authentication_mode(struct adapter *adapt,
|
||||
enum ndis_802_11_auth_mode authmode);
|
||||
u8 rtw_set_802_11_bssid(struct adapter*adapter, u8 *bssid);
|
||||
u8 rtw_set_802_11_add_wep(struct adapter *adapter, struct ndis_802_11_wep *wep);
|
||||
u8 rtw_set_802_11_disassociate(struct adapter *adapter);
|
||||
u8 rtw_set_802_11_bssid_list_scan(struct adapter*adapter,
|
||||
struct ndis_802_11_ssid *pssid,
|
||||
int ssid_max_num);
|
||||
u8 rtw_set_802_11_infrastructure_mode(struct adapter *adapter,
|
||||
enum ndis_802_11_network_infra type);
|
||||
u8 rtw_set_802_11_remove_wep(struct adapter *adapter, u32 keyindex);
|
||||
u8 rtw_set_802_11_ssid(struct adapter *adapt, struct ndis_802_11_ssid *ssid);
|
||||
u8 rtw_set_802_11_remove_key(struct adapter *adapt,
|
||||
struct ndis_802_11_remove_key *key);
|
||||
u8 rtw_validate_ssid(struct ndis_802_11_ssid *ssid);
|
||||
|
||||
u16 rtw_get_cur_max_rate(struct adapter *adapter);
|
||||
int rtw_set_scan_mode(struct adapter *adapter, enum rt_scan_type scan_mode);
|
||||
int rtw_set_channel_plan(struct adapter *adapter, u8 channel_plan);
|
||||
|
|
|
@ -22,30 +22,22 @@
|
|||
|
||||
#include <osdep_service.h>
|
||||
#include <drv_types.h>
|
||||
struct xmit_frame *rtw_IOL_accquire_xmit_frame(struct adapter *adapter);
|
||||
int rtw_IOL_append_cmds(struct xmit_frame *xmit_frame, u8 *IOL_cmds, u32 cmd_len);
|
||||
int rtw_IOL_append_LLT_cmd(struct xmit_frame *xmit_frame, u8 page_boundary);
|
||||
int rtw_IOL_exec_cmds_sync(struct adapter *adapter, struct xmit_frame *xmit_frame, u32 max_wating_ms, u32 bndy_cnt);
|
||||
bool rtw_IOL_applied(struct adapter *adapter);
|
||||
int rtw_IOL_append_DELAY_US_cmd(struct xmit_frame *xmit_frame, u16 us);
|
||||
int rtw_IOL_append_DELAY_MS_cmd(struct xmit_frame *xmit_frame, u16 ms);
|
||||
int rtw_IOL_append_END_cmd(struct xmit_frame *xmit_frame);
|
||||
|
||||
|
||||
#define IOREG_CMD_END_LEN 4
|
||||
|
||||
struct ioreg_cfg{
|
||||
struct ioreg_cfg {
|
||||
u8 length;
|
||||
u8 cmd_id;
|
||||
__le16 address;
|
||||
__le32 data;
|
||||
__le32 mask;
|
||||
};
|
||||
enum ioreg_cmd{
|
||||
IOREG_CMD_LLT = 0x01,
|
||||
IOREG_CMD_REFUSE = 0x02,
|
||||
IOREG_CMD_EFUSE_PATH = 0x03,
|
||||
IOREG_CMD_WB_REG = 0x04,
|
||||
|
||||
enum ioreg_cmd {
|
||||
IOREG_CMD_LLT = 0x01,
|
||||
IOREG_CMD_REFUSE = 0x02,
|
||||
IOREG_CMD_EFUSE_PATH = 0x03,
|
||||
IOREG_CMD_WB_REG = 0x04,
|
||||
IOREG_CMD_WW_REG = 0x05,
|
||||
IOREG_CMD_WD_REG = 0x06,
|
||||
IOREG_CMD_W_RF = 0x07,
|
||||
|
@ -53,16 +45,38 @@ enum ioreg_cmd{
|
|||
IOREG_CMD_DELAY_MS = 0x11,
|
||||
IOREG_CMD_END = 0xFF,
|
||||
};
|
||||
void read_efuse_from_txpktbuf(struct adapter *adapter, int bcnhead, u8 *content, u16 *size);
|
||||
|
||||
int _rtw_IOL_append_WB_cmd(struct xmit_frame *xmit_frame, u16 addr, u8 value, u8 mask);
|
||||
int _rtw_IOL_append_WW_cmd(struct xmit_frame *xmit_frame, u16 addr, u16 value, u16 mask);
|
||||
int _rtw_IOL_append_WD_cmd(struct xmit_frame *xmit_frame, u16 addr, u32 value, u32 mask);
|
||||
int _rtw_IOL_append_WRF_cmd(struct xmit_frame *xmit_frame, u8 rf_path, u16 addr, u32 value, u32 mask);
|
||||
#define rtw_IOL_append_WB_cmd(xmit_frame, addr, value,mask) _rtw_IOL_append_WB_cmd((xmit_frame), (addr), (value) ,(mask))
|
||||
#define rtw_IOL_append_WW_cmd(xmit_frame, addr, value,mask) _rtw_IOL_append_WW_cmd((xmit_frame), (addr), (value),(mask))
|
||||
#define rtw_IOL_append_WD_cmd(xmit_frame, addr, value,mask) _rtw_IOL_append_WD_cmd((xmit_frame), (addr), (value),(mask))
|
||||
#define rtw_IOL_append_WRF_cmd(xmit_frame, rf_path, addr, value,mask) _rtw_IOL_append_WRF_cmd((xmit_frame),(rf_path), (addr), (value),(mask))
|
||||
struct xmit_frame *rtw_IOL_accquire_xmit_frame(struct adapter *adapter);
|
||||
int rtw_IOL_append_cmds(struct xmit_frame *xmit_frame, u8 *IOL_cmds,
|
||||
u32 cmd_len);
|
||||
int rtw_IOL_append_LLT_cmd(struct xmit_frame *xmit_frame, u8 page_boundary);
|
||||
int rtw_IOL_exec_cmds_sync(struct adapter *adapter,
|
||||
struct xmit_frame *xmit_frame, u32 max_wating_ms,
|
||||
u32 bndy_cnt);
|
||||
bool rtw_IOL_applied(struct adapter *adapter);
|
||||
int rtw_IOL_append_DELAY_US_cmd(struct xmit_frame *xmit_frame, u16 us);
|
||||
int rtw_IOL_append_DELAY_MS_cmd(struct xmit_frame *xmit_frame, u16 ms);
|
||||
int rtw_IOL_append_END_cmd(struct xmit_frame *xmit_frame);
|
||||
|
||||
void read_efuse_from_txpktbuf(struct adapter *adapter, int bcnhead,
|
||||
u8 *content, u16 *size);
|
||||
|
||||
int _rtw_IOL_append_WB_cmd(struct xmit_frame *xmit_frame, u16 addr,
|
||||
u8 value, u8 mask);
|
||||
int _rtw_IOL_append_WW_cmd(struct xmit_frame *xmit_frame, u16 addr,
|
||||
u16 value, u16 mask);
|
||||
int _rtw_IOL_append_WD_cmd(struct xmit_frame *xmit_frame, u16 addr,
|
||||
u32 value, u32 mask);
|
||||
int _rtw_IOL_append_WRF_cmd(struct xmit_frame *xmit_frame, u8 rf_path,
|
||||
u16 addr, u32 value, u32 mask);
|
||||
#define rtw_IOL_append_WB_cmd(xmit_frame, addr, value, mask) \
|
||||
_rtw_IOL_append_WB_cmd((xmit_frame), (addr), (value) ,(mask))
|
||||
#define rtw_IOL_append_WW_cmd(xmit_frame, addr, value, mask) \
|
||||
_rtw_IOL_append_WW_cmd((xmit_frame), (addr), (value),(mask))
|
||||
#define rtw_IOL_append_WD_cmd(xmit_frame, addr, value, mask) \
|
||||
_rtw_IOL_append_WD_cmd((xmit_frame), (addr), (value), (mask))
|
||||
#define rtw_IOL_append_WRF_cmd(xmit_frame, rf_path, addr, value, mask) \
|
||||
_rtw_IOL_append_WRF_cmd((xmit_frame),(rf_path), (addr), (value), (mask))
|
||||
|
||||
u8 rtw_IOL_cmd_boundary_handle(struct xmit_frame *pxmit_frame);
|
||||
void rtw_IOL_cmd_buf_dump(struct adapter *Adapter,int buf_len,u8 *pbuf);
|
||||
|
|
|
@ -25,36 +25,36 @@
|
|||
|
||||
#define MSECS(t) (HZ * ((t) / 1000) + (HZ * ((t) % 1000)) / 1000)
|
||||
|
||||
#define LED_BLINK_NORMAL_INTERVAL 100
|
||||
#define LED_BLINK_SLOWLY_INTERVAL 200
|
||||
#define LED_BLINK_LONG_INTERVAL 400
|
||||
#define LED_BLINK_NORMAL_INTERVAL 100
|
||||
#define LED_BLINK_SLOWLY_INTERVAL 200
|
||||
#define LED_BLINK_LONG_INTERVAL 400
|
||||
|
||||
#define LED_BLINK_NO_LINK_INTERVAL_ALPHA 1000
|
||||
#define LED_BLINK_LINK_INTERVAL_ALPHA 500 /* 500 */
|
||||
#define LED_BLINK_NO_LINK_INTERVAL_ALPHA 1000
|
||||
#define LED_BLINK_LINK_INTERVAL_ALPHA 500 /* 500 */
|
||||
#define LED_BLINK_SCAN_INTERVAL_ALPHA 180 /* 150 */
|
||||
#define LED_BLINK_FASTER_INTERVAL_ALPHA 50
|
||||
#define LED_BLINK_WPS_SUCESS_INTERVAL_ALPHA 5000
|
||||
|
||||
#define LED_BLINK_NORMAL_INTERVAL_NETTRONIX 100
|
||||
#define LED_BLINK_SLOWLY_INTERVAL_NETTRONIX 2000
|
||||
#define LED_BLINK_NORMAL_INTERVAL_NETTRONIX 100
|
||||
#define LED_BLINK_SLOWLY_INTERVAL_NETTRONIX 2000
|
||||
|
||||
#define LED_BLINK_SLOWLY_INTERVAL_PORNET 1000
|
||||
#define LED_BLINK_NORMAL_INTERVAL_PORNET 100
|
||||
#define LED_BLINK_SLOWLY_INTERVAL_PORNET 1000
|
||||
#define LED_BLINK_NORMAL_INTERVAL_PORNET 100
|
||||
|
||||
#define LED_BLINK_FAST_INTERVAL_BITLAND 30
|
||||
#define LED_BLINK_FAST_INTERVAL_BITLAND 30
|
||||
|
||||
/* 060403, rcnjko: Customized for AzWave. */
|
||||
#define LED_CM2_BLINK_ON_INTERVAL 250
|
||||
#define LED_CM2_BLINK_ON_INTERVAL 250
|
||||
#define LED_CM2_BLINK_OFF_INTERVAL 4750
|
||||
|
||||
#define LED_CM8_BLINK_INTERVAL 500 /* for QMI */
|
||||
#define LED_CM8_BLINK_OFF_INTERVAL 3750 /* for QMI */
|
||||
#define LED_CM8_BLINK_INTERVAL 500 /* for QMI */
|
||||
#define LED_CM8_BLINK_OFF_INTERVAL 3750 /* for QMI */
|
||||
|
||||
/* 080124, lanhsin: Customized for RunTop */
|
||||
#define LED_RunTop_BLINK_INTERVAL 300
|
||||
#define LED_RunTop_BLINK_INTERVAL 300
|
||||
|
||||
/* 060421, rcnjko: Customized for Sercomm Printer Server case. */
|
||||
#define LED_CM3_BLINK_INTERVAL 1500
|
||||
#define LED_CM3_BLINK_INTERVAL 1500
|
||||
|
||||
enum LED_CTL_MODE {
|
||||
LED_CTL_POWER_ON = 1,
|
||||
|
@ -80,9 +80,12 @@ enum LED_STATE_871x {
|
|||
LED_BLINK_NORMAL = 3,
|
||||
LED_BLINK_SLOWLY = 4,
|
||||
LED_BLINK_POWER_ON = 5,
|
||||
LED_BLINK_SCAN = 6, /* LED is blinking during scanning period, the # of times to blink is depend on time for scanning. */
|
||||
LED_BLINK_SCAN = 6, /* LED is blinking during scanning period,
|
||||
* the # of times to blink is depend on time
|
||||
* for scanning. */
|
||||
LED_BLINK_NO_LINK = 7, /* LED is blinking during no link state. */
|
||||
LED_BLINK_StartToBlink = 8,/* Customzied for Sercomm Printer Server case */
|
||||
LED_BLINK_StartToBlink = 8,/* Customzied for Sercomm Printer
|
||||
* Server case */
|
||||
LED_BLINK_TXRX = 9,
|
||||
LED_BLINK_WPS = 10, /* LED is blinkg during WPS communication */
|
||||
LED_BLINK_WPS_STOP = 11, /* for ALPHA */
|
||||
|
@ -102,75 +105,78 @@ enum LED_PIN_871x {
|
|||
};
|
||||
|
||||
struct LED_871x {
|
||||
struct adapter *padapter;
|
||||
struct adapter *padapter;
|
||||
|
||||
enum LED_PIN_871x LedPin; /* Identify how to implement this SW led. */
|
||||
enum LED_PIN_871x LedPin; /* Identify how to implement this
|
||||
* SW led. */
|
||||
enum LED_STATE_871x CurrLedState; /* Current LED state. */
|
||||
enum LED_STATE_871x BlinkingLedState; /* Next state for blinking, either RTW_LED_ON or RTW_LED_OFF are. */
|
||||
enum LED_STATE_871x BlinkingLedState; /* Next state for blinking,
|
||||
* either RTW_LED_ON or RTW_LED_OFF are. */
|
||||
|
||||
u8 bLedOn; /* true if LED is ON, false if LED is OFF. */
|
||||
u8 bLedOn; /* true if LED is ON, false if LED is OFF. */
|
||||
|
||||
u8 bLedBlinkInProgress; /* true if it is blinking, false o.w.. */
|
||||
u8 bLedBlinkInProgress; /* true if it is blinking, false o.w.. */
|
||||
|
||||
u8 bLedWPSBlinkInProgress;
|
||||
u8 bLedWPSBlinkInProgress;
|
||||
|
||||
u32 BlinkTimes; /* Number of times to toggle led state for blinking. */
|
||||
u32 BlinkTimes; /* Number of times to toggle led state for blinking. */
|
||||
|
||||
struct timer_list BlinkTimer; /* Timer object for led blinking. */
|
||||
|
||||
u8 bSWLedCtrl;
|
||||
u8 bSWLedCtrl;
|
||||
|
||||
/* ALPHA, added by chiyoko, 20090106 */
|
||||
u8 bLedNoLinkBlinkInProgress;
|
||||
u8 bLedLinkBlinkInProgress;
|
||||
u8 bLedStartToLinkBlinkInProgress;
|
||||
u8 bLedScanBlinkInProgress;
|
||||
struct work_struct BlinkWorkItem; /* Workitem used by BlinkTimer to manipulate H/W to blink LED. */
|
||||
u8 bLedNoLinkBlinkInProgress;
|
||||
u8 bLedLinkBlinkInProgress;
|
||||
u8 bLedStartToLinkBlinkInProgress;
|
||||
u8 bLedScanBlinkInProgress;
|
||||
struct work_struct BlinkWorkItem; /* Workitem used by BlinkTimer to
|
||||
* manipulate H/W to blink LED. */
|
||||
};
|
||||
|
||||
#define IS_LED_WPS_BLINKING(_LED_871x) (((struct LED_871x *)_LED_871x)->CurrLedState==LED_BLINK_WPS \
|
||||
|| ((struct LED_871x *)_LED_871x)->CurrLedState==LED_BLINK_WPS_STOP \
|
||||
|| ((struct LED_871x *)_LED_871x)->bLedWPSBlinkInProgress)
|
||||
#define IS_LED_WPS_BLINKING(_LED_871x) \
|
||||
(((struct LED_871x *)_LED_871x)->CurrLedState == LED_BLINK_WPS || \
|
||||
((struct LED_871x *)_LED_871x)->CurrLedState == LED_BLINK_WPS_STOP || \
|
||||
((struct LED_871x *)_LED_871x)->bLedWPSBlinkInProgress)
|
||||
|
||||
#define IS_LED_BLINKING(_LED_871x) (((struct LED_871x *)_LED_871x)->bLedWPSBlinkInProgress \
|
||||
||((struct LED_871x *)_LED_871x)->bLedScanBlinkInProgress)
|
||||
#define IS_LED_BLINKING(_LED_871x) \
|
||||
(((struct LED_871x *)_LED_871x)->bLedWPSBlinkInProgress || \
|
||||
((struct LED_871x *)_LED_871x)->bLedScanBlinkInProgress)
|
||||
|
||||
/* */
|
||||
/* LED customization. */
|
||||
/* */
|
||||
|
||||
enum LED_STRATEGY_871x {
|
||||
SW_LED_MODE0 = 0, /* SW control 1 LED via GPIO0. It is default option. */
|
||||
SW_LED_MODE0 = 0, /* SW control 1 LED via GPIO0. It is default option.*/
|
||||
SW_LED_MODE1= 1, /* 2 LEDs, through LED0 and LED1. For ALPHA. */
|
||||
SW_LED_MODE2 = 2, /* SW control 1 LED via GPIO0, customized for AzWave 8187 minicard. */
|
||||
SW_LED_MODE3 = 3, /* SW control 1 LED via GPIO0, customized for Sercomm Printer Server case. */
|
||||
SW_LED_MODE2 = 2, /* SW control 1 LED via GPIO0, customized for AzWave
|
||||
* 8187 minicard. */
|
||||
SW_LED_MODE3 = 3, /* SW control 1 LED via GPIO0, customized for Sercomm
|
||||
* Printer Server case. */
|
||||
SW_LED_MODE4 = 4, /* for Edimax / Belkin */
|
||||
SW_LED_MODE5 = 5, /* for Sercomm / Belkin */
|
||||
SW_LED_MODE6 = 6, /* for 88CU minicard, porting from ce SW_LED_MODE7 */
|
||||
HW_LED = 50, /* HW control 2 LEDs, LED0 and LED1 (there are 4 different control modes, see MAC.CONFIG1 for details.) */
|
||||
HW_LED = 50, /* HW control 2 LEDs, LED0 and LED1 (there are 4
|
||||
* different control modes, see MAC.CONFIG1 for details.)*/
|
||||
LED_ST_NONE = 99,
|
||||
};
|
||||
|
||||
void
|
||||
LedControl871x(
|
||||
struct adapter *padapter,
|
||||
enum LED_CTL_MODE LedAction
|
||||
);
|
||||
void LedControl871x(struct adapter *padapter, enum LED_CTL_MODE LedAction);
|
||||
|
||||
struct led_priv{
|
||||
/* add for led controll */
|
||||
struct LED_871x SwLed0;
|
||||
struct LED_871x SwLed1;
|
||||
enum LED_STRATEGY_871x LedStrategy;
|
||||
u8 bRegUseLed;
|
||||
void (*LedControlHandler)(struct adapter *padapter, enum LED_CTL_MODE LedAction);
|
||||
u8 bRegUseLed;
|
||||
void (*LedControlHandler)(struct adapter *padapter,
|
||||
enum LED_CTL_MODE LedAction);
|
||||
/* add for led controll */
|
||||
};
|
||||
|
||||
#define rtw_led_control(adapter, LedAction) \
|
||||
#define rtw_led_control(adapt, action) \
|
||||
do { \
|
||||
if ((adapter)->ledpriv.LedControlHandler) \
|
||||
(adapter)->ledpriv.LedControlHandler((adapter), (LedAction)); \
|
||||
if ((adapt)->ledpriv.LedControlHandler) \
|
||||
(adapt)->ledpriv.LedControlHandler((adapt), (action)); \
|
||||
} while (0)
|
||||
|
||||
void BlinkTimerCallback(void *data);
|
||||
|
@ -178,18 +184,14 @@ void BlinkWorkItemCallback(struct work_struct *work);
|
|||
|
||||
void ResetLedStatus(struct LED_871x * pLed);
|
||||
|
||||
void
|
||||
InitLed871x(
|
||||
struct adapter *padapter,
|
||||
struct LED_871x *pLed,
|
||||
enum LED_PIN_871x LedPin
|
||||
);
|
||||
void InitLed871x(struct adapter *padapter, struct LED_871x *pLed,
|
||||
enum LED_PIN_871x LedPin);
|
||||
|
||||
void DeInitLed871x(struct LED_871x *pLed);
|
||||
|
||||
/* hal... */
|
||||
void BlinkHandler(struct LED_871x * pLed);
|
||||
void SwLedOn(struct adapter *padapter, struct LED_871x * pLed);
|
||||
void SwLedOn(struct adapter *padapter, struct LED_871x *pLed);
|
||||
void SwLedOff(struct adapter *padapter, struct LED_871x *pLed);
|
||||
|
||||
#endif /* __RTW_LED_H_ */
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
#define MAX_BSS_CNT 128
|
||||
#define MAX_JOIN_TIMEOUT 6500
|
||||
|
||||
/* Increase the scanning timeout because of increasing the SURVEY_TO value. */
|
||||
/* Increase the scanning timeout because of increasing the SURVEY_TO value. */
|
||||
|
||||
#define SCANNING_TIMEOUT 8000
|
||||
|
||||
|
@ -36,29 +36,29 @@
|
|||
|
||||
#define SCANQUEUE_LIFETIME 20 /* unit:sec */
|
||||
|
||||
#define WIFI_NULL_STATE 0x00000000
|
||||
#define WIFI_NULL_STATE 0x00000000
|
||||
|
||||
#define WIFI_ASOC_STATE 0x00000001 /* Under Linked state... */
|
||||
#define WIFI_REASOC_STATE 0x00000002
|
||||
#define WIFI_SLEEP_STATE 0x00000004
|
||||
#define WIFI_ASOC_STATE 0x00000001 /* Under Linked state */
|
||||
#define WIFI_REASOC_STATE 0x00000002
|
||||
#define WIFI_SLEEP_STATE 0x00000004
|
||||
#define WIFI_STATION_STATE 0x00000008
|
||||
|
||||
#define WIFI_AP_STATE 0x00000010
|
||||
#define WIFI_ADHOC_STATE 0x00000020
|
||||
#define WIFI_ADHOC_MASTER_STATE 0x00000040
|
||||
#define WIFI_UNDER_LINKING 0x00000080
|
||||
#define WIFI_AP_STATE 0x00000010
|
||||
#define WIFI_ADHOC_STATE 0x00000020
|
||||
#define WIFI_ADHOC_MASTER_STATE 0x00000040
|
||||
#define WIFI_UNDER_LINKING 0x00000080
|
||||
|
||||
#define WIFI_UNDER_WPS 0x00000100
|
||||
#define WIFI_STA_ALIVE_CHK_STATE 0x00000400
|
||||
#define WIFI_SITE_MONITOR 0x00000800 /* to indicate the station is under site surveying */
|
||||
#define WIFI_SITE_MONITOR 0x00000800 /* to indicate the station is under site surveying */
|
||||
|
||||
#define WIFI_MP_STATE 0x00010000
|
||||
#define WIFI_MP_CTX_BACKGROUND 0x00020000 /* in continous tx background */
|
||||
#define WIFI_MP_CTX_ST 0x00040000 /* in continous tx with single-tone */
|
||||
#define WIFI_MP_STATE 0x00010000
|
||||
#define WIFI_MP_CTX_BACKGROUND 0x00020000 /* in continous tx background */
|
||||
#define WIFI_MP_CTX_ST 0x00040000 /* in continous tx with single-tone */
|
||||
#define WIFI_MP_CTX_BACKGROUND_PENDING 0x00080000 /* pending in continous tx background due to out of skb */
|
||||
#define WIFI_MP_CTX_CCK_HW 0x00100000 /* in continous tx */
|
||||
#define WIFI_MP_CTX_CCK_CS 0x00200000 /* in continous tx with carrier suppression */
|
||||
#define WIFI_MP_LPBK_STATE 0x00400000
|
||||
#define WIFI_MP_CTX_CCK_HW 0x00100000 /* in continous tx */
|
||||
#define WIFI_MP_CTX_CCK_CS 0x00200000 /* in continous tx with carrier suppression */
|
||||
#define WIFI_MP_LPBK_STATE 0x00400000
|
||||
|
||||
#define _FW_UNDER_LINKING WIFI_UNDER_LINKING
|
||||
#define _FW_LINKED WIFI_ASOC_STATE
|
||||
|
@ -80,30 +80,29 @@ enum rt_scan_type {
|
|||
SCAN_MIX,
|
||||
};
|
||||
|
||||
enum SCAN_RESULT_TYPE
|
||||
{
|
||||
SCAN_RESULT_P2P_ONLY = 0, /* Will return all the P2P devices. */
|
||||
SCAN_RESULT_ALL = 1, /* Will return all the scanned device, include AP. */
|
||||
SCAN_RESULT_WFD_TYPE = 2 /* Will just return the correct WFD device. */
|
||||
/* If this device is Miracast sink device, it will just return all the Miracast source devices. */
|
||||
enum SCAN_RESULT_TYPE {
|
||||
SCAN_RESULT_P2P_ONLY = 0, /* Will return all the P2P devices. */
|
||||
SCAN_RESULT_ALL = 1, /* Will return all the scanned device,
|
||||
* include AP. */
|
||||
SCAN_RESULT_WFD_TYPE = 2 /* Will just return the correct WFD
|
||||
* device. */
|
||||
/* If this device is Miracast sink
|
||||
* device, it will just return all the
|
||||
* Miracast source devices. */
|
||||
};
|
||||
|
||||
/*
|
||||
|
||||
there are several "locks" in mlme_priv,
|
||||
since mlme_priv is a shared resource between many threads,
|
||||
like ISR/Call-Back functions, the OID handlers, and even timer functions.
|
||||
|
||||
|
||||
Each _queue has its own locks, already.
|
||||
Other items are protected by mlme_priv.lock.
|
||||
|
||||
To avoid possible dead lock, any thread trying to modifiying mlme_priv
|
||||
SHALL not lock up more than one locks at a time!
|
||||
|
||||
SHALL not lock up more than one lock at a time!
|
||||
*/
|
||||
|
||||
|
||||
#define traffic_threshold 10
|
||||
#define traffic_scan_period 500
|
||||
|
||||
|
@ -122,8 +121,10 @@ struct rt_link_detect {
|
|||
bool bTxBusyTraffic;
|
||||
bool bRxBusyTraffic;
|
||||
bool bHigherBusyTraffic; /* For interrupt migration purpose. */
|
||||
bool bHigherBusyRxTraffic; /* We may disable Tx interrupt according as Rx traffic. */
|
||||
bool bHigherBusyTxTraffic; /* We may disable Tx interrupt according as Tx traffic. */
|
||||
bool bHigherBusyRxTraffic; /* We may disable Tx interrupt according
|
||||
* to Rx traffic. */
|
||||
bool bHigherBusyTxTraffic; /* We may disable Tx interrupt according
|
||||
* to Tx traffic. */
|
||||
};
|
||||
|
||||
struct profile_info {
|
||||
|
@ -132,174 +133,216 @@ struct profile_info {
|
|||
u8 peermac[ ETH_ALEN ];
|
||||
};
|
||||
|
||||
struct tx_invite_req_info{
|
||||
u8 token;
|
||||
u8 benable;
|
||||
u8 go_ssid[ WLAN_SSID_MAXLEN ];
|
||||
u8 ssidlen;
|
||||
u8 go_bssid[ ETH_ALEN ];
|
||||
u8 peer_macaddr[ ETH_ALEN ];
|
||||
u8 operating_ch; /* This information will be set by using the p2p_set op_ch=x */
|
||||
u8 peer_ch; /* The listen channel for peer P2P device */
|
||||
|
||||
struct tx_invite_req_info {
|
||||
u8 token;
|
||||
u8 benable;
|
||||
u8 go_ssid[ WLAN_SSID_MAXLEN ];
|
||||
u8 ssidlen;
|
||||
u8 go_bssid[ ETH_ALEN ];
|
||||
u8 peer_macaddr[ ETH_ALEN ];
|
||||
u8 operating_ch; /* This information will be set by using the
|
||||
* p2p_set op_ch=x */
|
||||
u8 peer_ch; /* The listen channel for peer P2P device */
|
||||
};
|
||||
|
||||
struct tx_invite_resp_info{
|
||||
u8 token; /* Used to record the dialog token of p2p invitation request frame. */
|
||||
struct tx_invite_resp_info {
|
||||
u8 token; /* Used to record the dialog token of p2p invitation
|
||||
* request frame. */
|
||||
};
|
||||
|
||||
struct tx_provdisc_req_info{
|
||||
u16 wps_config_method_request; /* Used when sending the provisioning request frame */
|
||||
u16 peer_channel_num[2]; /* The channel number which the receiver stands. */
|
||||
struct tx_provdisc_req_info {
|
||||
u16 wps_config_method_request; /* Used when sending the
|
||||
* provisioning request frame*/
|
||||
u16 peer_channel_num[2]; /* The channel number which the
|
||||
* receiver stands. */
|
||||
struct ndis_802_11_ssid ssid;
|
||||
u8 peerDevAddr[ ETH_ALEN ]; /* Peer device address */
|
||||
u8 peerIFAddr[ ETH_ALEN ]; /* Peer interface address */
|
||||
u8 benable; /* This provision discovery request frame is trigger to send or not */
|
||||
u8 peerDevAddr[ETH_ALEN]; /* Peer device address */
|
||||
u8 peerIFAddr[ETH_ALEN]; /* Peer interface address */
|
||||
u8 benable; /* This provision discovery
|
||||
* request frame is trigger
|
||||
* to send or not */
|
||||
};
|
||||
|
||||
struct rx_provdisc_req_info{ /* When peer device issue prov_disc_req first, we should store the following informations */
|
||||
u8 peerDevAddr[ ETH_ALEN ]; /* Peer device address */
|
||||
u8 strconfig_method_desc_of_prov_disc_req[4]; /* description for the config method located in the provisioning discovery request frame. */
|
||||
/* The UI must know this information to know which config method the remote p2p device is requiring. */
|
||||
/* When peer device issue prov_disc_req first, we should store the following
|
||||
* information */
|
||||
/* The UI must know this information to know which config method the
|
||||
* remote p2p device needs. */
|
||||
struct rx_provdisc_req_info {
|
||||
u8 peerDevAddr[ETH_ALEN]; /* Peer device address */
|
||||
u8 strconfig_method_desc_of_prov_disc_req[4]; /* description
|
||||
* for the config method located in the provisioning
|
||||
* discovery request frame. */
|
||||
};
|
||||
|
||||
struct tx_nego_req_info{
|
||||
u16 peer_channel_num[2]; /* The channel number which the receiver stands. */
|
||||
u8 peerDevAddr[ ETH_ALEN ]; /* Peer device address */
|
||||
u8 benable; /* This negoitation request frame is trigger to send or not */
|
||||
struct tx_nego_req_info {
|
||||
u16 peer_channel_num[2]; /* The channel number. */
|
||||
u8 peerDevAddr[ETH_ALEN]; /* Peer device address */
|
||||
u8 benable; /* This negotiation request frame is
|
||||
* trigger to send or not */
|
||||
};
|
||||
|
||||
struct group_id_info{
|
||||
u8 go_device_addr[ ETH_ALEN ]; /* The GO's device address of this P2P group */
|
||||
u8 ssid[ WLAN_SSID_MAXLEN ]; /* The SSID of this P2P group */
|
||||
struct group_id_info {
|
||||
u8 go_device_addr[ ETH_ALEN ]; /* The GO's device address of
|
||||
* this P2P group */
|
||||
u8 ssid[ WLAN_SSID_MAXLEN ]; /* The SSID of this P2P group */
|
||||
};
|
||||
|
||||
struct scan_limit_info{
|
||||
u8 scan_op_ch_only; /* When this flag is set, the driver should just scan the operation channel */
|
||||
u8 operation_ch[2]; /* Store the operation channel of invitation request frame */
|
||||
struct scan_limit_info {
|
||||
u8 scan_op_ch_only; /* When this flag is set, the driver
|
||||
* should only scan the op. channel */
|
||||
u8 operation_ch[2]; /* Store the op. chan of invitation */
|
||||
};
|
||||
|
||||
struct wifidirect_info{
|
||||
struct adapter* padapter;
|
||||
struct wifidirect_info {
|
||||
struct adapter *padapter;
|
||||
struct timer_list find_phase_timer;
|
||||
struct timer_list restore_p2p_state_timer;
|
||||
|
||||
/* Used to do the scanning. After confirming the peer is availalble, the driver transmits the P2P frame to peer. */
|
||||
/* Used to do the scanning. After confirming the peer is availalble,
|
||||
* the driver transmits the P2P frame to peer. */
|
||||
struct timer_list pre_tx_scan_timer;
|
||||
struct timer_list reset_ch_sitesurvey;
|
||||
struct timer_list reset_ch_sitesurvey2; /* Just for resetting the scan limit function by using p2p nego */
|
||||
struct timer_list reset_ch_sitesurvey2; /* Just for resetting the scan
|
||||
* limit function by using p2p nego */
|
||||
struct tx_provdisc_req_info tx_prov_disc_info;
|
||||
struct rx_provdisc_req_info rx_prov_disc_info;
|
||||
struct tx_invite_req_info invitereq_info;
|
||||
struct profile_info profileinfo[ P2P_MAX_PERSISTENT_GROUP_NUM ]; /* Store the profile information of persistent group */
|
||||
/* Store the profile information of persistent group */
|
||||
struct profile_info profileinfo[P2P_MAX_PERSISTENT_GROUP_NUM];
|
||||
struct tx_invite_resp_info inviteresp_info;
|
||||
struct tx_nego_req_info nego_req_info;
|
||||
struct group_id_info groupid_info; /* Store the group id information when doing the group negotiation handshake. */
|
||||
struct scan_limit_info rx_invitereq_info; /* Used for get the limit scan channel from the Invitation procedure */
|
||||
struct scan_limit_info p2p_info; /* Used for get the limit scan channel from the P2P negotiation handshake */
|
||||
enum P2P_ROLE role;
|
||||
enum P2P_STATE pre_p2p_state;
|
||||
enum P2P_STATE p2p_state;
|
||||
u8 device_addr[ETH_ALEN]; /* The device address should be the mac address of this device. */
|
||||
u8 interface_addr[ETH_ALEN];
|
||||
u8 social_chan[4];
|
||||
u8 listen_channel;
|
||||
u8 operating_channel;
|
||||
u8 listen_dwell; /* This value should be between 1 and 3 */
|
||||
u8 support_rate[8];
|
||||
u8 p2p_wildcard_ssid[P2P_WILDCARD_SSID_LEN];
|
||||
u8 intent; /* should only include the intent value. */
|
||||
u8 p2p_peer_interface_addr[ ETH_ALEN ];
|
||||
u8 p2p_peer_device_addr[ ETH_ALEN ];
|
||||
u8 peer_intent; /* Included the intent value and tie breaker value. */
|
||||
u8 device_name[ WPS_MAX_DEVICE_NAME_LEN ]; /* Device name for displaying on searching device screen */
|
||||
u8 device_name_len;
|
||||
u8 profileindex; /* Used to point to the index of profileinfo array */
|
||||
u8 peer_operating_ch;
|
||||
u8 find_phase_state_exchange_cnt;
|
||||
u16 device_password_id_for_nego; /* The device password ID for group negotation */
|
||||
u8 negotiation_dialog_token;
|
||||
u8 nego_ssid[ WLAN_SSID_MAXLEN ]; /* SSID information for group negotitation */
|
||||
u8 nego_ssidlen;
|
||||
u8 p2p_group_ssid[WLAN_SSID_MAXLEN];
|
||||
u8 p2p_group_ssid_len;
|
||||
u8 persistent_supported; /* Flag to know the persistent function should be supported or not. */
|
||||
/* In the Sigma test, the Sigma will provide this enable from the sta_set_p2p CAPI. */
|
||||
/* 0: disable */
|
||||
/* 1: enable */
|
||||
u8 session_available; /* Flag to set the WFD session available to enable or disable "by Sigma" */
|
||||
/* In the Sigma test, the Sigma will disable the session available by using the sta_preset CAPI. */
|
||||
/* 0: disable */
|
||||
/* 1: enable */
|
||||
/* Store the group id info when doing the group negot handshake. */
|
||||
struct group_id_info groupid_info;
|
||||
/* Used for get the limit scan channel from the Invitation procedure */
|
||||
struct scan_limit_info rx_invitereq_info;
|
||||
/* Used for get the limit scan chan from the P2P negotiation handshake*/
|
||||
struct scan_limit_info p2p_info;
|
||||
enum P2P_ROLE role;
|
||||
enum P2P_STATE pre_p2p_state;
|
||||
enum P2P_STATE p2p_state;
|
||||
/* The device address should be the mac address of this device. */
|
||||
u8 device_addr[ETH_ALEN];
|
||||
u8 interface_addr[ETH_ALEN];
|
||||
u8 social_chan[4];
|
||||
u8 listen_channel;
|
||||
u8 operating_channel;
|
||||
u8 listen_dwell; /* This value should be between 1 and 3 */
|
||||
u8 support_rate[8];
|
||||
u8 p2p_wildcard_ssid[P2P_WILDCARD_SSID_LEN];
|
||||
u8 intent; /* should only include the intent value. */
|
||||
u8 p2p_peer_interface_addr[ETH_ALEN];
|
||||
u8 p2p_peer_device_addr[ETH_ALEN];
|
||||
u8 peer_intent; /* Included the intent value and tie breaker value. */
|
||||
/* Device name for displaying on searching device screen */
|
||||
u8 device_name[WPS_MAX_DEVICE_NAME_LEN];
|
||||
u8 device_name_len;
|
||||
u8 profileindex; /* Used to point to the index of profileinfo array */
|
||||
u8 peer_operating_ch;
|
||||
u8 find_phase_state_exchange_cnt;
|
||||
/* The device password ID for group negotation */
|
||||
u16 device_password_id_for_nego;
|
||||
u8 negotiation_dialog_token;
|
||||
/* SSID information for group negotitation */
|
||||
u8 nego_ssid[WLAN_SSID_MAXLEN];
|
||||
u8 nego_ssidlen;
|
||||
u8 p2p_group_ssid[WLAN_SSID_MAXLEN];
|
||||
u8 p2p_group_ssid_len;
|
||||
/* Flag to know if the persistent function should be supported or not.*/
|
||||
u8 persistent_supported;
|
||||
/* In the Sigma test, the Sigma will provide this enable from the
|
||||
* sta_set_p2p CAPI. */
|
||||
/* 0: disable */
|
||||
/* 1: enable */
|
||||
u8 session_available; /* Flag to set the WFD session available to
|
||||
* enable or disable "by Sigma" */
|
||||
/* In the Sigma test, the Sigma will disable the session available
|
||||
* by using the sta_preset CAPI. */
|
||||
/* 0: disable */
|
||||
/* 1: enable */
|
||||
u8 wfd_tdls_enable; /* Flag to enable or disable the TDLS by WFD Sigma*/
|
||||
/* 0: disable */
|
||||
/* 1: enable */
|
||||
u8 wfd_tdls_weaksec; /* Flag to enable or disable the weak security
|
||||
* function for TDLS by WFD Sigma */
|
||||
/* 0: disable */
|
||||
/* In this case, the driver can't issue the tdsl
|
||||
* setup request frame. */
|
||||
/* 1: enable */
|
||||
/* In this case, the driver can issue the tdls
|
||||
* setup request frame */
|
||||
/* even the current security is weak security. */
|
||||
|
||||
u8 wfd_tdls_enable; /* Flag to enable or disable the TDLS by WFD Sigma */
|
||||
/* 0: disable */
|
||||
/* 1: enable */
|
||||
u8 wfd_tdls_weaksec; /* Flag to enable or disable the weak security function for TDLS by WFD Sigma */
|
||||
/* 0: disable */
|
||||
/* In this case, the driver can't issue the tdsl setup request frame. */
|
||||
/* 1: enable */
|
||||
/* In this case, the driver can issue the tdls setup request frame */
|
||||
/* even the current security is weak security. */
|
||||
|
||||
enum P2P_WPSINFO ui_got_wps_info; /* This field will store the WPS value (PIN value or PBC) that UI had got from the user. */
|
||||
u16 supported_wps_cm; /* This field describes the WPS config method which this driver supported. */
|
||||
/* The value should be the combination of config method defined in page104 of WPS v2.0 spec. */
|
||||
uint channel_list_attr_len; /* This field will contain the length of body of P2P Channel List attribute of group negotitation response frame. */
|
||||
u8 channel_list_attr[100]; /* This field will contain the body of P2P Channel List attribute of group negotitation response frame. */
|
||||
/* We will use the channel_cnt and channel_list fields when constructing the group negotitation confirm frame. */
|
||||
enum P2P_PS_MODE p2p_ps_mode; /* indicate p2p ps mode */
|
||||
enum P2P_PS_STATE p2p_ps_state; /* indicate p2p ps state */
|
||||
u8 noa_index; /* Identifies and instance of Notice of Absence timing. */
|
||||
u8 ctwindow; /* Client traffic window. A period of time in TU after TBTT. */
|
||||
u8 opp_ps; /* opportunistic power save. */
|
||||
u8 noa_num; /* number of NoA descriptor in P2P IE. */
|
||||
u8 noa_count[P2P_MAX_NOA_NUM]; /* Count for owner, Type of client. */
|
||||
u32 noa_duration[P2P_MAX_NOA_NUM]; /* Max duration for owner, preferred or min acceptable duration for client. */
|
||||
u32 noa_interval[P2P_MAX_NOA_NUM]; /* Length of interval for owner, preferred or max acceptable interval of client. */
|
||||
u32 noa_start_time[P2P_MAX_NOA_NUM]; /* schedule expressed in terms of the lower 4 bytes of the TSF timer. */
|
||||
/* This field will store the WPS value (PIN value or PBC) that UI had
|
||||
* got from the user. */
|
||||
enum P2P_WPSINFO ui_got_wps_info;
|
||||
u16 supported_wps_cm; /* This field describes the WPS config method
|
||||
* which this driver supported. */
|
||||
/* The value should be the combination of config
|
||||
* method defined in page104 of WPS v2.0 spec.*/
|
||||
/* This field will contain the length of body of P2P Channel List
|
||||
* attribute of group negotiation response frame. */
|
||||
uint channel_list_attr_len;
|
||||
/* This field will contain the body of P2P Channel List attribute of
|
||||
* group negotitation response frame. */
|
||||
/* We will use the channel_cnt and channel_list fields when constructing
|
||||
* the group negotiation confirm frame. */
|
||||
u8 channel_list_attr[100];
|
||||
enum P2P_PS_MODE p2p_ps_mode; /* indicate p2p ps mode */
|
||||
enum P2P_PS_STATE p2p_ps_state; /* indicate p2p ps state */
|
||||
u8 noa_index; /* Identifies and instance of Notice of Absence timing. */
|
||||
u8 ctwindow; /* Client traffic window. A period of time in TU after TBTT. */
|
||||
u8 opp_ps; /* opportunistic power save. */
|
||||
u8 noa_num; /* number of NoA descriptor in P2P IE. */
|
||||
u8 noa_count[P2P_MAX_NOA_NUM]; /* Count for owner, Type of client. */
|
||||
/* Max duration for owner, preferred or min acceptable duration for
|
||||
* client. */
|
||||
u32 noa_duration[P2P_MAX_NOA_NUM];
|
||||
/* Length of interval for owner, preferred or max acceptable interval
|
||||
* of client. */
|
||||
u32 noa_interval[P2P_MAX_NOA_NUM];
|
||||
/* schedule expressed in terms of the lower 4 bytes of the TSF timer. */
|
||||
u32 noa_start_time[P2P_MAX_NOA_NUM];
|
||||
};
|
||||
|
||||
struct tdls_ss_record{ /* signal strength record */
|
||||
u8 macaddr[ETH_ALEN];
|
||||
u8 RxPWDBAll;
|
||||
u8 is_tdls_sta; /* true: direct link sta, false: else */
|
||||
struct tdls_ss_record { /* signal strength record */
|
||||
u8 macaddr[ETH_ALEN];
|
||||
u8 RxPWDBAll;
|
||||
u8 is_tdls_sta; /* true: direct link sta, false: else */
|
||||
};
|
||||
|
||||
struct tdls_info{
|
||||
u8 ap_prohibited;
|
||||
uint setup_state;
|
||||
u8 sta_cnt;
|
||||
u8 sta_maximum; /* 1:tdls sta is equal (NUM_STA-1), reach max direct link number; 0: else; */
|
||||
struct tdls_info {
|
||||
u8 ap_prohibited;
|
||||
uint setup_state;
|
||||
u8 sta_cnt;
|
||||
u8 sta_maximum; /* 1:tdls sta is equal (NUM_STA-1), reach max direct link number; 0: else; */
|
||||
struct tdls_ss_record ss_record;
|
||||
u8 macid_index; /* macid entry that is ready to write */
|
||||
u8 clear_cam; /* cam entry that is trying to clear, using it in direct link teardown */
|
||||
u8 ch_sensing;
|
||||
u8 cur_channel;
|
||||
u8 candidate_ch;
|
||||
u8 collect_pkt_num[MAX_CHANNEL_NUM];
|
||||
u8 macid_index; /* macid entry that is ready to write */
|
||||
u8 clear_cam; /* cam entry that is trying to clear, using it in direct link teardown */
|
||||
u8 ch_sensing;
|
||||
u8 cur_channel;
|
||||
u8 candidate_ch;
|
||||
u8 collect_pkt_num[MAX_CHANNEL_NUM];
|
||||
spinlock_t cmd_lock;
|
||||
spinlock_t hdl_lock;
|
||||
u8 watchdog_count;
|
||||
u8 dev_discovered; /* WFD_TDLS: for sigma test */
|
||||
u8 enable;
|
||||
u8 watchdog_count;
|
||||
u8 dev_discovered; /* WFD_TDLS: for sigma test */
|
||||
u8 enable;
|
||||
};
|
||||
|
||||
struct mlme_priv {
|
||||
|
||||
spinlock_t lock;
|
||||
int fw_state; /* shall we protect this variable? maybe not necessarily... */
|
||||
int fw_state; /* shall we protect this variable? maybe not necessarily... */
|
||||
u8 bScanInProcess;
|
||||
u8 to_join; /* flag */
|
||||
u8 to_join; /* flag */
|
||||
u8 to_roaming; /* roaming trying times */
|
||||
|
||||
u8 *nic_hdl;
|
||||
u8 *nic_hdl;
|
||||
|
||||
u8 not_indic_disco;
|
||||
u8 not_indic_disco;
|
||||
struct list_head *pscanned;
|
||||
struct __queue free_bss_pool;
|
||||
struct __queue scanned_queue;
|
||||
u8 *free_bss_buf;
|
||||
u8 *free_bss_buf;
|
||||
u32 num_of_scanned;
|
||||
|
||||
struct ndis_802_11_ssid assoc_ssid;
|
||||
|
@ -307,8 +350,6 @@ struct mlme_priv {
|
|||
|
||||
struct wlan_network cur_network;
|
||||
|
||||
/* uint wireless_mode; no used, remove it */
|
||||
|
||||
u32 scan_interval;
|
||||
|
||||
struct timer_list assoc_timer;
|
||||
|
@ -327,11 +368,8 @@ struct mlme_priv {
|
|||
/* Number of HT AP/stations 20 MHz */
|
||||
/* int num_sta_ht_20mhz; */
|
||||
|
||||
|
||||
int num_FortyMHzIntolerant;
|
||||
|
||||
struct ht_priv htpriv;
|
||||
|
||||
struct rt_link_detect LinkDetectInfo;
|
||||
struct timer_list dynamic_chk_timer; /* dynamic/periodic check timer */
|
||||
|
||||
|
@ -358,7 +396,7 @@ struct mlme_priv {
|
|||
|
||||
int olbc; /* Overlapping Legacy BSS Condition */
|
||||
|
||||
/* Number of HT associated stations that do not support greenfield */
|
||||
/* Number of HT assoc sta that do not support greenfield */
|
||||
int num_sta_ht_no_gf;
|
||||
|
||||
/* Number of associated non-HT stations */
|
||||
|
@ -404,52 +442,49 @@ struct mlme_priv {
|
|||
|
||||
#ifdef CONFIG_AP_MODE
|
||||
|
||||
struct hostapd_priv
|
||||
{
|
||||
struct hostapd_priv {
|
||||
struct adapter *padapter;
|
||||
};
|
||||
|
||||
extern int hostapd_mode_init(struct adapter *padapter);
|
||||
extern void hostapd_mode_unload(struct adapter *padapter);
|
||||
int hostapd_mode_init(struct adapter *padapter);
|
||||
void hostapd_mode_unload(struct adapter *padapter);
|
||||
#endif
|
||||
|
||||
|
||||
extern unsigned char WPA_TKIP_CIPHER[4];
|
||||
extern unsigned char RSN_TKIP_CIPHER[4];
|
||||
|
||||
extern unsigned char REALTEK_96B_IE[];
|
||||
|
||||
extern unsigned char MCS_rate_2R[16];
|
||||
extern unsigned char MCS_rate_1R[16];
|
||||
|
||||
extern void rtw_joinbss_event_prehandle(struct adapter *adapter, u8 *pbuf);
|
||||
extern void rtw_survey_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
extern void rtw_surveydone_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
extern void rtw_joinbss_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
extern void rtw_stassoc_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
extern void rtw_stadel_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
extern void rtw_atimdone_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
extern void rtw_cpwm_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
void rtw_joinbss_event_prehandle(struct adapter *adapter, u8 *pbuf);
|
||||
void rtw_survey_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
void rtw_surveydone_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
void rtw_joinbss_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
void rtw_stassoc_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
void rtw_stadel_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
void rtw_atimdone_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
void rtw_cpwm_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
void indicate_wx_scan_complete_event(struct adapter *padapter);
|
||||
void rtw_indicate_wx_assoc_event(struct adapter *padapter);
|
||||
void rtw_indicate_wx_disassoc_event(struct adapter *padapter);
|
||||
extern int event_thread(void *context);
|
||||
extern void rtw_join_timeout_handler(void* FunctionContext);
|
||||
extern void _rtw_scan_timeout_handler(void* FunctionContext);
|
||||
extern void rtw_free_network_queue(struct adapter *adapter,u8 isfreeall);
|
||||
extern int rtw_init_mlme_priv(struct adapter *adapter);/* (struct mlme_priv *pmlmepriv); */
|
||||
extern void rtw_free_mlme_priv (struct mlme_priv *pmlmepriv);
|
||||
extern int rtw_select_and_join_from_scanned_queue(struct mlme_priv *pmlmepriv);
|
||||
extern int rtw_set_key(struct adapter *adapter, struct security_priv *psecuritypriv, int keyid, u8 set_tx);
|
||||
extern int rtw_set_auth(struct adapter *adapter, struct security_priv *psecuritypriv);
|
||||
int event_thread(void *context);
|
||||
void rtw_join_timeout_handler(void *FunctionContext);
|
||||
void _rtw_scan_timeout_handler(void *FunctionContext);
|
||||
void rtw_free_network_queue(struct adapter *adapter, u8 isfreeall);
|
||||
int rtw_init_mlme_priv(struct adapter *adapter);
|
||||
void rtw_free_mlme_priv (struct mlme_priv *pmlmepriv);
|
||||
int rtw_select_and_join_from_scanned_queue(struct mlme_priv *pmlmepriv);
|
||||
int rtw_set_key(struct adapter *adapter, struct security_priv *psecuritypriv,
|
||||
int keyid, u8 set_tx);
|
||||
int rtw_set_auth(struct adapter *adapter, struct security_priv *psecuritypriv);
|
||||
|
||||
__inline static u8 *get_bssid(struct mlme_priv *pmlmepriv)
|
||||
static inline u8 *get_bssid(struct mlme_priv *pmlmepriv)
|
||||
{ /* if sta_mode:pmlmepriv->cur_network.network.MacAddress=> bssid */
|
||||
/* if adhoc_mode:pmlmepriv->cur_network.network.MacAddress=> ibss mac address */
|
||||
return pmlmepriv->cur_network.network.MacAddress;
|
||||
}
|
||||
|
||||
__inline static int check_fwstate(struct mlme_priv *pmlmepriv, int state)
|
||||
static inline int check_fwstate(struct mlme_priv *pmlmepriv, int state)
|
||||
{
|
||||
if (pmlmepriv->fw_state & state)
|
||||
return true;
|
||||
|
@ -457,7 +492,7 @@ __inline static int check_fwstate(struct mlme_priv *pmlmepriv, int state)
|
|||
return false;
|
||||
}
|
||||
|
||||
__inline static int get_fwstate(struct mlme_priv *pmlmepriv)
|
||||
static inline int get_fwstate(struct mlme_priv *pmlmepriv)
|
||||
{
|
||||
return pmlmepriv->fw_state;
|
||||
}
|
||||
|
@ -469,127 +504,131 @@ __inline static int get_fwstate(struct mlme_priv *pmlmepriv)
|
|||
* ### NOTE:#### (!!!!)
|
||||
* MUST TAKE CARE THAT BEFORE CALLING THIS FUNC, YOU SHOULD HAVE LOCKED pmlmepriv->lock
|
||||
*/
|
||||
__inline static void set_fwstate(struct mlme_priv *pmlmepriv, int state)
|
||||
static inline void set_fwstate(struct mlme_priv *pmlmepriv, int state)
|
||||
{
|
||||
pmlmepriv->fw_state |= state;
|
||||
/* FOR HW integration */
|
||||
if (_FW_UNDER_SURVEY==state){
|
||||
if (_FW_UNDER_SURVEY==state)
|
||||
pmlmepriv->bScanInProcess = true;
|
||||
}
|
||||
}
|
||||
|
||||
__inline static void _clr_fwstate_(struct mlme_priv *pmlmepriv, int state)
|
||||
static inline void _clr_fwstate_(struct mlme_priv *pmlmepriv, int state)
|
||||
{
|
||||
pmlmepriv->fw_state &= ~state;
|
||||
/* FOR HW integration */
|
||||
if (_FW_UNDER_SURVEY==state){
|
||||
if (_FW_UNDER_SURVEY==state)
|
||||
pmlmepriv->bScanInProcess = false;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* No Limit on the calling context,
|
||||
* therefore set it to be the critical section...
|
||||
*/
|
||||
__inline static void clr_fwstate(struct mlme_priv *pmlmepriv, int state)
|
||||
static inline void clr_fwstate(struct mlme_priv *pmlmepriv, int state)
|
||||
{
|
||||
unsigned long irqL;
|
||||
unsigned long irql;
|
||||
|
||||
_enter_critical_bh(&pmlmepriv->lock, &irqL);
|
||||
_enter_critical_bh(&pmlmepriv->lock, &irql);
|
||||
if (check_fwstate(pmlmepriv, state) == true)
|
||||
pmlmepriv->fw_state ^= state;
|
||||
_exit_critical_bh(&pmlmepriv->lock, &irqL);
|
||||
_exit_critical_bh(&pmlmepriv->lock, &irql);
|
||||
}
|
||||
|
||||
__inline static void clr_fwstate_ex(struct mlme_priv *pmlmepriv, int state)
|
||||
static inline void clr_fwstate_ex(struct mlme_priv *pmlmepriv, int state)
|
||||
{
|
||||
unsigned long irqL;
|
||||
unsigned long irql;
|
||||
|
||||
_enter_critical_bh(&pmlmepriv->lock, &irqL);
|
||||
_enter_critical_bh(&pmlmepriv->lock, &irql);
|
||||
_clr_fwstate_(pmlmepriv, state);
|
||||
_exit_critical_bh(&pmlmepriv->lock, &irqL);
|
||||
_exit_critical_bh(&pmlmepriv->lock, &irql);
|
||||
}
|
||||
|
||||
__inline static void up_scanned_network(struct mlme_priv *pmlmepriv)
|
||||
static inline void up_scanned_network(struct mlme_priv *pmlmepriv)
|
||||
{
|
||||
unsigned long irqL;
|
||||
unsigned long irql;
|
||||
|
||||
_enter_critical_bh(&pmlmepriv->lock, &irqL);
|
||||
_enter_critical_bh(&pmlmepriv->lock, &irql);
|
||||
pmlmepriv->num_of_scanned++;
|
||||
_exit_critical_bh(&pmlmepriv->lock, &irqL);
|
||||
_exit_critical_bh(&pmlmepriv->lock, &irql);
|
||||
}
|
||||
|
||||
__inline static void down_scanned_network(struct mlme_priv *pmlmepriv)
|
||||
static inline void down_scanned_network(struct mlme_priv *pmlmepriv)
|
||||
{
|
||||
unsigned long irqL;
|
||||
unsigned long irql;
|
||||
|
||||
_enter_critical_bh(&pmlmepriv->lock, &irqL);
|
||||
_enter_critical_bh(&pmlmepriv->lock, &irql);
|
||||
pmlmepriv->num_of_scanned--;
|
||||
_exit_critical_bh(&pmlmepriv->lock, &irqL);
|
||||
_exit_critical_bh(&pmlmepriv->lock, &irql);
|
||||
}
|
||||
|
||||
__inline static void set_scanned_network_val(struct mlme_priv *pmlmepriv, int val)
|
||||
static inline void set_scanned_network_val(struct mlme_priv *pmlmepriv, int val)
|
||||
{
|
||||
unsigned long irqL;
|
||||
unsigned long irql;
|
||||
|
||||
_enter_critical_bh(&pmlmepriv->lock, &irqL);
|
||||
_enter_critical_bh(&pmlmepriv->lock, &irql);
|
||||
pmlmepriv->num_of_scanned = val;
|
||||
_exit_critical_bh(&pmlmepriv->lock, &irqL);
|
||||
_exit_critical_bh(&pmlmepriv->lock, &irql);
|
||||
}
|
||||
|
||||
extern u16 rtw_get_capability(struct wlan_bssid_ex *bss);
|
||||
extern void rtw_update_scanned_network(struct adapter *adapter, struct wlan_bssid_ex *target);
|
||||
extern void rtw_disconnect_hdl_under_linked(struct adapter* adapter, struct sta_info *psta, u8 free_assoc);
|
||||
extern void rtw_generate_random_ibss(u8 *pibss);
|
||||
extern struct wlan_network* rtw_find_network(struct __queue *scanned_queue, u8 *addr);
|
||||
extern struct wlan_network* rtw_get_oldest_wlan_network(struct __queue *scanned_queue);
|
||||
u16 rtw_get_capability(struct wlan_bssid_ex *bss);
|
||||
void rtw_update_scanned_network(struct adapter *adapter,
|
||||
struct wlan_bssid_ex *target);
|
||||
void rtw_disconnect_hdl_under_linked(struct adapter *adapter,
|
||||
struct sta_info *psta, u8 free_assoc);
|
||||
void rtw_generate_random_ibss(u8 *pibss);
|
||||
struct wlan_network *rtw_find_network(struct __queue *scanned_queue, u8 *addr);
|
||||
struct wlan_network *rtw_get_oldest_wlan_network(struct __queue *scanned_queue);
|
||||
|
||||
extern void rtw_free_assoc_resources(struct adapter* adapter, int lock_scanned_queue);
|
||||
extern void rtw_indicate_disconnect(struct adapter* adapter);
|
||||
extern void rtw_indicate_connect(struct adapter* adapter);
|
||||
void rtw_free_assoc_resources(struct adapter *adapter, int lock_scanned_queue);
|
||||
void rtw_indicate_disconnect(struct adapter *adapter);
|
||||
void rtw_indicate_connect(struct adapter *adapter);
|
||||
void rtw_indicate_scan_done( struct adapter *padapter, bool aborted);
|
||||
void rtw_scan_abort(struct adapter *adapter);
|
||||
|
||||
extern int rtw_restruct_sec_ie(struct adapter *adapter,u8 *in_ie,u8 *out_ie,uint in_len);
|
||||
extern int rtw_restruct_wmm_ie(struct adapter *adapter, u8 *in_ie, u8 *out_ie, uint in_len, uint initial_out_len);
|
||||
extern void rtw_init_registrypriv_dev_network(struct adapter *adapter);
|
||||
int rtw_restruct_sec_ie(struct adapter *adapter, u8 *in_ie, u8 *out_ie,
|
||||
uint in_len);
|
||||
int rtw_restruct_wmm_ie(struct adapter *adapter, u8 *in_ie, u8 *out_ie,
|
||||
uint in_len, uint initial_out_len);
|
||||
void rtw_init_registrypriv_dev_network(struct adapter *adapter);
|
||||
|
||||
extern void rtw_update_registrypriv_dev_network(struct adapter *adapter);
|
||||
void rtw_update_registrypriv_dev_network(struct adapter *adapter);
|
||||
|
||||
extern void rtw_get_encrypt_decrypt_from_registrypriv(struct adapter *adapter);
|
||||
void rtw_get_encrypt_decrypt_from_registrypriv(struct adapter *adapter);
|
||||
|
||||
extern void _rtw_join_timeout_handler(struct adapter *adapter);
|
||||
extern void rtw_scan_timeout_handler(struct adapter *adapter);
|
||||
void _rtw_join_timeout_handler(struct adapter *adapter);
|
||||
void rtw_scan_timeout_handler(struct adapter *adapter);
|
||||
|
||||
extern void rtw_dynamic_check_timer_handlder(struct adapter *adapter);
|
||||
void rtw_dynamic_check_timer_handlder(struct adapter *adapter);
|
||||
#define rtw_is_scan_deny(adapter) false
|
||||
#define rtw_clear_scan_deny(adapter) do {} while (0)
|
||||
#define rtw_set_scan_deny_timer_hdl(adapter) do {} while (0)
|
||||
#define rtw_set_scan_deny(adapter, ms) do {} while (0)
|
||||
|
||||
|
||||
extern int _rtw_init_mlme_priv(struct adapter *padapter);
|
||||
int _rtw_init_mlme_priv(struct adapter *padapter);
|
||||
|
||||
void rtw_free_mlme_priv_ie_data(struct mlme_priv *pmlmepriv);
|
||||
|
||||
extern void _rtw_free_mlme_priv(struct mlme_priv *pmlmepriv);
|
||||
void _rtw_free_mlme_priv(struct mlme_priv *pmlmepriv);
|
||||
|
||||
extern int _rtw_enqueue_network(struct __queue *queue, struct wlan_network *pnetwork);
|
||||
int _rtw_enqueue_network(struct __queue *queue, struct wlan_network *pnetwork);
|
||||
|
||||
extern struct wlan_network* _rtw_dequeue_network(struct __queue *queue);
|
||||
struct wlan_network *_rtw_dequeue_network(struct __queue *queue);
|
||||
|
||||
extern struct wlan_network* _rtw_alloc_network(struct mlme_priv *pmlmepriv);
|
||||
struct wlan_network *_rtw_alloc_network(struct mlme_priv *pmlmepriv);
|
||||
|
||||
|
||||
extern void _rtw_free_network(struct mlme_priv *pmlmepriv, struct wlan_network *pnetwork, u8 isfreeall);
|
||||
extern void _rtw_free_network_nolock(struct mlme_priv *pmlmepriv, struct wlan_network *pnetwork);
|
||||
void _rtw_free_network(struct mlme_priv *pmlmepriv,
|
||||
struct wlan_network *pnetwork, u8 isfreeall);
|
||||
void _rtw_free_network_nolock(struct mlme_priv *pmlmepriv,
|
||||
struct wlan_network *pnetwork);
|
||||
|
||||
|
||||
extern struct wlan_network* _rtw_find_network(struct __queue *scanned_queue, u8 *addr);
|
||||
struct wlan_network* _rtw_find_network(struct __queue *scanned_queue, u8 *addr);
|
||||
|
||||
extern void _rtw_free_network_queue(struct adapter* padapter, u8 isfreeall);
|
||||
void _rtw_free_network_queue(struct adapter *padapter, u8 isfreeall);
|
||||
|
||||
extern int rtw_if_up(struct adapter *padapter);
|
||||
int rtw_if_up(struct adapter *padapter);
|
||||
|
||||
|
||||
u8 *rtw_get_capability_from_ie(u8 *ie);
|
||||
|
@ -599,9 +638,11 @@ u8 *rtw_get_beacon_interval_from_ie(u8 *ie);
|
|||
|
||||
void rtw_joinbss_reset(struct adapter *padapter);
|
||||
|
||||
unsigned int rtw_restructure_ht_ie(struct adapter *padapter, u8 *in_ie, u8 *out_ie, uint in_len, uint *pout_len);
|
||||
unsigned int rtw_restructure_ht_ie(struct adapter *padapter, u8 *in_ie,
|
||||
u8 *out_ie, uint in_len, uint *pout_len);
|
||||
void rtw_update_ht_cap(struct adapter *padapter, u8 *pie, uint ie_len);
|
||||
void rtw_issue_addbareq_cmd(struct adapter *padapter, struct xmit_frame *pxmitframe);
|
||||
void rtw_issue_addbareq_cmd(struct adapter *padapter,
|
||||
struct xmit_frame *pxmitframe);
|
||||
|
||||
int rtw_is_same_ibss(struct adapter *adapter, struct wlan_network *pnetwork);
|
||||
int is_same_network(struct wlan_bssid_ex *src, struct wlan_bssid_ex *dst);
|
||||
|
@ -610,4 +651,5 @@ void rtw_roaming(struct adapter *padapter, struct wlan_network *tgt_network);
|
|||
void _rtw_roaming(struct adapter *padapter, struct wlan_network *tgt_network);
|
||||
|
||||
void rtw_stassoc_hw_rpt(struct adapter *adapter,struct sta_info *psta);
|
||||
|
||||
#endif /* __RTL871X_MLME_H_ */
|
||||
|
|
|
@ -25,11 +25,11 @@
|
|||
#include <wlan_bssdef.h>
|
||||
|
||||
|
||||
/* Commented by Albert 20101105 */
|
||||
/* Increase the SURVEY_TO value from 100 to 150 ( 100ms to 150ms ) */
|
||||
/* The Realtek 8188CE SoftAP will spend around 100ms to send the probe response after receiving the probe request. */
|
||||
/* So, this driver tried to extend the dwell time for each scanning channel. */
|
||||
/* This will increase the chance to receive the probe response from SoftAP. */
|
||||
/* Commented by Albert 20101105 */
|
||||
/* Increase the SURVEY_TO value from 100 to 150 ( 100ms to 150ms ) */
|
||||
/* The Realtek 8188CE SoftAP will spend around 100ms to send the probe response after receiving the probe request. */
|
||||
/* So, this driver tried to extend the dwell time for each scanning channel. */
|
||||
/* This will increase the chance to receive the probe response from SoftAP. */
|
||||
|
||||
#define SURVEY_TO (100)
|
||||
#define REAUTH_TO (300) /* 50) */
|
||||
|
@ -103,15 +103,13 @@ extern unsigned char P2P_OUI[];
|
|||
extern unsigned char WMM_INFO_OUI[];
|
||||
extern unsigned char WMM_PARA_OUI[];
|
||||
|
||||
|
||||
/* */
|
||||
/* Channel Plan Type. */
|
||||
/* Note: */
|
||||
/* We just add new channel plan when the new channel plan is different from any of the following */
|
||||
/* channel plan. */
|
||||
/* If you just wnat to customize the acitions(scan period or join actions) about one of the channel plan, */
|
||||
/* customize them in struct rt_channel_info in the RT_CHANNEL_LIST. */
|
||||
/* */
|
||||
/* We just add new channel plan when the new channel plan is different
|
||||
* from any of the following channel plan. */
|
||||
/* If you just wnat to customize the acitions(scan period or join actions)
|
||||
* about one of the channel plan, */
|
||||
/* customize them in struct rt_channel_info in the RT_CHANNEL_LIST. */
|
||||
enum RT_CHANNEL_DOMAIN {
|
||||
/* old channel plan mapping ===== */
|
||||
RT_CHANNEL_DOMAIN_FCC = 0x00,
|
||||
|
@ -165,7 +163,7 @@ enum RT_CHANNEL_DOMAIN {
|
|||
};
|
||||
|
||||
enum RT_CHANNEL_DOMAIN_2G {
|
||||
RT_CHANNEL_DOMAIN_2G_WORLD = 0x00, /* Worldwird 13 */
|
||||
RT_CHANNEL_DOMAIN_2G_WORLD = 0x00, /* Worldwide 13 */
|
||||
RT_CHANNEL_DOMAIN_2G_ETSI1 = 0x01, /* Europe */
|
||||
RT_CHANNEL_DOMAIN_2G_FCC1 = 0x02, /* US */
|
||||
RT_CHANNEL_DOMAIN_2G_MKK1 = 0x03, /* Japan */
|
||||
|
@ -178,15 +176,15 @@ enum RT_CHANNEL_DOMAIN_2G {
|
|||
enum RT_CHANNEL_DOMAIN_5G {
|
||||
RT_CHANNEL_DOMAIN_5G_NULL = 0x00,
|
||||
RT_CHANNEL_DOMAIN_5G_ETSI1 = 0x01, /* Europe */
|
||||
RT_CHANNEL_DOMAIN_5G_ETSI2 = 0x02, /* Australia, New Zealand */
|
||||
RT_CHANNEL_DOMAIN_5G_ETSI2 = 0x02, /* Australia, NZ */
|
||||
RT_CHANNEL_DOMAIN_5G_ETSI3 = 0x03, /* Russia */
|
||||
RT_CHANNEL_DOMAIN_5G_FCC1 = 0x04, /* US */
|
||||
RT_CHANNEL_DOMAIN_5G_FCC2 = 0x05, /* FCC o/w DFS Channels */
|
||||
RT_CHANNEL_DOMAIN_5G_FCC2 = 0x05, /* FCC o/w DFS Chan */
|
||||
RT_CHANNEL_DOMAIN_5G_FCC3 = 0x06, /* India, Mexico */
|
||||
RT_CHANNEL_DOMAIN_5G_FCC4 = 0x07, /* Venezuela */
|
||||
RT_CHANNEL_DOMAIN_5G_FCC5 = 0x08, /* China */
|
||||
RT_CHANNEL_DOMAIN_5G_FCC6 = 0x09, /* Israel */
|
||||
RT_CHANNEL_DOMAIN_5G_FCC7_IC1 = 0x0A, /* US, Canada */
|
||||
RT_CHANNEL_DOMAIN_5G_FCC7_IC1 = 0x0A, /* US, Canada */
|
||||
RT_CHANNEL_DOMAIN_5G_KCC1 = 0x0B, /* Korea */
|
||||
RT_CHANNEL_DOMAIN_5G_MKK1 = 0x0C, /* Japan */
|
||||
RT_CHANNEL_DOMAIN_5G_MKK2 = 0x0D, /* Japan (W52, W53) */
|
||||
|
@ -201,7 +199,9 @@ enum RT_CHANNEL_DOMAIN_5G {
|
|||
RT_CHANNEL_DOMAIN_5G_MAX,
|
||||
};
|
||||
|
||||
#define rtw_is_channel_plan_valid(chplan) (chplan<RT_CHANNEL_DOMAIN_MAX || chplan == RT_CHANNEL_DOMAIN_REALTEK_DEFINE)
|
||||
#define rtw_is_channel_plan_valid(chplan) \
|
||||
(chplan < RT_CHANNEL_DOMAIN_MAX || \
|
||||
chplan == RT_CHANNEL_DOMAIN_REALTEK_DEFINE)
|
||||
|
||||
struct rt_channel_plan {
|
||||
unsigned char Channel[MAX_CHANNEL_NUM];
|
||||
|
@ -230,24 +230,24 @@ enum Associated_AP {
|
|||
};
|
||||
|
||||
enum HT_IOT_PEER {
|
||||
HT_IOT_PEER_UNKNOWN = 0,
|
||||
HT_IOT_PEER_REALTEK = 1,
|
||||
HT_IOT_PEER_REALTEK_92SE = 2,
|
||||
HT_IOT_PEER_UNKNOWN = 0,
|
||||
HT_IOT_PEER_REALTEK = 1,
|
||||
HT_IOT_PEER_REALTEK_92SE = 2,
|
||||
HT_IOT_PEER_BROADCOM = 3,
|
||||
HT_IOT_PEER_RALINK = 4,
|
||||
HT_IOT_PEER_ATHEROS = 5,
|
||||
HT_IOT_PEER_CISCO = 6,
|
||||
HT_IOT_PEER_MERU = 7,
|
||||
HT_IOT_PEER_MARVELL = 8,
|
||||
HT_IOT_PEER_REALTEK_SOFTAP = 9,/* peer is RealTek SOFT_AP, by Bohn, 2009.12.17 */
|
||||
HT_IOT_PEER_SELF_SOFTAP = 10, /* Self is SoftAP */
|
||||
HT_IOT_PEER_AIRGO = 11,
|
||||
HT_IOT_PEER_INTEL = 12,
|
||||
HT_IOT_PEER_RTK_APCLIENT = 13,
|
||||
HT_IOT_PEER_REALTEK_81XX = 14,
|
||||
HT_IOT_PEER_REALTEK_WOW = 15,
|
||||
HT_IOT_PEER_TENDA = 16,
|
||||
HT_IOT_PEER_MAX = 17
|
||||
HT_IOT_PEER_RALINK = 4,
|
||||
HT_IOT_PEER_ATHEROS = 5,
|
||||
HT_IOT_PEER_CISCO = 6,
|
||||
HT_IOT_PEER_MERU = 7,
|
||||
HT_IOT_PEER_MARVELL = 8,
|
||||
HT_IOT_PEER_REALTEK_SOFTAP = 9,/* peer is RealTek SOFT_AP */
|
||||
HT_IOT_PEER_SELF_SOFTAP = 10, /* Self is SoftAP */
|
||||
HT_IOT_PEER_AIRGO = 11,
|
||||
HT_IOT_PEER_INTEL = 12,
|
||||
HT_IOT_PEER_RTK_APCLIENT = 13,
|
||||
HT_IOT_PEER_REALTEK_81XX = 14,
|
||||
HT_IOT_PEER_REALTEK_WOW = 15,
|
||||
HT_IOT_PEER_TENDA = 16,
|
||||
HT_IOT_PEER_MAX = 17
|
||||
};
|
||||
|
||||
enum SCAN_STATE {
|
||||
|
@ -261,18 +261,17 @@ enum SCAN_STATE {
|
|||
|
||||
struct mlme_handler {
|
||||
unsigned int num;
|
||||
char* str;
|
||||
unsigned int (*func)(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
char *str;
|
||||
unsigned int (*func)(struct adapter *adapt, union recv_frame *frame);
|
||||
};
|
||||
|
||||
struct action_handler {
|
||||
unsigned int num;
|
||||
char* str;
|
||||
unsigned int (*func)(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int (*func)(struct adapter *adapt, union recv_frame *frame);
|
||||
};
|
||||
|
||||
struct ss_res
|
||||
{
|
||||
struct ss_res {
|
||||
int state;
|
||||
int bss_cnt;
|
||||
int channel_idx;
|
||||
|
@ -288,19 +287,22 @@ struct ss_res
|
|||
/* define AD_HOC_MODE 0x04 */
|
||||
/* define NO_LINK_MODE 0x00 */
|
||||
|
||||
#define WIFI_FW_NULL_STATE _HW_STATE_NOLINK_
|
||||
#define WIFI_FW_NULL_STATE _HW_STATE_NOLINK_
|
||||
#define WIFI_FW_STATION_STATE _HW_STATE_STATION_
|
||||
#define WIFI_FW_AP_STATE _HW_STATE_AP_
|
||||
#define WIFI_FW_ADHOC_STATE _HW_STATE_ADHOC_
|
||||
#define WIFI_FW_AP_STATE _HW_STATE_AP_
|
||||
#define WIFI_FW_ADHOC_STATE _HW_STATE_ADHOC_
|
||||
|
||||
#define WIFI_FW_AUTH_NULL 0x00000100
|
||||
#define WIFI_FW_AUTH_STATE 0x00000200
|
||||
#define WIFI_FW_AUTH_SUCCESS 0x00000400
|
||||
#define WIFI_FW_AUTH_NULL 0x00000100
|
||||
#define WIFI_FW_AUTH_STATE 0x00000200
|
||||
#define WIFI_FW_AUTH_SUCCESS 0x00000400
|
||||
|
||||
#define WIFI_FW_ASSOC_STATE 0x00002000
|
||||
#define WIFI_FW_ASSOC_STATE 0x00002000
|
||||
#define WIFI_FW_ASSOC_SUCCESS 0x00004000
|
||||
|
||||
#define WIFI_FW_LINKING_STATE (WIFI_FW_AUTH_NULL | WIFI_FW_AUTH_STATE | WIFI_FW_AUTH_SUCCESS |WIFI_FW_ASSOC_STATE)
|
||||
#define WIFI_FW_LINKING_STATE (WIFI_FW_AUTH_NULL | \
|
||||
WIFI_FW_AUTH_STATE | \
|
||||
WIFI_FW_AUTH_SUCCESS | \
|
||||
WIFI_FW_ASSOC_STATE)
|
||||
|
||||
struct FW_Sta_Info {
|
||||
struct sta_info *psta;
|
||||
|
@ -315,11 +317,12 @@ struct FW_Sta_Info {
|
|||
* When one iface acted as AP mode and the other iface is STA mode and scanning,
|
||||
* it should switch back to AP's operating channel periodically.
|
||||
* Parameters info:
|
||||
* When the driver scanned RTW_SCAN_NUM_OF_CH channels, it would switch back to AP's operating channel for
|
||||
* When the driver scanned RTW_SCAN_NUM_OF_CH channels, it would switch back to
|
||||
* AP's operating channel for
|
||||
* RTW_STAY_AP_CH_MILLISECOND * SURVEY_TO milliseconds.
|
||||
* Example:
|
||||
* For chip supports 2.4G + 5GHz and AP mode is operating in channel 1,
|
||||
* RTW_SCAN_NUM_OF_CH is 8, RTW_STAY_AP_CH_MILLISECOND is 3 and SURVEY_TO is 100.
|
||||
* RTW_SCAN_NUM_OF_CH is 8, RTW_STAY_AP_CH_MS is 3 and SURVEY_TO is 100.
|
||||
* When it's STA mode gets set_scan command,
|
||||
* it would
|
||||
* 1. Doing the scan on channel 1.2.3.4.5.6.7.8
|
||||
|
@ -338,7 +341,8 @@ struct mlme_ext_info {
|
|||
u32 auth_algo; /* 802.11 auth, could be open, shared, auto */
|
||||
u32 authModeToggle;
|
||||
u32 enc_algo;/* encrypt algorithm; */
|
||||
u32 key_index; /* this is only valid for legendary wep, 0~3 for key id. */
|
||||
u32 key_index; /* this is only valid for legacy wep,
|
||||
* 0~3 for key id. */
|
||||
u32 iv;
|
||||
u8 chg_txt[128];
|
||||
u16 aid;
|
||||
|
@ -366,19 +370,23 @@ struct mlme_ext_info {
|
|||
u8 bwmode_updated;
|
||||
u8 hidden_ssid_mode;
|
||||
|
||||
struct ADDBA_request ADDBA_req;
|
||||
struct ADDBA_request ADDBA_req;
|
||||
struct WMM_para_element WMM_param;
|
||||
struct HT_caps_element HT_caps;
|
||||
struct HT_info_element HT_info;
|
||||
struct wlan_bssid_ex network;/* join network or bss_network, if in ap mode, it is the same to cur_network.network */
|
||||
struct FW_Sta_Info FW_sta_info[NUM_STA];
|
||||
struct HT_info_element HT_info;
|
||||
struct wlan_bssid_ex network;/* join network or bss_network,
|
||||
* if in ap mode, it is the same
|
||||
* as cur_network.network */
|
||||
struct FW_Sta_Info FW_sta_info[NUM_STA];
|
||||
};
|
||||
|
||||
/* The channel information about this channel including joining, scanning, and power constraints. */
|
||||
/* The channel information about this channel including joining,
|
||||
* scanning, and power constraints. */
|
||||
struct rt_channel_info {
|
||||
u8 ChannelNum; /* The channel number. */
|
||||
enum rt_scan_type ScanType; /* Scan type such as passive or active scan. */
|
||||
u32 rx_count;
|
||||
u8 ChannelNum; /* The channel number. */
|
||||
enum rt_scan_type ScanType; /* Scan type such as passive
|
||||
* or active scan. */
|
||||
u32 rx_count;
|
||||
};
|
||||
|
||||
int rtw_ch_set_search_ch(struct rt_channel_info *ch_set, const u32 ch);
|
||||
|
@ -386,7 +394,7 @@ int rtw_ch_set_search_ch(struct rt_channel_info *ch_set, const u32 ch);
|
|||
/* P2P_MAX_REG_CLASSES - Maximum number of regulatory classes */
|
||||
#define P2P_MAX_REG_CLASSES 10
|
||||
|
||||
/* P2P_MAX_REG_CLASS_CHANNELS - Maximum number of channels per regulatory class */
|
||||
/* P2P_MAX_REG_CLASS_CHANNELS - Maximum number of chan per regulatory class */
|
||||
#define P2P_MAX_REG_CLASS_CHANNELS 20
|
||||
|
||||
/* struct p2p_channels - List of supported channels */
|
||||
|
@ -413,24 +421,22 @@ struct p2p_oper_class_map {
|
|||
u8 min_chan;
|
||||
u8 max_chan;
|
||||
u8 inc;
|
||||
enum { BW20, BW40PLUS, BW40MINUS } bw;
|
||||
enum {BW20, BW40PLUS, BW40MINUS} bw;
|
||||
};
|
||||
|
||||
struct mlme_ext_priv
|
||||
{
|
||||
struct mlme_ext_priv {
|
||||
struct adapter *padapter;
|
||||
u8 mlmeext_init;
|
||||
ATOMIC_T event_seq;
|
||||
ATOMIC_T event_seq;
|
||||
u16 mgnt_seq;
|
||||
|
||||
/* struct fw_priv fwpriv; */
|
||||
|
||||
unsigned char cur_channel;
|
||||
unsigned char cur_bwmode;
|
||||
unsigned char cur_ch_offset;/* PRIME_CHNL_OFFSET */
|
||||
unsigned char cur_wireless_mode; /* NETWORK_TYPE */
|
||||
|
||||
unsigned char oper_channel; /* saved channel info when call set_channel_bw */
|
||||
unsigned char oper_channel; /* saved chan info when call
|
||||
* set_channel_bw */
|
||||
unsigned char oper_bwmode;
|
||||
unsigned char oper_ch_offset;/* PRIME_CHNL_OFFSET */
|
||||
|
||||
|
@ -441,11 +447,13 @@ struct mlme_ext_priv
|
|||
unsigned char datarate[NumRates];
|
||||
|
||||
struct ss_res sitesurvey_res;
|
||||
struct mlme_ext_info mlmext_info;/* for sta/adhoc mode, including current scanning/connecting/connected related info. */
|
||||
/* for ap mode, network includes ap's cap_info */
|
||||
struct mlme_ext_info mlmext_info;/* for sta/adhoc mode, including
|
||||
* current scan/connecting/connected
|
||||
* related info. For ap mode,
|
||||
* network includes ap's cap_info*/
|
||||
struct timer_list survey_timer;
|
||||
struct timer_list link_timer;
|
||||
u16 chan_scan_time;
|
||||
u16 chan_scan_time;
|
||||
|
||||
u8 scan_abort;
|
||||
u8 tx_rate; /* TXRATE when USERATE is set. */
|
||||
|
@ -457,7 +465,6 @@ struct mlme_ext_priv
|
|||
#ifdef CONFIG_AP_MODE
|
||||
unsigned char bstart_bss;
|
||||
#endif
|
||||
|
||||
u8 update_channel_plan_by_ap_done;
|
||||
/* recv_decache check for Action_public frame */
|
||||
u8 action_public_dialog_token;
|
||||
|
@ -465,17 +472,17 @@ struct mlme_ext_priv
|
|||
u8 active_keep_alive_check;
|
||||
};
|
||||
|
||||
int init_mlme_ext_priv(struct adapter* padapter);
|
||||
int init_mlme_ext_priv(struct adapter *adapter);
|
||||
int init_hw_mlme_ext(struct adapter *padapter);
|
||||
void free_mlme_ext_priv (struct mlme_ext_priv *pmlmeext);
|
||||
extern void init_mlme_ext_timer(struct adapter *padapter);
|
||||
extern void init_addba_retry_timer(struct adapter *padapter, struct sta_info *psta);
|
||||
extern void init_addba_retry_timer(struct adapter *adapt, struct sta_info *sta);
|
||||
extern struct xmit_frame *alloc_mgtxmitframe(struct xmit_priv *pxmitpriv);
|
||||
|
||||
unsigned char networktype_to_raid(unsigned char network_type);
|
||||
u8 judge_network_type(struct adapter *padapter, unsigned char *rate, int ratelen);
|
||||
void get_rate_set(struct adapter *padapter, unsigned char *pbssrate, int *bssrate_len);
|
||||
void UpdateBrateTbl(struct adapter *padapter,u8 *mBratesOS);
|
||||
u8 judge_network_type(struct adapter *padapter, unsigned char *rate, int len);
|
||||
void get_rate_set(struct adapter *padapter, unsigned char *pbssrate, int *len);
|
||||
void UpdateBrateTbl(struct adapter *padapter, u8 *mBratesOS);
|
||||
void UpdateBrateTblForSoftAP(u8 *bssrateset, u32 bssratelen);
|
||||
|
||||
void Save_DM_Func_Flag(struct adapter *padapter);
|
||||
|
@ -491,9 +498,11 @@ void rtw_set_oper_bw(struct adapter *adapter, u8 bw);
|
|||
u8 rtw_get_oper_choffset(struct adapter *adapter);
|
||||
void rtw_set_oper_choffset(struct adapter *adapter, u8 offset);
|
||||
|
||||
void set_channel_bwmode(struct adapter *padapter, unsigned char channel, unsigned char channel_offset, unsigned short bwmode);
|
||||
void set_channel_bwmode(struct adapter *padapter, unsigned char channel,
|
||||
unsigned char channel_offset, unsigned short bwmode);
|
||||
void SelectChannel(struct adapter *padapter, unsigned char channel);
|
||||
void SetBWMode(struct adapter *padapter, unsigned short bwmode, unsigned char channel_offset);
|
||||
void SetBWMode(struct adapter *padapter, unsigned short bwmode,
|
||||
unsigned char channel_offset);
|
||||
|
||||
unsigned int decide_wait_for_beacon_timeout(unsigned int bcn_interval);
|
||||
|
||||
|
@ -503,18 +512,19 @@ void clear_cam_entry(struct adapter *padapter, u8 entry);
|
|||
void invalidate_cam_all(struct adapter *padapter);
|
||||
void CAM_empty_entry(struct adapter * Adapter, u8 ucIndex);
|
||||
|
||||
|
||||
int allocate_fw_sta_entry(struct adapter *padapter);
|
||||
void flush_all_cam_entry(struct adapter *padapter);
|
||||
|
||||
bool IsLegal5GChannel(struct adapter * Adapter, u8 channel);
|
||||
|
||||
void site_survey(struct adapter *padapter);
|
||||
u8 collect_bss_info(struct adapter *padapter, union recv_frame *precv_frame, struct wlan_bssid_ex *bssid);
|
||||
void update_network(struct wlan_bssid_ex *dst, struct wlan_bssid_ex *src, struct adapter * padapter, bool update_ie);
|
||||
u8 collect_bss_info(struct adapter *padapter, union recv_frame *precv_frame,
|
||||
struct wlan_bssid_ex *bssid);
|
||||
void update_network(struct wlan_bssid_ex *dst, struct wlan_bssid_ex *src,
|
||||
struct adapter *adapter, bool update_ie);
|
||||
|
||||
int get_bsstype(unsigned short capability);
|
||||
u8* get_my_bssid(struct wlan_bssid_ex *pnetwork);
|
||||
u8 *get_my_bssid(struct wlan_bssid_ex *pnetwork);
|
||||
u16 get_beacon_interval(struct wlan_bssid_ex *bss);
|
||||
|
||||
int is_client_associated_to_ap(struct adapter *padapter);
|
||||
|
@ -523,24 +533,26 @@ int is_IBSS_empty(struct adapter *padapter);
|
|||
|
||||
unsigned char check_assoc_AP(u8 *pframe, uint len);
|
||||
|
||||
int WMM_param_handler(struct adapter *padapter, struct ndis_802_11_var_ie * pIE);
|
||||
int WMM_param_handler(struct adapter *padapter, struct ndis_802_11_var_ie *pIE);
|
||||
void WMMOnAssocRsp(struct adapter *padapter);
|
||||
|
||||
void HT_caps_handler(struct adapter *padapter, struct ndis_802_11_var_ie * pIE);
|
||||
void HT_info_handler(struct adapter *padapter, struct ndis_802_11_var_ie * pIE);
|
||||
void HT_caps_handler(struct adapter *padapter, struct ndis_802_11_var_ie *pIE);
|
||||
void HT_info_handler(struct adapter *padapter, struct ndis_802_11_var_ie *pIE);
|
||||
void HTOnAssocRsp(struct adapter *padapter);
|
||||
|
||||
void ERP_IE_handler(struct adapter *padapter, struct ndis_802_11_var_ie * pIE);
|
||||
void ERP_IE_handler(struct adapter *padapter, struct ndis_802_11_var_ie *pIE);
|
||||
void VCS_update(struct adapter *padapter, struct sta_info *psta);
|
||||
|
||||
void update_beacon_info(struct adapter *padapter, u8 *pframe, uint len, struct sta_info *psta);
|
||||
void update_beacon_info(struct adapter *padapter, u8 *pframe, uint len,
|
||||
struct sta_info *psta);
|
||||
int rtw_check_bcn_info(struct adapter *Adapter, u8 *pframe, u32 packet_len);
|
||||
void update_IOT_info(struct adapter *padapter);
|
||||
void update_capinfo(struct adapter * Adapter, u16 updateCap);
|
||||
void update_wireless_mode(struct adapter * padapter);
|
||||
void update_capinfo(struct adapter *adapter, u16 updatecap);
|
||||
void update_wireless_mode(struct adapter *padapter);
|
||||
void update_tx_basic_rate(struct adapter *padapter, u8 modulation);
|
||||
void update_bmc_sta_support_rate(struct adapter *padapter, u32 mac_id);
|
||||
int update_sta_support_rate(struct adapter *padapter, u8* pvar_ie, uint var_ie_len, int cam_idx);
|
||||
int update_sta_support_rate(struct adapter *padapter, u8 *pvar_ie,
|
||||
uint var_ie_len, int cam_idx);
|
||||
|
||||
/* for sta/adhoc mode */
|
||||
void update_sta_info(struct adapter *padapter, struct sta_info *psta);
|
||||
|
@ -550,85 +562,126 @@ unsigned int update_MSC_rate(struct HT_caps_element *pHT_caps);
|
|||
void Update_RA_Entry(struct adapter *padapter, u32 mac_id);
|
||||
void set_sta_rate(struct adapter *padapter, struct sta_info *psta);
|
||||
|
||||
unsigned int receive_disconnect(struct adapter *padapter, unsigned char *MacAddr, unsigned short reason);
|
||||
unsigned int receive_disconnect(struct adapter *padapter,
|
||||
unsigned char *macaddr, unsigned short reason);
|
||||
|
||||
unsigned char get_highest_rate_idx(u32 mask);
|
||||
int support_short_GI(struct adapter *padapter, struct HT_caps_element *pHT_caps);
|
||||
int support_short_GI(struct adapter *padapter, struct HT_caps_element *caps);
|
||||
unsigned int is_ap_in_tkip(struct adapter *padapter);
|
||||
unsigned int is_ap_in_wep(struct adapter *padapter);
|
||||
unsigned int should_forbid_n_rate(struct adapter * padapter);
|
||||
unsigned int should_forbid_n_rate(struct adapter *padapter);
|
||||
|
||||
void report_join_res(struct adapter *padapter, int res);
|
||||
void report_survey_event(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
void report_surveydone_event(struct adapter *padapter);
|
||||
void report_del_sta_event(struct adapter *padapter, unsigned char* MacAddr, unsigned short reason);
|
||||
void report_add_sta_event(struct adapter *padapter, unsigned char* MacAddr, int cam_idx);
|
||||
void report_del_sta_event(struct adapter *padapter,
|
||||
unsigned char *addr, unsigned short reason);
|
||||
void report_add_sta_event(struct adapter *padapter, unsigned char* addr,
|
||||
int cam_idx);
|
||||
|
||||
void beacon_timing_control(struct adapter *padapter);
|
||||
extern u8 set_tx_beacon_cmd(struct adapter*padapter);
|
||||
unsigned int setup_beacon_frame(struct adapter *padapter, unsigned char *beacon_frame);
|
||||
unsigned int setup_beacon_frame(struct adapter *padapter,
|
||||
unsigned char *beacon_frame);
|
||||
void update_mgnt_tx_rate(struct adapter *padapter, u8 rate);
|
||||
void update_mgntframe_attrib(struct adapter *padapter, struct pkt_attrib *pattrib);
|
||||
void update_mgntframe_attrib(struct adapter *padapter,
|
||||
struct pkt_attrib *pattrib);
|
||||
void dump_mgntframe(struct adapter *padapter, struct xmit_frame *pmgntframe);
|
||||
s32 dump_mgntframe_and_wait(struct adapter *padapter, struct xmit_frame *pmgntframe, int timeout_ms);
|
||||
s32 dump_mgntframe_and_wait_ack(struct adapter *padapter, struct xmit_frame *pmgntframe);
|
||||
s32 dump_mgntframe_and_wait(struct adapter *padapter,
|
||||
struct xmit_frame *pmgntframe, int timeout_ms);
|
||||
s32 dump_mgntframe_and_wait_ack(struct adapter *padapter,
|
||||
struct xmit_frame *pmgntframe);
|
||||
|
||||
#ifdef CONFIG_P2P
|
||||
void issue_probersp_p2p(struct adapter *padapter, unsigned char *da);
|
||||
void issue_p2p_provision_request( struct adapter *padapter, u8* pssid, u8 ussidlen, u8* pdev_raddr);
|
||||
void issue_p2p_GO_request(struct adapter *padapter, u8* raddr);
|
||||
void issue_p2p_provision_request(struct adapter *padapter, u8 *pssid,
|
||||
u8 ussidlen, u8 *pdev_raddr);
|
||||
void issue_p2p_GO_request(struct adapter *padapter, u8 *raddr);
|
||||
void issue_probereq_p2p(struct adapter *padapter, u8 *da);
|
||||
int issue_probereq_p2p_ex(struct adapter *adapter, u8 *da, int try_cnt, int wait_ms);
|
||||
void issue_p2p_invitation_response(struct adapter *padapter, u8* raddr, u8 dialogToken, u8 success);
|
||||
void issue_p2p_invitation_request(struct adapter *padapter, u8* raddr );
|
||||
int issue_probereq_p2p_ex(struct adapter *adapter, u8 *da, int try_cnt,
|
||||
int wait_ms);
|
||||
void issue_p2p_invitation_response(struct adapter *padapter, u8 *raddr,
|
||||
u8 dialogToken, u8 success);
|
||||
void issue_p2p_invitation_request(struct adapter *padapter, u8* raddr);
|
||||
#endif /* CONFIG_P2P */
|
||||
void issue_beacon(struct adapter *padapter, int timeout_ms);
|
||||
void issue_probersp(struct adapter *padapter, unsigned char *da, u8 is_valid_p2p_probereq);
|
||||
void issue_probersp(struct adapter *padapter, unsigned char *da,
|
||||
u8 is_valid_p2p_probereq);
|
||||
void issue_assocreq(struct adapter *padapter);
|
||||
void issue_asocrsp(struct adapter *padapter, unsigned short status, struct sta_info *pstat, int pkt_type);
|
||||
void issue_auth(struct adapter *padapter, struct sta_info *psta, unsigned short status);
|
||||
void issue_probereq(struct adapter *padapter, struct ndis_802_11_ssid *pssid, u8 *da);
|
||||
s32 issue_probereq_ex(struct adapter *padapter, struct ndis_802_11_ssid *pssid, u8* da, int try_cnt, int wait_ms);
|
||||
int issue_nulldata(struct adapter *padapter, unsigned char *da, unsigned int power_mode, int try_cnt, int wait_ms);
|
||||
int issue_qos_nulldata(struct adapter *padapter, unsigned char *da, u16 tid, int try_cnt, int wait_ms);
|
||||
int issue_deauth(struct adapter *padapter, unsigned char *da, unsigned short reason);
|
||||
int issue_deauth_ex(struct adapter *padapter, u8 *da, unsigned short reason, int try_cnt, int wait_ms);
|
||||
void issue_action_spct_ch_switch (struct adapter *padapter, u8 *ra, u8 new_ch, u8 ch_offset);
|
||||
void issue_action_BA(struct adapter *padapter, unsigned char *raddr, unsigned char action, unsigned short status);
|
||||
void issue_asocrsp(struct adapter *padapter, unsigned short status,
|
||||
struct sta_info *pstat, int pkt_type);
|
||||
void issue_auth(struct adapter *padapter, struct sta_info *psta,
|
||||
unsigned short status);
|
||||
void issue_probereq(struct adapter *padapter, struct ndis_802_11_ssid *pssid,
|
||||
u8 *da);
|
||||
s32 issue_probereq_ex(struct adapter *adapter, struct ndis_802_11_ssid *pssid,
|
||||
u8* da, int try_cnt, int wait_ms);
|
||||
int issue_nulldata(struct adapter *padapter, unsigned char *da,
|
||||
unsigned int power_mode, int try_cnt, int wait_ms);
|
||||
int issue_qos_nulldata(struct adapter *padapter, unsigned char *da,
|
||||
u16 tid, int try_cnt, int wait_ms);
|
||||
int issue_deauth(struct adapter *padapter, unsigned char *da,
|
||||
unsigned short reason);
|
||||
int issue_deauth_ex(struct adapter *padapter, u8 *da, unsigned short reason,
|
||||
int try_cnt, int wait_ms);
|
||||
void issue_action_spct_ch_switch(struct adapter *padapter, u8 *ra, u8 new_ch,
|
||||
u8 ch_offset);
|
||||
void issue_action_BA(struct adapter *padapter, unsigned char *raddr,
|
||||
unsigned char action, unsigned short status);
|
||||
unsigned int send_delba(struct adapter *padapter, u8 initiator, u8 *addr);
|
||||
unsigned int send_beacon(struct adapter *padapter);
|
||||
|
||||
void start_clnt_assoc(struct adapter *padapter);
|
||||
void start_clnt_auth(struct adapter* padapter);
|
||||
void start_clnt_join(struct adapter* padapter);
|
||||
void start_create_ibss(struct adapter* padapter);
|
||||
void start_clnt_auth(struct adapter *padapter);
|
||||
void start_clnt_join(struct adapter *padapter);
|
||||
void start_create_ibss(struct adapter *padapter);
|
||||
|
||||
unsigned int OnAssocReq(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnAssocRsp(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnProbeReq(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnProbeRsp(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int DoReserved(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnBeacon(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnAtim(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnDisassoc(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnAuth(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnAuthClient(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnDeAuth(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnAction(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
|
||||
unsigned int on_action_spct(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnAction_qos(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnAction_dls(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnAction_back(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int on_action_public(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnAction_ht(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnAction_wmm(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnAction_p2p(struct adapter *padapter, union recv_frame *precv_frame);
|
||||
unsigned int OnAssocReq(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnAssocRsp(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnProbeReq(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnProbeRsp(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int DoReserved(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnBeacon(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnAtim(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnDisassoc(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnAuth(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnAuthClient(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnDeAuth(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnAction(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
|
||||
unsigned int on_action_spct(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnAction_qos(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnAction_dls(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnAction_back(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int on_action_public(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnAction_ht(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnAction_wmm(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
unsigned int OnAction_p2p(struct adapter *padapter,
|
||||
union recv_frame *precv_frame);
|
||||
|
||||
void mlmeext_joinbss_event_callback(struct adapter *padapter, int join_res);
|
||||
void mlmeext_sta_del_event_callback(struct adapter *padapter);
|
||||
void mlmeext_sta_add_event_callback(struct adapter *padapter, struct sta_info *psta);
|
||||
void mlmeext_sta_add_event_callback(struct adapter *padapter,
|
||||
struct sta_info *psta);
|
||||
|
||||
void linked_status_chk(struct adapter *padapter);
|
||||
|
||||
|
@ -646,20 +699,19 @@ void addba_timer_hdl(struct sta_info *psta);
|
|||
_set_timer(&(mlmeext)->link_timer, (ms)); \
|
||||
} while (0)
|
||||
|
||||
extern int cckrates_included(unsigned char *rate, int ratelen);
|
||||
extern int cckratesonly_included(unsigned char *rate, int ratelen);
|
||||
int cckrates_included(unsigned char *rate, int ratelen);
|
||||
int cckratesonly_included(unsigned char *rate, int ratelen);
|
||||
|
||||
extern void process_addba_req(struct adapter *padapter, u8 *paddba_req, u8 *addr);
|
||||
void process_addba_req(struct adapter *padapter, u8 *paddba_req, u8 *addr);
|
||||
|
||||
extern void update_TSF(struct mlme_ext_priv *pmlmeext, u8 *pframe, uint len);
|
||||
extern void correct_TSF(struct adapter *padapter, struct mlme_ext_priv *pmlmeext);
|
||||
void update_TSF(struct mlme_ext_priv *pmlmeext, u8 *pframe, uint len);
|
||||
void correct_TSF(struct adapter *padapter, struct mlme_ext_priv *pmlmeext);
|
||||
|
||||
struct cmd_hdl {
|
||||
uint parmsize;
|
||||
u8 (*h2cfuns)(struct adapter *padapter, u8 *pbuf);
|
||||
};
|
||||
|
||||
|
||||
u8 read_macreg_hdl(struct adapter *padapter, u8 *pbuf);
|
||||
u8 write_macreg_hdl(struct adapter *padapter, u8 *pbuf);
|
||||
u8 read_bbreg_hdl(struct adapter *padapter, u8 *pbuf);
|
||||
|
@ -685,17 +737,16 @@ u8 tx_beacon_hdl(struct adapter *padapter, unsigned char *pbuf);
|
|||
u8 set_ch_hdl(struct adapter *padapter, u8 *pbuf);
|
||||
u8 set_chplan_hdl(struct adapter *padapter, unsigned char *pbuf);
|
||||
u8 led_blink_hdl(struct adapter *padapter, unsigned char *pbuf);
|
||||
u8 set_csa_hdl(struct adapter *padapter, unsigned char *pbuf); /* Kurt: Handling DFS channel switch announcement ie. */
|
||||
/* Handling DFS channel switch announcement ie. */
|
||||
u8 set_csa_hdl(struct adapter *padapter, unsigned char *pbuf);
|
||||
u8 tdls_hdl(struct adapter *padapter, unsigned char *pbuf);
|
||||
|
||||
|
||||
#define GEN_DRV_CMD_HANDLER(size, cmd) {size, &cmd ## _hdl},
|
||||
#define GEN_MLME_EXT_HANDLER(size, cmd) {size, cmd},
|
||||
|
||||
#ifdef _RTW_CMD_C_
|
||||
|
||||
static struct cmd_hdl wlancmds[] =
|
||||
{
|
||||
static struct cmd_hdl wlancmds[] = {
|
||||
GEN_DRV_CMD_HANDLER(0, NULL) /*0*/
|
||||
GEN_DRV_CMD_HANDLER(0, NULL)
|
||||
GEN_DRV_CMD_HANDLER(0, NULL)
|
||||
|
@ -714,7 +765,8 @@ static struct cmd_hdl wlancmds[] =
|
|||
GEN_MLME_EXT_HANDLER(sizeof (struct disconnect_parm), disconnect_hdl)
|
||||
GEN_MLME_EXT_HANDLER(sizeof (struct createbss_parm), createbss_hdl)
|
||||
GEN_MLME_EXT_HANDLER(sizeof (struct setopmode_parm), setopmode_hdl)
|
||||
GEN_MLME_EXT_HANDLER(sizeof (struct sitesurvey_parm), sitesurvey_cmd_hdl) /*18*/
|
||||
GEN_MLME_EXT_HANDLER(sizeof (struct sitesurvey_parm),
|
||||
sitesurvey_cmd_hdl) /*18*/
|
||||
GEN_MLME_EXT_HANDLER(sizeof (struct setauth_parm), setauth_hdl)
|
||||
GEN_MLME_EXT_HANDLER(sizeof (struct setkey_parm), setkey_hdl) /*20*/
|
||||
GEN_MLME_EXT_HANDLER(sizeof (struct set_stakey_parm), set_stakey_hdl)
|
||||
|
@ -751,57 +803,49 @@ static struct cmd_hdl wlancmds[] =
|
|||
GEN_MLME_EXT_HANDLER(0, NULL)
|
||||
GEN_MLME_EXT_HANDLER(0, NULL)
|
||||
GEN_MLME_EXT_HANDLER(0, NULL)
|
||||
GEN_MLME_EXT_HANDLER(sizeof(struct Tx_Beacon_param), tx_beacon_hdl) /*55*/
|
||||
GEN_MLME_EXT_HANDLER(sizeof(struct Tx_Beacon_param),
|
||||
tx_beacon_hdl) /*55*/
|
||||
|
||||
GEN_MLME_EXT_HANDLER(0, mlme_evt_hdl) /*56*/
|
||||
GEN_MLME_EXT_HANDLER(0, rtw_drvextra_cmd_hdl) /*57*/
|
||||
|
||||
GEN_MLME_EXT_HANDLER(0, h2c_msg_hdl) /*58*/
|
||||
GEN_MLME_EXT_HANDLER(sizeof(struct SetChannelPlan_param), set_chplan_hdl) /*59*/
|
||||
GEN_MLME_EXT_HANDLER(sizeof(struct LedBlink_param), led_blink_hdl) /*60*/
|
||||
GEN_MLME_EXT_HANDLER(sizeof(struct SetChannelPlan_param),
|
||||
set_chplan_hdl) /*59*/
|
||||
GEN_MLME_EXT_HANDLER(sizeof(struct LedBlink_param),
|
||||
led_blink_hdl) /*60*/
|
||||
|
||||
GEN_MLME_EXT_HANDLER(sizeof(struct SetChannelSwitch_param), set_csa_hdl) /*61*/
|
||||
GEN_MLME_EXT_HANDLER(sizeof(struct TDLSoption_param), tdls_hdl) /*62*/
|
||||
GEN_MLME_EXT_HANDLER(sizeof(struct SetChannelSwitch_param),
|
||||
set_csa_hdl) /*61*/
|
||||
GEN_MLME_EXT_HANDLER(sizeof(struct TDLSoption_param),
|
||||
tdls_hdl) /*62*/
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
struct C2HEvent_Header
|
||||
{
|
||||
|
||||
struct C2HEvent_Header {
|
||||
#ifdef __LITTLE_ENDIAN
|
||||
|
||||
unsigned int len:16;
|
||||
unsigned int ID:8;
|
||||
unsigned int seq:8;
|
||||
|
||||
#elif defined(__BIG_ENDIAN)
|
||||
|
||||
unsigned int seq:8;
|
||||
unsigned int ID:8;
|
||||
unsigned int len:16;
|
||||
|
||||
#else
|
||||
|
||||
# error "Must be LITTLE or BIG Endian"
|
||||
|
||||
#endif
|
||||
|
||||
unsigned int rsvd;
|
||||
|
||||
};
|
||||
|
||||
void rtw_dummy_event_callback(struct adapter *adapter , u8 *pbuf);
|
||||
void rtw_fwdbg_event_callback(struct adapter *adapter , u8 *pbuf);
|
||||
void rtw_dummy_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
void rtw_fwdbg_event_callback(struct adapter *adapter, u8 *pbuf);
|
||||
|
||||
enum rtw_c2h_event
|
||||
{
|
||||
GEN_EVT_CODE(_Read_MACREG)=0, /*0*/
|
||||
enum rtw_c2h_event {
|
||||
GEN_EVT_CODE(_Read_MACREG) = 0, /*0*/
|
||||
GEN_EVT_CODE(_Read_BBREG),
|
||||
GEN_EVT_CODE(_Read_RFREG),
|
||||
GEN_EVT_CODE(_Read_EEPROM),
|
||||
GEN_EVT_CODE(_Read_EFUSE),
|
||||
GEN_EVT_CODE(_Read_CAM), /*5*/
|
||||
GEN_EVT_CODE(_Read_CAM), /*5*/
|
||||
GEN_EVT_CODE(_Get_BasicRate),
|
||||
GEN_EVT_CODE(_Get_DataRate),
|
||||
GEN_EVT_CODE(_Survey), /*8*/
|
||||
|
@ -810,26 +854,26 @@ enum rtw_c2h_event
|
|||
GEN_EVT_CODE(_JoinBss) , /*10*/
|
||||
GEN_EVT_CODE(_AddSTA),
|
||||
GEN_EVT_CODE(_DelSTA),
|
||||
GEN_EVT_CODE(_AtimDone) ,
|
||||
GEN_EVT_CODE(_AtimDone),
|
||||
GEN_EVT_CODE(_TX_Report),
|
||||
GEN_EVT_CODE(_CCX_Report), /*15*/
|
||||
GEN_EVT_CODE(_CCX_Report), /*15*/
|
||||
GEN_EVT_CODE(_DTM_Report),
|
||||
GEN_EVT_CODE(_TX_Rate_Statistics),
|
||||
GEN_EVT_CODE(_C2HLBK),
|
||||
GEN_EVT_CODE(_FWDBG),
|
||||
GEN_EVT_CODE(_C2HFEEDBACK), /*20*/
|
||||
GEN_EVT_CODE(_C2HFEEDBACK), /*20*/
|
||||
GEN_EVT_CODE(_ADDBA),
|
||||
GEN_EVT_CODE(_C2HBCN),
|
||||
GEN_EVT_CODE(_ReportPwrState), /* filen: only for PCIE, USB */
|
||||
GEN_EVT_CODE(_CloseRF), /* filen: only for PCIE, work around ASPM */
|
||||
GEN_EVT_CODE(_ReportPwrState), /* filen: only for PCIE, USB */
|
||||
GEN_EVT_CODE(_CloseRF), /* filen: only for PCIE,
|
||||
* work around ASPM */
|
||||
MAX_C2HEVT
|
||||
};
|
||||
|
||||
|
||||
#ifdef _RTW_MLME_EXT_C_
|
||||
|
||||
static struct fwevent wlanevents[] =
|
||||
{
|
||||
static struct fwevent wlanevents[] = {
|
||||
{0, rtw_dummy_event_callback}, /*0*/
|
||||
{0, NULL},
|
||||
{0, NULL},
|
||||
|
@ -839,8 +883,7 @@ static struct fwevent wlanevents[] =
|
|||
{0, NULL},
|
||||
{0, NULL},
|
||||
{0, &rtw_survey_event_callback}, /*8*/
|
||||
{sizeof (struct surveydone_event), &rtw_surveydone_event_callback}, /*9*/
|
||||
|
||||
{sizeof (struct surveydone_event), &rtw_surveydone_event_callback},/*9*/
|
||||
{0, &rtw_joinbss_event_callback}, /*10*/
|
||||
{sizeof(struct stassoc_event), &rtw_stassoc_event_callback},
|
||||
{sizeof(struct stadel_event), &rtw_stadel_event_callback},
|
||||
|
|
245
include/rtw_mp.h
245
include/rtw_mp.h
|
@ -20,8 +20,8 @@
|
|||
#ifndef _RTW_MP_H_
|
||||
#define _RTW_MP_H_
|
||||
|
||||
/* 00 - Success */
|
||||
/* 11 - Error */
|
||||
/* 00 - Success */
|
||||
/* 11 - Error */
|
||||
#define STATUS_SUCCESS (0x00000000L)
|
||||
#define STATUS_PENDING (0x00000103L)
|
||||
|
||||
|
@ -37,7 +37,7 @@
|
|||
#define NDIS_STATUS_CALL_ACTIVE ((int)0x00010007L)
|
||||
|
||||
#define NDIS_STATUS_FAILURE ((int)STATUS_UNSUCCESSFUL)
|
||||
#define NDIS_STATUS_RESOURCES ((int)STATUS_INSUFFICIENT_RESOURCES)
|
||||
#define NDIS_STATUS_RESOURCES ((int)STATUS_INSUFFICIENT_RESOURCES)
|
||||
#define NDIS_STATUS_CLOSING ((int)0xC0010002L)
|
||||
#define NDIS_STATUS_BAD_VERSION ((int)0xC0010004L)
|
||||
#define NDIS_STATUS_BAD_CHARACTERISTICS ((int)0xC0010005L)
|
||||
|
@ -73,12 +73,12 @@
|
|||
#define NDIS_STATUS_SAP_IN_USE ((int)0xC0010021L)
|
||||
#define NDIS_STATUS_INVALID_ADDRESS ((int)0xC0010022L)
|
||||
#define NDIS_STATUS_VC_NOT_ACTIVATED ((int)0xC0010023L)
|
||||
#define NDIS_STATUS_DEST_OUT_OF_ORDER ((int)0xC0010024L) /* cause 27 */
|
||||
#define NDIS_STATUS_VC_NOT_AVAILABLE ((int)0xC0010025L) /* cause 35,45 */
|
||||
#define NDIS_STATUS_CELLRATE_NOT_AVAILABLE ((int)0xC0010026L) /* cause 37 */
|
||||
#define NDIS_STATUS_INCOMPATABLE_QOS ((int)0xC0010027L) /* cause 49 */
|
||||
#define NDIS_STATUS_AAL_PARAMS_UNSUPPORTED ((int)0xC0010028L) /* cause 93 */
|
||||
#define NDIS_STATUS_NO_ROUTE_TO_DESTINATION ((int)0xC0010029L) /* cause 3 */
|
||||
#define NDIS_STATUS_DEST_OUT_OF_ORDER ((int)0xC0010024L) /*cause 27*/
|
||||
#define NDIS_STATUS_VC_NOT_AVAILABLE ((int)0xC0010025L) /*cause 35,45 */
|
||||
#define NDIS_STATUS_CELLRATE_NOT_AVAILABLE ((int)0xC0010026L) /*cause 37*/
|
||||
#define NDIS_STATUS_INCOMPATABLE_QOS ((int)0xC0010027L) /*cause 49*/
|
||||
#define NDIS_STATUS_AAL_PARAMS_UNSUPPORTED ((int)0xC0010028L) /*cause 93*/
|
||||
#define NDIS_STATUS_NO_ROUTE_TO_DESTINATION ((int)0xC0010029L) /*cause 3 */
|
||||
|
||||
enum antenna_path {
|
||||
ANTENNA_NONE = 0x00,
|
||||
|
@ -166,81 +166,76 @@ struct mpt_context {
|
|||
|
||||
/* 8190 PCI does not support NDIS_WORK_ITEM. */
|
||||
/* Work Item for Mass Production Test. */
|
||||
/* Event used to sync the case unloading driver and MptWorkItem is still in progress. */
|
||||
/* Event used to sync the case unloading driver and MptWorkItem
|
||||
* is still in progress. */
|
||||
/* Indicate a MptWorkItem is scheduled and not yet finished. */
|
||||
bool bMptWorkItemInProgress;
|
||||
/* An instance which implements function and context of MptWorkItem. */
|
||||
MPT_WORK_ITEM_HANDLER CurrMptAct;
|
||||
|
||||
/* 1=Start, 0=Stop from UI. */
|
||||
u32 MptTestStart;
|
||||
u32 MptTestStart;
|
||||
/* _TEST_MODE, defined in MPT_Req2.h */
|
||||
u32 MptTestItem;
|
||||
u32 MptTestItem;
|
||||
/* Variable needed in each implementation of CurrMptAct. */
|
||||
u32 MptActType; /* Type of action performed in CurrMptAct. */
|
||||
u32 MptActType; /* Type of action performed in CurrMptAct. */
|
||||
/* The Offset of IO operation is depend of MptActType. */
|
||||
u32 MptIoOffset;
|
||||
u32 MptIoOffset;
|
||||
/* The Value of IO operation is depend of MptActType. */
|
||||
u32 MptIoValue;
|
||||
u32 MptIoValue;
|
||||
/* The RfPath of IO operation is depend of MptActType. */
|
||||
u32 MptRfPath;
|
||||
u32 MptRfPath;
|
||||
|
||||
enum wireless_mode MptWirelessModeToSw; /* Wireless mode to switch. */
|
||||
u8 MptChannelToSw; /* Channel to switch. */
|
||||
u8 MptInitGainToSet; /* Initial gain to set. */
|
||||
u32 MptBandWidth; /* bandwidth to switch. */
|
||||
u32 MptRateIndex; /* rate index. */
|
||||
u8 MptChannelToSw; /* Channel to switch. */
|
||||
u8 MptInitGainToSet; /* Initial gain to set. */
|
||||
u32 MptBandWidth; /* bandwidth to switch. */
|
||||
u32 MptRateIndex; /* rate index. */
|
||||
/* Register value kept for Single Carrier Tx test. */
|
||||
u8 btMpCckTxPower;
|
||||
u8 btMpCckTxPower;
|
||||
/* Register value kept for Single Carrier Tx test. */
|
||||
u8 btMpOfdmTxPower;
|
||||
u8 btMpOfdmTxPower;
|
||||
/* For MP Tx Power index */
|
||||
u8 TxPwrLevel[2]; /* rf-A, rf-B */
|
||||
u8 TxPwrLevel[2]; /* rf-A, rf-B */
|
||||
|
||||
/* Content of RCR Regsiter for Mass Production Test. */
|
||||
u32 MptRCR;
|
||||
u32 MptRCR;
|
||||
/* true if we only receive packets with specific pattern. */
|
||||
bool bMptFilterPattern;
|
||||
bool bMptFilterPattern;
|
||||
/* Rx OK count, statistics used in Mass Production Test. */
|
||||
u32 MptRxOkCnt;
|
||||
u32 MptRxOkCnt;
|
||||
/* Rx CRC32 error count, statistics used in Mass Production Test. */
|
||||
u32 MptRxCrcErrCnt;
|
||||
u32 MptRxCrcErrCnt;
|
||||
|
||||
bool bCckContTx; /* true if we are in CCK Continuous Tx test. */
|
||||
bool bOfdmContTx; /* true if we are in OFDM Continuous Tx test. */
|
||||
bool bStartContTx; /* true if we have start Continuous Tx test. */
|
||||
bool bCckContTx; /* true if we are in CCK Continuous Tx test. */
|
||||
bool bOfdmContTx; /* true if we are in OFDM Continuous Tx test. */
|
||||
bool bStartContTx; /* true if we have start Continuous Tx test. */
|
||||
/* true if we are in Single Carrier Tx test. */
|
||||
bool bSingleCarrier;
|
||||
bool bSingleCarrier;
|
||||
/* true if we are in Carrier Suppression Tx Test. */
|
||||
bool bCarrierSuppression;
|
||||
bool bCarrierSuppression;
|
||||
/* true if we are in Single Tone Tx test. */
|
||||
bool bSingleTone;
|
||||
bool bSingleTone;
|
||||
|
||||
/* ACK counter asked by K.Y.. */
|
||||
bool bMptEnableAckCounter;
|
||||
u32 MptAckCounter;
|
||||
bool bMptEnableAckCounter;
|
||||
u32 MptAckCounter;
|
||||
|
||||
/* SD3 Willis For 8192S to save 1T/2T RF table for ACUT Only fro ACUT delete later ~~~! */
|
||||
/* s8 BufOfLines[2][MAX_LINES_HWCONFIG_TXT][MAX_BYTES_LINE_HWCONFIG_TXT]; */
|
||||
/* s8 BufOfLines[2][MP_MAX_LINES][MP_MAX_LINES_BYTES]; */
|
||||
/* s32 RfReadLine[2]; */
|
||||
u8 APK_bound[2]; /* for APK path A/path B */
|
||||
bool bMptIndexEven;
|
||||
|
||||
u8 APK_bound[2]; /* for APK path A/path B */
|
||||
bool bMptIndexEven;
|
||||
u8 backup0xc50;
|
||||
u8 backup0xc58;
|
||||
u8 backup0xc30;
|
||||
u8 backup0x52_RF_A;
|
||||
u8 backup0x52_RF_B;
|
||||
|
||||
u8 backup0xc50;
|
||||
u8 backup0xc58;
|
||||
u8 backup0xc30;
|
||||
u8 backup0x52_RF_A;
|
||||
u8 backup0x52_RF_B;
|
||||
|
||||
u8 h2cReqNum;
|
||||
u8 c2hBuf[20];
|
||||
|
||||
u8 btInBuf[100];
|
||||
u32 mptOutLen;
|
||||
u8 mptOutBuf[100];
|
||||
u8 h2cReqNum;
|
||||
u8 c2hBuf[20];
|
||||
|
||||
u8 btInBuf[100];
|
||||
u32 mptOutLen;
|
||||
u8 mptOutBuf[100];
|
||||
};
|
||||
|
||||
enum {
|
||||
|
@ -275,18 +270,17 @@ enum {
|
|||
MP_NULL,
|
||||
};
|
||||
|
||||
struct mp_priv
|
||||
{
|
||||
struct mp_priv {
|
||||
struct adapter *papdater;
|
||||
|
||||
/* Testing Flag */
|
||||
u32 mode;/* 0 for normal type packet, 1 for loopback packet (16bytes TXCMD) */
|
||||
/* 0 for normal type packet, 1 for loopback packet (16bytes TXCMD) */
|
||||
u32 mode;
|
||||
|
||||
u32 prev_fw_state;
|
||||
|
||||
/* OID cmd handler */
|
||||
struct mp_wiparam workparam;
|
||||
/* u8 act_in_progress; */
|
||||
|
||||
/* Tx Section */
|
||||
u8 TID;
|
||||
|
@ -425,88 +419,77 @@ enum encry_ctrl_state {
|
|||
SW_ENCRY_HW_DECRY /* sw encryption & hw decryption */
|
||||
};
|
||||
|
||||
/* */
|
||||
/* extern struct mp_xmit_frame *alloc_mp_xmitframe(struct mp_priv *pmp_priv); */
|
||||
/* extern int free_mp_xmitframe(struct xmit_priv *pxmitpriv, struct mp_xmit_frame *pmp_xmitframe); */
|
||||
s32 init_mp_priv(struct adapter *padapter);
|
||||
void free_mp_priv(struct mp_priv *pmp_priv);
|
||||
s32 MPT_InitializeAdapter(struct adapter *padapter, u8 Channel);
|
||||
void MPT_DeInitAdapter(struct adapter *padapter);
|
||||
s32 mp_start_test(struct adapter *padapter);
|
||||
void mp_stop_test(struct adapter *padapter);
|
||||
|
||||
extern s32 init_mp_priv(struct adapter * padapter);
|
||||
extern void free_mp_priv(struct mp_priv *pmp_priv);
|
||||
extern s32 MPT_InitializeAdapter(struct adapter * padapter, u8 Channel);
|
||||
extern void MPT_DeInitAdapter(struct adapter * padapter);
|
||||
extern s32 mp_start_test(struct adapter * padapter);
|
||||
extern void mp_stop_test(struct adapter * padapter);
|
||||
u32 _read_rfreg(struct adapter *padapter, u8 rfpath, u32 addr, u32 bitmask);
|
||||
void _write_rfreg(struct adapter *padapter, u8 rfpath, u32 addr, u32 bitmask, u32 val);
|
||||
|
||||
/* */
|
||||
u32 read_macreg(struct adapter *padapter, u32 addr, u32 sz);
|
||||
void write_macreg(struct adapter *padapter, u32 addr, u32 val, u32 sz);
|
||||
u32 read_bbreg(struct adapter *padapter, u32 addr, u32 bitmask);
|
||||
void write_bbreg(struct adapter *padapter, u32 addr, u32 bitmask, u32 val);
|
||||
u32 read_rfreg(struct adapter *padapter, u8 rfpath, u32 addr);
|
||||
void write_rfreg(struct adapter *padapter, u8 rfpath, u32 addr, u32 val);
|
||||
|
||||
extern u32 _read_rfreg(struct adapter * padapter, u8 rfpath, u32 addr, u32 bitmask);
|
||||
extern void _write_rfreg(struct adapter * padapter, u8 rfpath, u32 addr, u32 bitmask, u32 val);
|
||||
void SetChannel(struct adapter *pAdapter);
|
||||
void SetBandwidth(struct adapter *pAdapter);
|
||||
void SetTxPower(struct adapter *pAdapter);
|
||||
void SetAntennaPathPower(struct adapter *pAdapter);
|
||||
void SetDataRate(struct adapter *pAdapter);
|
||||
|
||||
extern u32 read_macreg(struct adapter *padapter, u32 addr, u32 sz);
|
||||
extern void write_macreg(struct adapter *padapter, u32 addr, u32 val, u32 sz);
|
||||
extern u32 read_bbreg(struct adapter *padapter, u32 addr, u32 bitmask);
|
||||
extern void write_bbreg(struct adapter *padapter, u32 addr, u32 bitmask, u32 val);
|
||||
extern u32 read_rfreg(struct adapter * padapter, u8 rfpath, u32 addr);
|
||||
extern void write_rfreg(struct adapter * padapter, u8 rfpath, u32 addr, u32 val);
|
||||
void SetAntenna(struct adapter *pAdapter);
|
||||
|
||||
extern void SetChannel(struct adapter * pAdapter);
|
||||
extern void SetBandwidth(struct adapter * pAdapter);
|
||||
extern void SetTxPower(struct adapter * pAdapter);
|
||||
extern void SetAntennaPathPower(struct adapter * pAdapter);
|
||||
extern void SetDataRate(struct adapter * pAdapter);
|
||||
s32 SetThermalMeter(struct adapter *pAdapter, u8 target_ther);
|
||||
void GetThermalMeter(struct adapter *pAdapter, u8 *value);
|
||||
|
||||
extern void SetAntenna(struct adapter * pAdapter);
|
||||
void SetContinuousTx(struct adapter *pAdapter, u8 bStart);
|
||||
void SetSingleCarrierTx(struct adapter *pAdapter, u8 bStart);
|
||||
void SetSingleToneTx(struct adapter *pAdapter, u8 bStart);
|
||||
void SetCarrierSuppressionTx(struct adapter *pAdapter, u8 bStart);
|
||||
void PhySetTxPowerLevel(struct adapter *pAdapter);
|
||||
|
||||
extern s32 SetThermalMeter(struct adapter * pAdapter, u8 target_ther);
|
||||
extern void GetThermalMeter(struct adapter * pAdapter, u8 *value);
|
||||
void fill_txdesc_for_mp(struct adapter *padapter, struct tx_desc *ptxdesc);
|
||||
void SetPacketTx(struct adapter *padapter);
|
||||
void SetPacketRx(struct adapter *pAdapter, u8 bStartRx);
|
||||
|
||||
extern void SetContinuousTx(struct adapter * pAdapter, u8 bStart);
|
||||
extern void SetSingleCarrierTx(struct adapter * pAdapter, u8 bStart);
|
||||
extern void SetSingleToneTx(struct adapter * pAdapter, u8 bStart);
|
||||
extern void SetCarrierSuppressionTx(struct adapter * pAdapter, u8 bStart);
|
||||
extern void PhySetTxPowerLevel(struct adapter * pAdapter);
|
||||
void ResetPhyRxPktCount(struct adapter *pAdapter);
|
||||
u32 GetPhyRxPktReceived(struct adapter *pAdapter);
|
||||
u32 GetPhyRxPktCRC32Error(struct adapter *pAdapter);
|
||||
|
||||
extern void fill_txdesc_for_mp(struct adapter * padapter, struct tx_desc *ptxdesc);
|
||||
extern void SetPacketTx(struct adapter * padapter);
|
||||
extern void SetPacketRx(struct adapter * pAdapter, u8 bStartRx);
|
||||
|
||||
extern void ResetPhyRxPktCount(struct adapter * pAdapter);
|
||||
extern u32 GetPhyRxPktReceived(struct adapter * pAdapter);
|
||||
extern u32 GetPhyRxPktCRC32Error(struct adapter * pAdapter);
|
||||
|
||||
extern s32 SetPowerTracking(struct adapter * padapter, u8 enable);
|
||||
extern void GetPowerTracking(struct adapter * padapter, u8 *enable);
|
||||
|
||||
extern u32 mp_query_psd(struct adapter * pAdapter, u8 *data);
|
||||
|
||||
|
||||
extern void Hal_SetAntenna(struct adapter * pAdapter);
|
||||
extern void Hal_SetBandwidth(struct adapter * pAdapter);
|
||||
|
||||
extern void Hal_SetTxPower(struct adapter * pAdapter);
|
||||
extern void Hal_SetCarrierSuppressionTx(struct adapter * pAdapter, u8 bStart);
|
||||
extern void Hal_SetSingleToneTx ( struct adapter * pAdapter , u8 bStart );
|
||||
extern void Hal_SetSingleCarrierTx (struct adapter * pAdapter, u8 bStart);
|
||||
extern void Hal_SetContinuousTx (struct adapter * pAdapter, u8 bStart);
|
||||
extern void Hal_SetBandwidth(struct adapter * pAdapter);
|
||||
|
||||
extern void Hal_SetDataRate(struct adapter * pAdapter);
|
||||
extern void Hal_SetChannel(struct adapter * pAdapter);
|
||||
extern void Hal_SetAntennaPathPower(struct adapter * pAdapter);
|
||||
extern s32 Hal_SetThermalMeter(struct adapter * pAdapter, u8 target_ther);
|
||||
extern s32 Hal_SetPowerTracking(struct adapter * padapter, u8 enable);
|
||||
extern void Hal_GetPowerTracking(struct adapter * padapter, u8 * enable);
|
||||
extern void Hal_GetThermalMeter(struct adapter * pAdapter, u8 *value);
|
||||
extern void Hal_mpt_SwitchRfSetting(struct adapter * pAdapter);
|
||||
extern void Hal_MPT_CCKTxPowerAdjust(struct adapter * Adapter, bool bInCH14);
|
||||
extern void Hal_MPT_CCKTxPowerAdjustbyIndex(struct adapter * pAdapter, bool beven);
|
||||
extern void Hal_SetCCKTxPower(struct adapter * pAdapter, u8 * TxPower);
|
||||
extern void Hal_SetOFDMTxPower(struct adapter * pAdapter, u8 * TxPower);
|
||||
extern void Hal_TriggerRFThermalMeter(struct adapter * pAdapter);
|
||||
extern u8 Hal_ReadRFThermalMeter(struct adapter * pAdapter);
|
||||
extern void Hal_SetCCKContinuousTx(struct adapter * pAdapter, u8 bStart);
|
||||
extern void Hal_SetOFDMContinuousTx(struct adapter * pAdapter, u8 bStart);
|
||||
extern void Hal_ProSetCrystalCap (struct adapter * pAdapter , u32 CrystalCapVal);
|
||||
extern void _rtw_mp_xmit_priv(struct xmit_priv *pxmitpriv);
|
||||
extern void MP_PHY_SetRFPathSwitch(struct adapter * pAdapter ,bool bMain);
|
||||
s32 SetPowerTracking(struct adapter *padapter, u8 enable);
|
||||
void GetPowerTracking(struct adapter *padapter, u8 *enable);
|
||||
u32 mp_query_psd(struct adapter *pAdapter, u8 *data);
|
||||
void Hal_SetAntenna(struct adapter *pAdapter);
|
||||
void Hal_SetBandwidth(struct adapter *pAdapter);
|
||||
void Hal_SetTxPower(struct adapter *pAdapter);
|
||||
void Hal_SetCarrierSuppressionTx(struct adapter *pAdapter, u8 bStart);
|
||||
void Hal_SetSingleToneTx(struct adapter *pAdapter, u8 bStart);
|
||||
void Hal_SetSingleCarrierTx (struct adapter *pAdapter, u8 bStart);
|
||||
void Hal_SetContinuousTx (struct adapter *pAdapter, u8 bStart);
|
||||
void Hal_SetBandwidth(struct adapter *pAdapter);
|
||||
void Hal_SetDataRate(struct adapter *pAdapter);
|
||||
void Hal_SetChannel(struct adapter *pAdapter);
|
||||
void Hal_SetAntennaPathPower(struct adapter *pAdapter);
|
||||
s32 Hal_SetThermalMeter(struct adapter *pAdapter, u8 target_ther);
|
||||
s32 Hal_SetPowerTracking(struct adapter *padapter, u8 enable);
|
||||
void Hal_GetPowerTracking(struct adapter *padapter, u8 * enable);
|
||||
void Hal_GetThermalMeter(struct adapter *pAdapter, u8 *value);
|
||||
void Hal_mpt_SwitchRfSetting(struct adapter *pAdapter);
|
||||
void Hal_MPT_CCKTxPowerAdjust(struct adapter * Adapter, bool bInCH14);
|
||||
void Hal_MPT_CCKTxPowerAdjustbyIndex(struct adapter *pAdapter, bool beven);
|
||||
void Hal_SetCCKTxPower(struct adapter *pAdapter, u8 * TxPower);
|
||||
void Hal_SetOFDMTxPower(struct adapter *pAdapter, u8 * TxPower);
|
||||
void Hal_TriggerRFThermalMeter(struct adapter *pAdapter);
|
||||
u8 Hal_ReadRFThermalMeter(struct adapter *pAdapter);
|
||||
void Hal_SetCCKContinuousTx(struct adapter *pAdapter, u8 bStart);
|
||||
void Hal_SetOFDMContinuousTx(struct adapter *pAdapter, u8 bStart);
|
||||
void Hal_ProSetCrystalCap (struct adapter *pAdapter , u32 CrystalCapVal);
|
||||
void _rtw_mp_xmit_priv(struct xmit_priv *pxmitpriv);
|
||||
void MP_PHY_SetRFPathSwitch(struct adapter *pAdapter ,bool bMain);
|
||||
|
||||
#endif /* _RTW_MP_H_ */
|
||||
|
|
|
@ -79,13 +79,13 @@ int oid_rt_pro_set_tx_power_control_hdl(struct oid_par_priv *poid_par_priv);
|
|||
/* oid_rtl_seg_81_80_20 */
|
||||
int oid_rt_pro_query_tx_packet_sent_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_query_rx_packet_received_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_query_rx_packet_crc32_error_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_query_rx_packet_crc32_error_hdl(struct oid_par_priv *par_priv);
|
||||
int oid_rt_pro_reset_tx_packet_sent_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_reset_rx_packet_received_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_reset_rx_packet_received_hdl(struct oid_par_priv *par_priv);
|
||||
int oid_rt_pro_set_modulation_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_set_continuous_tx_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_set_single_carrier_tx_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_set_carrier_suppression_tx_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_set_carrier_suppression_tx_hdl(struct oid_par_priv *par_priv);
|
||||
int oid_rt_pro_set_single_tone_tx_hdl(struct oid_par_priv *poid_par_priv);
|
||||
|
||||
/* oid_rtl_seg_81_87 */
|
||||
|
@ -105,7 +105,7 @@ int oid_rt_pro_burst_read_register_hdl(struct oid_par_priv *poid_par_priv);
|
|||
int oid_rt_pro_burst_write_register_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_write_txcmd_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_read16_eeprom_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_write16_eeprom_hdl (struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_write16_eeprom_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro8711_wi_poll_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro8711_pkt_loss_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_rd_attrib_mem_hdl(struct oid_par_priv *poid_par_priv);
|
||||
|
@ -146,7 +146,7 @@ int oid_rt_pro_set_pkt_test_mode_hdl(struct oid_par_priv *poid_par_priv);
|
|||
int oid_rt_get_thermal_meter_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_reset_phy_rx_packet_count_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_phy_rx_packet_received_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_phy_rx_packet_crc32_error_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_phy_rx_packet_crc32_error_hdl(struct oid_par_priv *par_priv);
|
||||
int oid_rt_set_power_down_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_get_power_mode_hdl(struct oid_par_priv *poid_par_priv);
|
||||
int oid_rt_pro_trigger_gpio_hdl(struct oid_par_priv *poid_par_priv);
|
||||
|
@ -154,56 +154,56 @@ int oid_rt_pro_trigger_gpio_hdl(struct oid_par_priv *poid_par_priv);
|
|||
#ifdef _RTW_MP_IOCTL_C_
|
||||
|
||||
static const struct oid_obj_priv oid_rtl_seg_81_80_00[] = {
|
||||
{1, &oid_null_function}, /* 0x00 OID_RT_PRO_RESET_DUT */
|
||||
{1, &oid_rt_pro_set_data_rate_hdl}, /* 0x01 */
|
||||
{1, &oid_rt_pro_start_test_hdl}, /* 0x02 */
|
||||
{1, &oid_rt_pro_stop_test_hdl}, /* 0x03 */
|
||||
{1, &oid_null_function}, /* 0x04 OID_RT_PRO_SET_PREAMBLE */
|
||||
{1, &oid_null_function}, /* 0x05 OID_RT_PRO_SET_SCRAMBLER */
|
||||
{1, &oid_null_function}, /* 0x06 OID_RT_PRO_SET_FILTER_BB */
|
||||
{1, &oid_null_function}, /* 0x07 OID_RT_PRO_SET_MANUAL_DIVERSITY_BB */
|
||||
{1, &oid_null_function}, /* 0x00 OID_RT_PRO_RESET_DUT */
|
||||
{1, &oid_rt_pro_set_data_rate_hdl}, /* 0x01 */
|
||||
{1, &oid_rt_pro_start_test_hdl}, /* 0x02 */
|
||||
{1, &oid_rt_pro_stop_test_hdl}, /* 0x03 */
|
||||
{1, &oid_null_function}, /* 0x04 OID_RT_PRO_SET_PREAMBLE */
|
||||
{1, &oid_null_function}, /* 0x05 OID_RT_PRO_SET_SCRAMBLER */
|
||||
{1, &oid_null_function}, /* 0x06 OID_RT_PRO_SET_FILTER_BB */
|
||||
{1, &oid_null_function},/* 0x07 OID_RT_PRO_SET_MANUAL_DIVERSITY_BB */
|
||||
{1, &oid_rt_pro_set_channel_direct_call_hdl}, /* 0x08 */
|
||||
{1, &oid_null_function}, /* 0x09 OID_RT_PRO_SET_SLEEP_MODE_DIRECT_CALL */
|
||||
{1, &oid_null_function}, /* 0x0A OID_RT_PRO_SET_WAKE_MODE_DIRECT_CALL */
|
||||
{1, &oid_rt_pro_set_continuous_tx_hdl}, /* 0x0B OID_RT_PRO_SET_TX_CONTINUOUS_DIRECT_CALL */
|
||||
{1, &oid_rt_pro_set_single_carrier_tx_hdl}, /* 0x0C OID_RT_PRO_SET_SINGLE_CARRIER_TX_CONTINUOUS */
|
||||
{1, &oid_null_function}, /* 0x0D OID_RT_PRO_SET_TX_ANTENNA_BB */
|
||||
{1, &oid_rt_pro_set_antenna_bb_hdl}, /* 0x0E */
|
||||
{1, &oid_null_function}, /* 0x0F OID_RT_PRO_SET_CR_SCRAMBLER */
|
||||
{1, &oid_null_function}, /* 0x10 OID_RT_PRO_SET_CR_NEW_FILTER */
|
||||
{1, &oid_rt_pro_set_tx_power_control_hdl}, /* 0x11 OID_RT_PRO_SET_TX_POWER_CONTROL */
|
||||
{1, &oid_null_function}, /* 0x12 OID_RT_PRO_SET_CR_TX_CONFIG */
|
||||
{1, &oid_null_function}, /* 0x13 OID_RT_PRO_GET_TX_POWER_CONTROL */
|
||||
{1, &oid_null_function}, /* 0x14 OID_RT_PRO_GET_CR_SIGNAL_QUALITY */
|
||||
{1, &oid_null_function}, /* 0x15 OID_RT_PRO_SET_CR_SETPOINT */
|
||||
{1, &oid_null_function}, /* 0x16 OID_RT_PRO_SET_INTEGRATOR */
|
||||
{1, &oid_null_function}, /* 0x17 OID_RT_PRO_SET_SIGNAL_QUALITY */
|
||||
{1, &oid_null_function}, /* 0x18 OID_RT_PRO_GET_INTEGRATOR */
|
||||
{1, &oid_null_function}, /* 0x19 OID_RT_PRO_GET_SIGNAL_QUALITY */
|
||||
{1, &oid_null_function}, /* 0x1A OID_RT_PRO_QUERY_EEPROM_TYPE */
|
||||
{1, &oid_null_function}, /* 0x1B OID_RT_PRO_WRITE_MAC_ADDRESS */
|
||||
{1, &oid_null_function}, /* 0x1C OID_RT_PRO_READ_MAC_ADDRESS */
|
||||
{1, &oid_null_function}, /* 0x1D OID_RT_PRO_WRITE_CIS_DATA */
|
||||
{1, &oid_null_function}, /* 0x1E OID_RT_PRO_READ_CIS_DATA */
|
||||
{1, &oid_null_function} /* 0x1F OID_RT_PRO_WRITE_POWER_CONTROL */
|
||||
{1, &oid_null_function},/* 0x09 OID_RT_PRO_SET_SLEEP_MODE_DIRECT_CALL */
|
||||
{1, &oid_null_function},/* 0x0A OID_RT_PRO_SET_WAKE_MODE_DIRECT_CALL */
|
||||
{1, &oid_rt_pro_set_continuous_tx_hdl}, /* 0x0B OID_RT_PRO_SET_TX_CONTINUOUS_DIRECT_CALL */
|
||||
{1, &oid_rt_pro_set_single_carrier_tx_hdl},/* 0x0C OID_RT_PRO_SET_SINGLE_CARRIER_TX_CONTINUOUS */
|
||||
{1, &oid_null_function}, /* 0x0D OID_RT_PRO_SET_TX_ANTENNA_BB */
|
||||
{1, &oid_rt_pro_set_antenna_bb_hdl}, /* 0x0E */
|
||||
{1, &oid_null_function}, /* 0x0F OID_RT_PRO_SET_CR_SCRAMBLER */
|
||||
{1, &oid_null_function}, /* 0x10 OID_RT_PRO_SET_CR_NEW_FILTER */
|
||||
{1, &oid_rt_pro_set_tx_power_control_hdl},/* 0x11 OID_RT_PRO_SET_TX_POWER_CONTROL */
|
||||
{1, &oid_null_function}, /* 0x12 OID_RT_PRO_SET_CR_TX_CONFIG */
|
||||
{1, &oid_null_function}, /* 0x13 OID_RT_PRO_GET_TX_POWER_CONTROL */
|
||||
{1, &oid_null_function}, /* 0x14 OID_RT_PRO_GET_CR_SIGNAL_QUALITY */
|
||||
{1, &oid_null_function}, /* 0x15 OID_RT_PRO_SET_CR_SETPOINT */
|
||||
{1, &oid_null_function}, /* 0x16 OID_RT_PRO_SET_INTEGRATOR */
|
||||
{1, &oid_null_function}, /* 0x17 OID_RT_PRO_SET_SIGNAL_QUALITY */
|
||||
{1, &oid_null_function}, /* 0x18 OID_RT_PRO_GET_INTEGRATOR */
|
||||
{1, &oid_null_function}, /* 0x19 OID_RT_PRO_GET_SIGNAL_QUALITY */
|
||||
{1, &oid_null_function}, /* 0x1A OID_RT_PRO_QUERY_EEPROM_TYPE */
|
||||
{1, &oid_null_function}, /* 0x1B OID_RT_PRO_WRITE_MAC_ADDRESS */
|
||||
{1, &oid_null_function}, /* 0x1C OID_RT_PRO_READ_MAC_ADDRESS */
|
||||
{1, &oid_null_function}, /* 0x1D OID_RT_PRO_WRITE_CIS_DATA */
|
||||
{1, &oid_null_function}, /* 0x1E OID_RT_PRO_READ_CIS_DATA */
|
||||
{1, &oid_null_function} /* 0x1F OID_RT_PRO_WRITE_POWER_CONTROL */
|
||||
};
|
||||
|
||||
static const struct oid_obj_priv oid_rtl_seg_81_80_20[] = {
|
||||
{1, &oid_null_function}, /* 0x20 OID_RT_PRO_READ_POWER_CONTROL */
|
||||
{1, &oid_null_function}, /* 0x21 OID_RT_PRO_WRITE_EEPROM */
|
||||
{1, &oid_null_function}, /* 0x22 OID_RT_PRO_READ_EEPROM */
|
||||
{1, &oid_null_function}, /* 0x20 OID_RT_PRO_READ_POWER_CONTROL */
|
||||
{1, &oid_null_function}, /* 0x21 OID_RT_PRO_WRITE_EEPROM */
|
||||
{1, &oid_null_function}, /* 0x22 OID_RT_PRO_READ_EEPROM */
|
||||
{1, &oid_rt_pro_reset_tx_packet_sent_hdl}, /* 0x23 */
|
||||
{1, &oid_rt_pro_query_tx_packet_sent_hdl}, /* 0x24 */
|
||||
{1, &oid_rt_pro_reset_rx_packet_received_hdl}, /* 0x25 */
|
||||
{1, &oid_rt_pro_query_rx_packet_received_hdl}, /* 0x26 */
|
||||
{1, &oid_rt_pro_query_rx_packet_crc32_error_hdl}, /* 0x27 */
|
||||
{1, &oid_null_function}, /* 0x28 OID_RT_PRO_QUERY_CURRENT_ADDRESS */
|
||||
{1, &oid_null_function}, /* 0x29 OID_RT_PRO_QUERY_PERMANENT_ADDRESS */
|
||||
{1, &oid_null_function}, /* 0x2A OID_RT_PRO_SET_PHILIPS_RF_PARAMETERS */
|
||||
{1, &oid_null_function}, /* 0x28 OID_RT_PRO_QUERY_CURRENT_ADDRESS */
|
||||
{1, &oid_null_function}, /* 0x29 OID_RT_PRO_QUERY_PERMANENT_ADDRESS */
|
||||
{1, &oid_null_function}, /* 0x2A OID_RT_PRO_SET_PHILIPS_RF_PARAMETERS */
|
||||
{1, &oid_rt_pro_set_carrier_suppression_tx_hdl},/* 0x2B OID_RT_PRO_SET_CARRIER_SUPPRESSION_TX */
|
||||
{1, &oid_null_function}, /* 0x2C OID_RT_PRO_RECEIVE_PACKET */
|
||||
{1, &oid_null_function}, /* 0x2D OID_RT_PRO_WRITE_EEPROM_BYTE */
|
||||
{1, &oid_null_function}, /* 0x2E OID_RT_PRO_READ_EEPROM_BYTE */
|
||||
{1, &oid_null_function}, /* 0x2C OID_RT_PRO_RECEIVE_PACKET */
|
||||
{1, &oid_null_function}, /* 0x2D OID_RT_PRO_WRITE_EEPROM_BYTE */
|
||||
{1, &oid_null_function}, /* 0x2E OID_RT_PRO_READ_EEPROM_BYTE */
|
||||
{1, &oid_rt_pro_set_modulation_hdl} /* 0x2F */
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue