Main Page | Data Structures | Directories | File List | Data Fields | Globals

hostap_hw.c File Reference

#include <linux/config.h>
#include <linux/version.h>
#include <asm/delay.h>
#include <asm/uaccess.h>
#include <linux/slab.h>
#include <linux/netdevice.h>
#include <linux/etherdevice.h>
#include <linux/proc_fs.h>
#include <linux/if_arp.h>
#include <linux/delay.h>
#include <linux/random.h>
#include <linux/wait.h>
#include <linux/sched.h>
#include <linux/rtnetlink.h>
#include "hostap_wext.h"
#include <asm/irq.h>
#include "hostap_80211.h"
#include "hostap.h"
#include "hostap_ap.h"
#include "../click_wifi/packet_anno.h"
#include "ieee80211_radiotap.h"
#include "hostap_download.c"

Include dependency graph for hostap_hw.c:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Defines

#define PUSH_PRISM   0
#define EXTRA_EVENTS_WTERR   HFA384X_EV_WTERR
#define EXTRA_EVENTS_BUS_MASTER   0
#define HFA384X_BAP0_EVENTS   (HFA384X_EV_TXEXC | HFA384X_EV_RX | HFA384X_EV_INFO | HFA384X_EV_TX)
#define HFA384X_EVENT_MASK
#define HFA384X_TX_CTRL_FLAGS   (HFA384X_TX_CTRL_802_11 | HFA384X_TX_CTRL_TX_EX | HFA384X_TX_CTRL_TX_OK)
#define HFA384X_CMD_BUSY_TIMEOUT   5000
#define HFA384X_BAP_BUSY_TIMEOUT   50000
#define HFA384X_CMD_COMPL_TIMEOUT   20000
#define HFA384X_DL_COMPL_TIMEOUT   1000000
#define HFA384X_INIT_TIMEOUT   (HZ / 2)
#define HFA384X_ALLOC_COMPL_TIMEOUT   (HZ / 20)
#define HFA384X_MAGIC   0x8A32
#define NUM_RADIOTAP_ELEMENTS   18
#define EXTRA_FID_READ_TESTS
#define ATH_RX_RADIOTAP_PRESENT
#define HOSTAP_TX_RADIOTAP_PRESENT
#define SHOW_REG(n)   p += sprintf(p, #n "=%04x\n", hfa384x_read_reg(local->dev, HFA384X_##n##_OFF))
#define ARPHRD_IEEE80211_RADIOTAP   803

Functions

 MODULE_PARM (mtu,"i")
 MODULE_PARM_DESC (mtu,"Maximum transfer unit")
 MODULE_PARM (channel, PARM_MIN_MAX"i")
 MODULE_PARM_DESC (channel,"Initial channel")
 MODULE_PARM (essid, PARM_MIN_MAX"s")
 MODULE_PARM_DESC (essid,"Host AP's ESSID")
 MODULE_PARM (iw_mode, PARM_MIN_MAX"i")
 MODULE_PARM_DESC (iw_mode,"Initial operation mode")
 MODULE_PARM (beacon_int, PARM_MIN_MAX"i")
 MODULE_PARM_DESC (beacon_int,"Beacon interval (1 = 1024 usec)")
 MODULE_PARM (dtim_period, PARM_MIN_MAX"i")
 MODULE_PARM_DESC (dtim_period,"DTIM period")
 MODULE_PARM (delayed_enable,"i")
 MODULE_PARM_DESC (delayed_enable,"Delay MAC port enable until netdevice open")
 MODULE_PARM (disable_on_close,"i")
 MODULE_PARM_DESC (disable_on_close,"Disable MAC port on netdevice close")
 MODULE_PARM (dev_template,"s")
 MODULE_PARM_DESC (dev_template,"Prefix for network device name (default: ""wlan%d)")
