This source file includes following definitions.
- rsi_usb_check_queue_status
- rsi_usb_event_timeout
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18 #ifndef __RSI_USB_INTF__
19 #define __RSI_USB_INTF__
20
21 #include <linux/usb.h>
22 #include "rsi_main.h"
23 #include "rsi_common.h"
24
25 #define RSI_USB_VENDOR_ID 0x1618
26 #define RSI_USB_PID_9113 0x9113
27 #define RSI_USB_PID_9116 0x9116
28
29 #define USB_INTERNAL_REG_1 0x25000
30 #define RSI_USB_READY_MAGIC_NUM 0xab
31 #define FW_STATUS_REG 0x41050012
32 #define RSI_TA_HOLD_REG 0x22000844
33 #define RSI_FW_WDT_DISABLE_REQ 0x69
34
35 #define USB_VENDOR_REGISTER_READ 0x15
36 #define USB_VENDOR_REGISTER_WRITE 0x16
37 #define RSI_USB_TX_HEAD_ROOM 128
38
39 #define MAX_RX_URBS 2
40 #define MAX_BULK_EP 8
41 #define WLAN_EP 1
42 #define BT_EP 2
43
44 #define RSI_USB_BUF_SIZE 4096
45 #define RSI_USB_CTRL_BUF_SIZE 0x04
46
47 struct rx_usb_ctrl_block {
48 u8 *data;
49 struct urb *rx_urb;
50 struct sk_buff *rx_skb;
51 u8 ep_num;
52 };
53
54 struct rsi_91x_usbdev {
55 void *priv;
56 struct rsi_thread rx_thread;
57 u8 endpoint;
58 struct usb_device *usbdev;
59 struct usb_interface *pfunction;
60 struct rx_usb_ctrl_block rx_cb[MAX_RX_URBS];
61 u8 *tx_buffer;
62 __le16 bulkin_size[MAX_BULK_EP];
63 u8 bulkin_endpoint_addr[MAX_BULK_EP];
64 __le16 bulkout_size[MAX_BULK_EP];
65 u8 bulkout_endpoint_addr[MAX_BULK_EP];
66 u32 tx_blk_size;
67 u8 write_fail;
68 struct sk_buff_head rx_q;
69 };
70
71 static inline int rsi_usb_check_queue_status(struct rsi_hw *adapter, u8 q_num)
72 {
73
74 return QUEUE_NOT_FULL;
75 }
76
77 static inline int rsi_usb_event_timeout(struct rsi_hw *adapter)
78 {
79 return EVENT_WAIT_FOREVER;
80 }
81
82 void rsi_usb_rx_thread(struct rsi_common *common);
83 #endif