mirror of
https://github.com/Mange/rtl8192eu-linux-driver
synced 2024-12-23 12:37:42 +00:00
Remove code related to PLATFORM_FREEBSD
This commit is contained in:
parent
9d13b33a29
commit
9e36a8086e
@ -14,9 +14,6 @@
|
||||
*****************************************************************************/
|
||||
#define _RTW_MP_C_
|
||||
#include <drv_types.h>
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
#include <sys/unistd.h> /* for RFHIGHPID */
|
||||
#endif
|
||||
|
||||
#include "../hal/phydm/phydm_precomp.h"
|
||||
#if defined(CONFIG_RTL8723B) || defined(CONFIG_RTL8821A)
|
||||
@ -1997,18 +1994,6 @@ void SetPacketTx(PADAPTER padapter)
|
||||
pmp_priv->tx.PktTxThread = NULL;
|
||||
}
|
||||
#endif
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
{
|
||||
struct proc *p;
|
||||
struct thread *td;
|
||||
pmp_priv->tx.PktTxThread = kproc_kthread_add(mp_xmit_packet_thread, pmp_priv,
|
||||
&p, &td, RFHIGHPID, 0, "MPXmitThread", "MPXmitThread");
|
||||
|
||||
if (pmp_priv->tx.PktTxThread < 0)
|
||||
RTW_INFO("Create PktTx Thread Fail !!!!!\n");
|
||||
}
|
||||
#endif
|
||||
|
||||
Rtw_MPSetMacTxEDCA(padapter);
|
||||
exit:
|
||||
return;
|
||||
|
@ -2129,8 +2129,6 @@ BIP_exit:
|
||||
return res;
|
||||
}
|
||||
#endif /* CONFIG_IEEE80211W */
|
||||
|
||||
#ifndef PLATFORM_FREEBSD
|
||||
#if defined(CONFIG_TDLS)
|
||||
/* compress 512-bits */
|
||||
static int sha256_compress(struct sha256_state_rtk *md, unsigned char *buf)
|
||||
@ -2406,7 +2404,7 @@ static void hmac_sha256_vector(u8 *key, size_t key_len, size_t num_elem,
|
||||
sha256_vector(2, _addr, _len, mac);
|
||||
}
|
||||
#endif /* CONFIG_TDLS */
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
|
||||
/**
|
||||
* sha256_prf - SHA256-based Pseudo-Random Function (IEEE 802.11r, 8.5.1.5.2)
|
||||
* @key: Key for PRF
|
||||
@ -2420,7 +2418,6 @@ static void hmac_sha256_vector(u8 *key, size_t key_len, size_t num_elem,
|
||||
* This function is used to derive new, cryptographically separate keys from a
|
||||
* given key.
|
||||
*/
|
||||
#ifndef PLATFORM_FREEBSD /* Baron */
|
||||
#if defined(CONFIG_TDLS)
|
||||
static void sha256_prf(u8 *key, size_t key_len, char *label,
|
||||
u8 *data, size_t data_len, u8 *buf, size_t buf_len)
|
||||
@ -2459,7 +2456,6 @@ static void sha256_prf(u8 *key, size_t key_len, char *label,
|
||||
}
|
||||
}
|
||||
#endif
|
||||
#endif /* PLATFORM_FREEBSD Baron */
|
||||
|
||||
/* AES tables*/
|
||||
const u32 Te0[256] = {
|
||||
@ -2638,7 +2634,6 @@ const u8 rcons[] = {
|
||||
*
|
||||
* @return the number of rounds for the given cipher key size.
|
||||
*/
|
||||
#ifndef PLATFORM_FREEBSD /* Baron */
|
||||
static void rijndaelKeySetupEnc(u32 rk[/*44*/], const u8 cipherKey[])
|
||||
{
|
||||
int i;
|
||||
@ -2855,7 +2850,6 @@ int omac1_aes_128(const u8 *key, const u8 *data, size_t data_len, u8 *mac)
|
||||
{
|
||||
return omac1_aes_128_vector(key, 1, &data, &data_len, mac);
|
||||
}
|
||||
#endif /* PLATFORM_FREEBSD Baron */
|
||||
|
||||
#ifdef CONFIG_RTW_MESH_AEK
|
||||
/* for AES-SIV */
|
||||
|
@ -29,12 +29,6 @@ int usb_init_recv_priv(_adapter *padapter, u16 ini_in_buf_sz)
|
||||
(unsigned long)padapter);
|
||||
#endif /* PLATFORM_LINUX */
|
||||
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
#ifdef CONFIG_RX_INDICATE_QUEUE
|
||||
TASK_INIT(&precvpriv->rx_indicate_tasklet, 0, rtw_rx_indicate_tasklet, padapter);
|
||||
#endif /* CONFIG_RX_INDICATE_QUEUE */
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
|
||||
#ifdef CONFIG_USB_INTERRUPT_IN_PIPE
|
||||
#ifdef PLATFORM_LINUX
|
||||
precvpriv->int_in_urb = usb_alloc_urb(0, GFP_KERNEL);
|
||||
@ -93,7 +87,6 @@ int usb_init_recv_priv(_adapter *padapter, u16 ini_in_buf_sz)
|
||||
|
||||
precvpriv->free_recv_buf_queue_cnt = NR_RECVBUFF;
|
||||
|
||||
#if defined(PLATFORM_LINUX) || defined(PLATFORM_FREEBSD)
|
||||
|
||||
skb_queue_head_init(&precvpriv->rx_skb_queue);
|
||||
|
||||
@ -122,11 +115,6 @@ int usb_init_recv_priv(_adapter *padapter, u16 ini_in_buf_sz)
|
||||
#endif /* CONFIG_PREALLOC_RX_SKB_BUFFER */
|
||||
|
||||
if (pskb) {
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
pskb->dev = padapter->pifp;
|
||||
#else
|
||||
pskb->dev = padapter->pnetdev;
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
|
||||
#ifndef CONFIG_PREALLOC_RX_SKB_BUFFER
|
||||
tmpaddr = (SIZE_PTR)pskb->data;
|
||||
@ -139,8 +127,6 @@ int usb_init_recv_priv(_adapter *padapter, u16 ini_in_buf_sz)
|
||||
}
|
||||
#endif /* CONFIG_PREALLOC_RECV_SKB */
|
||||
|
||||
#endif /* defined(PLATFORM_LINUX) || defined(PLATFORM_FREEBSD) */
|
||||
|
||||
exit:
|
||||
|
||||
return res;
|
||||
@ -198,27 +184,6 @@ void usb_free_recv_priv(_adapter *padapter, u16 ini_in_buf_sz)
|
||||
|
||||
#endif /* PLATFORM_LINUX */
|
||||
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
struct sk_buff *pskb;
|
||||
while (NULL != (pskb = skb_dequeue(&precvpriv->rx_skb_queue)))
|
||||
rtw_skb_free(pskb);
|
||||
|
||||
#if !defined(CONFIG_USE_USB_BUFFER_ALLOC_RX)
|
||||
rtw_skb_queue_purge(&precvpriv->free_recv_skb_queue);
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_RX_INDICATE_QUEUE
|
||||
struct mbuf *m;
|
||||
for (;;) {
|
||||
IF_DEQUEUE(&precvpriv->rx_indicate_queue, m);
|
||||
if (m == NULL)
|
||||
break;
|
||||
rtw_os_pkt_free(m);
|
||||
}
|
||||
mtx_destroy(&precvpriv->rx_indicate_queue.ifq_mtx);
|
||||
#endif /* CONFIG_RX_INDICATE_QUEUE */
|
||||
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
}
|
||||
|
||||
#ifdef CONFIG_FW_C2H_REG
|
||||
|
@ -109,50 +109,6 @@ enum {
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
|
||||
typedef signed char s8;
|
||||
typedef unsigned char u8;
|
||||
|
||||
typedef signed short s16;
|
||||
typedef unsigned short u16;
|
||||
|
||||
typedef signed int s32;
|
||||
typedef unsigned int u32;
|
||||
|
||||
typedef unsigned int uint;
|
||||
typedef signed int sint;
|
||||
typedef long atomic_t;
|
||||
|
||||
typedef signed long long s64;
|
||||
typedef unsigned long long u64;
|
||||
#define IN
|
||||
#define OUT
|
||||
#define VOID void
|
||||
#define NDIS_OID uint
|
||||
#define NDIS_STATUS uint
|
||||
|
||||
#ifndef PVOID
|
||||
typedef void *PVOID;
|
||||
/* #define PVOID (void *) */
|
||||
#endif
|
||||
typedef u32 dma_addr_t;
|
||||
#define UCHAR u8
|
||||
#define USHORT u16
|
||||
#define UINT u32
|
||||
#define ULONG u32
|
||||
|
||||
typedef void (*proc_t)(void *);
|
||||
|
||||
typedef unsigned int __kernel_size_t;
|
||||
typedef int __kernel_ssize_t;
|
||||
|
||||
typedef __kernel_size_t SIZE_T;
|
||||
typedef __kernel_ssize_t SSIZE_T;
|
||||
#define FIELD_OFFSET(s, field) ((SSIZE_T)&((s *)(0))->field)
|
||||
|
||||
#endif
|
||||
|
||||
#define MEM_ALIGNMENT_OFFSET (sizeof (SIZE_T))
|
||||
#define MEM_ALIGNMENT_PADDING (sizeof(SIZE_T) - 1)
|
||||
|
||||
|
@ -160,15 +160,11 @@
|
||||
extern __u32 ntohl(__u32);
|
||||
extern __u32 htonl(__u32);
|
||||
#else /* defined(PLATFORM_LINUX) || (defined (__GLIBC__) && __GLIBC__ >= 2) */
|
||||
#ifndef PLATFORM_FREEBSD
|
||||
extern unsigned long int ntohl(unsigned long int);
|
||||
extern unsigned long int htonl(unsigned long int);
|
||||
#endif
|
||||
extern unsigned long int ntohl(unsigned long int);
|
||||
extern unsigned long int htonl(unsigned long int);
|
||||
#endif
|
||||
#ifndef PLATFORM_FREEBSD
|
||||
extern unsigned short int ntohs(unsigned short int);
|
||||
extern unsigned short int htons(unsigned short int);
|
||||
#endif
|
||||
|
||||
#if defined(__GNUC__) && (__GNUC__ >= 2) && defined(__OPTIMIZE__) || defined(PLATFORM_MPIXEL)
|
||||
|
||||
|
@ -104,19 +104,11 @@ __inline static __u64 __arch__swab64(__u64 x)
|
||||
#define __swab64(x) __fswab64(x)
|
||||
#endif /* __swab16 */
|
||||
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
__inline static __u16 __fswab16(__u16 x)
|
||||
#else
|
||||
__inline static const __u16 __fswab16(__u16 x)
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
{
|
||||
return __arch__swab16(x);
|
||||
}
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
__inline static __u32 __fswab32(__u32 x)
|
||||
#else
|
||||
__inline static const __u32 __fswab32(__u32 x)
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
{
|
||||
return __arch__swab32(x);
|
||||
}
|
||||
|
@ -1151,10 +1151,6 @@ struct dvobj_priv {
|
||||
struct usb_device *pusbdev;
|
||||
#endif/* PLATFORM_LINUX */
|
||||
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
struct usb_interface *pusbintf;
|
||||
struct usb_device *pusbdev;
|
||||
#endif/* PLATFORM_FREEBSD */
|
||||
|
||||
#endif/* CONFIG_USB_HCI */
|
||||
|
||||
@ -1521,11 +1517,6 @@ struct _ADAPTER {
|
||||
|
||||
#endif /* PLATFORM_LINUX */
|
||||
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
_nic_hdl pifp;
|
||||
int bup;
|
||||
_lock glock;
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
u8 mac_addr[ETH_ALEN];
|
||||
int net_closed;
|
||||
|
||||
|
@ -423,7 +423,6 @@ struct ieee_ibss_seq {
|
||||
_list list;
|
||||
};
|
||||
|
||||
#if defined(PLATFORM_LINUX) || defined(CONFIG_RTL8711FW) || defined(PLATFORM_FREEBSD)
|
||||
|
||||
struct rtw_ieee80211_hdr {
|
||||
u16 frame_ctl;
|
||||
@ -496,7 +495,6 @@ struct rtw_ieee80211s_hdr {
|
||||
u32 rann_interval;
|
||||
u32 rann_metric;
|
||||
} __attribute__((packed));
|
||||
#endif
|
||||
|
||||
enum eap_type {
|
||||
EAP_PACKET = 0,
|
||||
@ -606,7 +604,6 @@ enum eap_type {
|
||||
|
||||
#define P80211_OUI_LEN 3
|
||||
|
||||
#if defined(PLATFORM_LINUX) || defined(CONFIG_RTL8711FW) || defined(PLATFORM_FREEBSD)
|
||||
|
||||
struct ieee80211_snap_hdr {
|
||||
|
||||
@ -617,8 +614,6 @@ struct ieee80211_snap_hdr {
|
||||
|
||||
} __attribute__((packed));
|
||||
|
||||
#endif
|
||||
|
||||
#define SNAP_SIZE sizeof(struct ieee80211_snap_hdr)
|
||||
|
||||
#define WLAN_FC_GET_TYPE(fc) ((fc) & RTW_IEEE80211_FCTL_FTYPE)
|
||||
@ -1001,7 +996,6 @@ struct ieee80211_frag_entry {
|
||||
u8 dst_addr[ETH_ALEN];
|
||||
};
|
||||
|
||||
#ifndef PLATFORM_FREEBSD /* Baron BSD has already defined */
|
||||
struct ieee80211_stats {
|
||||
uint tx_unicast_frames;
|
||||
uint tx_multicast_frames;
|
||||
@ -1025,7 +1019,7 @@ struct ieee80211_stats {
|
||||
uint rx_message_in_msg_fragments;
|
||||
uint rx_message_in_bad_msg_fragments;
|
||||
};
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
|
||||
struct ieee80211_softmac_stats {
|
||||
uint rx_ass_ok;
|
||||
uint rx_ass_err;
|
||||
@ -1294,8 +1288,6 @@ join_res:
|
||||
> 0: TID
|
||||
*/
|
||||
|
||||
#ifndef PLATFORM_FREEBSD /* Baron BSD has already defined */
|
||||
|
||||
enum ieee80211_state {
|
||||
|
||||
/* the card is not linked at all */
|
||||
@ -1334,7 +1326,6 @@ enum ieee80211_state {
|
||||
IEEE80211_LINKED_SCANNING,
|
||||
|
||||
};
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
|
||||
#define DEFAULT_MAX_SCAN_AGE (15 * HZ)
|
||||
#define DEFAULT_FTS 2346
|
||||
@ -1347,12 +1338,6 @@ enum ieee80211_state {
|
||||
#define PORT_FMT "%u"
|
||||
#define PORT_ARG(x) ntohs(*((u16 *)(x)))
|
||||
|
||||
#ifdef PLATFORM_FREEBSD /* Baron change func to macro */
|
||||
#define is_multicast_mac_addr(Addr) ((((Addr[0]) & 0x01) == 0x01) && ((Addr[0]) != 0xff))
|
||||
#define is_broadcast_mac_addr(Addr) ((((Addr[0]) & 0xff) == 0xff) && (((Addr[1]) & 0xff) == 0xff) && \
|
||||
(((Addr[2]) & 0xff) == 0xff) && (((Addr[3]) & 0xff) == 0xff) && (((Addr[4]) & 0xff) == 0xff) && \
|
||||
(((Addr[5]) & 0xff) == 0xff))
|
||||
#else
|
||||
extern __inline int is_multicast_mac_addr(const u8 *addr)
|
||||
{
|
||||
return (addr[0] != 0xff) && (0x01 & addr[0]);
|
||||
@ -1369,7 +1354,6 @@ extern __inline int is_zero_mac_addr(const u8 *addr)
|
||||
return ((addr[0] == 0x00) && (addr[1] == 0x00) && (addr[2] == 0x00) && \
|
||||
(addr[3] == 0x00) && (addr[4] == 0x00) && (addr[5] == 0x00));
|
||||
}
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
|
||||
#define CFG_IEEE80211_RESERVE_FCS (1<<0)
|
||||
#define CFG_IEEE80211_COMPUTE_FCS (1<<1)
|
||||
@ -1578,9 +1562,8 @@ enum rtw_ieee80211_wnm_actioncode {
|
||||
|
||||
#define OUI_MICROSOFT 0x0050f2 /* Microsoft (also used in Wi-Fi specs)
|
||||
* 00:50:F2 */
|
||||
#ifndef PLATFORM_FREEBSD /* Baron BSD has defined */
|
||||
#define WME_OUI_TYPE 2
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
#define WME_OUI_TYPE 2
|
||||
|
||||
#define WME_OUI_SUBTYPE_INFORMATION_ELEMENT 0
|
||||
#define WME_OUI_SUBTYPE_PARAMETER_ELEMENT 1
|
||||
#define WME_OUI_SUBTYPE_TSPEC_ELEMENT 2
|
||||
|
@ -136,11 +136,6 @@ void rtw_set_rtnl_lock_holder(struct dvobj_priv *dvobj, _thread_hdl_ thd_hdl);
|
||||
|
||||
#endif /* PLATFORM_LINUX */
|
||||
|
||||
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
extern int rtw_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data);
|
||||
#endif
|
||||
|
||||
void rtw_ips_dev_unload(_adapter *padapter);
|
||||
|
||||
#ifdef CONFIG_IPS
|
||||
|
@ -36,11 +36,6 @@
|
||||
#undef _FALSE
|
||||
#define _FALSE 0
|
||||
|
||||
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
#include <osdep_service_bsd.h>
|
||||
#endif
|
||||
|
||||
#ifdef PLATFORM_LINUX
|
||||
#include <linux/version.h>
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 11, 0))
|
||||
@ -264,9 +259,7 @@ void rtw_list_splice(_list *list, _list *head);
|
||||
void rtw_list_splice_init(_list *list, _list *head);
|
||||
void rtw_list_splice_tail(_list *list, _list *head);
|
||||
|
||||
#ifndef PLATFORM_FREEBSD
|
||||
extern void rtw_list_delete(_list *plist);
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
|
||||
void rtw_hlist_head_init(rtw_hlist_head *h);
|
||||
void rtw_hlist_add_head(rtw_hlist_node *n, rtw_hlist_head *h);
|
||||
@ -280,9 +273,7 @@ extern void _rtw_up_sema(_sema *sema);
|
||||
extern u32 _rtw_down_sema(_sema *sema);
|
||||
extern void _rtw_mutex_init(_mutex *pmutex);
|
||||
extern void _rtw_mutex_free(_mutex *pmutex);
|
||||
#ifndef PLATFORM_FREEBSD
|
||||
extern void _rtw_spinlock_init(_lock *plock);
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
extern void _rtw_spinlock(_lock *plock);
|
||||
extern void _rtw_spinunlock(_lock *plock);
|
||||
extern void _rtw_spinlock_ex(_lock *plock);
|
||||
@ -345,9 +336,6 @@ static __inline void thread_enter(char *name)
|
||||
#ifdef PLATFORM_LINUX
|
||||
allow_signal(SIGTERM);
|
||||
#endif
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
printf("%s", "RTKTHREAD_enter");
|
||||
#endif
|
||||
}
|
||||
void thread_exit(_completion *comp);
|
||||
void _rtw_init_completion(_completion *comp);
|
||||
@ -387,10 +375,7 @@ __inline static void flush_signals_thread(void)
|
||||
|
||||
__inline static _OS_STATUS res_to_status(sint res)
|
||||
{
|
||||
|
||||
#if defined(PLATFORM_LINUX) || defined (PLATFORM_MPIXEL) || defined (PLATFORM_FREEBSD)
|
||||
return res;
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
@ -537,12 +522,7 @@ extern int rtw_is_file_readable_with_size(const char *path, u32 *sz);
|
||||
extern int rtw_retrieve_from_file(const char *path, u8 *buf, u32 sz);
|
||||
extern int rtw_store_to_file(const char *path, u8 *buf, u32 sz);
|
||||
|
||||
|
||||
#ifndef PLATFORM_FREEBSD
|
||||
extern void rtw_free_netdev(struct net_device *netdev);
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
|
||||
|
||||
extern u64 rtw_division64(u64 x, u64 y);
|
||||
extern u32 rtw_random32(void);
|
||||
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -64,12 +64,6 @@ extern void rtl871x_cedbg(const char *fmt, ...);
|
||||
#define KERN_CONT
|
||||
#endif
|
||||
#define _seqdump seq_printf
|
||||
#elif defined PLATFORM_FREEBSD
|
||||
#define _dbgdump printf
|
||||
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 24))
|
||||
#define KERN_CONT
|
||||
#endif
|
||||
#define _seqdump(sel, fmt, arg...) _dbgdump(fmt, ##arg)
|
||||
#endif
|
||||
|
||||
void RTW_BUF_DUMP_SEL(uint _loglevel, void *sel, u8 *_titlestring,
|
||||
|
@ -388,14 +388,9 @@ struct recv_priv {
|
||||
#endif /* CONFIG_USB_INTERRUPT_IN_PIPE */
|
||||
|
||||
#endif
|
||||
#if defined(PLATFORM_LINUX) || defined(PLATFORM_FREEBSD)
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
struct task irq_prepare_beacon_tasklet;
|
||||
struct task recv_tasklet;
|
||||
#else /* PLATFORM_FREEBSD */
|
||||
struct tasklet_struct irq_prepare_beacon_tasklet;
|
||||
struct tasklet_struct recv_tasklet;
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
struct tasklet_struct irq_prepare_beacon_tasklet;
|
||||
struct tasklet_struct recv_tasklet;
|
||||
|
||||
struct sk_buff_head free_recv_skb_queue;
|
||||
struct sk_buff_head rx_skb_queue;
|
||||
#ifdef CONFIG_RTW_NAPI
|
||||
@ -406,8 +401,6 @@ struct recv_priv {
|
||||
struct ifqueue rx_indicate_queue;
|
||||
#endif /* CONFIG_RX_INDICATE_QUEUE */
|
||||
|
||||
#endif /* defined(PLATFORM_LINUX) || defined(PLATFORM_FREEBSD) */
|
||||
|
||||
u8 *pallocated_recv_buf;
|
||||
u8 *precv_buf; /* 4 alignment */
|
||||
_queue free_recv_buf_queue;
|
||||
@ -521,11 +514,9 @@ struct recv_buf {
|
||||
|
||||
#ifdef CONFIG_USB_HCI
|
||||
|
||||
#if defined(PLATFORM_OS_XP) || defined(PLATFORM_LINUX) || defined(PLATFORM_FREEBSD)
|
||||
PURB purb;
|
||||
dma_addr_t dma_transfer_addr; /* (in) dma addr for transfer_buffer */
|
||||
u32 alloc_sz;
|
||||
#endif
|
||||
PURB purb;
|
||||
dma_addr_t dma_transfer_addr; /* (in) dma addr for transfer_buffer */
|
||||
u32 alloc_sz;
|
||||
|
||||
#ifdef PLATFORM_OS_XP
|
||||
PIRP pirp;
|
||||
@ -542,8 +533,6 @@ struct recv_buf {
|
||||
|
||||
#if defined(PLATFORM_LINUX)
|
||||
_pkt *pskb;
|
||||
#elif defined(PLATFORM_FREEBSD) /* skb solution */
|
||||
struct sk_buff *pskb;
|
||||
#endif
|
||||
};
|
||||
|
||||
|
@ -597,10 +597,8 @@ struct xmit_buf {
|
||||
u8 bulkout_id; /* for halmac */
|
||||
#endif /* RTW_HALMAC */
|
||||
|
||||
#if defined(PLATFORM_OS_XP) || defined(PLATFORM_LINUX) || defined(PLATFORM_FREEBSD)
|
||||
PURB pxmit_urb[8];
|
||||
dma_addr_t dma_transfer_addr; /* (in) dma addr for transfer_buffer */
|
||||
#endif
|
||||
|
||||
#ifdef PLATFORM_OS_XP
|
||||
PIRP pxmit_irp[8];
|
||||
@ -801,9 +799,6 @@ struct xmit_priv {
|
||||
#endif
|
||||
#ifdef PLATFORM_LINUX
|
||||
struct tasklet_struct xmit_tasklet;
|
||||
#endif
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
struct task xmit_tasklet;
|
||||
#endif
|
||||
/* per AC pending irp */
|
||||
int beq_cnt;
|
||||
|
@ -711,10 +711,6 @@ struct rtw_ieee80211_bar {
|
||||
} __attribute__((packed));
|
||||
#endif
|
||||
|
||||
#if defined(PLATFORM_LINUX) || defined(CONFIG_RTL8712FW) || defined(PLATFORM_FREEBSD)
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* struct rtw_ieee80211_ht_cap - HT capabilities
|
||||
*
|
||||
@ -786,11 +782,6 @@ struct ADDBA_request {
|
||||
unsigned short BA_starting_seqctrl;
|
||||
} __attribute__((packed));
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
typedef enum _HT_CAP_AMPDU_FACTOR {
|
||||
MAX_AMPDU_FACTOR_8K = 0,
|
||||
MAX_AMPDU_FACTOR_16K = 1,
|
||||
|
@ -269,251 +269,6 @@ typedef struct _NDIS_802_11_TEST {
|
||||
|
||||
#endif /* end of #ifdef PLATFORM_LINUX */
|
||||
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
|
||||
#define NDIS_802_11_LENGTH_SSID 32
|
||||
#define NDIS_802_11_LENGTH_RATES 8
|
||||
#define NDIS_802_11_LENGTH_RATES_EX 16
|
||||
|
||||
typedef unsigned char NDIS_802_11_MAC_ADDRESS[ETH_ALEN];
|
||||
typedef long NDIS_802_11_RSSI; /* in dBm */
|
||||
typedef unsigned char NDIS_802_11_RATES[NDIS_802_11_LENGTH_RATES]; /* Set of 8 data rates */
|
||||
typedef unsigned char NDIS_802_11_RATES_EX[NDIS_802_11_LENGTH_RATES_EX]; /* Set of 16 data rates */
|
||||
|
||||
|
||||
typedef ULONG NDIS_802_11_KEY_INDEX;
|
||||
typedef unsigned long long NDIS_802_11_KEY_RSC;
|
||||
|
||||
|
||||
typedef struct _NDIS_802_11_SSID {
|
||||
ULONG SsidLength;
|
||||
UCHAR Ssid[32];
|
||||
} NDIS_802_11_SSID, *PNDIS_802_11_SSID;
|
||||
|
||||
typedef enum _NDIS_802_11_NETWORK_TYPE {
|
||||
Ndis802_11FH,
|
||||
Ndis802_11DS,
|
||||
Ndis802_11OFDM5,
|
||||
Ndis802_11OFDM24,
|
||||
Ndis802_11NetworkTypeMax /* not a real type, defined as an upper bound */
|
||||
} NDIS_802_11_NETWORK_TYPE, *PNDIS_802_11_NETWORK_TYPE;
|
||||
|
||||
typedef struct _NDIS_802_11_CONFIGURATION_FH {
|
||||
ULONG Length; /* Length of structure */
|
||||
ULONG HopPattern; /* As defined by 802.11, MSB set */
|
||||
ULONG HopSet; /* to one if non-802.11 */
|
||||
ULONG DwellTime; /* units are Kusec */
|
||||
} NDIS_802_11_CONFIGURATION_FH, *PNDIS_802_11_CONFIGURATION_FH;
|
||||
|
||||
|
||||
/*
|
||||
FW will only save the channel number in DSConfig.
|
||||
ODI Handler will convert the channel number to freq. number.
|
||||
*/
|
||||
typedef struct _NDIS_802_11_CONFIGURATION {
|
||||
ULONG Length; /* Length of structure */
|
||||
ULONG BeaconPeriod; /* units are Kusec */
|
||||
ULONG ATIMWindow; /* units are Kusec */
|
||||
ULONG DSConfig; /* channel number */
|
||||
NDIS_802_11_CONFIGURATION_FH FHConfig;
|
||||
} NDIS_802_11_CONFIGURATION, *PNDIS_802_11_CONFIGURATION;
|
||||
|
||||
|
||||
|
||||
typedef enum _NDIS_802_11_NETWORK_INFRASTRUCTURE {
|
||||
Ndis802_11IBSS,
|
||||
Ndis802_11Infrastructure,
|
||||
Ndis802_11AutoUnknown,
|
||||
Ndis802_11InfrastructureMax, /* Not a real value, defined as upper bound */
|
||||
Ndis802_11APMode
|
||||
} NDIS_802_11_NETWORK_INFRASTRUCTURE, *PNDIS_802_11_NETWORK_INFRASTRUCTURE;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
typedef struct _NDIS_802_11_FIXED_IEs {
|
||||
UCHAR Timestamp[8];
|
||||
USHORT BeaconInterval;
|
||||
USHORT Capabilities;
|
||||
} NDIS_802_11_FIXED_IEs, *PNDIS_802_11_FIXED_IEs;
|
||||
|
||||
|
||||
|
||||
typedef struct _NDIS_802_11_VARIABLE_IEs {
|
||||
UCHAR ElementID;
|
||||
UCHAR Length;
|
||||
UCHAR data[1];
|
||||
} NDIS_802_11_VARIABLE_IEs, *PNDIS_802_11_VARIABLE_IEs;
|
||||
|
||||
|
||||
|
||||
/*
|
||||
|
||||
|
||||
|
||||
Length is the 4 bytes multiples of the sume of
|
||||
sizeof (NDIS_802_11_MAC_ADDRESS) + 2 + sizeof (NDIS_802_11_SSID) + sizeof (ULONG)
|
||||
+ sizeof (NDIS_802_11_RSSI) + sizeof (NDIS_802_11_NETWORK_TYPE) + sizeof (NDIS_802_11_CONFIGURATION)
|
||||
+ sizeof (NDIS_802_11_RATES_EX) + IELength
|
||||
|
||||
Except the IELength, all other fields are fixed length. Therefore, we can define a marco to present the
|
||||
partial sum.
|
||||
|
||||
*/
|
||||
#if 0
|
||||
typedef struct _NDIS_WLAN_BSSID_EX {
|
||||
ULONG Length;
|
||||
NDIS_802_11_MAC_ADDRESS MacAddress;
|
||||
UCHAR Reserved[2];/* [0]: IS beacon frame, [1]:optimum_antenna=>For antenna diversity; */
|
||||
NDIS_802_11_SSID Ssid;
|
||||
ULONG Privacy;
|
||||
NDIS_802_11_RSSI Rssi;
|
||||
NDIS_802_11_NETWORK_TYPE NetworkTypeInUse;
|
||||
NDIS_802_11_CONFIGURATION Configuration;
|
||||
NDIS_802_11_NETWORK_INFRASTRUCTURE InfrastructureMode;
|
||||
NDIS_802_11_RATES_EX SupportedRates;
|
||||
ULONG IELength;
|
||||
UCHAR IEs[MAX_IE_SZ]; /* (timestamp, beacon interval, and capability information) */
|
||||
} NDIS_WLAN_BSSID_EX, *PNDIS_WLAN_BSSID_EX;
|
||||
|
||||
|
||||
typedef struct _NDIS_802_11_BSSID_LIST_EX {
|
||||
ULONG NumberOfItems;
|
||||
NDIS_WLAN_BSSID_EX Bssid[1];
|
||||
} NDIS_802_11_BSSID_LIST_EX, *PNDIS_802_11_BSSID_LIST_EX;
|
||||
#endif
|
||||
|
||||
typedef enum _NDIS_802_11_AUTHENTICATION_MODE {
|
||||
Ndis802_11AuthModeOpen,
|
||||
Ndis802_11AuthModeShared,
|
||||
Ndis802_11AuthModeAutoSwitch,
|
||||
Ndis802_11AuthModeWPA,
|
||||
Ndis802_11AuthModeWPAPSK,
|
||||
Ndis802_11AuthModeWPANone,
|
||||
Ndis802_11AuthModeMax /* Not a real mode, defined as upper bound */
|
||||
} NDIS_802_11_AUTHENTICATION_MODE, *PNDIS_802_11_AUTHENTICATION_MODE;
|
||||
|
||||
typedef enum _NDIS_802_11_WEP_STATUS {
|
||||
Ndis802_11WEPEnabled,
|
||||
Ndis802_11Encryption1Enabled = Ndis802_11WEPEnabled,
|
||||
Ndis802_11WEPDisabled,
|
||||
Ndis802_11EncryptionDisabled = Ndis802_11WEPDisabled,
|
||||
Ndis802_11WEPKeyAbsent,
|
||||
Ndis802_11Encryption1KeyAbsent = Ndis802_11WEPKeyAbsent,
|
||||
Ndis802_11WEPNotSupported,
|
||||
Ndis802_11EncryptionNotSupported = Ndis802_11WEPNotSupported,
|
||||
Ndis802_11Encryption2Enabled,
|
||||
Ndis802_11Encryption2KeyAbsent,
|
||||
Ndis802_11Encryption3Enabled,
|
||||
Ndis802_11Encryption3KeyAbsent
|
||||
} NDIS_802_11_WEP_STATUS, *PNDIS_802_11_WEP_STATUS,
|
||||
NDIS_802_11_ENCRYPTION_STATUS, *PNDIS_802_11_ENCRYPTION_STATUS;
|
||||
|
||||
|
||||
#define NDIS_802_11_AI_REQFI_CAPABILITIES 1
|
||||
#define NDIS_802_11_AI_REQFI_LISTENINTERVAL 2
|
||||
#define NDIS_802_11_AI_REQFI_CURRENTAPADDRESS 4
|
||||
|
||||
#define NDIS_802_11_AI_RESFI_CAPABILITIES 1
|
||||
#define NDIS_802_11_AI_RESFI_STATUSCODE 2
|
||||
#define NDIS_802_11_AI_RESFI_ASSOCIATIONID 4
|
||||
|
||||
typedef struct _NDIS_802_11_AI_REQFI {
|
||||
USHORT Capabilities;
|
||||
USHORT ListenInterval;
|
||||
NDIS_802_11_MAC_ADDRESS CurrentAPAddress;
|
||||
} NDIS_802_11_AI_REQFI, *PNDIS_802_11_AI_REQFI;
|
||||
|
||||
typedef struct _NDIS_802_11_AI_RESFI {
|
||||
USHORT Capabilities;
|
||||
USHORT StatusCode;
|
||||
USHORT AssociationId;
|
||||
} NDIS_802_11_AI_RESFI, *PNDIS_802_11_AI_RESFI;
|
||||
|
||||
typedef struct _NDIS_802_11_ASSOCIATION_INFORMATION {
|
||||
ULONG Length;
|
||||
USHORT AvailableRequestFixedIEs;
|
||||
NDIS_802_11_AI_REQFI RequestFixedIEs;
|
||||
ULONG RequestIELength;
|
||||
ULONG OffsetRequestIEs;
|
||||
USHORT AvailableResponseFixedIEs;
|
||||
NDIS_802_11_AI_RESFI ResponseFixedIEs;
|
||||
ULONG ResponseIELength;
|
||||
ULONG OffsetResponseIEs;
|
||||
} NDIS_802_11_ASSOCIATION_INFORMATION, *PNDIS_802_11_ASSOCIATION_INFORMATION;
|
||||
|
||||
typedef enum _NDIS_802_11_RELOAD_DEFAULTS {
|
||||
Ndis802_11ReloadWEPKeys
|
||||
} NDIS_802_11_RELOAD_DEFAULTS, *PNDIS_802_11_RELOAD_DEFAULTS;
|
||||
|
||||
|
||||
/* Key mapping keys require a BSSID */
|
||||
typedef struct _NDIS_802_11_KEY {
|
||||
ULONG Length; /* Length of this structure */
|
||||
ULONG KeyIndex;
|
||||
ULONG KeyLength; /* length of key in bytes */
|
||||
NDIS_802_11_MAC_ADDRESS BSSID;
|
||||
NDIS_802_11_KEY_RSC KeyRSC;
|
||||
UCHAR KeyMaterial[32]; /* variable length depending on above field */
|
||||
} NDIS_802_11_KEY, *PNDIS_802_11_KEY;
|
||||
|
||||
typedef struct _NDIS_802_11_REMOVE_KEY {
|
||||
ULONG Length; /* Length of this structure */
|
||||
ULONG KeyIndex;
|
||||
NDIS_802_11_MAC_ADDRESS BSSID;
|
||||
} NDIS_802_11_REMOVE_KEY, *PNDIS_802_11_REMOVE_KEY;
|
||||
|
||||
typedef struct _NDIS_802_11_WEP {
|
||||
ULONG Length; /* Length of this structure */
|
||||
ULONG KeyIndex; /* 0 is the per-client key, 1-N are the global keys */
|
||||
ULONG KeyLength; /* length of key in bytes */
|
||||
UCHAR KeyMaterial[16];/* variable length depending on above field */
|
||||
} NDIS_802_11_WEP, *PNDIS_802_11_WEP;
|
||||
|
||||
typedef struct _NDIS_802_11_AUTHENTICATION_REQUEST {
|
||||
ULONG Length; /* Length of structure */
|
||||
NDIS_802_11_MAC_ADDRESS Bssid;
|
||||
ULONG Flags;
|
||||
} NDIS_802_11_AUTHENTICATION_REQUEST, *PNDIS_802_11_AUTHENTICATION_REQUEST;
|
||||
|
||||
typedef enum _NDIS_802_11_STATUS_TYPE {
|
||||
Ndis802_11StatusType_Authentication,
|
||||
Ndis802_11StatusType_MediaStreamMode,
|
||||
Ndis802_11StatusType_PMKID_CandidateList,
|
||||
Ndis802_11StatusTypeMax /* not a real type, defined as an upper bound */
|
||||
} NDIS_802_11_STATUS_TYPE, *PNDIS_802_11_STATUS_TYPE;
|
||||
|
||||
typedef struct _NDIS_802_11_STATUS_INDICATION {
|
||||
NDIS_802_11_STATUS_TYPE StatusType;
|
||||
} NDIS_802_11_STATUS_INDICATION, *PNDIS_802_11_STATUS_INDICATION;
|
||||
|
||||
/* mask for authentication/integrity fields */
|
||||
#define NDIS_802_11_AUTH_REQUEST_AUTH_FIELDS 0x0f
|
||||
#define NDIS_802_11_AUTH_REQUEST_REAUTH 0x01
|
||||
#define NDIS_802_11_AUTH_REQUEST_KEYUPDATE 0x02
|
||||
#define NDIS_802_11_AUTH_REQUEST_PAIRWISE_ERROR 0x06
|
||||
#define NDIS_802_11_AUTH_REQUEST_GROUP_ERROR 0x0E
|
||||
|
||||
/* MIC check time, 60 seconds. */
|
||||
#define MIC_CHECK_TIME 60000000
|
||||
|
||||
typedef struct _NDIS_802_11_AUTHENTICATION_EVENT {
|
||||
NDIS_802_11_STATUS_INDICATION Status;
|
||||
NDIS_802_11_AUTHENTICATION_REQUEST Request[1];
|
||||
} NDIS_802_11_AUTHENTICATION_EVENT, *PNDIS_802_11_AUTHENTICATION_EVENT;
|
||||
|
||||
typedef struct _NDIS_802_11_TEST {
|
||||
ULONG Length;
|
||||
ULONG Type;
|
||||
union {
|
||||
NDIS_802_11_AUTHENTICATION_EVENT AuthenticationEvent;
|
||||
NDIS_802_11_RSSI RssiTrigger;
|
||||
} tt;
|
||||
} NDIS_802_11_TEST, *PNDIS_802_11_TEST;
|
||||
|
||||
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
#ifndef Ndis802_11APMode
|
||||
#define Ndis802_11APMode (Ndis802_11InfrastructureMax+1)
|
||||
#endif
|
||||
|
@ -26,12 +26,6 @@ struct pkt_file {
|
||||
};
|
||||
|
||||
|
||||
#ifdef PLATFORM_FREEBSD
|
||||
#define NR_XMITFRAME 256
|
||||
extern int rtw_xmit_entry(_pkt *pkt, _nic_hdl pnetdev);
|
||||
extern void rtw_xmit_entry_wrap(struct ifnet *pifp);
|
||||
#endif /* PLATFORM_FREEBSD */
|
||||
|
||||
#ifdef PLATFORM_LINUX
|
||||
|
||||
#define NR_XMITFRAME 256
|
||||
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user