static void prism2_hw_reset (struct net_device *dev)
static void prism2_check_sta_fw_version (local_info_t *local)
static u16 hfa384x_read_reg (struct net_device *dev, u16 reg)
static void hfa384x_read_regs (struct net_device *dev, struct hfa384x_regs *regs)
static void __hostap_cmd_queue_free (local_info_t *local, struct hostap_cmd_queue *entry, int del_req)
static void hostap_cmd_queue_free (local_info_t *local, struct hostap_cmd_queue *entry, int del_req)
static int hfa384x_cmd_issue (struct net_device *dev, struct hostap_cmd_queue *entry)
static int hfa384x_cmd (struct net_device *dev, u16 cmd, u16 param0, u16 *param1, u16 *resp0)
static int hfa384x_cmd_callback (struct net_device *dev, u16 cmd, u16 param0, void(*callback)(struct net_device *dev, void *context, u16 resp0, u16 status), void *context)
static int hfa384x_cmd_wait (struct net_device *dev, u16 cmd, u16 param0)
static int hfa384x_cmd_no_wait (struct net_device *dev, u16 cmd, u16 param0)
static int hfa384x_wait_offset (struct net_device *dev, u16 o_off)
static int hfa384x_setup_bap (struct net_device *dev, u16 bap, u16 id, int offset)
static int hfa384x_get_rid (struct net_device *dev, u16 rid, void *buf, int len, int exact_len)
static int hfa384x_set_rid (struct net_device *dev, u16 rid, void *buf, int len)
static void hfa384x_disable_interrupts (struct net_device *dev)
static void hfa384x_enable_interrupts (struct net_device *dev)
static void hfa384x_events_no_bap0 (struct net_device *dev)
static void hfa384x_events_all (struct net_device *dev)
static void hfa384x_events_only_cmd (struct net_device *dev)
static u16 hfa384x_allocate_fid (struct net_device *dev, int len)
static int prism2_reset_port (struct net_device *dev)
static int prism2_get_version_info (struct net_device *dev, u16 rid, const char *txt)
static int prism2_setup_rids (struct net_device *dev)
static void prism2_clear_cmd_queue (local_info_t *local)
static int prism2_hw_init (struct net_device *dev, int initial)
static int prism2_hw_init2 (struct net_device *dev, int initial)
static int prism2_hw_enable (struct net_device *dev, int initial)
static int prism2_hw_config (struct net_device *dev, int initial)
static void prism2_hw_shutdown (struct net_device *dev, int no_disable)
static void prism2_schedule_reset (local_info_t *local)
static void handle_reset_queue (void *data)
static void prism2_netif_update_trans_start (struct net_device *dev)
static int prism2_get_txfid_idx (local_info_t *local)
static void prism2_transmit_cb (struct net_device *dev, void *context, u16 resp0, u16 res)
static int prism2_transmit (struct net_device *dev, int idx)
static void prism2_cmd_ev (struct net_device *dev)
static int rt_el_present (struct ieee80211_radiotap_header *th, u_int32_t element)
static int rt_check_header (struct ieee80211_radiotap_header *th, int len)
static u_int8_trt_el_offset (struct ieee80211_radiotap_header *th, u_int32_t element)
static int prism2_tx (struct sk_buff *skb, struct net_device *dev)
static int prism2_tx_80211 (struct sk_buff *skb, struct net_device *dev)
static u16 prism2_read_fid_reg (struct net_device *dev, u16 reg)
static void prism2_rx (local_info_t *local)
static void hostap_rx_skb (local_info_t *local, struct sk_buff *skb)
static void hostap_rx_tasklet (unsigned long data)
static void prism2_alloc_ev (struct net_device *dev)
static void hostap_tx_callback (local_info_t *local, struct hfa384x_tx_frame *txdesc, int ok, char *payload)
static int hostap_tx_compl_read (local_info_t *local, int error, struct hfa384x_tx_frame *txdesc, char **payload)
static void click_tx_callback (local_info_t *local, struct hfa384x_tx_frame *txdesc, int success, char *payload)
static void prism2_tx_ev (local_info_t *local)
static void hostap_sta_tx_exc_tasklet (unsigned long data)
static void prism2_txexc (local_info_t *local)
static void hostap_info_tasklet (unsigned long data)
static void prism2_info (local_info_t *local)
static void hostap_bap_tasklet (unsigned long data)
static void prism2_infdrop (struct net_device *dev)
static void prism2_ev_tick (struct net_device *dev)
static void prism2_check_magic (local_info_t *local)
static irqreturn_t prism2_interrupt (int irq, void *dev_id, struct pt_regs *regs)
static void prism2_crypt_deinit_entries (local_info_t *local, int force)
static void prism2_crypt_deinit_handler (unsigned long data)
static void hostap_passive_scan (unsigned long data)
static void hostap_tick_timer (unsigned long data)
static int prism2_registers_proc_read (char *page, char **start, off_t off, int count, int *eof, void *data)
static struct net_device * prism2_init_local_data (struct prism2_helper_functions *funcs, int card_idx)
static int prism2_init_dev (local_info_t *local)
static void prism2_free_local_data (struct net_device *dev)

Variables

static int mtu = 1500
static int channel [MAX_PARM_DEVICES] = { 3, DEF_INTS }
static char * essid [MAX_PARM_DEVICES] = { "test" }
static int iw_mode [MAX_PARM_DEVICES] = { IW_MODE_MASTER, DEF_INTS }
static int beacon_int [MAX_PARM_DEVICES] = { 100, DEF_INTS }
static int dtim_period [MAX_PARM_DEVICES] = { 1, DEF_INTS }
static int delayed_enable
static int disable_on_close
static char * dev_template = "wlan%d"
static int radiotap_elem_to_bytes [NUM_RADIOTAP_ELEMENTS]


Define Documentation

#define ARPHRD_IEEE80211_RADIOTAP   803
 

Definition at line 3496 of file hostap_hw.c.

Referenced by prism2_init_local_data().

#define ATH_RX_RADIOTAP_PRESENT
 

Value:

Definition at line 2384 of file hostap_hw.c.

Referenced by hostap_rx_skb().

#define EXTRA_EVENTS_BUS_MASTER   0
 

Definition at line 138 of file hostap_hw.c.

#define EXTRA_EVENTS_WTERR   HFA384X_EV_WTERR
 

Definition at line 132 of file hostap_hw.c.

#define EXTRA_FID_READ_TESTS
 

Definition at line 2198 of file hostap_hw.c.

#define HFA384X_ALLOC_COMPL_TIMEOUT   (HZ / 20)
 

Definition at line 170 of file hostap_hw.c.

Referenced by hfa384x_allocate_fid().

#define HFA384X_BAP0_EVENTS   (HFA384X_EV_TXEXC | HFA384X_EV_RX | HFA384X_EV_INFO | HFA384X_EV_TX)
 

Definition at line 142 of file hostap_hw.c.

Referenced by hfa384x_events_no_bap0(), hostap_bap_tasklet(), prism2_ev_tick(), and prism2_interrupt().

#define HFA384X_BAP_BUSY_TIMEOUT   50000
 

Definition at line 161 of file hostap_hw.c.

Referenced by hfa384x_wait_offset().

#define HFA384X_CMD_BUSY_TIMEOUT   5000
 

Definition at line 160 of file hostap_hw.c.

Referenced by hfa384x_cmd_issue(), hfa384x_cmd_no_wait(), hfa384x_cmd_wait(), and prism2_enable_aux_port().

#define HFA384X_CMD_COMPL_TIMEOUT   20000
 

Definition at line 164 of file hostap_hw.c.

Referenced by hfa384x_cmd_wait().

#define HFA384X_DL_COMPL_TIMEOUT   1000000
 

Definition at line 165 of file hostap_hw.c.

Referenced by hfa384x_cmd_wait().

#define HFA384X_EVENT_MASK
 

Value:

Definition at line 146 of file hostap_hw.c.

Referenced by hfa384x_enable_interrupts(), hfa384x_events_all(), hfa384x_events_no_bap0(), and prism2_interrupt().

#define HFA384X_INIT_TIMEOUT   (HZ / 2)
 

Definition at line 169 of file hostap_hw.c.

Referenced by prism2_hw_init().

#define HFA384X_MAGIC   0x8A32
 

Definition at line 194 of file hostap_hw.c.

Referenced by prism2_check_magic(), and prism2_hw_init2().

