1 /******************************************************************************
3 * Copyright(c) 2007 - 2014 Realtek Corporation. All rights reserved.
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.
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
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
19 ******************************************************************************/
21 * Public General Config
23 #define AUTOCONF_INCLUDED
25 #define RTL871X_MODULE_NAME "8723CS"
26 #define DRV_NAME "rtl8723cs"
28 #ifndef CONFIG_RTL8703B
29 #define CONFIG_RTL8703B
31 #define CONFIG_SDIO_HCI
33 #define PLATFORM_LINUX
37 * Wi-Fi Functions Config
39 #define CONFIG_80211N_HT
40 #define CONFIG_RECV_REORDERING_CTRL
42 /* #define CONFIG_IOCTL_CFG80211 */ /* Set from Makefile */
43 #ifdef CONFIG_IOCTL_CFG80211
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!
50 /* #define RTW_USE_CFG80211_STA_EVENT */ /* Indecate new sta asoc through cfg80211_new_sta */
51 #ifndef CONFIG_PLATFORM_INTEL_BYT
52 #define CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER
53 #endif /* !CONFIG_PLATFORM_INTEL_BYT */
54 /* #define CONFIG_DEBUG_CFG80211 */
55 #define CONFIG_SET_SCAN_DENY_TIMER
56 /*#define SUPPLICANT_RTK_VERSION_LOWER_THAN_JB42*/ /* wpa_supplicant realtek version <= jb42 will be defined this */
59 #define CONFIG_AP_MODE
61 #define CONFIG_NATIVEAP_MLME
62 #ifndef CONFIG_NATIVEAP_MLME
63 #define CONFIG_HOSTAPD_MLME
65 /* #define CONFIG_FIND_BEST_CHANNEL */
66 #define CONFIG_TX_MCAST2UNI /* Support IP multicast->unicast */
71 /* Added by Albert 20110812
72 The CONFIG_WFD is for supporting the Wi-Fi display */
75 #define CONFIG_P2P_REMOVE_GROUP_INFO
77 /* #define CONFIG_DBG_P2P */
79 #define CONFIG_P2P_OP_CHK_SOCIAL_CH
80 #define CONFIG_CFG80211_ONECHANNEL_UNDER_CONCURRENT /* replace CONFIG_P2P_CHK_INVITE_CH_LIST flag */
81 #define CONFIG_P2P_INVITE_IOT
84 /* Added by Kurt 20110511 */
86 #define CONFIG_TDLS_DRIVER_SETUP
90 /* #define CONFIG_TDLS_AUTOSETUP */
91 #define CONFIG_TDLS_AUTOCHECKALIVE
92 #define CONFIG_TDLS_CH_SW /* Enable this flag only when we confirm that TDLS CH SW is supported in FW */
95 /* #define CONFIG_CONCURRENT_MODE */ /* Set from Makefile */
96 #ifdef CONFIG_CONCURRENT_MODE
97 #define CONFIG_RUNTIME_PORT_SWITCH
98 /* #define DBG_RUNTIME_PORT_SWITCH */
101 #ifndef CONFIG_RUNTIME_PORT_SWITCH
102 #define CONFIG_TSF_RESET_OFFLOAD /* For 2 PORT TSF SYNC. */
104 /* #define DBG_RUNTIME_PORT_SWITCH */
105 #define CONFIG_SCAN_BACKOP
106 #endif /* CONFIG_CONCURRENT_MODE */
108 #define CONFIG_LAYER2_ROAMING
109 #define CONFIG_LAYER2_ROAMING_RESUME
111 /* #define CONFIG_80211D */
115 * Hareware/Firmware Related Config
117 /* #define CONFIG_BT_COEXIST */ /* Set from Makefile */
118 /* #define CONFIG_ANTENNA_DIVERSITY */ /* Set from Makefile */
119 /* #define SUPPORT_HW_RFOFF_DETECTED */
121 /* #define CONFIG_SW_LED */
123 #define CONFIG_XMIT_ACK
124 #ifdef CONFIG_XMIT_ACK
125 #define CONFIG_ACTIVE_KEEP_ALIVE_CHECK
128 #define CONFIG_RF_POWER_TRIM
130 #define DISABLE_BB_RF 0
132 #define RTW_NOTCH_FILTER 0 /* 0:Disable, 1:Enable, */
136 * Interface Related Config
138 #define CONFIG_TX_AGGREGATION
139 #define CONFIG_SDIO_RX_COPY
140 #define CONFIG_XMIT_THREAD_MODE
141 /* #define CONFIG_SDIO_TX_ENABLE_AVAL_INT */
147 /* #define CONFIG_MAC_LOOPBACK_DRIVER */
149 #define CONFIG_SKB_COPY /* for amsdu */
151 #define CONFIG_NEW_SIGNAL_STAT_PROCESS
153 #define CONFIG_EMBEDDED_FWIMG
155 #ifdef CONFIG_EMBEDDED_FWIMG
156 #define LOAD_FW_HEADER_FROM_DRIVER
158 /* #define CONFIG_FILE_FWIMG */
160 #define CONFIG_LONG_DELAY_ISSUE
161 /* #define CONFIG_PATCH_JOIN_WRONG_CHANNEL */
162 #define CONFIG_ATTEMPT_TO_FIX_AP_BEACON_ERROR
166 * Auto Config Section
168 #ifdef CONFIG_MAC_LOOPBACK_DRIVER
169 #undef CONFIG_IOCTL_CFG80211
170 #undef CONFIG_AP_MODE
171 #undef CONFIG_NATIVEAP_MLME
172 #undef CONFIG_POWER_SAVING
173 #undef CONFIG_BT_COEXIST
174 #undef CONFIG_ANTENNA_DIVERSITY
175 #undef SUPPORT_HW_RFOFF_DETECTED
178 #ifdef CONFIG_MP_INCLUDED
180 #define CONFIG_MP_IWPRIV_SUPPORT
181 /* disable unnecessary functions for MP */
182 /* #undef CONFIG_POWER_SAVING
183 #undef CONFIG_BT_COEXIST
184 #undef CONFIG_ANTENNA_DIVERSITY
185 #undef SUPPORT_HW_RFOFF_DETECTED */
186 #else /* !CONFIG_MP_INCLUDED */
188 #undef CONFIG_MP_IWPRIV_SUPPORT
189 #endif /* !CONFIG_MP_INCLUDED */
191 #ifdef CONFIG_POWER_SAVING
195 #if defined(CONFIG_LPS) && (defined(CONFIG_GSPI_HCI) || defined(CONFIG_SDIO_HCI))
196 #define CONFIG_LPS_LCLK
200 #define CONFIG_CHECK_LEAVE_LPS
201 #ifndef CONFIG_PLATFORM_INTEL_BYT
202 #define CONFIG_LPS_SLOW_TRANSITION
203 #endif /* !CONFIG_PLATFORM_INTEL_BYT */
206 #ifdef CONFIG_LPS_LCLK
207 #define CONFIG_DETECT_CPWM_BY_POLLING
208 #define CONFIG_LPS_RPWM_TIMER
209 #if defined(CONFIG_LPS_RPWM_TIMER) || defined(CONFIG_DETECT_CPWM_BY_POLLING)
210 #define LPS_RPWM_WAIT_MS 300
212 #define CONFIG_LPS_LCLK_WD_TIMER /* Watch Dog timer in LPS LCLK */
216 #define CONFIG_IPS_CHECK_IN_WD /* Do IPS Check in WatchDog. */
217 /* #define CONFIG_SWLPS_IN_IPS */ /* Do SW LPS flow when entering and leaving IPS */
218 /* #define CONFIG_FWLPS_IN_IPS */ /* issue H2C command to let FW do LPS when entering IPS */
220 #endif /* CONFIG_POWER_SAVING */
222 #ifdef CONFIG_BT_COEXIST
223 /* for ODM and outsrc BT-Coex */
225 #define CONFIG_LPS /* download reserved page to FW */
227 #endif /* !CONFIG_BT_COEXIST */
230 /* #define CONFIG_GTK_OL */
231 #define CONFIG_ARP_KEEP_ALIVE
232 #endif /* CONFIG_WOWLAN */
234 #ifdef CONFIG_GPIO_WAKEUP
235 #ifndef WAKEUP_GPIO_IDX
236 #define WAKEUP_GPIO_IDX 8 /* WIFI Chip Side */
237 #endif /* !WAKEUP_GPIO_IDX */
238 #endif /* CONFIG_GPIO_WAKEUP */
242 #ifdef CONFIG_ANTENNA_DIVERSITY
243 #define CONFIG_HW_ANTENNA_DIVERSITY
250 #ifdef CONFIG_PLATFORM_SPRD
252 #undef CONFIG_SDIO_RX_COPY
256 #define CONFIG_SDIO_RX_COPY
258 #else /* !ANDROID_2X */
260 #undef CONFIG_WOWLAN_8723
261 /* #define CONFIG_SDIO_RX_COPY */
262 /* #define CONFIG_LINKED_LCOK */
263 #define CONFIG_AUTH_DIRECT_WITHOUT_BCN
264 /* #define CONFIG_DISCONNECT_H2CWAY */
265 /* #define CONFIG_DONT_CARE_TP */
266 #define CONFIG_LOW_PWR_LPS
267 /* #define CONFIG_CMCC_TEST */
269 /* 1) LPS unit is only 102 ms, it's not
270 a good idear to retry it use timer,
271 2) we must wait ACK, or lots of IO
272 is not allowed under 32k, because
273 this will cause hw hang */
274 #undef CONFIG_LPS_RPWM_TIMER
275 #define CONFIG_WAIT_PS_ACK
276 #define CONFIG_SOFTAP_11N
277 #define CONFIG_CHECK_BT_HANG
279 /* #define CONFIG_8703BS_TEST */
280 #endif /* !ANDROID_2X */
282 #endif /* CONFIG_PLATFORM_SPRD */
286 * Debug Related Config
288 #ifdef CONFIG_RTW_DEBUG
289 #define DBG 1 /* for ODM & BTCOEX debug */
290 #else /* !CONFIG_RTW_DEBUG */
291 #define DBG 0 /* for ODM & BTCOEX debug */
292 #endif /* !CONFIG_RTW_DEBUG */
294 #define CONFIG_PROC_DEBUG
296 #define DBG_CONFIG_ERROR_DETECT
297 /* #define DBG_XMIT_BUF */
298 /* #define DBG_XMIT_BUF_EXT */
299 #define DBG_CHECK_FW_PS_STATE
300 #define DBG_CHECK_FW_PS_STATE_H2C
301 /* #define CONFIG_FW_C2H_DEBUG */
302 #define DBG_RX_DFRAME_RAW_DATA