#include <linux/compiler.h>
#include <linux/errno.h>
#include <linux/if_arp.h>
#include <linux/in6.h>
#include <linux/in.h>
#include <linux/ip.h>
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/netdevice.h>
#include <linux/pci.h>
#include <linux/proc_fs.h>
#include <linux/skbuff.h>
#include <linux/slab.h>
#include <linux/tcp.h>
#include <linux/types.h>
#include <linux/wireless.h>
#include <linux/etherdevice.h>
#include <linux/uaccess.h>
#include <linux/ctype.h>
#include "rtllib.h"
static void rtllib_rx_mgt(struct rtllib_device *ieee, struct sk_buff *skb,
struct rtllib_rx_stats *stats);
static inline void rtllib_monitor_rx(struct rtllib_device *ieee,
struct sk_buff *skb,
struct rtllib_rx_stats *rx_status,
size_t hdr_length)
{ … }
static struct rtllib_frag_entry *
rtllib_frag_cache_find(struct rtllib_device *ieee, unsigned int seq,
unsigned int frag, u8 tid, u8 *src, u8 *dst)
{ … }
static struct sk_buff *
rtllib_frag_cache_get(struct rtllib_device *ieee,
struct ieee80211_hdr *hdr)
{ … }
static int rtllib_frag_cache_invalidate(struct rtllib_device *ieee,
struct ieee80211_hdr *hdr)
{ … }
static inline int
rtllib_rx_frame_mgmt(struct rtllib_device *ieee, struct sk_buff *skb,
struct rtllib_rx_stats *rx_stats, u16 type, u16 stype)
{ … }
static int rtllib_is_eapol_frame(struct rtllib_device *ieee,
struct sk_buff *skb, size_t hdrlen)
{ … }
static inline int
rtllib_rx_frame_decrypt(struct rtllib_device *ieee, struct sk_buff *skb,
struct lib80211_crypt_data *crypt)
{ … }
static inline int
rtllib_rx_frame_decrypt_msdu(struct rtllib_device *ieee, struct sk_buff *skb,
int keyidx, struct lib80211_crypt_data *crypt)
{ … }
#define IEEE_PACKET_RETRY_TIME …
static int is_duplicate_packet(struct rtllib_device *ieee,
struct ieee80211_hdr *header)
{ … }
static bool add_reorder_entry(struct rx_ts_record *ts,
struct rx_reorder_entry *pReorderEntry)
{ … }
void rtllib_indicate_packets(struct rtllib_device *ieee,
struct rtllib_rxb **prxb_indicate_array, u8 index)
{ … }
void rtllib_flush_rx_ts_pending_pkts(struct rtllib_device *ieee,
struct rx_ts_record *ts)
{ … }
static void rx_reorder_indicate_packet(struct rtllib_device *ieee,
struct rtllib_rxb *prxb,
struct rx_ts_record *ts, u16 SeqNum)
{ … }
static u8 parse_subframe(struct rtllib_device *ieee, struct sk_buff *skb,
struct rtllib_rx_stats *rx_stats,
struct rtllib_rxb *rxb, u8 *src, u8 *dst)
{ … }
static size_t rtllib_rx_get_hdrlen(struct rtllib_device *ieee,
struct sk_buff *skb,
struct rtllib_rx_stats *rx_stats)
{ … }
static int rtllib_rx_check_duplicate(struct rtllib_device *ieee,
struct sk_buff *skb, u8 multicast)
{ … }
static void rtllib_rx_extract_addr(struct rtllib_device *ieee,
struct ieee80211_hdr *hdr, u8 *dst,
u8 *src, u8 *bssid)
{ … }
static int rtllib_rx_data_filter(struct rtllib_device *ieee, struct ieee80211_hdr *hdr,
u8 *dst, u8 *src, u8 *bssid, u8 *addr2)
{ … }
static int rtllib_rx_get_crypt(struct rtllib_device *ieee, struct sk_buff *skb,
struct lib80211_crypt_data **crypt, size_t hdrlen)
{ … }
static int rtllib_rx_decrypt(struct rtllib_device *ieee, struct sk_buff *skb,
struct rtllib_rx_stats *rx_stats,
struct lib80211_crypt_data *crypt, size_t hdrlen)
{ … }
static void rtllib_rx_check_leave_lps(struct rtllib_device *ieee, u8 unicast,
u8 nr_subframes)
{ … }
static void rtllib_rx_indicate_pkt_legacy(struct rtllib_device *ieee,
struct rtllib_rx_stats *rx_stats,
struct rtllib_rxb *rxb,
u8 *dst,
u8 *src)
{ … }
static int rtllib_rx_infra_adhoc(struct rtllib_device *ieee, struct sk_buff *skb,
struct rtllib_rx_stats *rx_stats)
{ … }
static int rtllib_rx_monitor(struct rtllib_device *ieee, struct sk_buff *skb,
struct rtllib_rx_stats *rx_stats)
{ … }
int rtllib_rx(struct rtllib_device *ieee, struct sk_buff *skb,
struct rtllib_rx_stats *rx_stats)
{ … }
EXPORT_SYMBOL(…);
static u8 qos_oui[QOS_OUI_LEN] = …;
static int rtllib_verify_qos_info(struct rtllib_qos_information_element
*info_element, int sub_type)
{ … }
static int rtllib_read_qos_param_element(
struct rtllib_qos_parameter_info *element_param,
struct rtllib_info_element *info_element)
{ … }
static int rtllib_read_qos_info_element(
struct rtllib_qos_information_element *element_info,
struct rtllib_info_element *info_element)
{ … }
static int rtllib_qos_convert_ac_to_parameters(struct rtllib_qos_parameter_info *param_elm,
struct rtllib_qos_data *qos_data)
{ … }
static int rtllib_parse_qos_info_param_IE(struct rtllib_device *ieee,
struct rtllib_info_element
*info_element,
struct rtllib_network *network)
{ … }
static const char *get_info_element_string(u16 id)
{ … }
static void rtllib_parse_mife_generic(struct rtllib_device *ieee,
struct rtllib_info_element *info_element,
struct rtllib_network *network,
u16 *tmp_htcap_len,
u16 *tmp_htinfo_len)
{ … }
static void rtllib_parse_mfie_ht_cap(struct rtllib_info_element *info_element,
struct rtllib_network *network,
u16 *tmp_htcap_len)
{ … }
int rtllib_parse_info_param(struct rtllib_device *ieee,
struct rtllib_info_element *info_element,
u16 length,
struct rtllib_network *network,
struct rtllib_rx_stats *stats)
{ … }
static long rtllib_translate_todbm(u8 signal_strength_index)
{ … }
static inline int rtllib_network_init(
struct rtllib_device *ieee,
struct rtllib_probe_response *beacon,
struct rtllib_network *network,
struct rtllib_rx_stats *stats)
{ … }
static inline int is_same_network(struct rtllib_network *src,
struct rtllib_network *dst, u8 ssidbroad)
{ … }
static inline void update_network(struct rtllib_device *ieee,
struct rtllib_network *dst,
struct rtllib_network *src)
{ … }
static int is_passive_channel(struct rtllib_device *rtllib, u8 channel)
{ … }
int rtllib_legal_channel(struct rtllib_device *rtllib, u8 channel)
{ … }
EXPORT_SYMBOL(…);
static inline void rtllib_process_probe_response(
struct rtllib_device *ieee,
struct rtllib_probe_response *beacon,
struct rtllib_rx_stats *stats)
{ … }
static void rtllib_rx_mgt(struct rtllib_device *ieee,
struct sk_buff *skb,
struct rtllib_rx_stats *stats)
{ … }