#define HFA384X_TX_CTRL_FLAGS   (HFA384X_TX_CTRL_802_11 | HFA384X_TX_CTRL_TX_EX | HFA384X_TX_CTRL_TX_OK)
 

Definition at line 155 of file hostap_hw.c.

Referenced by prism2_init_local_data().

#define HOSTAP_TX_RADIOTAP_PRESENT
 

Value:

Definition at line 2648 of file hostap_hw.c.

Referenced by click_tx_callback().

#define NUM_RADIOTAP_ELEMENTS   18
 

Definition at line 1713 of file hostap_hw.c.

Referenced by rt_check_header(), rt_el_offset(), and rt_el_present().

#define PUSH_PRISM   0
 

Definition at line 65 of file hostap_hw.c.

Referenced by click_tx_callback().

#define SHOW_REG  )    p += sprintf(p, #n "=%04x\n", hfa384x_read_reg(local->dev, HFA384X_##n##_OFF))
 

Referenced by prism2_registers_proc_read().


Function Documentation

static void __hostap_cmd_queue_free local_info_t * local,
struct hostap_cmd_queue * entry,
int del_req
[inline, static]
 

Definition at line 218 of file hostap_hw.c.

References list_del_init().

Referenced by hostap_cmd_queue_free(), prism2_clear_cmd_queue(), and prism2_cmd_ev().

Here is the call graph for this function:

static void click_tx_callback local_info_t * local,
struct hfa384x_tx_frametxdesc,
int success,
char * payload
[static]
 

Definition at line 2672 of file hostap_hw.c.

References hostap_80211_get_hdrlen(), HOSTAP_TX_RADIOTAP_PRESENT, IEEE80211_RADIOTAP_F_TX_FAIL, ieee80211_radiotap_header::it_len, ieee80211_radiotap_header::it_present, ieee80211_radiotap_header::it_version, PUSH_PRISM, push_prism2_header(), hostap_tx_radiotap_header::wt_antenna, hostap_tx_radiotap_header::wt_data_retries, hostap_tx_radiotap_header::wt_flags, hostap_tx_radiotap_header::wt_ihdr, hostap_tx_radiotap_header::wt_rate, hostap_tx_radiotap_header::wt_rts_retries, hostap_tx_radiotap_header::wt_tx_flags, and hostap_tx_radiotap_header::wt_txpower.

Referenced by prism2_tx_ev(), and prism2_txexc().

Here is the call graph for this function:

static void handle_reset_queue void * data  ) [static]
 

Definition at line 1431 of file hostap_hw.c.

References hostap_netif_wake_queues(), and prism2_hw_reset().

Referenced by prism2_init_local_data().

Here is the call graph for this function:

static u16 hfa384x_allocate_fid struct net_device * dev,
int len
[static]
 

Definition at line 805 of file hostap_hw.c.

References HFA384X_ALLOC_COMPL_TIMEOUT, hfa384x_cmd_wait(), HFA384X_CMDCODE_ALLOC, HFA384X_EV_ALLOC, HFA384X_INW, HFA384X_OUTW, and yield.

Referenced by prism2_hw_init2().

Here is the call graph for this function:

static int hfa384x_cmd struct net_device * dev,
u16 cmd,
u16 param0,
u16 * param1,
u16 * resp0
[static]
 

Definition at line 298 of file hostap_hw.c.

References hfa384x_cmd_issue(), HFA384X_EV_CMD, HFA384X_INW, hostap_cmd_queue_free(), and list_del_init().

Referenced by hfa384x_get_rid(), hfa384x_set_rid(), prism2_hw_enable(), prism2_hw_shutdown(), prism2_init_local_data(), and prism2_reset_port().

Here is the call graph for this function:

static int hfa384x_cmd_callback struct net_device * dev,
u16 cmd,
u16 param0,
void(*)(struct net_device *dev, void *context, u16 resp0, u16 status) callback,
void * context
[static]
 

Definition at line 461 of file hostap_hw.c.

References hfa384x_cmd_issue(), and hostap_cmd_queue_free().

Referenced by hostap_passive_scan(), hostap_tick_timer(), prism2_infdrop(), prism2_transmit(), and prism2_tx().

Here is the call graph for this function:

static int hfa384x_cmd_issue struct net_device * dev,
struct hostap_cmd_queue * entry
[inline, static]
 

Definition at line 246 of file hostap_hw.c.

References HFA384X_CMD_BUSY, HFA384X_CMD_BUSY_TIMEOUT, HFA384X_INW, and HFA384X_OUTW.

Referenced by hfa384x_cmd(), hfa384x_cmd_callback(), and prism2_cmd_ev().

static int hfa384x_cmd_no_wait struct net_device * dev,
u16 cmd,
u16 param0
[static]
 

Definition at line 572 of file hostap_hw.c.

References HFA384X_CMD_BUSY, HFA384X_CMD_BUSY_TIMEOUT, HFA384X_INW, and HFA384X_OUTW.

Referenced by prism2_download_volatile(), and prism2_hw_init().

static int hfa384x_cmd_wait struct net_device * dev,
u16 cmd,
u16 param0
[static]
 

Definition at line 513 of file hostap_hw.c.

References BIT, HFA384X_CMD_BUSY, HFA384X_CMD_BUSY_TIMEOUT, HFA384X_CMD_COMPL_TIMEOUT, HFA384X_CMDCODE_DOWNLOAD, HFA384X_CMDCODE_MASK, HFA384X_DL_COMPL_TIMEOUT, HFA384X_EV_CMD, HFA384X_INW, and HFA384X_OUTW.

Referenced by hfa384x_allocate_fid(), and prism2_download_volatile().

static void hfa384x_disable_interrupts struct net_device * dev  ) [static]
 

Definition at line 770 of file hostap_hw.c.

References HFA384X_OUTW.

Referenced by prism2_download_volatile(), prism2_hw_init2(), prism2_hw_reset(), prism2_hw_shutdown(), prism2_pci_remove(), and prism2_plx_remove().

static void hfa384x_enable_interrupts struct net_device * dev  ) [static]
 

