Add the rt linux 4.1.3-rt3 as base
[kvmfornfv.git] / kernel / drivers / staging / rtl8188eu / include / rtl8188e_recv.h
1 /******************************************************************************
2  *
3  * Copyright(c) 2007 - 2011 Realtek Corporation. All rights reserved.
4  *
5  * This program is free software; you can redistribute it and/or modify it
6  * under the terms of version 2 of the GNU General Public License as
7  * published by the Free Software Foundation.
8  *
9  * This program is distributed in the hope that it will be useful, but WITHOUT
10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11  * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12  * more details.
13  *
14  * You should have received a copy of the GNU General Public License along with
15  * this program; if not, write to the Free Software Foundation, Inc.,
16  * 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
17  *
18  *
19  ******************************************************************************/
20 #ifndef __RTL8188E_RECV_H__
21 #define __RTL8188E_RECV_H__
22
23 #define TX_RPT1_PKT_LEN 8
24
25 #define RECV_BLK_SZ 512
26 #define RECV_BLK_CNT 16
27 #define RECV_BLK_TH RECV_BLK_CNT
28 #define RECV_BULK_IN_ADDR               0x80
29 #define RECV_INT_IN_ADDR                0x81
30
31 #define NR_PREALLOC_RECV_SKB (8)
32
33 #define NR_RECVBUFF (4)
34
35 #define MAX_RECVBUF_SZ (15360) /*  15k < 16k */
36
37 struct phy_stat {
38         unsigned int phydw0;
39         unsigned int phydw1;
40         unsigned int phydw2;
41         unsigned int phydw3;
42         unsigned int phydw4;
43         unsigned int phydw5;
44         unsigned int phydw6;
45         unsigned int phydw7;
46 };
47
48 /*  Rx smooth factor */
49 #define Rx_Smooth_Factor (20)
50
51 enum rx_packet_type {
52         NORMAL_RX,/* Normal rx packet */
53         TX_REPORT1,/* CCX */
54         TX_REPORT2,/* TX RPT */
55         HIS_REPORT,/*  USB HISR RPT */
56 };
57
58 #define INTERRUPT_MSG_FORMAT_LEN 60
59 s32 rtl8188eu_init_recv_priv(struct adapter *padapter);
60 void rtl8188eu_free_recv_priv(struct adapter *padapter);
61 void rtl8188eu_recv_hdl(struct adapter *padapter, struct recv_buf *precvbuf);
62 void rtl8188eu_recv_tasklet(void *priv);
63 void rtl8188e_query_rx_phy_status(struct recv_frame *fr, struct phy_stat *phy);
64 void rtl8188e_process_phy_info(struct adapter *padapter, void *prframe);
65 void update_recvframe_phyinfo_88e(struct recv_frame *fra, struct phy_stat *phy);
66 void update_recvframe_attrib_88e(struct recv_frame *fra,
67                                  struct recv_stat *stat);
68
69 #endif