OSDN Git Service

Fix incompatible pointer issue for kernel >= 5.2
[android-x86/external-kernel-drivers.git] / rtl8821ce / hal / phydm / phydm_features_ce.h
1 /******************************************************************************
2  *
3  * Copyright(c) 2007 - 2017  Realtek Corporation.
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  * The full GNU General Public License is included in this distribution in the
15  * file called LICENSE.
16  *
17  * Contact Information:
18  * wlanfae <wlanfae@realtek.com>
19  * Realtek Corporation, No. 2, Innovation Road II, Hsinchu Science Park,
20  * Hsinchu 300, Taiwan.
21  *
22  * Larry Finger <Larry.Finger@lwfinger.net>
23  *
24  *****************************************************************************/
25
26 #ifndef __PHYDM_FEATURES_CE_H__
27 #define __PHYDM_FEATURES_CE_H__
28
29 #if (RTL8814A_SUPPORT || RTL8821C_SUPPORT || RTL8822B_SUPPORT ||\
30         RTL8197F_SUPPORT || RTL8192F_SUPPORT || RTL8198F_SUPPORT ||\
31         RTL8822C_SUPPORT)
32         #define PHYDM_LA_MODE_SUPPORT                   1
33 #else
34         #define PHYDM_LA_MODE_SUPPORT                   0
35 #endif
36
37 #if (RTL8822B_SUPPORT || RTL8812A_SUPPORT || RTL8197F_SUPPORT ||\
38         RTL8192F_SUPPORT)
39         #define DYN_ANT_WEIGHTING_SUPPORT
40 #endif
41
42 #if (RTL8822B_SUPPORT || RTL8821C_SUPPORT)
43         #define FAHM_SUPPORT
44 #endif
45         #define NHM_SUPPORT
46         #define CLM_SUPPORT
47
48 #if (RTL8822B_SUPPORT)
49         /*@#define PHYDM_PHYSTAUS_SMP_MODE*/
50 #endif
51
52 /*@#define PHYDM_TDMA_DIG_SUPPORT*/
53
54 #if (RTL8814B_SUPPORT || RTL8822C_SUPPORT)
55         /*@#define PHYDM_TDMA_DIG_SUPPORT*/
56         #ifdef PHYDM_TDMA_DIG_SUPPORT
57         /*@#define IS_USE_NEW_TDMA*/ /*new tdma dig test*/
58         #endif
59 #endif
60
61 #if (RTL8197F_SUPPORT || RTL8822B_SUPPORT || RTL8814B_SUPPORT)
62         /*@#define PHYDM_LNA_SAT_CHK_SUPPORT*/
63         #ifdef PHYDM_LNA_SAT_CHK_SUPPORT
64
65                 #if (RTL8197F_SUPPORT)
66                 /*@#define PHYDM_LNA_SAT_CHK_SUPPORT_TYPE1*/
67                 #endif
68
69                 #if (RTL8822B_SUPPORT)
70                 /*@#define PHYDM_LNA_SAT_CHK_TYPE2*/
71                 #endif
72
73                 #if (RTL8814B_SUPPORT)
74                 /*@#define PHYDM_LNA_SAT_CHK_TYPE1*/
75                 #endif
76         #endif
77 #endif
78
79 #if (RTL8822B_SUPPORT || RTL8192F_SUPPORT)
80         #define PHYDM_POWER_TRAINING_SUPPORT
81 #endif
82
83 #if (RTL8822C_SUPPORT)
84         /* #define PHYDM_PMAC_TX_SETTING_SUPPORT */
85 #endif
86
87 #if (RTL8822C_SUPPORT)
88         /* #define PHYDM_MP_SUPPORT */
89 #endif
90
91 #if (RTL8822B_SUPPORT)
92         #define PHYDM_TXA_CALIBRATION
93 #endif
94
95 #if (RTL8188E_SUPPORT)
96         #define PHYDM_PRIMARY_CCA
97 #endif
98
99 #if (RTL8188F_SUPPORT || RTL8710B_SUPPORT || RTL8821C_SUPPORT ||\
100         RTL8822B_SUPPORT || RTL8192F_SUPPORT)
101         #define PHYDM_DC_CANCELLATION
102 #endif
103
104 #if (RTL8822B_SUPPORT || RTL8197F_SUPPORT || RTL8192F_SUPPORT)
105         #define CONFIG_ADAPTIVE_SOML
106 #endif
107
108 #if (RTL8188E_SUPPORT || RTL8192E_SUPPORT)
109         #define CONFIG_RECEIVER_BLOCKING
110 #endif
111
112 #if (RTL8192F_SUPPORT == 1)
113         /*#define       CONFIG_8912F_SPUR_CALIBRATION*/
114 #endif
115
116 #if (RTL8822B_SUPPORT == 1)
117         #define CONFIG_8822B_SPUR_CALIBRATION
118 #endif
119
120 #ifdef CONFIG_SUPPORT_DYNAMIC_TXPWR
121 #define CONFIG_DYNAMIC_TX_TWR
122 #endif
123 #define PHYDM_SUPPORT_CCKPD
124 #define PHYDM_SUPPORT_ADAPTIVITY
125
126 /*@Antenna Diversity*/
127 #ifdef CONFIG_ANTENNA_DIVERSITY
128         #define CONFIG_PHYDM_ANTENNA_DIVERSITY
129
130         #ifdef CONFIG_PHYDM_ANTENNA_DIVERSITY
131
132                 #if (RTL8723B_SUPPORT || RTL8821A_SUPPORT ||\
133                      RTL8188F_SUPPORT || RTL8821C_SUPPORT ||\
134                      RTL8723D_SUPPORT)
135                         #define CONFIG_S0S1_SW_ANTENNA_DIVERSITY
136                 #endif
137
138                 #if (RTL8821A_SUPPORT)
139                         /*@#define CONFIG_HL_SMART_ANTENNA_TYPE1*/
140                 #endif
141
142                 #if (RTL8822B_SUPPORT)
143                         /*@#define CONFIG_HL_SMART_ANTENNA_TYPE2*/
144                 #endif
145
146         #endif
147 #endif
148
149 /*@[SmartAntenna]*/
150 /*@#define      CONFIG_SMART_ANTENNA*/
151 #ifdef CONFIG_SMART_ANTENNA
152         /*@#define      CONFIG_CUMITEK_SMART_ANTENNA*/
153 #endif
154 /* @--------------------------------------------------*/
155
156 #ifdef CONFIG_DFS_MASTER
157         #define CONFIG_PHYDM_DFS_MASTER
158 #endif
159
160 #if (RTL8812A_SUPPORT || RTL8821A_SUPPORT || RTL8881A_SUPPORT ||\
161         RTL8192E_SUPPORT || RTL8723B_SUPPORT)
162         /*@#define      CONFIG_RA_FW_DBG_CODE*/
163 #endif
164
165 #define CONFIG_PSD_TOOL
166 /*@#define      CONFIG_ANT_DETECTION*/
167 /*@#define      CONFIG_PATH_DIVERSITY*/
168 /*@#define      CONFIG_RA_DYNAMIC_RTY_LIMIT*/
169 #define CONFIG_BB_TXBF_API
170 #define CONFIG_PHYDM_DEBUG_FUNCTION
171
172 #ifdef CONFIG_BT_COEXIST
173         #define ODM_CONFIG_BT_COEXIST
174 #endif
175 #define PHYDM_SUPPORT_RSSI_MONITOR
176 /*@#define      PHYDM_AUTO_DEGBUG*/
177 #define CFG_DIG_DAMPING_CHK
178
179
180 #ifdef BEAMFORMING_SUPPORT
181         #if (RTL8812A_SUPPORT || RTL8821A_SUPPORT || RTL8192E_SUPPORT ||\
182              RTL8814A_SUPPORT || RTL8881A_SUPPORT)
183                 #define PHYDM_BEAMFORMING_VERSION1
184         #endif
185         #if (RTL8192F_SUPPORT || RTL8195B_SUPPORT || RTL8821C_SUPPORT ||\
186              RTL8822B_SUPPORT || RTL8197F_SUPPORT || RTL8198F_SUPPORT ||\
187              RTL8822C_SUPPORT || RTL8814B_SUPPORT)
188                 #define DRIVER_BEAMFORMING_VERSION2
189         #endif
190 #endif
191
192 #if (RTL8822B_SUPPORT)
193         #ifdef CONFIG_MCC_MODE
194         #define CONFIG_MCC_DM
195         #endif
196 #endif
197
198 #if (RTL8822B_SUPPORT)
199         #ifdef CONFIG_DYNAMIC_BYPASS_MODE
200         #define CONFIG_DYNAMIC_BYPASS
201         #endif
202 #endif
203
204
205 #endif