Definition at line 778 of file hostap_hw.c.

References HFA384X_EVENT_MASK, and HFA384X_OUTW.

Referenced by prism2_hw_enable().

static void hfa384x_events_all struct net_device * dev  ) [static]
 

Definition at line 793 of file hostap_hw.c.

References HFA384X_EVENT_MASK, and HFA384X_OUTW.

Referenced by hostap_bap_tasklet().

static void hfa384x_events_no_bap0 struct net_device * dev  ) [static]
 

Definition at line 786 of file hostap_hw.c.

References HFA384X_BAP0_EVENTS, HFA384X_EVENT_MASK, and HFA384X_OUTW.

Referenced by prism2_ev_tick(), and prism2_interrupt().

static void hfa384x_events_only_cmd struct net_device * dev  ) [static]
 

Definition at line 799 of file hostap_hw.c.

References HFA384X_EV_CMD, and HFA384X_OUTW.

Referenced by prism2_hw_init2(), and prism2_hw_shutdown().

static int hfa384x_get_rid struct net_device * dev,
u16 rid,
void * buf,
int len,
int exact_len
[static]
 

Definition at line 664 of file hostap_hw.c.

References hfa384x_cmd(), HFA384X_CMDCODE_ACCESS, hfa384x_from_bap(), hfa384x_setup_bap(), prism2_hw_reset(), spin_lock_bh, and spin_unlock_bh.

Referenced by prism2_check_sta_fw_version(), prism2_get_version_info(), prism2_hw_init2(), prism2_init_local_data(), and prism2_setup_rids().

Here is the call graph for this function:

static u16 hfa384x_read_reg struct net_device * dev,
u16 reg
[static]
 

Definition at line 200 of file hostap_hw.c.

References HFA384X_INW.

static void hfa384x_read_regs struct net_device * dev,
struct hfa384x_regsregs
[static]
 

Definition at line 206 of file hostap_hw.c.

References HFA384X_INW.

Referenced by prism2_init_local_data().

static int hfa384x_set_rid struct net_device * dev,
u16 rid,
void * buf,
int len
[static]
 

Definition at line 724 of file hostap_hw.c.

References hfa384x_cmd(), HFA384X_CMDCODE_ACCESS_WRITE, hfa384x_setup_bap(), hfa384x_to_bap(), hfa384x_rid_hdr::len, prism2_hw_reset(), hfa384x_rid_hdr::rid, spin_lock_bh, and spin_unlock_bh.

Referenced by prism2_init_local_data().

Here is the call graph for this function:

static int hfa384x_setup_bap struct net_device * dev,
u16 bap,
u16 id,
int offset
[static]
 

Definition at line 614 of file hostap_hw.c.

References HFA384X_INW, HFA384X_OFFSET_ERR, HFA384X_OUTW, and hfa384x_wait_offset().

Referenced by hfa384x_get_rid(), hfa384x_set_rid(), hostap_tx_compl_read(), prism2_info(), prism2_rx(), prism2_tx(), and prism2_tx_80211().

Here is the call graph for this function:

static int hfa384x_wait_offset struct net_device * dev,
u16 o_off
[inline, static]
 

Definition at line 599 of file hostap_hw.c.

References HFA384X_BAP_BUSY_TIMEOUT, HFA384X_INW, and HFA384X_OFFSET_BUSY.

Referenced by hfa384x_setup_bap().

static void hostap_bap_tasklet unsigned long data  ) [static]
 

Definition at line 2972 of file hostap_hw.c.

References HFA384X_BAP0_EVENTS, HFA384X_EV_INFO, HFA384X_EV_RX, HFA384X_EV_TX, HFA384X_EV_TXEXC, hfa384x_events_all(), HFA384X_INW, prism2_info(), prism2_rx(), prism2_tx_ev(), and prism2_txexc().

Referenced by prism2_init_local_data().

Here is the call graph for this function:

static void hostap_cmd_queue_free local_info_t * local,
struct hostap_cmd_queue * entry,
int del_req
[inline, static]
 

Definition at line 234 of file hostap_hw.c.

References __hostap_cmd_queue_free().

Referenced by hfa384x_cmd(), hfa384x_cmd_callback(), and prism2_cmd_ev().

Here is the call graph for this function:

static void hostap_info_tasklet unsigned long data  ) [static]
 

Definition at line 2891 of file hostap_hw.c.

References hostap_info_process().

Referenced by prism2_init_local_data().

Here is the call graph for this function:

static void hostap_passive_scan unsigned long data  ) [static]
 

Definition at line 3346 of file hostap_hw.c.

References channel, hfa384x_cmd_callback(), HFA384X_CMDCODE_TEST, and HFA384X_TEST_CHANGE_CHANNEL.

Referenced by prism2_init_local_data().

Here is the call graph for this function:

static void hostap_rx_skb local_info_t * local,
struct sk_buff * skb
[static]
 

Definition at line 2395 of file hostap_hw.c.

References ATH_RX_RADIOTAP_PRESENT, hfa384x_rx_frame::frame_control, HFA384X_RX_STATUS_FCSERR, hostap_80211_get_hdrlen(), hostap_dump_rx_header(), hostap_get_stats(), IEEE80211_RADIOTAP_F_RX_BADFCS, ieee80211_radiotap_header::it_len, ieee80211_radiotap_header::it_present, ieee80211_radiotap_header::it_version, IW_MODE_MONITOR, hfa384x_rx_frame::rate, hfa384x_rx_frame::signal, hfa384x_rx_frame::status, hostap_rx_radiotap_header::wr_antenna, hostap_rx_radiotap_header::wr_antsignal, hostap_rx_radiotap_header::wr_chan_flags, hostap_rx_radiotap_header::wr_chan_freq, hostap_rx_radiotap_header::wr_flags, hostap_rx_radiotap_header::wr_ihdr, hostap_rx_radiotap_header::wr_rate, and hostap_rx_radiotap_header::wr_rx_flags.

Referenced by hostap_rx_tasklet().

Here is the call graph for this function:

static void hostap_rx_tasklet unsigned long data  ) [static]
 

