blob: f96c63ea65a921d4ad8496b9f1a478c5d810fd69 [file] [log] [blame]
Jeff Johnson2c24a3b2012-12-10 12:28:11 -08001# We can build either as part of a standalone Kernel build or part
2# of an Android build. Determine which mechanism is being used
3ifeq ($(MODNAME),)
4 KERNEL_BUILD := 1
5else
6 KERNEL_BUILD := 0
7endif
8
9ifeq ($(KERNEL_BUILD),1)
10 # These are provided in Android-based builds
11 # Need to explicitly define for Kernel-based builds
12 MODNAME := wlan
Jeff Johnson91a420a2012-12-16 11:16:18 -080013 WLAN_ROOT := drivers/staging/prima
Jeff Johnson2c24a3b2012-12-10 12:28:11 -080014endif
15
16ifeq ($(KERNEL_BUILD),0)
17 # These are configurable via Kconfig for kernel-based builds
18 # Need to explicitly configure for Android-based builds
19
Jeff Johnson2c24a3b2012-12-10 12:28:11 -080020 #Flag to enable BlueTooth AMP feature
21 CONFIG_PRIMA_WLAN_BTAMP := n
22
23 #Flag to enable Legacy Fast Roaming(LFR)
24 CONFIG_PRIMA_WLAN_LFR := y
25
26 #JB kernel has PMKSA patches, hence enabling this flag
27 CONFIG_PRIMA_WLAN_OKC := y
28
29 # JB kernel has CPU enablement patches, so enable
30 CONFIG_PRIMA_WLAN_11AC_HIGH_TP := y
Kiran Venkatappad52a3c72012-12-27 17:25:33 -080031
32 #Flag to enable TDLS feature
33 CONFIG_QCOM_TDLS := y
Gopichand Nakkalad7d13652013-02-15 01:48:00 +053034
35 #Flag to enable Fast Transition (11r) feature
Gopichand Nakkalafebb97e2013-04-18 19:25:48 +053036 CONFIG_QCOM_VOWIFI_11R := y
Gopichand Nakkalad7d13652013-02-15 01:48:00 +053037
Chet Lanctot6802b302013-04-04 16:50:46 -070038 #Flag to enable Protected Managment Frames (11w) feature
39 ifneq ($(CONFIG_PRONTO_WLAN),)
40 CONFIG_WLAN_FEATURE_11W := y
41 endif
42
Jeff Johnson2c24a3b2012-12-10 12:28:11 -080043endif
44
45# Feature flags which are not (currently) configurable via Kconfig
46
Jeff Johnson25abf4d2012-12-01 12:42:42 -080047#Whether to build debug version
48BUILD_DEBUG_VERSION := 1
49
50#Enable this flag to build driver in diag version
51BUILD_DIAG_VERSION := 0
Jeff Johnson25abf4d2012-12-01 12:42:42 -080052
53#Do we panic on bug? default is to warn
Sameer Thalappil451ebb92013-06-28 15:49:58 -070054PANIC_ON_BUG := 1
Jeff Johnson25abf4d2012-12-01 12:42:42 -080055
56#Re-enable wifi on WDI timeout
57RE_ENABLE_WIFI_ON_WDI_TIMEOUT := 0
58
Jeff Johnson25abf4d2012-12-01 12:42:42 -080059
60ifeq ($(CONFIG_CFG80211),y)
61HAVE_CFG80211 := 1
62else
63ifeq ($(CONFIG_CFG80211),m)
64HAVE_CFG80211 := 1
Jeff Johnson25abf4d2012-12-01 12:42:42 -080065else
66HAVE_CFG80211 := 0
67endif
68endif
69
Jeff Johnson2c24a3b2012-12-10 12:28:11 -080070############ BAP ############
71BAP_DIR := CORE/BAP
72BAP_INC_DIR := $(BAP_DIR)/inc
73BAP_SRC_DIR := $(BAP_DIR)/src
74
Jeff Johnson91a420a2012-12-16 11:16:18 -080075BAP_INC := -I$(WLAN_ROOT)/$(BAP_INC_DIR) \
76 -I$(WLAN_ROOT)/$(BAP_SRC_DIR)
Jeff Johnson2c24a3b2012-12-10 12:28:11 -080077
78BAP_OBJS := $(BAP_SRC_DIR)/bapApiData.o \
79 $(BAP_SRC_DIR)/bapApiDebug.o \
80 $(BAP_SRC_DIR)/bapApiExt.o \
81 $(BAP_SRC_DIR)/bapApiHCBB.o \
82 $(BAP_SRC_DIR)/bapApiInfo.o \
83 $(BAP_SRC_DIR)/bapApiLinkCntl.o \
84 $(BAP_SRC_DIR)/bapApiLinkSupervision.o \
85 $(BAP_SRC_DIR)/bapApiStatus.o \
86 $(BAP_SRC_DIR)/bapApiTimer.o \
87 $(BAP_SRC_DIR)/bapModule.o \
88 $(BAP_SRC_DIR)/bapRsn8021xAuthFsm.o \
89 $(BAP_SRC_DIR)/bapRsn8021xPrf.o \
90 $(BAP_SRC_DIR)/bapRsn8021xSuppRsnFsm.o \
91 $(BAP_SRC_DIR)/bapRsnAsfPacket.o \
92 $(BAP_SRC_DIR)/bapRsnSsmAesKeyWrap.o \
93 $(BAP_SRC_DIR)/bapRsnSsmEapol.o \
94 $(BAP_SRC_DIR)/bapRsnSsmReplayCtr.o \
95 $(BAP_SRC_DIR)/bapRsnTxRx.o \
96 $(BAP_SRC_DIR)/btampFsm.o \
97 $(BAP_SRC_DIR)/btampHCI.o
98
99############ DXE ############
100DXE_DIR := CORE/DXE
101DXE_INC_DIR := $(DXE_DIR)/inc
102DXE_SRC_DIR := $(DXE_DIR)/src
103
Jeff Johnson91a420a2012-12-16 11:16:18 -0800104DXE_INC := -I$(WLAN_ROOT)/$(DXE_INC_DIR) \
105 -I$(WLAN_ROOT)/$(DXE_SRC_DIR)
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800106
107DXE_OBJS = $(DXE_SRC_DIR)/wlan_qct_dxe.o \
108 $(DXE_SRC_DIR)/wlan_qct_dxe_cfg_i.o
109
110############ HDD ############
111HDD_DIR := CORE/HDD
112HDD_INC_DIR := $(HDD_DIR)/inc
113HDD_SRC_DIR := $(HDD_DIR)/src
114
Jeff Johnson91a420a2012-12-16 11:16:18 -0800115HDD_INC := -I$(WLAN_ROOT)/$(HDD_INC_DIR) \
116 -I$(WLAN_ROOT)/$(HDD_SRC_DIR)
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800117
118HDD_OBJS := $(HDD_SRC_DIR)/bap_hdd_main.o \
119 $(HDD_SRC_DIR)/wlan_hdd_assoc.o \
120 $(HDD_SRC_DIR)/wlan_hdd_cfg.o \
121 $(HDD_SRC_DIR)/wlan_hdd_dev_pwr.o \
122 $(HDD_SRC_DIR)/wlan_hdd_dp_utils.o \
123 $(HDD_SRC_DIR)/wlan_hdd_early_suspend.o \
124 $(HDD_SRC_DIR)/wlan_hdd_ftm.o \
125 $(HDD_SRC_DIR)/wlan_hdd_hostapd.o \
126 $(HDD_SRC_DIR)/wlan_hdd_oemdata.o \
127 $(HDD_SRC_DIR)/wlan_hdd_main.o \
128 $(HDD_SRC_DIR)/wlan_hdd_mib.o \
129 $(HDD_SRC_DIR)/wlan_hdd_scan.o \
130 $(HDD_SRC_DIR)/wlan_hdd_softap_tx_rx.o \
131 $(HDD_SRC_DIR)/wlan_hdd_tx_rx.o \
132 $(HDD_SRC_DIR)/wlan_hdd_wext.o \
133 $(HDD_SRC_DIR)/wlan_hdd_wmm.o \
134 $(HDD_SRC_DIR)/wlan_hdd_wowl.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800135
136ifeq ($(HAVE_CFG80211),1)
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800137HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_cfg80211.o \
138 $(HDD_SRC_DIR)/wlan_hdd_p2p.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800139endif
140
141ifeq ($(CONFIG_QCOM_TDLS),y)
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800142HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_tdls.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800143endif
144
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800145############ MAC ############
146MAC_DIR := CORE/MAC
147MAC_INC_DIR := $(MAC_DIR)/inc
148MAC_SRC_DIR := $(MAC_DIR)/src
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800149
Jeff Johnson91a420a2012-12-16 11:16:18 -0800150MAC_INC := -I$(WLAN_ROOT)/$(MAC_INC_DIR) \
151 -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/dph \
152 -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/include \
153 -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/pe/include \
154 -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/pe/lim
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800155
156MAC_CFG_OBJS := $(MAC_SRC_DIR)/cfg/cfgApi.o \
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800157 $(MAC_SRC_DIR)/cfg/cfgDebug.o \
158 $(MAC_SRC_DIR)/cfg/cfgParamName.o \
159 $(MAC_SRC_DIR)/cfg/cfgProcMsg.o \
160 $(MAC_SRC_DIR)/cfg/cfgSendMsg.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800161
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800162MAC_DPH_OBJS := $(MAC_SRC_DIR)/dph/dphHashTable.o
163
164MAC_LIM_OBJS := $(MAC_SRC_DIR)/pe/lim/limAIDmgmt.o \
165 $(MAC_SRC_DIR)/pe/lim/limAdmitControl.o \
166 $(MAC_SRC_DIR)/pe/lim/limApi.o \
167 $(MAC_SRC_DIR)/pe/lim/limAssocUtils.o \
168 $(MAC_SRC_DIR)/pe/lim/limDebug.o \
169 $(MAC_SRC_DIR)/pe/lim/limFT.o \
170 $(MAC_SRC_DIR)/pe/lim/limIbssPeerMgmt.o \
171 $(MAC_SRC_DIR)/pe/lim/limLinkMonitoringAlgo.o \
172 $(MAC_SRC_DIR)/pe/lim/limLogDump.o \
173 $(MAC_SRC_DIR)/pe/lim/limP2P.o \
174 $(MAC_SRC_DIR)/pe/lim/limProcessActionFrame.o \
175 $(MAC_SRC_DIR)/pe/lim/limProcessAssocReqFrame.o \
176 $(MAC_SRC_DIR)/pe/lim/limProcessAssocRspFrame.o \
177 $(MAC_SRC_DIR)/pe/lim/limProcessAuthFrame.o \
178 $(MAC_SRC_DIR)/pe/lim/limProcessBeaconFrame.o \
179 $(MAC_SRC_DIR)/pe/lim/limProcessCfgUpdates.o \
180 $(MAC_SRC_DIR)/pe/lim/limProcessDeauthFrame.o \
181 $(MAC_SRC_DIR)/pe/lim/limProcessDisassocFrame.o \
182 $(MAC_SRC_DIR)/pe/lim/limProcessLmmMessages.o \
183 $(MAC_SRC_DIR)/pe/lim/limProcessMessageQueue.o \
184 $(MAC_SRC_DIR)/pe/lim/limProcessMlmReqMessages.o \
185 $(MAC_SRC_DIR)/pe/lim/limProcessMlmRspMessages.o \
186 $(MAC_SRC_DIR)/pe/lim/limProcessProbeReqFrame.o \
187 $(MAC_SRC_DIR)/pe/lim/limProcessProbeRspFrame.o \
188 $(MAC_SRC_DIR)/pe/lim/limProcessSmeReqMessages.o \
189 $(MAC_SRC_DIR)/pe/lim/limPropExtsUtils.o \
190 $(MAC_SRC_DIR)/pe/lim/limRoamingAlgo.o \
191 $(MAC_SRC_DIR)/pe/lim/limScanResultUtils.o \
192 $(MAC_SRC_DIR)/pe/lim/limSecurityUtils.o \
193 $(MAC_SRC_DIR)/pe/lim/limSendManagementFrames.o \
194 $(MAC_SRC_DIR)/pe/lim/limSendMessages.o \
195 $(MAC_SRC_DIR)/pe/lim/limSendSmeRspMessages.o \
196 $(MAC_SRC_DIR)/pe/lim/limSerDesUtils.o \
197 $(MAC_SRC_DIR)/pe/lim/limSession.o \
198 $(MAC_SRC_DIR)/pe/lim/limSessionUtils.o \
199 $(MAC_SRC_DIR)/pe/lim/limSmeReqUtils.o \
200 $(MAC_SRC_DIR)/pe/lim/limStaHashApi.o \
201 $(MAC_SRC_DIR)/pe/lim/limTimerUtils.o \
202 $(MAC_SRC_DIR)/pe/lim/limTrace.o \
203 $(MAC_SRC_DIR)/pe/lim/limUtils.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800204
205ifeq ($(CONFIG_QCOM_CCX),y)
206MAC_LIM_OBJS += $(MAC_SRC_DIR)/pe/lim/limProcessCcxFrame.o
207endif
208
209ifeq ($(CONFIG_QCOM_TDLS),y)
210MAC_LIM_OBJS += $(MAC_SRC_DIR)/pe/lim/limProcessTdls.o
211endif
212
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800213MAC_PMM_OBJS := $(MAC_SRC_DIR)/pe/pmm/pmmAP.o \
214 $(MAC_SRC_DIR)/pe/pmm/pmmApi.o \
215 $(MAC_SRC_DIR)/pe/pmm/pmmDebug.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800216
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800217MAC_SCH_OBJS := $(MAC_SRC_DIR)/pe/sch/schApi.o \
218 $(MAC_SRC_DIR)/pe/sch/schBeaconGen.o \
219 $(MAC_SRC_DIR)/pe/sch/schBeaconProcess.o \
220 $(MAC_SRC_DIR)/pe/sch/schDebug.o \
221 $(MAC_SRC_DIR)/pe/sch/schMessage.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800222
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800223MAC_RRM_OBJS := $(MAC_SRC_DIR)/pe/rrm/rrmApi.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800224
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800225MAC_OBJS := $(MAC_CFG_OBJS) \
226 $(MAC_DPH_OBJS) \
227 $(MAC_LIM_OBJS) \
228 $(MAC_PMM_OBJS) \
229 $(MAC_SCH_OBJS) \
230 $(MAC_RRM_OBJS)
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800231
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800232############ SAP ############
233SAP_DIR := CORE/SAP
234SAP_INC_DIR := $(SAP_DIR)/inc
235SAP_SRC_DIR := $(SAP_DIR)/src
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800236
Jeff Johnson91a420a2012-12-16 11:16:18 -0800237SAP_INC := -I$(WLAN_ROOT)/$(SAP_INC_DIR) \
238 -I$(WLAN_ROOT)/$(SAP_SRC_DIR)
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800239
240SAP_OBJS := $(SAP_SRC_DIR)/sapApiLinkCntl.o \
241 $(SAP_SRC_DIR)/sapChSelect.o \
242 $(SAP_SRC_DIR)/sapFsm.o \
243 $(SAP_SRC_DIR)/sapModule.o
244
245############ SME ############
246SME_DIR := CORE/SME
247SME_INC_DIR := $(SME_DIR)/inc
248SME_SRC_DIR := $(SME_DIR)/src
249
Jeff Johnson91a420a2012-12-16 11:16:18 -0800250SME_INC := -I$(WLAN_ROOT)/$(SME_INC_DIR) \
251 -I$(WLAN_ROOT)/$(SME_SRC_DIR)/csr
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800252
253SME_CCM_OBJS := $(SME_SRC_DIR)/ccm/ccmApi.o \
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800254 $(SME_SRC_DIR)/ccm/ccmLogDump.o
255
256SME_CSR_OBJS := $(SME_SRC_DIR)/csr/csrApiRoam.o \
257 $(SME_SRC_DIR)/csr/csrApiScan.o \
258 $(SME_SRC_DIR)/csr/csrCmdProcess.o \
259 $(SME_SRC_DIR)/csr/csrLinkList.o \
260 $(SME_SRC_DIR)/csr/csrLogDump.o \
261 $(SME_SRC_DIR)/csr/csrNeighborRoam.o \
262 $(SME_SRC_DIR)/csr/csrUtil.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800263
264ifeq ($(CONFIG_QCOM_CCX),y)
Jeff Johnson91a420a2012-12-16 11:16:18 -0800265SME_CSR_OBJS += $(SME_SRC_DIR)/csr/csrCcx.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800266endif
267
268ifeq ($(CONFIG_QCOM_TDLS),y)
269SME_CSR_OBJS += $(SME_SRC_DIR)/csr/csrTdlsProcess.o
270endif
271
272SME_PMC_OBJS := $(SME_SRC_DIR)/pmc/pmcApi.o \
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800273 $(SME_SRC_DIR)/pmc/pmc.o \
274 $(SME_SRC_DIR)/pmc/pmcLogDump.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800275
276SME_QOS_OBJS := $(SME_SRC_DIR)/QoS/sme_Qos.o
277
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800278SME_CMN_OBJS := $(SME_SRC_DIR)/sme_common/sme_Api.o \
279 $(SME_SRC_DIR)/sme_common/sme_FTApi.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800280
281SME_BTC_OBJS := $(SME_SRC_DIR)/btc/btcApi.o
282
283SME_OEM_DATA_OBJS := $(SME_SRC_DIR)/oemData/oemDataApi.o
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800284
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800285SME_P2P_OBJS = $(SME_SRC_DIR)/p2p/p2p_Api.o
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800286
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800287SME_RRM_OBJS := $(SME_SRC_DIR)/rrm/sme_rrm.o
288
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800289SME_OBJS := $(SME_BTC_OBJS) \
290 $(SME_CCM_OBJS) \
291 $(SME_CMN_OBJS) \
292 $(SME_CSR_OBJS) \
293 $(SME_OEM_DATA_OBJS) \
294 $(SME_P2P_OBJS) \
295 $(SME_PMC_OBJS) \
296 $(SME_QOS_OBJS) \
297 $(SME_RRM_OBJS)
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800298
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800299############ SVC ############
300SVC_DIR := CORE/SVC
301SVC_INC_DIR := $(SVC_DIR)/inc
302SVC_SRC_DIR := $(SVC_DIR)/src
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800303
Jeff Johnson91a420a2012-12-16 11:16:18 -0800304SVC_INC := -I$(WLAN_ROOT)/$(SVC_INC_DIR) \
305 -I$(WLAN_ROOT)/$(SVC_DIR)/external
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800306
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800307BTC_SRC_DIR := $(SVC_SRC_DIR)/btc
308BTC_OBJS := $(BTC_SRC_DIR)/wlan_btc_svc.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800309
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800310NLINK_SRC_DIR := $(SVC_SRC_DIR)/nlink
311NLINK_OBJS := $(NLINK_SRC_DIR)/wlan_nlink_srv.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800312
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800313PTT_SRC_DIR := $(SVC_SRC_DIR)/ptt
314PTT_OBJS := $(PTT_SRC_DIR)/wlan_ptt_sock_svc.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800315
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800316SVC_OBJS := $(BTC_OBJS) \
317 $(NLINK_OBJS) \
318 $(PTT_OBJS)
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800319
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800320############ SYS ############
321SYS_DIR := CORE/SYS
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800322
Jeff Johnson91a420a2012-12-16 11:16:18 -0800323SYS_INC := -I$(WLAN_ROOT)/$(SYS_DIR)/common/inc \
324 -I$(WLAN_ROOT)/$(SYS_DIR)/legacy/src/pal/inc \
325 -I$(WLAN_ROOT)/$(SYS_DIR)/legacy/src/platform/inc \
326 -I$(WLAN_ROOT)/$(SYS_DIR)/legacy/src/system/inc \
327 -I$(WLAN_ROOT)/$(SYS_DIR)/legacy/src/utils/inc
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800328
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800329SYS_COMMON_SRC_DIR := $(SYS_DIR)/common/src
330SYS_LEGACY_SRC_DIR := $(SYS_DIR)/legacy/src
331SYS_OBJS := $(SYS_COMMON_SRC_DIR)/wlan_qct_sys.o \
332 $(SYS_LEGACY_SRC_DIR)/pal/src/palApiComm.o \
333 $(SYS_LEGACY_SRC_DIR)/pal/src/palTimer.o \
334 $(SYS_LEGACY_SRC_DIR)/platform/src/VossWrapper.o \
335 $(SYS_LEGACY_SRC_DIR)/system/src/macInitApi.o \
336 $(SYS_LEGACY_SRC_DIR)/system/src/sysEntryFunc.o \
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800337 $(SYS_LEGACY_SRC_DIR)/utils/src/dot11f.o \
338 $(SYS_LEGACY_SRC_DIR)/utils/src/logApi.o \
339 $(SYS_LEGACY_SRC_DIR)/utils/src/logDump.o \
340 $(SYS_LEGACY_SRC_DIR)/utils/src/macTrace.o \
341 $(SYS_LEGACY_SRC_DIR)/utils/src/parserApi.o \
342 $(SYS_LEGACY_SRC_DIR)/utils/src/utilsApi.o \
343 $(SYS_LEGACY_SRC_DIR)/utils/src/utilsParser.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800344
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800345ifeq ($(CONFIG_QCOM_CCX),y)
346SYS_OBJS += $(SYS_LEGACY_SRC_DIR)/utils/src/limCcxparserApi.o
347endif
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800348
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800349############ TL ############
350TL_DIR := CORE/TL
351TL_INC_DIR := $(TL_DIR)/inc
352TL_SRC_DIR := $(TL_DIR)/src
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800353
Jeff Johnson91a420a2012-12-16 11:16:18 -0800354TL_INC := -I$(WLAN_ROOT)/$(TL_INC_DIR) \
355 -I$(WLAN_ROOT)/$(TL_SRC_DIR)
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800356
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800357TL_OBJS := $(TL_SRC_DIR)/wlan_qct_tl.o \
358 $(TL_SRC_DIR)/wlan_qct_tl_ba.o \
359 $(TL_SRC_DIR)/wlan_qct_tl_hosupport.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800360
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800361############ VOSS ############
362VOSS_DIR := CORE/VOSS
363VOSS_INC_DIR := $(VOSS_DIR)/inc
364VOSS_SRC_DIR := $(VOSS_DIR)/src
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800365
Jeff Johnson91a420a2012-12-16 11:16:18 -0800366VOSS_INC := -I$(WLAN_ROOT)/$(VOSS_INC_DIR) \
367 -I$(WLAN_ROOT)/$(VOSS_SRC_DIR)
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800368
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800369VOSS_OBJS := $(VOSS_SRC_DIR)/vos_api.o \
370 $(VOSS_SRC_DIR)/vos_event.o \
371 $(VOSS_SRC_DIR)/vos_getBin.o \
372 $(VOSS_SRC_DIR)/vos_list.o \
373 $(VOSS_SRC_DIR)/vos_lock.o \
374 $(VOSS_SRC_DIR)/vos_memory.o \
375 $(VOSS_SRC_DIR)/vos_mq.o \
376 $(VOSS_SRC_DIR)/vos_nvitem.o \
377 $(VOSS_SRC_DIR)/vos_packet.o \
378 $(VOSS_SRC_DIR)/vos_power.o \
379 $(VOSS_SRC_DIR)/vos_sched.o \
380 $(VOSS_SRC_DIR)/vos_threads.o \
381 $(VOSS_SRC_DIR)/vos_timer.o \
382 $(VOSS_SRC_DIR)/vos_trace.o \
383 $(VOSS_SRC_DIR)/vos_types.o \
384 $(VOSS_SRC_DIR)/vos_utils.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800385
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800386ifeq ($(BUILD_DIAG_VERSION),1)
387VOSS_OBJS += $(VOSS_SRC_DIR)/vos_diag.o
388endif
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800389
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800390############ WDA ############
391WDA_DIR := CORE/WDA
392WDA_INC_DIR := $(WDA_DIR)/inc
393WDA_SRC_DIR := $(WDA_DIR)/src
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800394
Jeff Johnson91a420a2012-12-16 11:16:18 -0800395WDA_INC := -I$(WLAN_ROOT)/$(WDA_INC_DIR) \
396 -I$(WLAN_ROOT)/$(WDA_INC_DIR)/legacy \
397 -I$(WLAN_ROOT)/$(WDA_SRC_DIR)
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800398
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800399WDA_OBJS := $(WDA_SRC_DIR)/wlan_qct_wda.o \
400 $(WDA_SRC_DIR)/wlan_qct_wda_debug.o \
401 $(WDA_SRC_DIR)/wlan_qct_wda_ds.o \
402 $(WDA_SRC_DIR)/wlan_qct_wda_legacy.o \
403 $(WDA_SRC_DIR)/wlan_nv.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800404
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800405############ WDI ############
406WDI_DIR := CORE/WDI
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800407
Jeff Johnson91a420a2012-12-16 11:16:18 -0800408WDI_CP_INC := -I$(WLAN_ROOT)/$(WDI_DIR)/CP/inc/
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800409
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800410WDI_CP_SRC_DIR := $(WDI_DIR)/CP/src
411WDI_CP_OBJS := $(WDI_CP_SRC_DIR)/wlan_qct_wdi.o \
412 $(WDI_CP_SRC_DIR)/wlan_qct_wdi_dp.o \
413 $(WDI_CP_SRC_DIR)/wlan_qct_wdi_sta.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800414
Jeff Johnson91a420a2012-12-16 11:16:18 -0800415WDI_DP_INC := -I$(WLAN_ROOT)/$(WDI_DIR)/DP/inc/
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800416
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800417WDI_DP_SRC_DIR := $(WDI_DIR)/DP/src
418WDI_DP_OBJS := $(WDI_DP_SRC_DIR)/wlan_qct_wdi_bd.o \
419 $(WDI_DP_SRC_DIR)/wlan_qct_wdi_ds.o
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800420
Jeff Johnson91a420a2012-12-16 11:16:18 -0800421WDI_TRP_INC := -I$(WLAN_ROOT)/$(WDI_DIR)/TRP/CTS/inc/ \
422 -I$(WLAN_ROOT)/$(WDI_DIR)/TRP/DTS/inc/
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800423
424WDI_TRP_CTS_SRC_DIR := $(WDI_DIR)/TRP/CTS/src
Jeff Johnson91a420a2012-12-16 11:16:18 -0800425WDI_TRP_CTS_OBJS := $(WDI_TRP_CTS_SRC_DIR)/wlan_qct_wdi_cts.o
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800426
427WDI_TRP_DTS_SRC_DIR := $(WDI_DIR)/TRP/DTS/src
Jeff Johnson91a420a2012-12-16 11:16:18 -0800428WDI_TRP_DTS_OBJS := $(WDI_TRP_DTS_SRC_DIR)/wlan_qct_wdi_dts.o
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800429
430WDI_TRP_OBJS := $(WDI_TRP_CTS_OBJS) \
431 $(WDI_TRP_DTS_OBJS)
432
Jeff Johnson91a420a2012-12-16 11:16:18 -0800433WDI_WPAL_INC := -I$(WLAN_ROOT)/$(WDI_DIR)/WPAL/inc
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800434
435WDI_WPAL_SRC_DIR := $(WDI_DIR)/WPAL/src
436WDI_WPAL_OBJS := $(WDI_WPAL_SRC_DIR)/wlan_qct_pal_api.o \
437 $(WDI_WPAL_SRC_DIR)/wlan_qct_pal_device.o \
438 $(WDI_WPAL_SRC_DIR)/wlan_qct_pal_msg.o \
439 $(WDI_WPAL_SRC_DIR)/wlan_qct_pal_packet.o \
440 $(WDI_WPAL_SRC_DIR)/wlan_qct_pal_sync.o \
441 $(WDI_WPAL_SRC_DIR)/wlan_qct_pal_timer.o \
442 $(WDI_WPAL_SRC_DIR)/wlan_qct_pal_trace.o
443
444WDI_INC := $(WDI_CP_INC) \
445 $(WDI_DP_INC) \
446 $(WDI_TRP_INC) \
447 $(WDI_WPAL_INC)
448
449WDI_OBJS := $(WDI_CP_OBJS) \
450 $(WDI_DP_OBJS) \
451 $(WDI_TRP_OBJS) \
452 $(WDI_WPAL_OBJS)
453
454
Jeff Johnson91a420a2012-12-16 11:16:18 -0800455RIVA_INC := -I$(WLAN_ROOT)/riva/inc
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800456
457LINUX_INC := -Iinclude/linux
458
459INCS := $(BAP_INC) \
460 $(DXE_INC) \
461 $(HDD_INC) \
462 $(LINUX_INC) \
463 $(MAC_INC) \
464 $(RIVA_INC) \
465 $(SAP_INC) \
466 $(SME_INC) \
467 $(SVC_INC) \
468 $(SYS_INC) \
469 $(TL_INC) \
470 $(VOSS_INC) \
471 $(WDA_INC) \
472 $(WDI_INC)
473
474OBJS := $(BAP_OBJS) \
475 $(DXE_OBJS) \
476 $(HDD_OBJS) \
477 $(MAC_OBJS) \
478 $(SAP_OBJS) \
479 $(SME_OBJS) \
480 $(SVC_OBJS) \
481 $(SYS_OBJS) \
482 $(TL_OBJS) \
483 $(VOSS_OBJS) \
484 $(WDA_OBJS) \
485 $(WDI_OBJS)
486
487EXTRA_CFLAGS += $(INCS)
488
Jeff Johnsoncfc48eb2013-03-06 09:50:58 -0800489CDEFINES := -DANI_BUS_TYPE_PLATFORM=1 \
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800490 -DANI_LITTLE_BYTE_ENDIAN \
491 -DANI_LITTLE_BIT_ENDIAN \
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800492 -DQC_WLAN_CHIPSET_PRIMA \
493 -DINTEGRATION_READY \
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800494 -DDOT11F_LITTLE_ENDIAN_HOST \
495 -DGEN6_ONWARDS \
496 -DANI_COMPILER_TYPE_GCC \
497 -DANI_OS_TYPE_ANDROID=6 \
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800498 -DANI_LOGDUMP \
499 -DWLAN_PERF \
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800500 -DPTT_SOCK_SVC_ENABLE \
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800501 -Wall\
502 -D__linux__ \
503 -DMSM_PLATFORM \
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800504 -DHAL_SELF_STA_PER_BSS=1 \
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800505 -DWLAN_FEATURE_VOWIFI_11R \
506 -DWLAN_FEATURE_NEIGHBOR_ROAMING \
507 -DWLAN_FEATURE_NEIGHBOR_ROAMING_DEBUG \
508 -DWLAN_FEATURE_VOWIFI_11R_DEBUG \
509 -DFEATURE_WLAN_WAPI \
510 -DFEATURE_OEM_DATA_SUPPORT\
511 -DSOFTAP_CHANNEL_RANGE \
512 -DWLAN_AP_STA_CONCURRENCY \
513 -DFEATURE_WLAN_SCAN_PNO \
514 -DWLAN_FEATURE_PACKET_FILTERING \
515 -DWLAN_FEATURE_VOWIFI \
516 -DWLAN_FEATURE_11AC \
517 -DWLAN_FEATURE_P2P_DEBUG \
Yathish9f22e662012-12-10 14:21:35 -0800518 -DWLAN_ENABLE_AGEIE_ON_SCAN_RESULTS \
Ravi Kumar Vaishnavb7652402013-01-18 19:05:15 -0800519 -DWLANTL_DEBUG\
Gopichand Nakkala7fcc6de2012-12-21 07:38:04 -0800520 -DWLAN_ACTIVEMODE_OFFLOAD_FEATURE \
Gopichand Nakkala976e3252013-01-03 15:45:56 -0800521 -DWLAN_FEATURE_HOLD_RX_WAKELOCK \
Varun Reddy Yeturud0a3f252013-04-15 21:58:13 -0700522 -DWLAN_SOFTAP_VSTA_FEATURE \
Gopichand Nakkalaf0137052013-06-24 11:45:56 +0530523 -DWLAN_FEATURE_ROAM_SCAN_OFFLOAD \
524 -DWLAN_FEATURE_GTK_OFFLOAD
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800525
Jeff Johnson91a420a2012-12-16 11:16:18 -0800526ifneq ($(CONFIG_PRONTO_WLAN),)
527CDEFINES += -DWCN_PRONTO
528CDEFINES += -DWCN_PRONTO_V1
529endif
530
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800531ifeq ($(BUILD_DEBUG_VERSION),1)
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800532CDEFINES += -DWLAN_DEBUG \
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800533 -DTRACE_RECORD \
Leela V Kiran Kumar Reddy Chiralac3b9d382013-01-31 20:49:53 -0800534 -DLIM_TRACE_RECORD \
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800535 -DPE_DEBUG_LOGW \
536 -DPE_DEBUG_LOGE \
537 -DDEBUG
538endif
539
540ifeq ($(CONFIG_SLUB_DEBUG_ON),y)
541CDEFINES += -DTIMER_MANAGER
542CDEFINES += -DMEMORY_DEBUG
543endif
544
545ifeq ($(HAVE_CFG80211),1)
546CDEFINES += -DWLAN_FEATURE_P2P
547CDEFINES += -DWLAN_FEATURE_WFD
Gopichand Nakkalafebb97e2013-04-18 19:25:48 +0530548ifeq ($(CONFIG_QCOM_VOWIFI_11R),y)
549CDEFINES += -DKERNEL_SUPPORT_11R_CFG80211
550CDEFINES += -DUSE_80211_WMMTSPEC_FOR_RIC
551endif
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800552endif
553
554ifeq ($(CONFIG_QCOM_CCX),y)
555CDEFINES += -DFEATURE_WLAN_CCX
556endif
557
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800558#normally, TDLS negative behavior is not needed
559ifeq ($(CONFIG_QCOM_TDLS),y)
560CDEFINES += -DFEATURE_WLAN_TDLS
Gopichand Nakkala29d00192013-06-20 19:03:52 +0530561ifeq ($(BUILD_DEBUG_VERSION),1)
Jeff Johnson22141432013-02-21 17:07:33 -0800562CDEFINES += -DWLAN_FEATURE_TDLS_DEBUG
Gopichand Nakkala29d00192013-06-20 19:03:52 +0530563endif
Chilam NG571c65a2013-01-19 12:27:36 +0530564CDEFINES += -DCONFIG_TDLS_IMPLICIT
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800565#CDEFINES += -DFEATURE_WLAN_TDLS_NEGATIVE
566#Code under FEATURE_WLAN_TDLS_INTERNAL is ported from volans, This code
567#is not tested only verifed that it compiles. This is not required for
568#supplicant based implementation
569#CDEFINES += -DFEATURE_WLAN_TDLS_INTERNAL
570endif
571
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800572ifeq ($(CONFIG_PRIMA_WLAN_BTAMP),y)
573CDEFINES += -DWLAN_BTAMP_FEATURE
574endif
575
576ifeq ($(CONFIG_PRIMA_WLAN_LFR),y)
577CDEFINES += -DFEATURE_WLAN_LFR
578endif
579
580ifeq ($(CONFIG_PRIMA_WLAN_OKC),y)
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800581CDEFINES += -DFEATURE_WLAN_OKC
582endif
583
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800584ifeq ($(CONFIG_PRIMA_WLAN_11AC_HIGH_TP),y)
585CDEFINES += -DWLAN_FEATURE_11AC_HIGH_TP
586endif
587
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800588ifeq ($(BUILD_DIAG_VERSION),1)
589CDEFINES += -DFEATURE_WLAN_DIAG_SUPPORT
590CDEFINES += -DFEATURE_WLAN_DIAG_SUPPORT_CSR
591CDEFINES += -DFEATURE_WLAN_DIAG_SUPPORT_LIM
592endif
593
594# enable the MAC Address auto-generation feature
595CDEFINES += -DWLAN_AUTOGEN_MACADDR_FEATURE
596
Chet Lanctot6802b302013-04-04 16:50:46 -0700597ifeq ($(CONFIG_WLAN_FEATURE_11W),y)
598CDEFINES += -DWLAN_FEATURE_11W
599endif
600
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800601ifneq (, $(filter msm8960, $(BOARD_PLATFORM)))
602EXTRA_CFLAGS += -march=armv7-a
603CDEFINES += -DMSM_PLATFORM_8960
604endif
605
606ifneq (, $(filter msm8660, $(BOARD_PLATFORM)))
607EXTRA_CFLAGS += -march=armv7-a
608CDEFINES += -DMSM_PLATFORM_8660
609endif
610
611ifneq (, $(filter msm7630_surf msm7630_fusion, $(BOARD_PLATFORM)))
612EXTRA_CFLAGS += -march=armv7-a
613CDEFINES += -DMSM_PLATFORM_7x30
614endif
615
616ifneq (, $(filter msm7627_surf, $(BOARD_PLATFORM)))
617EXTRA_CFLAGS += -march=armv6
618CDEFINES += -DMSM_PLATFORM_7x27
619endif
620
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800621ifeq ($(PANIC_ON_BUG),1)
622CDEFINES += -DPANIC_ON_BUG
623endif
624
625ifeq ($(RE_ENABLE_WIFI_ON_WDI_TIMEOUT),1)
626CDEFINES += -DWDI_RE_ENABLE_WIFI_ON_WDI_TIMEOUT
627endif
628
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800629ifeq ($(KERNEL_BUILD),1)
630CDEFINES += -DWLAN_OPEN_SOURCE
631endif
632
Amar Singhala663bb32013-02-14 13:48:43 -0800633ifeq ($(findstring opensource, $(WLAN_ROOT)), opensource)
634CDEFINES += -DWLAN_OPEN_SOURCE
635endif
636
Jeff Johnson51019dc2013-02-21 16:44:09 -0800637# Fix build for GCC 4.7
638EXTRA_CFLAGS += -Wno-maybe-uninitialized -Wno-unused-function
639
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800640KBUILD_CPPFLAGS += $(CDEFINES)
641
Jeff Johnson25abf4d2012-12-01 12:42:42 -0800642# Module information used by KBuild framework
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800643obj-$(CONFIG_PRIMA_WLAN) += $(MODNAME).o
Jeff Johnson91a420a2012-12-16 11:16:18 -0800644obj-$(CONFIG_PRONTO_WLAN) += $(MODNAME).o
Jeff Johnson2c24a3b2012-12-10 12:28:11 -0800645$(MODNAME)-y := $(OBJS)