xref: /OK3568_Linux_fs/kernel/drivers/net/wireless/rockchip_wlan/rtl8723bu/include/autoconf.h (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1 /******************************************************************************
2  *
3  * Copyright(c) 2007 - 2014 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 /*
21  * Public General Config
22  */
23 #define AUTOCONF_INCLUDED
24 
25 #define RTL871X_MODULE_NAME "8723BU"
26 #define DRV_NAME "rtl8723bu"
27 
28 #ifndef CONFIG_RTL8723B
29 #define CONFIG_RTL8723B
30 #endif
31 #define CONFIG_USB_HCI
32 
33 #define PLATFORM_LINUX
34 
35 
36 /*
37  * Wi-Fi Functions Config
38  */
39 #define CONFIG_80211N_HT
40 #define CONFIG_RECV_REORDERING_CTRL
41 
42 //#define CONFIG_IOCTL_CFG80211		// Set from Makefile
43 #ifdef CONFIG_IOCTL_CFG80211
44 	/*
45 	 * Indecate new sta asoc through cfg80211_new_sta
46 	 * If kernel version >= 3.2 or
47 	 * version < 3.2 but already apply cfg80211 patch,
48 	 * RTW_USE_CFG80211_STA_EVENT must be defiend!
49 	 */
50 	//#define RTW_USE_CFG80211_STA_EVENT /* Indecate new sta asoc through cfg80211_new_sta */
51 	#define CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER
52 	//#define CONFIG_DEBUG_CFG80211
53 	//#define CONFIG_DRV_ISSUE_PROV_REQ // IOT FOR S2
54 	#define CONFIG_SET_SCAN_DENY_TIMER
55 	/* #define SUPPLICANT_RTK_VERSION_LOWER_THAN_JB42*/ /* wpa_supplicant realtek version <= jb42 will be defined this */
56 #endif
57 
58 #define CONFIG_AP_MODE
59 #ifdef CONFIG_AP_MODE
60 	#define CONFIG_NATIVEAP_MLME
61 	#ifndef CONFIG_NATIVEAP_MLME
62 		#define CONFIG_HOSTAPD_MLME
63 	#endif
64 	//#define CONFIG_FIND_BEST_CHANNEL
65 	#define CONFIG_TX_MCAST2UNI	// Support IP multicast->unicast
66 
67 	//#define CONFIG_AUTO_AP_MODE
68 #endif
69 
70 #define CONFIG_P2P
71 #ifdef CONFIG_P2P
72 	//Added by Albert 20110812
73 	//The CONFIG_WFD is for supporting the Wi-Fi display
74 	#define CONFIG_WFD
75 
76 	#define CONFIG_P2P_REMOVE_GROUP_INFO
77 
78 	//#define CONFIG_DBG_P2P
79 	#define CONFIG_P2P_PS
80 	#define CONFIG_P2P_OP_CHK_SOCIAL_CH
81 	#define CONFIG_CFG80211_ONECHANNEL_UNDER_CONCURRENT  //replace CONFIG_P2P_CHK_INVITE_CH_LIST flag
82 	#define CONFIG_P2P_INVITE_IOT
83 #endif
84 
85 // Added by Kurt 20110511
86 #ifdef CONFIG_TDLS
87 	#define CONFIG_TDLS_DRIVER_SETUP
88 //	#ifndef CONFIG_WFD
89 //		#define CONFIG_WFD
90 //	#endif
91 //	#define CONFIG_TDLS_AUTOSETUP
92 	#define CONFIG_TDLS_AUTOCHECKALIVE
93 	/* #define CONFIG_TDLS_CH_SW */	/* Enable this flag only when we confirm that TDLS CH SW is supported in FW */
94 #endif
95 
96 //#define CONFIG_CONCURRENT_MODE	// Set from Makefile
97 #ifdef CONFIG_CONCURRENT_MODE
98 	#define CONFIG_TSF_RESET_OFFLOAD			// For 2 PORT TSF SYNC.
99 	//#define CONFIG_HWPORT_SWAP				// Port0->Sec , Port1 -> Pri
100 	#define CONFIG_RUNTIME_PORT_SWITCH
101 	//#define DBG_RUNTIME_PORT_SWITCH
102 	#define CONFIG_SCAN_BACKOP
103 
104 	//#define CONFIG_MULTI_VIR_IFACES //besides primary&secondary interfaces, extend to support more interfaces
105 #endif // CONFIG_CONCURRENT_MODE
106 
107 #define CONFIG_LAYER2_ROAMING
108 #define CONFIG_LAYER2_ROAMING_RESUME
109 
110 #define CONFIG_80211D
111 
112 
113 /*
114  * Hareware/Firmware Related Config
115  */
116 //#define CONFIG_ANTENNA_DIVERSITY	// Set from Makefile
117 //#define SUPPORT_HW_RFOFF_DETECTED
118 
119 #define CONFIG_LED
120 #ifdef CONFIG_LED
121 	#define CONFIG_SW_LED
122 	#ifdef CONFIG_SW_LED
123 		//#define CONFIG_LED_HANDLED_BY_CMD_THREAD
124 	#endif
125 #endif // CONFIG_LED
126 
127 #define CONFIG_XMIT_ACK
128 #ifdef CONFIG_XMIT_ACK
129 	#define CONFIG_ACTIVE_KEEP_ALIVE_CHECK
130 #endif
131 
132 #define CONFIG_C2H_PACKET_EN
133 
134 #define CONFIG_RF_GAIN_OFFSET
135 
136 #define DISABLE_BB_RF	0
137 
138 #define RTW_NOTCH_FILTER 0 /* 0:Disable, 1:Enable, */
139 
140 /*
141  * Interface Related Config
142  */
143 #define CONFIG_USB_TX_AGGREGATION
144 #define CONFIG_USB_RX_AGGREGATION
145 
146 #define USB_INTERFERENCE_ISSUE // this should be checked in all usb interface
147 
148 #define CONFIG_GLOBAL_UI_PID
149 
150 #define CONFIG_OUT_EP_WIFI_MODE
151 
152 #define ENABLE_USB_DROP_INCORRECT_OUT
153 
154 //#define CONFIG_SUPPORT_USB_INT
155 #ifdef CONFIG_SUPPORT_USB_INT
156 //#define CONFIG_USB_INTERRUPT_IN_PIPE
157 #endif
158 
159 //#define CONFIG_REDUCE_USB_TX_INT	// Trade-off: Improve performance, but may cause TX URBs blocked by USB Host/Bus driver on few platforms.
160 
161 /*
162  * CONFIG_USE_USB_BUFFER_ALLOC_XX uses Linux USB Buffer alloc API and is for Linux platform only now!
163  */
164 //#define CONFIG_USE_USB_BUFFER_ALLOC_TX	// Trade-off: For TX path, improve stability on some platforms, but may cause performance degrade on other platforms.
165 //#define CONFIG_USE_USB_BUFFER_ALLOC_RX	// For RX path
166 
167 /*
168  * USB VENDOR REQ BUFFER ALLOCATION METHOD
169  * if not set we'll use function local variable (stack memory)
170  */
171 //#define CONFIG_USB_VENDOR_REQ_BUFFER_DYNAMIC_ALLOCATE
172 #define CONFIG_USB_VENDOR_REQ_BUFFER_PREALLOC
173 #define CONFIG_USB_VENDOR_REQ_MUTEX
174 #define CONFIG_VENDOR_REQ_RETRY
175 //#define CONFIG_USB_SUPPORT_ASYNC_VDN_REQ
176 
177 
178 /*
179  * Others
180  */
181 #define CONFIG_SKB_COPY	//for amsdu
182 
183 //#define CONFIG_EASY_REPLACEMENT
184 
185 //#define CONFIG_ADAPTOR_INFO_CACHING_FILE // now just applied on 8192cu only, should make it general...
186 
187 //#define CONFIG_RESUME_IN_WORKQUEUE
188 
189 //#define CONFIG_SET_SCAN_DENY_TIMER
190 
191 #define CONFIG_NEW_SIGNAL_STAT_PROCESS
192 
193 //#define CONFIG_SIGNAL_DISPLAY_DBM //display RX signal with dbm
194 #ifdef CONFIG_SIGNAL_DISPLAY_DBM
195 //#define CONFIG_BACKGROUND_NOISE_MONITOR
196 #endif
197 
198 //#define CONFIG_CHECK_AC_LIFETIME	// Check packet lifetime of 4 ACs.
199 
200 #define CONFIG_EMBEDDED_FWIMG
201 //#define CONFIG_FILE_FWIMG
202 
203 #define CONFIG_LONG_DELAY_ISSUE
204 #define CONFIG_ATTEMPT_TO_FIX_AP_BEACON_ERROR
205 
206 
207 /*
208  * Auto Config Section
209  */
210 #ifdef CONFIG_MINIMAL_MEMORY_USAGE
211 	#undef CONFIG_USB_TX_AGGREGATION
212 	#undef CONFIG_USB_RX_AGGREGATION
213 #endif
214 
215 #ifdef CONFIG_MP_INCLUDED
216 	#define MP_DRIVER	1
217 	#define CONFIG_MP_IWPRIV_SUPPORT
218 	//#undef CONFIG_USB_TX_AGGREGATION
219 	//#undef CONFIG_USB_RX_AGGREGATION
220 #else // !CONFIG_MP_INCLUDED
221 	#define MP_DRIVER	0
222 #endif // !CONFIG_MP_INCLUDED
223 
224 #ifdef CONFIG_POWER_SAVING
225 	#define CONFIG_IPS
226 	#define CONFIG_LPS
227 
228 	#ifdef CONFIG_IPS
229 	//#define CONFIG_IPS_LEVEL_2	1 //enable this to set default IPS mode to IPS_LEVEL_2
230 	#endif
231 
232 	#if defined(CONFIG_LPS) && defined(CONFIG_SUPPORT_USB_INT)
233 		//#define CONFIG_LPS_LCLK
234 	#endif
235 
236 	#ifdef CONFIG_LPS_LCLK
237 		#define CONFIG_XMIT_THREAD_MODE
238 	#endif
239 #endif // CONFIG_POWER_SAVING
240 
241 #ifdef CONFIG_BT_COEXIST
242 	// for ODM and outsrc BT-Coex
243 	#ifndef CONFIG_LPS
244 		#define CONFIG_LPS	// download reserved page to FW
245 	#endif
246 
247 	#ifndef CONFIG_C2H_PACKET_EN
248 		#define CONFIG_C2H_PACKET_EN
249 	#endif
250 #endif // !CONFIG_BT_COEXIST
251 
252 #ifdef CONFIG_WOWLAN
253 	//#define CONFIG_GTK_OL
254 #endif // CONFIG_WOWLAN
255 
256 #ifdef CONFIG_GPIO_WAKEUP
257 	#ifndef WAKEUP_GPIO_IDX
258 		#define WAKEUP_GPIO_IDX	14	// WIFI Chip Side
259 	#endif // !WAKEUP_GPIO_IDX
260 #endif // CONFIG_GPIO_WAKEUP
261 
262 #ifdef CONFIG_AP_MODE
263 	//#define CONFIG_INTERRUPT_BASED_TXBCN // Tx Beacon when driver BCN_OK ,BCN_ERR interrupt occurs
264 	#if defined(CONFIG_CONCURRENT_MODE) && defined(CONFIG_INTERRUPT_BASED_TXBCN)
265 		#undef CONFIG_INTERRUPT_BASED_TXBCN
266 	#endif
267 	#ifdef CONFIG_INTERRUPT_BASED_TXBCN
268 		//#define CONFIG_INTERRUPT_BASED_TXBCN_EARLY_INT
269 		#define CONFIG_INTERRUPT_BASED_TXBCN_BCN_OK_ERR
270 	#endif
271 #endif // CONFIG_AP_MODE
272 
273 #ifdef CONFIG_USE_USB_BUFFER_ALLOC_RX
274 
275 #else
276 	#define CONFIG_PREALLOC_RECV_SKB
277 	#ifdef CONFIG_PREALLOC_RECV_SKB
278 		//#define CONFIG_FIX_NR_BULKIN_BUFFER /* only use PREALLOC_RECV_SKB buffer, don't alloc skb at runtime */
279 	#endif
280 #endif
281 
282 #ifdef CONFIG_USB_TX_AGGREGATION
283 //#define CONFIG_TX_EARLY_MODE
284 #endif
285 
286 #ifdef CONFIG_TX_EARLY_MODE
287 #define RTL8723B_EARLY_MODE_PKT_NUM_10	0
288 #endif
289 
290 
291 
292 /*
293  * Debug Related Config
294  */
295 #define CONFIG_DEBUG /* DBG_871X, etc... */
296 
297 #ifdef CONFIG_DEBUG
298 #define DBG	1	// for ODM & BTCOEX debug
299 //#define CONFIG_DEBUG_RTL871X /* RT_TRACE, RT_PRINT_DATA, _func_enter_, _func_exit_ */
300 #else // !CONFIG_DEBUG
301 #define DBG	0	// for ODM & BTCOEX debug
302 #endif // !CONFIG_DEBUG
303 
304 #define CONFIG_PROC_DEBUG
305 
306 //#define DBG_CONFIG_ERROR_DETECT
307 //#define DBG_CONFIG_ERROR_DETECT_INT
308 //#define DBG_CONFIG_ERROR_RESET
309 
310 //#define DBG_IO
311 //#define DBG_DELAY_OS
312 //#define DBG_MEM_ALLOC
313 //#define DBG_IOCTL
314 
315 //#define DBG_TX
316 //#define DBG_XMIT_BUF
317 //#define DBG_XMIT_BUF_EXT
318 //#define DBG_TX_DROP_FRAME
319 
320 //#define DBG_RX_DROP_FRAME
321 //#define DBG_RX_SEQ
322 //#define DBG_RX_SIGNAL_DISPLAY_PROCESSING
323 //#define DBG_RX_SIGNAL_DISPLAY_SSID_MONITORED "rtw-ap"
324 
325 
326 //#define DBG_SHOW_MCUFWDL_BEFORE_51_ENABLE
327 //#define DBG_ROAMING_TEST
328 
329 //#define DBG_HAL_INIT_PROFILING
330 
331 //#define DBG_MEMORY_LEAK	1
332 
333