Definition at line 2477 of file hostap_hw.c.

References hostap_rx_skb().

Referenced by prism2_init_local_data().

Here is the call graph for this function:

static void hostap_sta_tx_exc_tasklet unsigned long data  ) [static]
 

Definition at line 2786 of file hostap_hw.c.

References hostap_handle_sta_tx_exc().

Referenced by prism2_init_local_data().

Here is the call graph for this function:

static void hostap_tick_timer unsigned long data  ) [static]
 

Definition at line 3411 of file hostap_hw.c.

References hfa384x_cmd_callback(), HFA384X_CMDCODE_INQUIRE, and HFA384X_INFO_COMMTALLIES.

Referenced by prism2_init_local_data().

Here is the call graph for this function:

static void hostap_tx_callback local_info_t * local,
struct hfa384x_tx_frametxdesc,
int ok,
char * payload
[static]
 

Definition at line 2551 of file hostap_hw.c.

References hostap_80211_get_hdrlen().

Referenced by prism2_tx_ev(), and prism2_txexc().

Here is the call graph for this function:

static int hostap_tx_compl_read local_info_t * local,
int error,
struct hfa384x_tx_frametxdesc,
char ** payload
[static]
 

Definition at line 2599 of file hostap_hw.c.

References hfa384x_from_bap(), hfa384x_setup_bap(), prism2_read_fid_reg(), and PRISM2_SCHEDULE_TASK.

Referenced by prism2_tx_ev(), and prism2_txexc().

Here is the call graph for this function:

MODULE_PARM dev_template ,
"s" 
 

MODULE_PARM disable_on_close ,
"i" 
 

MODULE_PARM delayed_enable ,
"i" 
 

MODULE_PARM dtim_period ,
PARM_MIN_MAX"i" 
 

MODULE_PARM beacon_int ,
PARM_MIN_MAX"i" 
 

MODULE_PARM iw_mode ,
PARM_MIN_MAX"i" 
 

MODULE_PARM essid ,
PARM_MIN_MAX"s" 
 

MODULE_PARM channel ,
PARM_MIN_MAX"i" 
 

MODULE_PARM mtu ,
"i" 
 

MODULE_PARM_DESC dev_template ,
"Prefix for network device name (default: ""wlan%d)" 
 

MODULE_PARM_DESC disable_on_close ,
"Disable MAC port on netdevice close" 
 

MODULE_PARM_DESC delayed_enable ,
"Delay MAC port enable until netdevice open" 
 

MODULE_PARM_DESC dtim_period ,
"DTIM period" 
 

MODULE_PARM_DESC beacon_int ,
"Beacon interval (1 = 1024 usec)" 
 

MODULE_PARM_DESC iw_mode ,
"Initial operation mode" 
 

MODULE_PARM_DESC essid ,
"Host AP's ESSID" 
 

MODULE_PARM_DESC channel ,
"Initial channel
 

MODULE_PARM_DESC mtu ,
"Maximum transfer unit" 
 

static void prism2_alloc_ev struct net_device * dev  ) [static]
 

Definition at line 2488 of file hostap_hw.c.

References HFA384X_INW, hostap_netif_wake_queues(), and prism2_read_fid_reg().

Referenced by prism2_interrupt().

Here is the call graph for this function:

static void prism2_check_magic local_info_t * local  ) [inline, static]
 

Definition at line 3086 of file hostap_hw.c.

References HFA384X_INW, HFA384X_MAGIC, HFA384X_OUTW, and PRISM2_SCHEDULE_TASK.

Referenced by prism2_interrupt().

static void prism2_check_sta_fw_version local_info_t * local  ) [static]
 

Definition at line 3250 of file hostap_hw.c.

References HFA384X_COMP_ID_FW_AP, HFA384X_COMP_ID_STA, hfa384x_get_rid(), HFA384X_RID_STAID, hostap_check_sta_fw_version(), and IW_MODE_MASTER.

Referenced by prism2_hw_init2().

Here is the call graph for this function:

static void prism2_clear_cmd_queue local_info_t * local  ) [static]
 

Definition at line 1097 of file hostap_hw.c.

References __hostap_cmd_queue_free().

Referenced by prism2_free_local_data(), and prism2_hw_shutdown().

Here is the call graph for this function:

static void prism2_cmd_ev struct net_device * dev  ) [static]
 

Definition at line 1613 of file hostap_hw.c.

References __hostap_cmd_queue_free(), BIT, hfa384x_cmd_issue(), HFA384X_EV_CMD, HFA384X_INW, HFA384X_OUTW, hostap_cmd_queue_free(), and list_del_init().

Referenced by prism2_interrupt().

Here is the call graph for this function:

static void prism2_crypt_deinit_entries local_info_t * local,
int force
[static]
 

Definition at line 3307 of file hostap_hw.c.

Referenced by prism2_crypt_deinit_handler(), and prism2_free_local_data().

static void prism2_crypt_deinit_handler unsigned long data  ) [static]
 

Definition at line 3328 of file hostap_hw.c.

References prism2_crypt_deinit_entries().

Referenced by prism2_init_local_data().

Here is the call graph for this function:

static void prism2_ev_tick struct net_device * dev  ) [static]
 

Definition at line 3056 of file hostap_hw.c.

References HFA384X_BAP0_EVENTS, hfa384x_events_no_bap0(), and HFA384X_INW.

Referenced by prism2_interrupt().

Here is the call graph for this function:

static void prism2_free_local_data struct net_device * dev  ) [static]
 

Definition at line 3695 of file hostap_hw.c.

References flush_scheduled_work(), hostap_free_data(), hostap_remove_interface(), hostap_remove_proc(), hostap_set_hostapd(), list_for_each_safe, prism2_clear_cmd_queue(), prism2_crypt_deinit_entries(), and prism2_download_free_data().

Referenced by prism2_detach(), prism2_pci_probe(), prism2_pci_remove(), prism2_plx_probe(), and prism2_plx_remove().

Here is the call graph for this function:

static int prism2_get_txfid_idx local_info_t * local  ) [static]
 

Definition at line 1475 of file hostap_hw.c.

