forget difference between big and small commands - obsolete with vm.
[minix.git] / drivers / orinoco / orinoco.h
blob45daee7e2619bba359b6b0ad929744209de69e52
1 /*
2 * orinoco.h
4 * This file contains the most important structure for the driver: t_or
5 * and some configurable definitions
7 * Created by Stevens Le Blond <slblond@few.vu.nl>
8 * and Michael Valkering <mjvalker@cs.vu.nl>
9 */
11 #include <net/gen/ether.h>
12 #include <net/gen/eth_io.h>
14 #define NR_RX_BUFS 32
16 #define LARGE_KEY_LENGTH 13
17 #define IW_ESSID_MAX_SIZE 32
18 #define OR_PORT_NR 1
19 #define IOVEC_NR 16
20 #define OR_ENVVAR "ORETH"
21 #define OR_NAME "orinoco#n"
23 #define IEEE802_11_HLEN 30
24 #define IEEE802_11_DATA_LEN (2304)
25 #define IEEE802_11_FRAME_LEN (IEEE802_11_DATA_LEN + IEEE802_11_HLEN + 3)
27 typedef struct s_or
29 int or_irq;
30 int or_hook_id;
31 int or_mode;
32 int or_flags;
33 char *or_model;
34 int or_client;
35 int or_link_up;
36 int or_got_int;
37 int or_tx_alive;
38 int or_send_int;
39 int or_clear_rx;
40 u32_t or_base_port;
41 int or_need_reset;
42 int or_report_link;
44 /* Events */
45 int or_ev_rx;
46 int or_ev_tx;
47 int or_ev_info;
48 int or_ev_txexc;
49 int or_ev_alloc;
50 int connected;
51 u16_t channel_mask;
52 u16_t channel;
53 u16_t ap_density;
54 u16_t rts_thresh;
55 int bitratemode;
56 int last_linkstatus;
57 int max_data_len;
58 int port_type;
60 /* Rx */
61 phys_bytes or_rx_buf;
62 vir_bytes or_read_s;
63 u16_t rxfid[NR_RX_BUFS];
64 int rx_length[NR_RX_BUFS];
65 u8_t rx_buf[NR_RX_BUFS][IEEE802_11_FRAME_LEN];
66 u8_t rx_offset[NR_RX_BUFS];
67 int rx_first;
68 int rx_last;
69 int rx_current;
71 /* Tx */
72 u16_t or_nicbuf_size;
73 vir_bytes or_transm_s;
74 int or_tx_head;
75 int or_tx_tail;
77 struct
79 int ret_busy;
80 u16_t or_txfid;
81 } or_tx;
82 u32_t or_ertxth;
84 /* PCI related */
85 int or_seen;
86 u8_t or_pci_bus;
87 u8_t or_pci_dev;
88 u8_t or_pci_func;
89 int devind;
91 /* 'large' items */
92 irq_hook_t or_hook;
93 eth_stat_t or_stat;
94 message or_rx_mess;
95 message or_tx_mess;
96 ether_addr_t or_address;
97 iovec_t or_iovec[IOVEC_NR];
98 iovec_s_t or_iovec_s[IOVEC_NR];
99 char or_name[sizeof (OR_NAME)];
100 hermes_t hw;
101 char nick[IW_ESSID_MAX_SIZE + 1];
104 } t_or;