dt-bindings: Document the Rockchip RGA bindings
[firefly-linux-kernel-4.4.55.git] / drivers / net / wireless / rockchip_wlan / rtl8723bs / include / rtl8192d_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 _RTL8192D_RECV_H_
21 #define _RTL8192D_RECV_H_
22
23
24 #define RECV_BLK_SZ 512
25 #define RECV_BLK_CNT 16
26 #define RECV_BLK_TH RECV_BLK_CNT
27
28 #if defined(CONFIG_USB_HCI)
29
30 #ifndef MAX_RECVBUF_SZ
31 #ifdef PLATFORM_OS_CE
32 #define MAX_RECVBUF_SZ (8192+1024) // 8K+1k
33 #else
34         #ifndef CONFIG_MINIMAL_MEMORY_USAGE
35                 //#define MAX_RECVBUF_SZ (32768) // 32k
36                 //#define MAX_RECVBUF_SZ (16384) //16K
37                 //#define MAX_RECVBUF_SZ (10240) //10K
38                 #ifdef CONFIG_PLATFORM_MSTAR
39                         #define MAX_RECVBUF_SZ (8192) // 8K
40                 #else
41                         #define MAX_RECVBUF_SZ (15360) // 15k < 16k
42                 #endif
43         #else
44                 #define MAX_RECVBUF_SZ (4000) // about 4K
45         #endif
46 #endif
47 #endif //!MAX_RECVBUF_SZ
48
49 #elif defined(CONFIG_PCI_HCI)
50 //#ifndef CONFIG_MINIMAL_MEMORY_USAGE
51 //      #define MAX_RECVBUF_SZ (9100)
52 //#else
53         #define MAX_RECVBUF_SZ (4000) // about 4K
54 //#endif
55
56 #endif
57
58 struct phy_stat
59 {
60         unsigned int phydw0;
61
62         unsigned int phydw1;
63
64         unsigned int phydw2;
65
66         unsigned int phydw3;
67
68         unsigned int phydw4;
69
70         unsigned int phydw5;
71
72         unsigned int phydw6;
73
74         unsigned int phydw7;
75 };
76
77 // Rx smooth factor
78 #define Rx_Smooth_Factor (20)
79
80 #ifdef CONFIG_USB_HCI
81 typedef struct _INTERRUPT_MSG_FORMAT_EX{
82         unsigned int C2H_MSG0;
83         unsigned int C2H_MSG1;
84         unsigned int C2H_MSG2;
85         unsigned int C2H_MSG3;
86         unsigned int HISR; // from HISR Reg0x124, read to clear
87         unsigned int HISRE;// from HISRE Reg0x12c, read to clear
88         unsigned int  MSG_EX;
89 }INTERRUPT_MSG_FORMAT_EX,*PINTERRUPT_MSG_FORMAT_EX;
90
91 void rtl8192du_init_recvbuf(_adapter *padapter, struct recv_buf *precvbuf);
92 int     rtl8192du_init_recv_priv(_adapter * padapter);
93 void    rtl8192du_free_recv_priv(_adapter * padapter);
94 #endif
95
96 #ifdef CONFIG_PCI_HCI
97 int     rtl8192de_init_recv_priv(_adapter * padapter);
98 void rtl8192de_free_recv_priv(_adapter * padapter);
99 #endif
100
101 void rtl8192d_translate_rx_signal_stuff(union recv_frame *precvframe, struct phy_stat *pphy_status);
102 void rtl8192d_query_rx_desc_status(union recv_frame *precvframe, struct recv_stat *pdesc);
103
104 #endif
105