Referenced by prism2_tx(), and prism2_tx_80211().

static int prism2_get_version_info struct net_device * dev,
u16 rid,
const char * txt
[static]
 

Definition at line 872 of file hostap_hw.c.

References hfa384x_get_rid().

Referenced by prism2_hw_init2().

Here is the call graph for this function:

static int prism2_hw_config struct net_device * dev,
int initial
[static]
 

Definition at line 1295 of file hostap_hw.c.

References delayed_enable, prism2_hw_enable(), prism2_hw_init(), and prism2_hw_init2().

Referenced by prism2_config(), prism2_download_volatile(), prism2_event(), prism2_hw_reset(), prism2_init_local_data(), and prism2_plx_probe().

Here is the call graph for this function:

static int prism2_hw_enable struct net_device * dev,
int initial
[static]
 

Definition at line 1260 of file hostap_hw.c.

References hfa384x_cmd(), HFA384X_CMDCODE_ENABLE, hfa384x_enable_interrupts(), hostap_netif_wake_queues(), and prism2_reset_port().

Referenced by prism2_hw_config(), and prism2_init_local_data().

Here is the call graph for this function:

static int prism2_hw_init struct net_device * dev,
int initial
[static]
 

Definition at line 1123 of file hostap_hw.c.

References dev_info, hfa384x_cmd_no_wait(), HFA384X_CMDCODE_INIT, HFA384X_EV_CMD, HFA384X_INIT_TIMEOUT, HFA384X_INW, HFA384X_OUTW, and yield.

Referenced by prism2_download_genesis(), prism2_download_volatile(), and prism2_hw_config().

Here is the call graph for this function:

static int prism2_hw_init2 struct net_device * dev,
int initial
[static]
 

Definition at line 1169 of file hostap_hw.c.

References dev_info, hfa384x_allocate_fid(), hfa384x_disable_interrupts(), hfa384x_events_only_cmd(), hfa384x_get_rid(), HFA384X_INW, HFA384X_MAGIC, HFA384X_OUTW, HFA384X_RID_CNFOWNMACADDR, HFA384X_RID_NICID, HFA384X_RID_PRIID, HFA384X_RID_STAID, prism2_check_sta_fw_version(), prism2_get_version_info(), prism2_read_pda(), and prism2_setup_rids().

Referenced by prism2_download_genesis(), and prism2_hw_config().

Here is the call graph for this function:

static void prism2_hw_reset struct net_device * dev  ) [static]
 

Definition at line 1348 of file hostap_hw.c.

References dev_info, hfa384x_disable_interrupts(), prism2_download_genesis(), prism2_download_volatile(), prism2_hw_config(), and prism2_hw_shutdown().

Referenced by handle_reset_queue(), hfa384x_get_rid(), hfa384x_set_rid(), and prism2_init_local_data().

Here is the call graph for this function:

static void prism2_hw_shutdown struct net_device * dev,
int no_disable
[static]
 

Definition at line 1316 of file hostap_hw.c.

References dev_info, hfa384x_cmd(), HFA384X_CMDCODE_DISABLE, hfa384x_disable_interrupts(), hfa384x_events_only_cmd(), and prism2_clear_cmd_queue().

Referenced by prism2_download_volatile(), prism2_event(), prism2_hw_reset(), prism2_init_local_data(), and prism2_release().

Here is the call graph for this function:

static void prism2_infdrop struct net_device * dev  ) [static]
 

Definition at line 3036 of file hostap_hw.c.

References hfa384x_cmd_callback(), HFA384X_CMDCODE_INQUIRE, and HFA384X_INFO_COMMTALLIES.

Referenced by prism2_interrupt().

Here is the call graph for this function:

static void prism2_info local_info_t * local  ) [static]
 

Definition at line 2904 of file hostap_hw.c.

References HFA384X_EV_INFO, hfa384x_from_bap(), HFA384X_INW, HFA384X_OUTW, hfa384x_setup_bap(), PRISM2_SCHEDULE_TASK, and tasklet_schedule().

Referenced by hostap_bap_tasklet().

Here is the call graph for this function:

static int prism2_init_dev local_info_t * local  ) [static]
 

Definition at line 3660 of file hostap_hw.c.

References dev_info, dev_template, hostap_init_data(), hostap_init_proc(), and prism2_registers_proc_read().

Referenced by prism2_config(), prism2_pci_probe(), and prism2_plx_probe().

Here is the call graph for this function:

static struct net_device* prism2_init_local_data struct prism2_helper_functions * funcs,
int card_idx
[static]
 

Definition at line 3500 of file hostap_hw.c.

References ARPHRD_IEEE80211_RADIOTAP, beacon_int, channel, disable_on_close, dtim_period, essid, GET_INT_PARM, handle_reset_queue(), hfa384x_cmd(), hfa384x_get_rid(), hfa384x_read_regs(), hfa384x_set_rid(), HFA384X_TX_CTRL_FLAGS, hostap_bap_tasklet(), hostap_info_init(), hostap_info_tasklet(), hostap_passive_scan(), hostap_rx_tasklet(), hostap_set_multicast_list_queue(), hostap_setup_dev(), hostap_sta_tx_exc_tasklet(), HOSTAP_TASKLET_INIT, hostap_tick_timer(), INIT_WORK(), iw_mode, IW_MODE_ADHOC, IW_MODE_MASTER, IW_MODE_MONITOR, IW_MODE_REPEAT, MAX_PARM_DEVICES, mtu, PRISM2_AUTH_OPEN, PRISM2_AUTH_SHARED_KEY, prism2_crypt_deinit_handler(), prism2_hw_config(), prism2_hw_enable(), prism2_hw_reset(), prism2_hw_shutdown(), prism2_reset_port(), prism2_schedule_reset(), prism2_tx(), prism2_tx_80211(), and rwlock_init.

Referenced by prism2_attach(), prism2_pci_probe(), and prism2_plx_probe().

Here is the call graph for this function:

static irqreturn_t prism2_interrupt int irq,
void * dev_id,
struct pt_regs * regs
[static]
 

Definition at line 3125 of file hostap_hw.c.

References HFA384X_BAP0_EVENTS, HFA384X_EV_ALLOC, HFA384X_EV_CMD, HFA384X_EV_INFDROP, HFA384X_EV_RX, HFA384X_EV_TICK, HFA384X_EV_WTERR, HFA384X_EVENT_MASK, hfa384x_events_no_bap0(), HFA384X_INW, HFA384X_OUTW, IRQ_HANDLED, IRQ_RETVAL, prism2_alloc_ev(), prism2_check_magic(), prism2_cmd_ev(), prism2_ev_tick(), prism2_infdrop(), PRISM2_MAX_INTERRUPT_EVENTS, and tasklet_schedule().

Here is the call graph for this function:

static void prism2_netif_update_trans_start struct net_device * dev  ) [static]
 

Definition at line 1459 of file hostap_hw.c.

Referenced by prism2_transmit().

static u16 prism2_read_fid_reg struct net_device * dev,
u16 reg
[inline, static]
 

Definition at line 2200 of file hostap_hw.c.

References HFA384X_INW.

Referenced by hostap_tx_compl_read(), prism2_alloc_ev(), and prism2_rx().

static int prism2_registers_proc_read char * page,
char ** start,
off_t off,
int count,
int * eof,
void * data
[static]
 

Definition at line 3433 of file hostap_hw.c.

References SHOW_REG.

Referenced by prism2_init_dev().

static int prism2_reset_port struct net_device * dev  ) [static]
 

Definition at line 835 of file hostap_hw.c.

References hfa384x_cmd(), HFA384X_CMDCODE_DISABLE, HFA384X_CMDCODE_ENABLE, HFA384X_RID_FRAGMENTATIONTHRESHOLD, and hostap_set_word().

Referenced by prism2_hw_enable(), and prism2_init_local_data().

Here is the call graph for this function:

static void prism2_rx local_info_t * local  ) [static]
 

Definition at line 2232 of file hostap_hw.c.

References HFA384X_EV_RX, hfa384x_from_bap(), HFA384X_INW, HFA384X_OUTW, hfa384x_setup_bap(), hostap_dump_rx_header(), hostap_get_stats(), IW_MODE_MONITOR, prism2_read_fid_reg(), PRISM2_SCHEDULE_TASK, and tasklet_schedule().

Referenced by hostap_bap_tasklet().

Here is the call graph for this function:

static void prism2_schedule_reset local_info_t * local  ) [static]
 

Definition at line 1423 of file hostap_hw.c.

References PRISM2_SCHEDULE_TASK.

Referenced by prism2_init_local_data().

static int prism2_setup_rids struct net_device * dev  ) [static]
 

Definition at line 889 of file hostap_hw.c.

References hfa384x_get_rid(), HFA384X_RATES_11MBPS, HFA384X_RATES_1MBPS, HFA384X_RATES_2MBPS, HFA384X_RATES_5MBPS, HFA384X_RID_CHANNELLIST, HFA384X_RID_CNFALTRETRYCOUNT, HFA384X_RID_CNFBASICRATES, HFA384X_RID_CNFBEACONINT, HFA384X_RID_CNFDESIREDSSID, HFA384X_RID_CNFENHSECURITY, HFA384X_RID_CNFMAXDATALEN, HFA384X_RID_CNFOWNCHANNEL, HFA384X_RID_CNFOWNDTIMPERIOD, HFA384X_RID_CNFOWNNAME, HFA384X_RID_CNFOWNSSID, HFA384X_RID_CNFPORTTYPE, HFA384X_RID_CNFSUPPORTEDRATES, HFA384X_RID_CNFTHIRTY2TALLY, HFA384X_RID_CREATEIBSS, HFA384X_RID_FRAGMENTATIONTHRESHOLD, HFA384X_RID_PROMISCUOUSMODE, HFA384X_RID_RTSTHRESHOLD, HFA384X_RID_TICKTIME, HFA384X_RID_TXRATECONTROL, hostap_get_porttype(), hostap_set_antsel(), hostap_set_auth_algs(), hostap_set_encryption(), hostap_set_roaming(), hostap_set_string(), hostap_set_word(), and IW_MODE_MASTER.

Referenced by prism2_hw_init2().

Here is the call graph for this function:

static int prism2_transmit struct net_device * dev,
int idx
[static]
 

Definition at line 1567 of file hostap_hw.c.

References hfa384x_cmd_callback(), HFA384X_CMD_TX_RECLAIM, HFA384X_CMDCODE_TRANSMIT, hostap_get_stats(), hostap_netif_stop_queues(), hostap_netif_wake_queues(), prism2_netif_update_trans_start(), and prism2_transmit_cb().

Referenced by prism2_tx(), and prism2_tx_80211().

Here is the call graph for this function:

static void prism2_transmit_cb struct net_device * dev,
void * context,
u16 resp0,
u16 res
[static]
 

Definition at line 1503 of file hostap_hw.c.

References hostap_netif_stop_queues(), and hostap_netif_wake_queues().

Referenced by prism2_transmit().

Here is the call graph for this function:

static int prism2_tx struct sk_buff * skb,
struct net_device * dev
[static]
 

Definition at line 1786 of file hostap_hw.c.

References EXTRA_HEADER_CB_OFFSET, hfa384x_cmd_callback(), HFA384X_CMDCODE_ENABLE, hfa384x_setup_bap(), hfa384x_to_bap(), hostap_dump_tx_header(), hostap_get_stats(), hostap_handle_sta_release(), hostap_netif_stop_queues(), IEEE80211_RADIOTAP_RATE, ieee80211_radiotap_header::it_len, IW_MODE_INFRA, IW_MODE_MASTER, IW_MODE_REPEAT, click_wifi_extra::len, click_wifi_extra::magic, prism2_get_txfid_idx(), PRISM2_SCHEDULE_TASK, prism2_transmit(), pull_prism2_header(), pull_wifi_extra_header(), click_wifi_extra::rate, rt_check_header(), rt_el_offset(), rt_el_present(), and WIFI_EXTRA_MAGIC.

Referenced by prism2_init_local_data().

Here is the call graph for this function:

static int prism2_tx_80211 struct sk_buff * skb,
struct net_device * dev
[static]
 

Definition at line 2075 of file hostap_hw.c.

References AP_TX_BUFFERED, BIT, hfa384x_tx_frame::data_len, hfa384x_tx_frame::frame_control, hfa384x_setup_bap(), hfa384x_to_bap(), HFA384X_TX_CTRL_TX_OK, hostap_handle_sta_tx(), hfa384x_tx_frame::len, prism2_get_txfid_idx(), PRISM2_SCHEDULE_TASK, prism2_transmit(), hfa384x_tx_frame::sw_support, hfa384x_tx_frame::tx_control, WLAN_FC_FROMDS, WLAN_FC_GET_STYPE, WLAN_FC_GET_TYPE, WLAN_FC_PVER, WLAN_FC_STYPE_ASSOC_RESP, WLAN_FC_STYPE_AUTH, WLAN_FC_STYPE_REASSOC_RESP, WLAN_FC_TODS, WLAN_FC_TYPE_DATA, and WLAN_FC_TYPE_MGMT.

Referenced by prism2_init_local_data().

Here is the call graph for this function:

static void prism2_tx_ev local_info_t * local  ) [static]
 

Definition at line 2752 of file hostap_hw.c.

References click_tx_callback(), hfa384x_tx_frame::duration_id, HFA384X_EV_TX, HFA384X_OUTW, hostap_tx_callback(), hostap_tx_compl_read(), hfa384x_tx_frame::retry_count, hfa384x_tx_frame::seq_ctrl, hfa384x_tx_frame::status, hfa384x_tx_frame::sw_support, and hfa384x_tx_frame::tx_rate.

Referenced by hostap_bap_tasklet().

Here is the call graph for this function:

static void prism2_txexc local_info_t * local  ) [static]
 

Definition at line 2801 of file hostap_hw.c.

References hfa384x_tx_frame::addr1, hfa384x_tx_frame::addr2, hfa384x_tx_frame::addr3, hfa384x_tx_frame::addr4, click_tx_callback(), hfa384x_tx_frame::frame_control, HFA384X_EV_TXEXC, HFA384X_OUTW, HFA384X_TX_STATUS_AGEDERR, HFA384X_TX_STATUS_DISCON, HFA384X_TX_STATUS_FORMERR, HFA384X_TX_STATUS_RETRYERR, hostap_tx_callback(), hostap_tx_compl_read(), IW_MODE_MASTER, IW_MODE_REPEAT, MAC2STR, MACSTR, hfa384x_tx_frame::retry_count, hfa384x_tx_frame::status, hfa384x_tx_frame::sw_support, tasklet_schedule(), hfa384x_tx_frame::tx_control, hfa384x_tx_frame::tx_rate, WLAN_FC_FROMDS, WLAN_FC_GET_STYPE, WLAN_FC_GET_TYPE, WLAN_FC_TODS, WLAN_FC_TYPE_CTRL, WLAN_FC_TYPE_DATA, and WLAN_FC_TYPE_MGMT.

Referenced by hostap_bap_tasklet().

Here is the call graph for this function:

static int rt_check_header struct ieee80211_radiotap_headerth,
int len
[static]
 

Definition at line 1750 of file hostap_hw.c.

References NUM_RADIOTAP_ELEMENTS, radiotap_elem_to_bytes, and rt_el_present().

Referenced by prism2_tx().

Here is the call graph for this function:

static u_int8_t* rt_el_offset struct ieee80211_radiotap_headerth,
u_int32_t element
[static]
 

Definition at line 1774 of file hostap_hw.c.

References NUM_RADIOTAP_ELEMENTS, radiotap_elem_to_bytes, and rt_el_present().

Referenced by prism2_tx().

Here is the call graph for this function:

static int rt_el_present struct ieee80211_radiotap_headerth,
u_int32_t element
[static]
 

Definition at line 1743 of file hostap_hw.c.

References NUM_RADIOTAP_ELEMENTS.

Referenced by prism2_tx(), rt_check_header(), and rt_el_offset().


Variable Documentation

int beacon_int[MAX_PARM_DEVICES] = { 100, DEF_INTS } [static]
 

Definition at line 84 of file hostap_hw.c.

Referenced by prism2_init_local_data().

int channel[MAX_PARM_DEVICES] = { 3, DEF_INTS } [static]
 

Definition at line 72 of file hostap_hw.c.

Referenced by hostap_passive_scan(), and prism2_init_local_data().

int delayed_enable [static]
 

Definition at line 92 of file hostap_hw.c.

Referenced by prism2_hw_config().

char* dev_template = "wlan%d" [static]
 

Definition at line 112 of file hostap_hw.c.

Referenced by prism2_init_dev().

int disable_on_close [static]
 

Definition at line 96 of file hostap_hw.c.

Referenced by prism2_init_local_data().

int dtim_period[MAX_PARM_DEVICES] = { 1, DEF_INTS } [static]
 

Definition at line 88 of file hostap_hw.c.

Referenced by prism2_init_local_data().

char* essid[MAX_PARM_DEVICES] = { "test" } [static]
 

Definition at line 76 of file hostap_hw.c.

Referenced by prism2_init_local_data().

int iw_mode[MAX_PARM_DEVICES] = { IW_MODE_MASTER, DEF_INTS } [static]
 

Definition at line 80 of file hostap_hw.c.

Referenced by prism2_init_local_data().

int mtu = 1500 [static]
 

Definition at line 68 of file hostap_hw.c.

Referenced by prism2_init_local_data().

int radiotap_elem_to_bytes[NUM_RADIOTAP_ELEMENTS] [static]
 

Initial value:

 
{8, 
         1, 
         1, 
         4, 
         2, 
         1, 
         1, 
         2, 
         2, 
         2, 
         1, 
         1, 
         1, 
         1, 
         2, 
         2, 
         1, 
         1, 
        }

Definition at line 1715 of file hostap_hw.c.

Referenced by rt_check_header(), and rt_el_offset().


Generated on Mon Nov 21 16:01:14 2005 for openwifi by  doxygen 1.4.1