blob: a539f4d6449353099282b2f86f6b386921fcefeb [file] [log] [blame]
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001# We can build either as part of a standalone Kernel build or as
2# an external module. Determine which mechanism is being used
3ifeq ($(MODNAME),)
4 KERNEL_BUILD := 1
5else
6 KERNEL_BUILD := 0
7endif
8
Leo Chang395cbb52016-11-11 14:35:03 -08009ifeq ($(CONFIG_CNSS_QCA6290), y)
10 CONFIG_LITHIUM := y
11endif
Leo Chang5f7a1e02016-11-04 14:04:26 -070012
Poddar, Siddarth29296fb2016-05-16 18:06:30 +053013ifeq ($(CONFIG_CLD_HL_SDIO_CORE), y)
14 CONFIG_QCA_WIFI_SDIO := 1
15endif
16
17ifeq ($(CONFIG_QCA_WIFI_SDIO), 1)
18 CONFIG_ROME_IF = sdio
19endif
20
Houston Hoffman57d10c22016-03-08 13:04:20 -080021ifdef CONFIG_ICNSS
22 CONFIG_ROME_IF = snoc
23endif
24
Yue Mae6a7a322016-08-31 11:09:23 -070025ifeq (y,$(findstring y,$(CONFIG_CNSS) $(CONFIG_CNSS2)))
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080026ifndef CONFIG_ROME_IF
27 #use pci as default interface
28 CONFIG_ROME_IF = pci
29endif
30endif
31
32ifeq ($(KERNEL_BUILD),1)
33 # These are provided in external module based builds
34 # Need to explicitly define for Kernel-based builds
35 MODNAME := wlan
36 WLAN_ROOT := drivers/staging/qcacld-3.0
Houston Hoffman52ec6692016-04-21 16:36:45 -070037 WLAN_COMMON_ROOT := ../qca-wifi-host-cmn
38 WLAN_COMMON_INC := $(WLAN_ROOT)/$(WLAN_COMMON_ROOT)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080039endif
40
41# Make WLAN as open-source driver by default
42WLAN_OPEN_SOURCE := 1
43
44ifeq ($(KERNEL_BUILD), 0)
45 # These are configurable via Kconfig for kernel-based builds
46 # Need to explicitly configure for Android-based builds
47
48 ifeq ($(CONFIG_ARCH_MDM9630), y)
49 CONFIG_MOBILE_ROUTER := y
50 endif
51
52 ifeq ($(CONFIG_ARCH_MDM9640), y)
53 CONFIG_MOBILE_ROUTER := y
54 endif
55
Chandrasekaran, Manishekarb2d9fa12016-04-07 12:00:10 +053056 # As per target team, build is done as follows:
57 # Defconfig : build with default flags
58 # Slub : defconfig + CONFIG_SLUB_DEBUG=y +
59 # CONFIG_SLUB_DEBUG_ON=y + CONFIG_PAGE_POISONING=y
60 # Perf : Using appropriate msmXXXX-perf_defconfig
61 #
62 # Shipment builds (user variants) should not have any debug feature
63 # enabled. This is identified using 'TARGET_BUILD_VARIANT'. Slub builds
64 # are identified using the CONFIG_SLUB_DEBUG_ON configuration. Since
65 # there is no other way to identify defconfig builds, QCOMs internal
66 # representation of perf builds (identified using the string 'perf'),
67 # is used to identify if the build is a slub or defconfig one. This
68 # way no critical debug feature will be enabled for perf and shipment
69 # builds. Other OEMs are also protected using the TARGET_BUILD_VARIANT
70 # config.
71 ifneq ($(TARGET_BUILD_VARIANT),user)
Venkata Sharath Chandra Manchala5d714d82017-01-18 14:56:32 -080072 ifeq ($(CONFIG_LITHIUM), y)
Ravi Joshifc2ed782016-11-22 17:36:50 -080073 CONFIG_FEATURE_PKTLOG := n
74 else
75 CONFIG_FEATURE_PKTLOG := y
76 endif
Chandrasekaran, Manishekarb2d9fa12016-04-07 12:00:10 +053077 ifeq ($(CONFIG_SLUB_DEBUG_ON),y)
Nirav Shahcc1f1ae2016-04-26 11:41:29 +053078 CONFIG_FEATURE_DP_TRACE := y
Chandrasekaran, Manishekarb2d9fa12016-04-07 12:00:10 +053079 else
80 ifeq ($(findstring perf,$(KERNEL_DEFCONFIG)),)
Nirav Shahcc1f1ae2016-04-26 11:41:29 +053081 CONFIG_FEATURE_DP_TRACE := y
Chandrasekaran, Manishekarb2d9fa12016-04-07 12:00:10 +053082 endif
83 endif
84 endif
85
Varun Reddy Yeturubbbbe232016-02-29 14:01:57 -080086 #Flag to enable Legacy Fast Roaming2(LFR2)
87 CONFIG_QCACLD_WLAN_LFR2 := y
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080088 #Flag to enable Legacy Fast Roaming3(LFR3)
89 CONFIG_QCACLD_WLAN_LFR3 := y
90
Sridhar Selvarajdc400d22016-10-18 17:18:03 +053091 #Enable Power debugfs feature only if debug_fs is enabled
92 ifeq ($(CONFIG_DEBUG_FS), y)
93 CONFIG_WLAN_POWER_DEBUGFS := y
94 endif
95
Prakash Dhavali7090c5f2015-11-02 17:55:19 -080096 # JB kernel has CPU enablement patches, so enable
97 ifeq ($(CONFIG_ROME_IF),pci)
98 CONFIG_PRIMA_WLAN_11AC_HIGH_TP := y
99 endif
100 ifeq ($(CONFIG_ROME_IF),usb)
101 CONFIG_PRIMA_WLAN_11AC_HIGH_TP := n
102 endif
103 ifeq ($(CONFIG_ROME_IF),sdio)
104 CONFIG_PRIMA_WLAN_11AC_HIGH_TP := n
105 endif
106
107 ifneq ($(CONFIG_MOBILE_ROUTER), y)
108 #Flag to enable TDLS feature
109 CONFIG_QCOM_TDLS := y
110 endif
111
112 ifeq ($(CONFIG_MOBILE_ROUTER), y)
113 CONFIG_QCACLD_FEATURE_GREEN_AP := y
114 endif
Ashwini Muduganti79649822016-11-16 11:29:50 -0800115 ifeq ($(CONFIG_ARCH_MSM8998), y)
Jeff Johnsona6300252016-09-28 15:58:55 -0700116 CONFIG_QCACLD_FEATURE_GREEN_AP := y
117 endif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800118
Poddar, Siddarth1bec7ae2017-01-24 18:02:31 +0530119 ifeq ($(CONFIG_ARCH_SDM660), y)
120 CONFIG_QCACLD_FEATURE_METERING := y
121 endif
122
123 ifeq ($(CONFIG_ARCH_SDM630), y)
124 CONFIG_QCACLD_FEATURE_METERING := y
125 endif
126
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800127 #Flag to enable Fast Transition (11r) feature
128 CONFIG_QCOM_VOWIFI_11R := y
129
130 ifneq ($(CONFIG_QCA_CLD_WLAN),)
Yue Mae6a7a322016-08-31 11:09:23 -0700131 ifeq (y,$(findstring y,$(CONFIG_CNSS) $(CONFIG_CNSS2) $(CONFIG_ICNSS)))
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800132 #Flag to enable Protected Managment Frames (11w) feature
133 CONFIG_WLAN_FEATURE_11W := y
134 #Flag to enable LTE CoEx feature
135 CONFIG_QCOM_LTE_COEX := y
136 ifneq ($(CONFIG_MOBILE_ROUTER), y)
137 #Flag to enable LPSS feature
138 CONFIG_WLAN_FEATURE_LPSS := y
139 endif
140 endif
141 endif
142
Ravi Joshia063dd92016-05-25 16:43:13 -0700143 #Flag to enable Protected Managment Frames (11w) feature
144 ifeq ($(CONFIG_ROME_IF),usb)
145 CONFIG_WLAN_FEATURE_11W := y
146 endif
147 ifeq ($(CONFIG_ROME_IF),sdio)
148 CONFIG_WLAN_FEATURE_11W := y
149 endif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800150
gbiane55c9562016-11-01 14:47:47 +0800151 #Flag to enable the tx desc sanity check
152 ifeq ($(CONFIG_ROME_IF),usb)
153 CONFIG_QCA_TXDESC_SANITY_CHECKS := y
154 endif
155
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800156 ifneq ($(CONFIG_MOBILE_ROUTER), y)
157 #Flag to enable NAN
158 CONFIG_QCACLD_FEATURE_NAN := y
159 endif
160
Ravi Joshia063dd92016-05-25 16:43:13 -0700161 ifneq ($(CONFIG_MOBILE_ROUTER), y)
162 #Flag to enable NAN Data path
163 CONFIG_WLAN_FEATURE_NAN_DATAPATH := y
164 endif
165
166 #Flag to enable Linux QCMBR feature as default feature
167 ifeq ($(CONFIG_ROME_IF),usb)
168 CONFIG_LINUX_QCMBR :=y
169 endif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800170
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800171 CONFIG_MPC_UT_FRAMEWORK := y
172
173 #Flag to enable offload packets feature
174 CONFIG_WLAN_OFFLOAD_PACKETS := y
175
Manikandan Mohan5356c2b2016-04-03 15:51:35 -0700176 #enable TSF get feature
177 CONFIG_WLAN_SYNC_TSF := y
Agrawal Ashishb141b092016-09-02 19:59:26 +0530178 #Enable DSRC feature
179
180 ifeq ($(CONFIG_QCA_WIFI_SDIO), 1)
181 CONFIG_WLAN_FEATURE_DSRC := y
182 endif
Manikandan Mohan5356c2b2016-04-03 15:51:35 -0700183
Poddar, Siddarth29296fb2016-05-16 18:06:30 +0530184ifneq ($(CONFIG_ROME_IF),sdio)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800185 #Flag to enable memdump feature
Krishna Kumaar Natarajane42bb172016-06-09 18:24:04 -0700186 CONFIG_WLAN_FEATURE_MEMDUMP := n
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800187
Padma, Santhosh Kumard7cc0792016-06-28 18:54:12 +0530188 #Flag to enable DISA
189 CONFIG_WLAN_FEATURE_DISA := y
190
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800191 #Flag to enable Fast Path feature
192 CONFIG_WLAN_FASTPATH := y
193
194 # Flag to enable NAPI
Leo Chang395cbb52016-11-11 14:35:03 -0800195ifeq (y,$(CONFIG_LITHIUM))
Leo Chang5f7a1e02016-11-04 14:04:26 -0700196 CONFIG_WLAN_NAPI := n
197 CONFIG_WLAN_NAPI_DEBUG := n
198else
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800199 CONFIG_WLAN_NAPI := y
200 CONFIG_WLAN_NAPI_DEBUG := n
Leo Chang5f7a1e02016-11-04 14:04:26 -0700201endif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800202 # Flag to enable FW based TX Flow control
Nirav Shah9d7f2e82015-09-28 11:09:09 -0700203 ifeq ($(CONFIG_CNSS_EOS),y)
204 CONFIG_WLAN_TX_FLOW_CONTROL_V2 := y
205 else
206 CONFIG_WLAN_TX_FLOW_CONTROL_V2 := n
207 endif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800208
209 # Flag to enable LRO (Large Receive Offload)
Manjunathappa Prakashbeeacb12016-06-17 18:18:32 -0700210 ifeq ($(CONFIG_INET_LRO), y)
211 CONFIG_WLAN_LRO := y
212 else
213 CONFIG_WLAN_LRO := n
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800214 endif
Poddar, Siddarth29296fb2016-05-16 18:06:30 +0530215endif
Ravi Joshi61c3c7a2015-11-09 18:41:20 -0800216
Manjunathappa Prakashfa345992016-04-21 16:45:40 -0700217ifeq ($(CONFIG_ROME_IF), snoc)
218 CONFIG_WLAN_TX_FLOW_CONTROL_V2 := y
219endif
220
Ravi Joshi61c3c7a2015-11-09 18:41:20 -0800221 # Flag to enable LFR Subnet Detection
222 CONFIG_LFR_SUBNET_DETECTION := y
Chandrasekaran Manishekar068e25e2016-03-07 11:51:07 +0530223
224 # Flag to enable MCC to SCC switch feature
225 CONFIG_MCC_TO_SCC_SWITCH := y
Mahesh Kumar Kalikot Veetilc0233a72016-10-27 15:06:05 -0700226
227ifeq ($(CONFIG_DEBUG_FS), y)
228 # Flag to enable debugfs. Depends on CONFIG_DEBUG_FS in kernel
229 # configuration.
230 CONFIG_WLAN_DEBUGFS := y
231endif
232
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800233endif
234
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -0800235# If not set, assume, Common driver is with in the build tree
236WLAN_COMMON_ROOT ?= qca-wifi-host-cmn
237WLAN_COMMON_INC ?= $(WLAN_ROOT)/$(WLAN_COMMON_ROOT)
238
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800239ifneq ($(CONFIG_MOBILE_ROUTER), y)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800240CONFIG_QCOM_ESE := y
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800241endif
242
243# Feature flags which are not (currently) configurable via Kconfig
244
245#Whether to build debug version
246BUILD_DEBUG_VERSION := 1
247
248#Enable this flag to build driver in diag version
249BUILD_DIAG_VERSION := 1
250
251#Do we panic on bug? default is to warn
252PANIC_ON_BUG := 1
253
254#Enable OL debug and wmi unified functions
255CONFIG_ATH_PERF_PWR_OFFLOAD := 1
256
257#Disable packet log
258CONFIG_REMOVE_PKT_LOG := 0
259
260#Enable 11AC TX
261ifeq ($(CONFIG_ROME_IF),pci)
262 CONFIG_ATH_11AC_TXCOMPACT := 1
263endif
264ifeq ($(CONFIG_ROME_IF),usb)
265 CONFIG_ATH_11AC_TXCOMPACT := 0
266endif
267
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800268#Enable OS specific IRQ abstraction
269CONFIG_ATH_SUPPORT_SHARED_IRQ := 1
270
271#Enable message based HIF instead of RAW access in BMI
272ifeq ($(CONFIG_QCA_WIFI_SDIO), 1)
273CONFIG_HIF_MESSAGE_BASED := 0
274else
275CONFIG_HIF_MESSAGE_BASED := 1
276endif
277
278#Enable PCI specific APIS (dma, etc)
279ifeq ($(CONFIG_ROME_IF),pci)
280 CONFIG_HIF_PCI := 1
281endif
282
Mohit Khannada4f4432016-05-17 15:02:09 -0700283#Enable USB specific APIS
284ifeq ($(CONFIG_ROME_IF),usb)
285 CONFIG_HIF_USB := 1
Mohit Khannae7a43572016-10-10 17:34:21 -0700286 CONFIG_PLD_USB_CNSS := y
Mohit Khannada4f4432016-05-17 15:02:09 -0700287endif
288
Yu Wang58e1cad2017-02-10 17:43:15 +0800289#Enable SDIO specific APIS
290ifeq ($(CONFIG_ROME_IF),sdio)
291 CONFIG_HIF_SDIO := 1
292endif
293
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800294#Enable pci read/write config functions
295ifeq ($(CONFIG_ROME_IF),pci)
296 CONFIG_ATH_PCI := 1
297endif
Houston Hoffman52ec6692016-04-21 16:36:45 -0700298
299ifeq ($(CONFIG_ROME_IF),snoc)
300 CONFIG_HIF_SNOC:= 1
301endif
302
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800303ifneq ($(CONFIG_MOBILE_ROUTER), y)
304#Enable IBSS support on CLD
305CONFIG_QCA_IBSS_SUPPORT := 1
306endif
307
308#Enable power management suspend/resume functionality to PCI
309CONFIG_ATH_BUS_PM := 1
310
311#Enable FLOWMAC module support
312CONFIG_ATH_SUPPORT_FLOWMAC_MODULE := 0
313
314#Enable spectral support
315CONFIG_ATH_SUPPORT_SPECTRAL := 0
316
317#Enable HOST statistics support
318CONFIG_SUPPORT_HOST_STATISTICS := 0
319
320#Enable WDI Event support
321CONFIG_WDI_EVENT_ENABLE := 1
322
323#Endianess selection
324CONFIG_LITTLE_ENDIAN := 1
325
326#Enable TX reclaim support
327CONFIG_TX_CREDIT_RECLAIM_SUPPORT := 0
328
329#Enable FTM support
330CONFIG_QCA_WIFI_FTM := 1
331
332#Enable Checksum Offload
333CONFIG_CHECKSUM_OFFLOAD := 1
334
335#Enable GTK offload
336CONFIG_GTK_OFFLOAD := 1
337
338#Enable EXT WOW
339ifeq ($(CONFIG_ROME_IF),pci)
340 CONFIG_EXT_WOW := 1
341endif
342
Houston Hoffman1158c0a2016-07-11 18:24:36 -0700343# Flag to enable bus auto suspend
344ifeq ($(CONFIG_ROME_IF),pci)
345ifeq ($(CONFIG_BUS_AUTO_SUSPEND), y)
346CDEFINES += -DFEATURE_RUNTIME_PM
347endif
348endif
349
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800350#Set this to 1 to catch erroneous Target accesses during debug.
351CONFIG_ATH_PCIE_ACCESS_DEBUG := 0
352
353#Enable IPA offload
354ifeq ($(CONFIG_IPA), y)
355CONFIG_IPA_OFFLOAD := 1
356endif
357
358#Enable Signed firmware support for split binary format
359CONFIG_QCA_SIGNED_SPLIT_BINARY_SUPPORT := 0
360
361#Enable single firmware binary format
362CONFIG_QCA_SINGLE_BINARY_SUPPORT := 0
363
364#Enable collecting target RAM dump after kernel panic
365CONFIG_TARGET_RAMDUMP_AFTER_KERNEL_PANIC := 1
366
367#Flag to enable/disable secure firmware feature
368CONFIG_FEATURE_SECURE_FIRMWARE := 0
369
370#Flag to enable Stats Ext implementation
371CONFIG_FEATURE_STATS_EXT := 1
372
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800373ifeq ($(CONFIG_CFG80211),y)
374HAVE_CFG80211 := 1
375else
376ifeq ($(CONFIG_CFG80211),m)
377HAVE_CFG80211 := 1
378else
379HAVE_CFG80211 := 0
380endif
381endif
382
383############ UAPI ############
384UAPI_DIR := uapi
385UAPI_INC := -I$(WLAN_ROOT)/$(UAPI_DIR)/linux
386
387############ COMMON ############
388COMMON_DIR := core/common
389COMMON_INC := -I$(WLAN_ROOT)/$(COMMON_DIR)
390
391############ HDD ############
392HDD_DIR := core/hdd
393HDD_INC_DIR := $(HDD_DIR)/inc
394HDD_SRC_DIR := $(HDD_DIR)/src
395
396HDD_INC := -I$(WLAN_ROOT)/$(HDD_INC_DIR) \
397 -I$(WLAN_ROOT)/$(HDD_SRC_DIR)
398
399HDD_OBJS := $(HDD_SRC_DIR)/wlan_hdd_assoc.o \
400 $(HDD_SRC_DIR)/wlan_hdd_cfg.o \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800401 $(HDD_SRC_DIR)/wlan_hdd_driver_ops.o \
402 $(HDD_SRC_DIR)/wlan_hdd_ftm.o \
403 $(HDD_SRC_DIR)/wlan_hdd_hostapd.o \
404 $(HDD_SRC_DIR)/wlan_hdd_ioctl.o \
405 $(HDD_SRC_DIR)/wlan_hdd_main.o \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800406 $(HDD_SRC_DIR)/wlan_hdd_oemdata.o \
407 $(HDD_SRC_DIR)/wlan_hdd_power.o \
Amar Singhale4f28ee2015-10-21 14:36:56 -0700408 $(HDD_SRC_DIR)/wlan_hdd_regulatory.o \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800409 $(HDD_SRC_DIR)/wlan_hdd_scan.o \
410 $(HDD_SRC_DIR)/wlan_hdd_softap_tx_rx.o \
411 $(HDD_SRC_DIR)/wlan_hdd_tx_rx.o \
412 $(HDD_SRC_DIR)/wlan_hdd_trace.o \
413 $(HDD_SRC_DIR)/wlan_hdd_wext.o \
414 $(HDD_SRC_DIR)/wlan_hdd_wmm.o \
Rajeev Kumar699debf2017-01-06 14:17:00 -0800415 $(HDD_SRC_DIR)/wlan_hdd_wowl.o \
416 $(HDD_SRC_DIR)/wlan_hdd_object_manager.o
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800417
Mahesh Kumar Kalikot Veetilc0233a72016-10-27 15:06:05 -0700418ifeq ($(CONFIG_WLAN_DEBUGFS), y)
419HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_debugfs.o
420endif
421
Agrawal Ashishb141b092016-09-02 19:59:26 +0530422ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
423HDD_OBJS+= $(HDD_SRC_DIR)/wlan_hdd_ocb.o
424endif
Amar Singhale4f28ee2015-10-21 14:36:56 -0700425
Jeff Johnson2b0a7b82016-05-18 15:08:02 -0700426ifeq ($(CONFIG_WLAN_FEATURE_LPSS),y)
427HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_lpass.o
428endif
429
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800430ifeq ($(CONFIG_WLAN_LRO), y)
431HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_lro.o
432endif
433
434ifeq ($(CONFIG_WLAN_NAPI), y)
435HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_napi.o
436endif
437
438ifeq ($(CONFIG_IPA_OFFLOAD), 1)
439HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_ipa.o
440endif
441
442ifeq ($(HAVE_CFG80211),1)
443HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_cfg80211.o \
444 $(HDD_SRC_DIR)/wlan_hdd_ext_scan.o \
445 $(HDD_SRC_DIR)/wlan_hdd_stats.o \
446 $(HDD_SRC_DIR)/wlan_hdd_p2p.o
447endif
448
449ifeq ($(CONFIG_QCACLD_FEATURE_GREEN_AP),y)
450HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_green_ap.o
451endif
452
453ifeq ($(CONFIG_QCACLD_FEATURE_NAN),y)
454HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_nan.o
455endif
456
457ifeq ($(CONFIG_QCOM_TDLS),y)
458HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_tdls.o
459endif
460
Manikandan Mohandcc21ba2016-03-15 14:31:56 -0700461ifeq ($(CONFIG_WLAN_SYNC_TSF),y)
462HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_tsf.o
463endif
464
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800465ifeq ($(CONFIG_MPC_UT_FRAMEWORK),y)
466HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_conc_ut.o
467endif
468
469ifeq ($(CONFIG_WLAN_FEATURE_MEMDUMP),y)
470HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_memdump.o
471endif
472
Padma, Santhosh Kumard7cc0792016-06-28 18:54:12 +0530473ifeq ($(CONFIG_WLAN_FEATURE_DISA),y)
474HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_disa.o
475endif
476
Ravi Joshi61c3c7a2015-11-09 18:41:20 -0800477ifeq ($(CONFIG_LFR_SUBNET_DETECTION), y)
478HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_subnet_detect.o
479endif
480
Ravi Joshia063dd92016-05-25 16:43:13 -0700481ifeq ($(CONFIG_WLAN_FEATURE_NAN_DATAPATH), y)
482HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_nan_datapath.o
483endif
484
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800485########### HOST DIAG LOG ###########
486HOST_DIAG_LOG_DIR := core/utils/host_diag_log
487
488HOST_DIAG_LOG_INC_DIR := $(HOST_DIAG_LOG_DIR)/inc
489HOST_DIAG_LOG_SRC_DIR := $(HOST_DIAG_LOG_DIR)/src
490
491HOST_DIAG_LOG_INC := -I$(WLAN_ROOT)/$(HOST_DIAG_LOG_INC_DIR) \
492 -I$(WLAN_ROOT)/$(HOST_DIAG_LOG_SRC_DIR)
493
494HOST_DIAG_LOG_OBJS += $(HOST_DIAG_LOG_SRC_DIR)/host_diag_log.o
495
496############ EPPING ############
497EPPING_DIR := core/utils/epping
498EPPING_INC_DIR := $(EPPING_DIR)/inc
499EPPING_SRC_DIR := $(EPPING_DIR)/src
500
501EPPING_INC := -I$(WLAN_ROOT)/$(EPPING_INC_DIR)
502
503EPPING_OBJS := $(EPPING_SRC_DIR)/epping_main.o \
504 $(EPPING_SRC_DIR)/epping_txrx.o \
505 $(EPPING_SRC_DIR)/epping_tx.o \
506 $(EPPING_SRC_DIR)/epping_rx.o \
507 $(EPPING_SRC_DIR)/epping_helper.o \
508
509
510############ MAC ############
511MAC_DIR := core/mac
512MAC_INC_DIR := $(MAC_DIR)/inc
513MAC_SRC_DIR := $(MAC_DIR)/src
514
515MAC_INC := -I$(WLAN_ROOT)/$(MAC_INC_DIR) \
516 -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/dph \
517 -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/include \
518 -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/pe/include \
Ravi Joshia063dd92016-05-25 16:43:13 -0700519 -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/pe/lim \
520 -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/pe/nan
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800521
522MAC_CFG_OBJS := $(MAC_SRC_DIR)/cfg/cfg_api.o \
523 $(MAC_SRC_DIR)/cfg/cfg_debug.o \
524 $(MAC_SRC_DIR)/cfg/cfg_param_name.o \
525 $(MAC_SRC_DIR)/cfg/cfg_proc_msg.o \
526 $(MAC_SRC_DIR)/cfg/cfg_send_msg.o
527
528MAC_DPH_OBJS := $(MAC_SRC_DIR)/dph/dph_hash_table.o
529
530MAC_LIM_OBJS := $(MAC_SRC_DIR)/pe/lim/lim_aid_mgmt.o \
531 $(MAC_SRC_DIR)/pe/lim/lim_admit_control.o \
532 $(MAC_SRC_DIR)/pe/lim/lim_api.o \
533 $(MAC_SRC_DIR)/pe/lim/lim_assoc_utils.o \
534 $(MAC_SRC_DIR)/pe/lim/lim_debug.o \
535 $(MAC_SRC_DIR)/pe/lim/lim_ft.o \
536 $(MAC_SRC_DIR)/pe/lim/lim_ibss_peer_mgmt.o \
537 $(MAC_SRC_DIR)/pe/lim/lim_link_monitoring_algo.o \
538 $(MAC_SRC_DIR)/pe/lim/lim_p2p.o \
539 $(MAC_SRC_DIR)/pe/lim/lim_process_action_frame.o \
540 $(MAC_SRC_DIR)/pe/lim/lim_process_assoc_req_frame.o \
541 $(MAC_SRC_DIR)/pe/lim/lim_process_assoc_rsp_frame.o \
542 $(MAC_SRC_DIR)/pe/lim/lim_process_auth_frame.o \
543 $(MAC_SRC_DIR)/pe/lim/lim_process_beacon_frame.o \
544 $(MAC_SRC_DIR)/pe/lim/lim_process_cfg_updates.o \
545 $(MAC_SRC_DIR)/pe/lim/lim_process_deauth_frame.o \
546 $(MAC_SRC_DIR)/pe/lim/lim_process_disassoc_frame.o \
547 $(MAC_SRC_DIR)/pe/lim/lim_process_message_queue.o \
548 $(MAC_SRC_DIR)/pe/lim/lim_process_mlm_req_messages.o \
549 $(MAC_SRC_DIR)/pe/lim/lim_process_mlm_rsp_messages.o \
550 $(MAC_SRC_DIR)/pe/lim/lim_process_probe_req_frame.o \
551 $(MAC_SRC_DIR)/pe/lim/lim_process_probe_rsp_frame.o \
552 $(MAC_SRC_DIR)/pe/lim/lim_process_sme_req_messages.o \
553 $(MAC_SRC_DIR)/pe/lim/lim_prop_exts_utils.o \
554 $(MAC_SRC_DIR)/pe/lim/lim_scan_result_utils.o \
555 $(MAC_SRC_DIR)/pe/lim/lim_security_utils.o \
556 $(MAC_SRC_DIR)/pe/lim/lim_send_management_frames.o \
557 $(MAC_SRC_DIR)/pe/lim/lim_send_messages.o \
558 $(MAC_SRC_DIR)/pe/lim/lim_send_sme_rsp_messages.o \
559 $(MAC_SRC_DIR)/pe/lim/lim_ser_des_utils.o \
560 $(MAC_SRC_DIR)/pe/lim/lim_session.o \
561 $(MAC_SRC_DIR)/pe/lim/lim_session_utils.o \
562 $(MAC_SRC_DIR)/pe/lim/lim_sme_req_utils.o \
563 $(MAC_SRC_DIR)/pe/lim/lim_sta_hash_api.o \
564 $(MAC_SRC_DIR)/pe/lim/lim_timer_utils.o \
565 $(MAC_SRC_DIR)/pe/lim/lim_trace.o \
566 $(MAC_SRC_DIR)/pe/lim/lim_utils.o
567
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800568ifeq ($(CONFIG_QCOM_TDLS),y)
569MAC_LIM_OBJS += $(MAC_SRC_DIR)/pe/lim/lim_process_tdls.o
570endif
571
Ravi Joshia063dd92016-05-25 16:43:13 -0700572ifeq ($(CONFIG_WLAN_FEATURE_NAN_DATAPATH), y)
573MAC_NDP_OBJS += $(MAC_SRC_DIR)/pe/nan/nan_datapath.o
574endif
575
Varun Reddy Yeturubbbbe232016-02-29 14:01:57 -0800576ifeq ($(CONFIG_QCACLD_WLAN_LFR2),y)
577 MAC_LIM_OBJS += $(MAC_SRC_DIR)/pe/lim/lim_process_mlm_host_roam.o \
578 $(MAC_SRC_DIR)/pe/lim/lim_send_frames_host_roam.o \
579 $(MAC_SRC_DIR)/pe/lim/lim_roam_timer_utils.o \
580 $(MAC_SRC_DIR)/pe/lim/lim_ft_preauth.o \
581 $(MAC_SRC_DIR)/pe/lim/lim_reassoc_utils.o
582endif
583
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800584MAC_SCH_OBJS := $(MAC_SRC_DIR)/pe/sch/sch_api.o \
585 $(MAC_SRC_DIR)/pe/sch/sch_beacon_gen.o \
586 $(MAC_SRC_DIR)/pe/sch/sch_beacon_process.o \
587 $(MAC_SRC_DIR)/pe/sch/sch_debug.o \
588 $(MAC_SRC_DIR)/pe/sch/sch_message.o
589
590MAC_RRM_OBJS := $(MAC_SRC_DIR)/pe/rrm/rrm_api.o
591
592MAC_OBJS := $(MAC_CFG_OBJS) \
593 $(MAC_DPH_OBJS) \
594 $(MAC_LIM_OBJS) \
595 $(MAC_SCH_OBJS) \
Ravi Joshia063dd92016-05-25 16:43:13 -0700596 $(MAC_RRM_OBJS) \
597 $(MAC_NDP_OBJS)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800598
599############ SAP ############
600SAP_DIR := core/sap
601SAP_INC_DIR := $(SAP_DIR)/inc
602SAP_SRC_DIR := $(SAP_DIR)/src
603
604SAP_INC := -I$(WLAN_ROOT)/$(SAP_INC_DIR) \
605 -I$(WLAN_ROOT)/$(SAP_SRC_DIR)
606
607SAP_OBJS := $(SAP_SRC_DIR)/sap_api_link_cntl.o \
608 $(SAP_SRC_DIR)/sap_ch_select.o \
609 $(SAP_SRC_DIR)/sap_fsm.o \
610 $(SAP_SRC_DIR)/sap_module.o
611
612############ DFS ############ 350
613DFS_DIR := $(SAP_DIR)/dfs
614DFS_INC_DIR := $(DFS_DIR)/inc
615DFS_SRC_DIR := $(DFS_DIR)/src
616
617DFS_INC := -I$(WLAN_ROOT)/$(DFS_INC_DIR) \
618 -I$(WLAN_ROOT)/$(DFS_SRC_DIR)
619
620DFS_OBJS := $(DFS_SRC_DIR)/dfs_bindetects.o \
621 $(DFS_SRC_DIR)/dfs.o \
622 $(DFS_SRC_DIR)/dfs_debug.o\
623 $(DFS_SRC_DIR)/dfs_fcc_bin5.o\
624 $(DFS_SRC_DIR)/dfs_init.o\
625 $(DFS_SRC_DIR)/dfs_misc.o\
626 $(DFS_SRC_DIR)/dfs_nol.o\
627 $(DFS_SRC_DIR)/dfs_phyerr_tlv.o\
628 $(DFS_SRC_DIR)/dfs_process_phyerr.o\
629 $(DFS_SRC_DIR)/dfs_process_radarevent.o\
630 $(DFS_SRC_DIR)/dfs_staggered.o
631
632############ SME ############
633SME_DIR := core/sme
634SME_INC_DIR := $(SME_DIR)/inc
635SME_SRC_DIR := $(SME_DIR)/src
636
637SME_INC := -I$(WLAN_ROOT)/$(SME_INC_DIR) \
638 -I$(WLAN_ROOT)/$(SME_SRC_DIR)/csr
639
640SME_CSR_OBJS := $(SME_SRC_DIR)/csr/csr_api_roam.o \
641 $(SME_SRC_DIR)/csr/csr_api_scan.o \
642 $(SME_SRC_DIR)/csr/csr_cmd_process.o \
643 $(SME_SRC_DIR)/csr/csr_link_list.o \
644 $(SME_SRC_DIR)/csr/csr_neighbor_roam.o \
Varun Reddy Yeturu86459d62016-02-22 10:07:02 -0800645 $(SME_SRC_DIR)/csr/csr_util.o \
Varun Reddy Yeturubbbbe232016-02-29 14:01:57 -0800646
647
648ifeq ($(CONFIG_QCACLD_WLAN_LFR2),y)
649SME_CSR_OBJS += $(SME_SRC_DIR)/csr/csr_roam_preauth.o \
Varun Reddy Yeturu86459d62016-02-22 10:07:02 -0800650 $(SME_SRC_DIR)/csr/csr_host_scan_roam.o
Varun Reddy Yeturubbbbe232016-02-29 14:01:57 -0800651endif
652
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800653
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800654ifeq ($(CONFIG_QCOM_TDLS),y)
655SME_CSR_OBJS += $(SME_SRC_DIR)/csr/csr_tdls_process.o
656endif
657
658SME_QOS_OBJS := $(SME_SRC_DIR)/qos/sme_qos.o
659
660SME_CMN_OBJS := $(SME_SRC_DIR)/common/sme_api.o \
661 $(SME_SRC_DIR)/common/sme_ft_api.o \
662 $(SME_SRC_DIR)/common/sme_power_save.o \
663 $(SME_SRC_DIR)/common/sme_trace.o
664
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800665SME_P2P_OBJS = $(SME_SRC_DIR)/p2p/p2p_api.o
666
667SME_RRM_OBJS := $(SME_SRC_DIR)/rrm/sme_rrm.o
668
669ifeq ($(CONFIG_QCACLD_FEATURE_NAN),y)
670SME_NAN_OBJS = $(SME_SRC_DIR)/nan/nan_api.o
671endif
672
Ravi Joshia063dd92016-05-25 16:43:13 -0700673ifeq ($(CONFIG_WLAN_FEATURE_NAN_DATAPATH), y)
674SME_NDP_OBJS += $(SME_SRC_DIR)/nan/nan_datapath_api.o
675endif
676
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800677SME_OBJS := $(SME_CMN_OBJS) \
678 $(SME_CSR_OBJS) \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800679 $(SME_P2P_OBJS) \
680 $(SME_QOS_OBJS) \
681 $(SME_RRM_OBJS) \
Ravi Joshia063dd92016-05-25 16:43:13 -0700682 $(SME_NAN_OBJS) \
683 $(SME_NDP_OBJS)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800684
685############ NLINK ############
686NLINK_DIR := core/utils/nlink
687NLINK_INC_DIR := $(NLINK_DIR)/inc
688NLINK_SRC_DIR := $(NLINK_DIR)/src
689
690NLINK_INC := -I$(WLAN_ROOT)/$(NLINK_INC_DIR)
691NLINK_OBJS := $(NLINK_SRC_DIR)/wlan_nlink_srv.o
692
693############ PTT ############
694PTT_DIR := core/utils/ptt
695PTT_INC_DIR := $(PTT_DIR)/inc
696PTT_SRC_DIR := $(PTT_DIR)/src
697
698PTT_INC := -I$(WLAN_ROOT)/$(PTT_INC_DIR)
699PTT_OBJS := $(PTT_SRC_DIR)/wlan_ptt_sock_svc.o
700
701############ WLAN_LOGGING ############
702WLAN_LOGGING_DIR := core/utils/logging
703WLAN_LOGGING_INC_DIR := $(WLAN_LOGGING_DIR)/inc
704WLAN_LOGGING_SRC_DIR := $(WLAN_LOGGING_DIR)/src
705
706WLAN_LOGGING_INC := -I$(WLAN_ROOT)/$(WLAN_LOGGING_INC_DIR)
707WLAN_LOGGING_OBJS := $(WLAN_LOGGING_SRC_DIR)/wlan_logging_sock_svc.o
708
709############ SYS ############
710SYS_DIR := core/mac/src/sys
711
712SYS_INC := -I$(WLAN_ROOT)/$(SYS_DIR)/common/inc \
713 -I$(WLAN_ROOT)/$(SYS_DIR)/legacy/src/platform/inc \
714 -I$(WLAN_ROOT)/$(SYS_DIR)/legacy/src/system/inc \
715 -I$(WLAN_ROOT)/$(SYS_DIR)/legacy/src/utils/inc
716
717SYS_COMMON_SRC_DIR := $(SYS_DIR)/common/src
718SYS_LEGACY_SRC_DIR := $(SYS_DIR)/legacy/src
719SYS_OBJS := $(SYS_COMMON_SRC_DIR)/wlan_qct_sys.o \
720 $(SYS_LEGACY_SRC_DIR)/platform/src/sys_wrapper.o \
721 $(SYS_LEGACY_SRC_DIR)/system/src/mac_init_api.o \
722 $(SYS_LEGACY_SRC_DIR)/system/src/sys_entry_func.o \
723 $(SYS_LEGACY_SRC_DIR)/utils/src/dot11f.o \
724 $(SYS_LEGACY_SRC_DIR)/utils/src/log_api.o \
725 $(SYS_LEGACY_SRC_DIR)/utils/src/mac_trace.o \
726 $(SYS_LEGACY_SRC_DIR)/utils/src/parser_api.o \
727 $(SYS_LEGACY_SRC_DIR)/utils/src/utils_api.o \
728 $(SYS_LEGACY_SRC_DIR)/utils/src/utils_parser.o
729
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -0800730############ Qca-wifi-host-cmn ############
731QDF_OS_DIR := qdf
732QDF_OS_INC_DIR := $(QDF_OS_DIR)/inc
733QDF_OS_SRC_DIR := $(QDF_OS_DIR)/linux/src
734QDF_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(QDF_OS_SRC_DIR)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800735
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -0800736QDF_INC := -I$(WLAN_COMMON_INC)/$(QDF_OS_INC_DIR) \
737 -I$(WLAN_COMMON_INC)/$(QDF_OS_SRC_DIR)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800738
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -0800739QDF_OBJS := $(QDF_OBJ_DIR)/qdf_defer.o \
740 $(QDF_OBJ_DIR)/qdf_event.o \
741 $(QDF_OBJ_DIR)/qdf_list.o \
742 $(QDF_OBJ_DIR)/qdf_lock.o \
743 $(QDF_OBJ_DIR)/qdf_mc_timer.o \
744 $(QDF_OBJ_DIR)/qdf_mem.o \
745 $(QDF_OBJ_DIR)/qdf_nbuf.o \
746 $(QDF_OBJ_DIR)/qdf_threads.o \
747 $(QDF_OBJ_DIR)/qdf_trace.o
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800748
Mahesh Kumar Kalikot Veetilc0233a72016-10-27 15:06:05 -0700749ifeq ($(CONFIG_WLAN_DEBUGFS), y)
750QDF_OBJS += $(QDF_OBJ_DIR)/qdf_debugfs.o
751endif
752
Frank Liu65b17d92016-11-23 15:58:44 +0800753############ UMAC_DISP ############
754UMAC_DISP_DIR := umac/global_umac_dispatcher/lmac_if
755UMAC_DISP_INC_DIR := $(UMAC_DISP_DIR)/inc
756UMAC_DISP_SRC_DIR := $(UMAC_DISP_DIR)/src
757UMAC_DISP_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_DISP_SRC_DIR)
758
759UMAC_DISP_INC := -I$(WLAN_COMMON_INC)/$(UMAC_DISP_INC_DIR)
760
761UMAC_DISP_OBJS := $(UMAC_DISP_OBJ_DIR)/wlan_lmac_if.o
762
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800763############ CDS (Connectivity driver services) ############
764CDS_DIR := core/cds
765CDS_INC_DIR := $(CDS_DIR)/inc
766CDS_SRC_DIR := $(CDS_DIR)/src
767
768CDS_INC := -I$(WLAN_ROOT)/$(CDS_INC_DIR) \
769 -I$(WLAN_ROOT)/$(CDS_SRC_DIR)
770
771CDS_OBJS := $(CDS_SRC_DIR)/cds_api.o \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800772 $(CDS_SRC_DIR)/cds_reg_service.o \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800773 $(CDS_SRC_DIR)/cds_packet.o \
774 $(CDS_SRC_DIR)/cds_regdomain.o \
775 $(CDS_SRC_DIR)/cds_sched.o \
776 $(CDS_SRC_DIR)/cds_concurrency.o \
Krunal Sonid32c6bc2016-10-18 18:00:21 -0700777 $(CDS_SRC_DIR)/cds_utils.o
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800778
779
Selvaraj, Sridhar0672a122016-12-29 16:11:48 +0530780###### UMAC OBJMGR ########
781UMAC_OBJMGR_DIR := $(WLAN_COMMON_ROOT)/umac/cmn_services/obj_mgr
782
783UMAC_OBJMGR_INC := -I$(WLAN_COMMON_INC)/umac/cmn_services/obj_mgr/inc \
784 -I$(WLAN_COMMON_INC)/umac/cmn_services/obj_mgr/src \
785 -I$(WLAN_COMMON_INC)/umac/cmn_services/inc \
786 -I$(WLAN_COMMON_INC)/umac/global_umac_dispatcher/lmac_if/inc
787
788UMAC_OBJMGR_OBJS := $(UMAC_OBJMGR_DIR)/src/wlan_objmgr_global_obj.o \
789 $(UMAC_OBJMGR_DIR)/src/wlan_objmgr_pdev_obj.o \
790 $(UMAC_OBJMGR_DIR)/src/wlan_objmgr_peer_obj.o \
791 $(UMAC_OBJMGR_DIR)/src/wlan_objmgr_psoc_obj.o \
792 $(UMAC_OBJMGR_DIR)/src/wlan_objmgr_vdev_obj.o
793
Himanshu Agarwal2fdf77a2016-12-29 11:41:00 +0530794
795########### UMAC MGMT TXRX ##########
796UMAC_MGMT_TXRX_DIR := $(WLAN_COMMON_ROOT)/umac/cmn_services/mgmt_txrx
797
Himanshu Agarwal795b7f72017-01-17 21:19:43 +0530798UMAC_MGMT_TXRX_INC := -I$(WLAN_COMMON_INC)/umac/cmn_services/mgmt_txrx/dispatcher/inc \
Himanshu Agarwal2fdf77a2016-12-29 11:41:00 +0530799
800UMAC_MGMT_TXRX_OBJS := $(UMAC_MGMT_TXRX_DIR)/core/src/wlan_mgmt_txrx_main.o \
801 $(UMAC_MGMT_TXRX_DIR)/dispatcher/src/wlan_mgmt_txrx_utils_api.o \
802 $(UMAC_MGMT_TXRX_DIR)/dispatcher/src/wlan_mgmt_txrx_tgt_api.o
803
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800804########### BMI ###########
805BMI_DIR := core/bmi
806
807BMI_INC := -I$(WLAN_ROOT)/$(BMI_DIR)/inc
808
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800809BMI_OBJS := $(BMI_DIR)/src/bmi.o \
Poddar, Siddarthef1f3022016-05-10 20:10:43 +0530810 $(BMI_DIR)/src/ol_fw.o \
811 $(BMI_DIR)/src/ol_fw_common.o
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800812BMI_OBJS += $(BMI_DIR)/src/bmi_1.o
Govind Singh0fea23a2016-03-18 12:59:27 +0530813
Mukul Sharmac3e7a782017-02-03 12:16:11 +0530814########## TARGET_IF #######
815TARGET_IF_DIR := $(WLAN_COMMON_ROOT)/target_if
816
817TARGET_IF_INC := -I$(WLAN_COMMON_INC)/target_if/core/inc \
818 -I$(WLAN_COMMON_INC)/target_if/core/src
819
820TARGET_IF_OBJ := $(TARGET_IF_DIR)/core/src/target_if_main.o
821
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800822########### WMI ###########
Govind Singh0fea23a2016-03-18 12:59:27 +0530823WMI_ROOT_DIR := wmi
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800824
Govind Singh0fea23a2016-03-18 12:59:27 +0530825WMI_SRC_DIR := $(WMI_ROOT_DIR)/src
826WMI_INC_DIR := $(WMI_ROOT_DIR)/inc
827WMI_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(WMI_SRC_DIR)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800828
Govind Singh0fea23a2016-03-18 12:59:27 +0530829WMI_INC := -I$(WLAN_COMMON_INC)/$(WMI_INC_DIR)
830
831WMI_OBJS := $(WMI_OBJ_DIR)/wmi_unified.o \
832 $(WMI_OBJ_DIR)/wmi_tlv_helper.o \
833 $(WMI_OBJ_DIR)/wmi_unified_tlv.o \
834 $(WMI_OBJ_DIR)/wmi_unified_api.o \
835 $(WMI_OBJ_DIR)/wmi_unified_non_tlv.o
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800836
837########### FWLOG ###########
838FWLOG_DIR := core/utils/fwlog
839
840FWLOG_INC := -I$(WLAN_ROOT)/$(FWLOG_DIR)
841
842FWLOG_OBJS := $(FWLOG_DIR)/dbglog_host.o
843
844############ TXRX ############
845TXRX_DIR := core/dp/txrx
846TXRX_INC := -I$(WLAN_ROOT)/$(TXRX_DIR)
847
848TXRX_OBJS := $(TXRX_DIR)/ol_txrx.o \
849 $(TXRX_DIR)/ol_cfg.o \
850 $(TXRX_DIR)/ol_rx.o \
851 $(TXRX_DIR)/ol_rx_fwd.o \
852 $(TXRX_DIR)/ol_txrx.o \
853 $(TXRX_DIR)/ol_rx_defrag.o \
854 $(TXRX_DIR)/ol_tx_desc.o \
855 $(TXRX_DIR)/ol_tx.o \
856 $(TXRX_DIR)/ol_rx_reorder_timeout.o \
857 $(TXRX_DIR)/ol_rx_reorder.o \
858 $(TXRX_DIR)/ol_rx_pn.o \
859 $(TXRX_DIR)/ol_tx_queue.o \
860 $(TXRX_DIR)/ol_txrx_peer_find.o \
861 $(TXRX_DIR)/ol_txrx_event.o \
862 $(TXRX_DIR)/ol_txrx_encap.o \
Poddar, Siddarth29296fb2016-05-16 18:06:30 +0530863 $(TXRX_DIR)/ol_tx_send.o \
864 $(TXRX_DIR)/ol_tx_sched.o \
865 $(TXRX_DIR)/ol_tx_classify.o
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800866
867ifeq ($(CONFIG_WLAN_TX_FLOW_CONTROL_V2), y)
868TXRX_OBJS += $(TXRX_DIR)/ol_txrx_flow_control.o
869endif
870
Venkata Sharath Chandra Manchala5d714d82017-01-18 14:56:32 -0800871ifeq ($(CONFIG_LITHIUM), y)
Leo Chang5f7a1e02016-11-04 14:04:26 -0700872############ DP 3.0 ############
873DP_INC := -I$(WLAN_COMMON_ROOT)/dp/inc \
874 -I$(WLAN_COMMON_ROOT)/dp/wifi3.0
875
876DP_SRC := $(WLAN_COMMON_ROOT)/dp/wifi3.0
877DP_OBJS := $(DP_SRC)/dp_main.o \
878 $(DP_SRC)/dp_tx.o \
879 $(DP_SRC)/dp_tx_desc.o \
880 $(DP_SRC)/dp_rx.o \
881 $(DP_SRC)/dp_rx_err.o \
882 $(DP_SRC)/dp_htt.o \
883 $(DP_SRC)/dp_peer.o \
Debashis Dutt237c6142017-01-04 11:28:59 -0800884 $(DP_SRC)/dp_rx_desc.o \
885 $(DP_SRC)/dp_reo.o
Venkata Sharath Chandra Manchala5d714d82017-01-18 14:56:32 -0800886endif
Leo Chang5f7a1e02016-11-04 14:04:26 -0700887
888############ CFG ############
889WCFG_DIR := $(WLAN_COMMON_ROOT)/wlan_cfg
890WCFG_INC := -I$(WCFG_DIR)
891WCFG_OBJS := $(WCFG_DIR)/wlan_cfg.o
892
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800893############ OL ############
894OL_DIR := core/dp/ol
895OL_INC := -I$(WLAN_ROOT)/$(OL_DIR)/inc
896
Dhanashri Atre12a08392016-02-17 13:10:34 -0800897############ CDP ############
898CDP_ROOT_DIR := dp
899CDP_INC_DIR := $(CDP_ROOT_DIR)/inc
900CDP_INC := -I$(WLAN_COMMON_INC)/$(CDP_INC_DIR)
901
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800902############ PKTLOG ############
903PKTLOG_DIR := core/utils/pktlog
904PKTLOG_INC := -I$(WLAN_ROOT)/$(PKTLOG_DIR)/include
905
906PKTLOG_OBJS := $(PKTLOG_DIR)/pktlog_ac.o \
907 $(PKTLOG_DIR)/pktlog_internal.o \
908 $(PKTLOG_DIR)/linux_ac.o
909
910############ HTT ############
911HTT_DIR := core/dp/htt
912HTT_INC := -I$(WLAN_ROOT)/$(HTT_DIR)
913
914HTT_OBJS := $(HTT_DIR)/htt_tx.o \
915 $(HTT_DIR)/htt.o \
916 $(HTT_DIR)/htt_t2h.o \
917 $(HTT_DIR)/htt_h2t.o \
918 $(HTT_DIR)/htt_fw_stats.o \
919 $(HTT_DIR)/htt_rx.o
920
Rajeev Kumar97767a02016-11-30 11:20:40 -0800921
922############## INIT-DEINIT ###########
923INIT_DEINIT_DIR := init_deinit/dispatcher
924INIT_DEINIT_INC_DIR := $(INIT_DEINIT_DIR)/inc
925INIT_DEINIT_SRC_DIR := $(INIT_DEINIT_DIR)/src
926INIT_DEINIT_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(INIT_DEINIT_SRC_DIR)
927INIT_DEINIT_INC := -I$(WLAN_COMMON_INC)/$(INIT_DEINIT_INC_DIR)
928INIT_DEINIT_OBJS := $(INIT_DEINIT_OBJ_DIR)/dispatcher_init_deinit.o
929
Rajeev Kumar1705fc22016-11-30 16:12:16 -0800930############## Control path common scheduler ##########
Rajeev Kumarebb0a732016-12-24 19:05:44 -0800931SCHEDULER_DIR := scheduler
932SCHEDULER_INC_DIR := $(SCHEDULER_DIR)/inc
933SCHEDULER_SRC_DIR := $(SCHEDULER_DIR)/src
934SCHEDULER_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(SCHEDULER_SRC_DIR)
935SCHEDULER_INC := -I$(WLAN_COMMON_INC)/$(SCHEDULER_INC_DIR)
936SCHEDULER_OBJS := $(SCHEDULER_OBJ_DIR)/scheduler_api.o \
937 $(SCHEDULER_OBJ_DIR)/scheduler_core.o
Rajeev Kumar1705fc22016-11-30 16:12:16 -0800938
Rajeev Kumar97767a02016-11-30 11:20:40 -0800939
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800940############## HTC ##########
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -0800941HTC_DIR := htc
942HTC_INC := -I$(WLAN_COMMON_INC)/$(HTC_DIR)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800943
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -0800944HTC_OBJS := $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc.o \
945 $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc_send.o \
946 $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc_recv.o \
947 $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc_services.o
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800948
949########### HIF ###########
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -0800950HIF_DIR := hif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800951HIF_CE_DIR := $(HIF_DIR)/src/ce
Houston Hoffman1edffd32016-01-27 16:30:34 -0800952
953HIF_DISPATCHER_DIR := $(HIF_DIR)/src/dispatcher
954
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800955HIF_PCIE_DIR := $(HIF_DIR)/src/pcie
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800956HIF_SNOC_DIR := $(HIF_DIR)/src/snoc
Mohit Khannada4f4432016-05-17 15:02:09 -0700957HIF_USB_DIR := $(HIF_DIR)/src/usb
Poddar, Siddarth29296fb2016-05-16 18:06:30 +0530958HIF_SDIO_DIR := $(HIF_DIR)/src/sdio
959
960HIF_SDIO_NATIVE_DIR := $(HIF_SDIO_DIR)/native_sdio
961HIF_SDIO_NATIVE_INC_DIR := $(HIF_SDIO_NATIVE_DIR)/include
962HIF_SDIO_NATIVE_SRC_DIR := $(HIF_SDIO_NATIVE_DIR)/src
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800963
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -0800964HIF_INC := -I$(WLAN_COMMON_INC)/$(HIF_DIR)/inc \
965 -I$(WLAN_COMMON_INC)/$(HIF_DIR)/src \
Yuanyuan Liu91353612016-05-04 12:02:00 -0700966 -I$(WLAN_COMMON_INC)/$(HIF_CE_DIR)
Houston Hoffman1edffd32016-01-27 16:30:34 -0800967
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800968ifeq ($(CONFIG_HIF_PCI), 1)
Houston Hoffman1edffd32016-01-27 16:30:34 -0800969HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_DISPATCHER_DIR)
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -0800970HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_PCIE_DIR)
Houston Hoffman1edffd32016-01-27 16:30:34 -0800971endif
972
973ifeq ($(CONFIG_HIF_SNOC), 1)
974HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_DISPATCHER_DIR)
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -0800975HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_SNOC_DIR)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -0800976endif
977
Mohit Khannada4f4432016-05-17 15:02:09 -0700978ifeq ($(CONFIG_HIF_USB), 1)
979HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_DISPATCHER_DIR)
980HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_USB_DIR)
981endif
982
Poddar, Siddarth29296fb2016-05-16 18:06:30 +0530983ifeq ($(CONFIG_HIF_SDIO), 1)
984HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_DISPATCHER_DIR)
985HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_SDIO_DIR)
986HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_SDIO_NATIVE_INC_DIR)
987endif
988
989HIF_COMMON_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/ath_procfs.o \
990 $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_main.o \
991 $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/mp_dev.o
992
993HIF_CE_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_bmi.o \
994 $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_diag.o \
995 $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_main.o \
996 $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_service.o \
997 $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_tasklet.o \
Venkata Sharath Chandra Manchala5d714d82017-01-18 14:56:32 -0800998 $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/regtable.o
Poddar, Siddarth29296fb2016-05-16 18:06:30 +0530999
Venkata Sharath Chandra Manchala5d714d82017-01-18 14:56:32 -08001000ifeq ($(CONFIG_LITHIUM), y)
1001HIF_CE_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/qca6290def.o \
1002 $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_service_srng.o
Houston Hoffmana0f93492016-11-18 13:42:12 -08001003endif
1004
Mohit Khannada4f4432016-05-17 15:02:09 -07001005HIF_USB_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_USB_DIR)/usbdrv.o \
1006 $(WLAN_COMMON_ROOT)/$(HIF_USB_DIR)/hif_usb.o \
1007 $(WLAN_COMMON_ROOT)/$(HIF_USB_DIR)/if_usb.o \
1008 $(WLAN_COMMON_ROOT)/$(HIF_USB_DIR)/regtable_usb.o
1009
Poddar, Siddarth29296fb2016-05-16 18:06:30 +05301010HIF_SDIO_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_sdio_send.o \
1011 $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_bmi_reg_access.o \
1012 $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_diag_reg_access.o \
1013 $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_sdio_dev.o \
1014 $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_sdio.o \
1015 $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_sdio_recv.o \
1016 $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/regtable_sdio.o
1017
1018HIF_SDIO_NATIVE_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_SDIO_NATIVE_SRC_DIR)/hif.o \
1019 $(WLAN_COMMON_ROOT)/$(HIF_SDIO_NATIVE_SRC_DIR)/hif_scatter.o
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001020
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001021ifeq ($(CONFIG_WLAN_NAPI), y)
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -08001022HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_napi.o
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001023endif
1024
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -08001025HIF_PCIE_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_PCIE_DIR)/if_pci.o
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -08001026HIF_SNOC_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_SNOC_DIR)/if_snoc.o
Poddar, Siddarth29296fb2016-05-16 18:06:30 +05301027HIF_SDIO_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/if_sdio.o
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001028
Houston Hoffman1edffd32016-01-27 16:30:34 -08001029HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus.o
Houston Hoffmanb61b9b12016-03-03 20:04:16 -08001030HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/dummy.o
Houston Hoffman1edffd32016-01-27 16:30:34 -08001031
1032ifeq ($(CONFIG_HIF_PCI), 1)
1033HIF_OBJS += $(HIF_PCIE_OBJS)
Poddar, Siddarth29296fb2016-05-16 18:06:30 +05301034HIF_OBJS += $(HIF_COMMON_OBJS)
1035HIF_OBJS += $(HIF_CE_OBJS)
Houston Hoffman1edffd32016-01-27 16:30:34 -08001036HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus_pci.o
1037endif
1038
1039ifeq ($(CONFIG_HIF_SNOC), 1)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001040HIF_OBJS += $(HIF_SNOC_OBJS)
Poddar, Siddarth29296fb2016-05-16 18:06:30 +05301041HIF_OBJS += $(HIF_COMMON_OBJS)
1042HIF_OBJS += $(HIF_CE_OBJS)
Houston Hoffman1edffd32016-01-27 16:30:34 -08001043HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus_snoc.o
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001044endif
1045
Poddar, Siddarth29296fb2016-05-16 18:06:30 +05301046ifeq ($(CONFIG_HIF_SDIO), 1)
1047HIF_OBJS += $(HIF_SDIO_OBJS)
1048HIF_OBJS += $(HIF_SDIO_NATIVE_OBJS)
1049HIF_OBJS += $(HIF_COMMON_OBJS)
1050HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus_sdio.o
1051endif
1052
Mohit Khannada4f4432016-05-17 15:02:09 -07001053ifeq ($(CONFIG_HIF_USB), 1)
1054HIF_OBJS += $(HIF_USB_OBJS)
1055HIF_OBJS += $(HIF_COMMON_OBJS)
1056HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus_usb.o
1057endif
1058
Venkata Sharath Chandra Manchala5d714d82017-01-18 14:56:32 -08001059ifeq ($(CONFIG_LITHIUM), y)
Leo Chang5f7a1e02016-11-04 14:04:26 -07001060############ HAL ############
1061HAL_DIR := hal
1062HAL_INC := -I$(WLAN_COMMON_INC)/$(HAL_DIR)/inc \
1063 -I$(WLAN_COMMON_INC)/$(HAL_DIR)/wifi3.0
1064
1065HAL_OBJS := $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/hal_srng.o \
1066 $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/hal_rx.o \
Debashis Dutt237c6142017-01-04 11:28:59 -08001067 $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/hal_wbm.o \
1068 $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/hal_reo.o
Venkata Sharath Chandra Manchala5d714d82017-01-18 14:56:32 -08001069endif
Leo Chang5f7a1e02016-11-04 14:04:26 -07001070
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001071############ WMA ############
1072WMA_DIR := core/wma
1073
1074WMA_INC_DIR := $(WMA_DIR)/inc
1075WMA_SRC_DIR := $(WMA_DIR)/src
1076
1077WMA_INC := -I$(WLAN_ROOT)/$(WMA_INC_DIR) \
1078 -I$(WLAN_ROOT)/$(WMA_SRC_DIR)
1079
Ravi Joshia063dd92016-05-25 16:43:13 -07001080ifeq ($(CONFIG_WLAN_FEATURE_NAN_DATAPATH), y)
1081WMA_NDP_OBJS += $(WMA_SRC_DIR)/wma_nan_datapath.o
1082endif
1083
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001084WMA_OBJS := $(WMA_SRC_DIR)/wma_main.o \
1085 $(WMA_SRC_DIR)/wma_scan_roam.o \
1086 $(WMA_SRC_DIR)/wma_dev_if.o \
1087 $(WMA_SRC_DIR)/wma_mgmt.o \
1088 $(WMA_SRC_DIR)/wma_power.o \
1089 $(WMA_SRC_DIR)/wma_data.o \
1090 $(WMA_SRC_DIR)/wma_utils.o \
1091 $(WMA_SRC_DIR)/wma_features.o \
1092 $(WMA_SRC_DIR)/wma_dfs_interface.o \
Ravi Joshia063dd92016-05-25 16:43:13 -07001093 $(WMA_SRC_DIR)/wlan_qct_wma_legacy.o\
1094 $(WMA_NDP_OBJS)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001095
Agrawal Ashishb141b092016-09-02 19:59:26 +05301096ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
Jeff Johnsonb90ab572017-01-31 15:57:35 -08001097WMA_OBJS+= $(WMA_SRC_DIR)/wma_ocb.o
Agrawal Ashishb141b092016-09-02 19:59:26 +05301098endif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001099ifeq ($(CONFIG_MPC_UT_FRAMEWORK),y)
1100WMA_OBJS += $(WMA_SRC_DIR)/wma_utils_ut.o
1101endif
1102
Yuanyuan Liud9f7a362016-01-22 14:27:12 -08001103############## PLD ##########
1104PLD_DIR := core/pld
1105PLD_INC_DIR := $(PLD_DIR)/inc
1106PLD_SRC_DIR := $(PLD_DIR)/src
1107
1108PLD_INC := -I$(WLAN_ROOT)/$(PLD_INC_DIR) \
1109 -I$(WLAN_ROOT)/$(PLD_SRC_DIR)
1110
1111PLD_OBJS := $(PLD_SRC_DIR)/pld_common.o
1112
1113ifeq ($(CONFIG_PCI), y)
1114PLD_OBJS += $(PLD_SRC_DIR)/pld_pcie.o
1115endif
1116ifeq ($(CONFIG_ICNSS),y)
1117PLD_OBJS += $(PLD_SRC_DIR)/pld_snoc.o
1118endif
Poddar, Siddarth29296fb2016-05-16 18:06:30 +05301119ifeq ($(CONFIG_CNSS_SDIO),y)
1120PLD_OBJS += $(PLD_SRC_DIR)/pld_sdio.o
1121endif
Mohit Khannae7a43572016-10-10 17:34:21 -07001122ifeq ($(CONFIG_PLD_USB_CNSS), y)
Mohit Khannada4f4432016-05-17 15:02:09 -07001123PLD_OBJS += $(PLD_SRC_DIR)/pld_usb.o
1124endif
Yuanyuan Liud9f7a362016-01-22 14:27:12 -08001125
Leo Chang5f7a1e02016-11-04 14:04:26 -07001126TARGET_INC := -I$(WLAN_ROOT)/../fw-api/hw/qca6290/v1 \
1127 -I$(WLAN_ROOT)/../fw-api/fw
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001128
1129LINUX_INC := -Iinclude/linux
1130
1131INCS := $(HDD_INC) \
1132 $(EPPING_INC) \
1133 $(LINUX_INC) \
1134 $(MAC_INC) \
1135 $(SAP_INC) \
1136 $(SME_INC) \
1137 $(SYS_INC) \
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -08001138 $(QDF_INC) \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001139 $(CDS_INC) \
Mukul Sharmac3e7a782017-02-03 12:16:11 +05301140 $(DFS_INC) \
1141 $(TARGET_IF_INC)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001142
1143INCS += $(WMA_INC) \
1144 $(UAPI_INC) \
1145 $(COMMON_INC) \
1146 $(WMI_INC) \
1147 $(FWLOG_INC) \
1148 $(TXRX_INC) \
1149 $(OL_INC) \
Dhanashri Atre12a08392016-02-17 13:10:34 -08001150 $(CDP_INC) \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001151 $(PKTLOG_INC) \
1152 $(HTT_INC) \
Rajeev Kumar97767a02016-11-30 11:20:40 -08001153 $(INIT_DEINIT_INC) \
Rajeev Kumarebb0a732016-12-24 19:05:44 -08001154 $(SCHEDULER_INC) \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001155 $(HTC_INC) \
Leo Chang5f7a1e02016-11-04 14:04:26 -07001156 $(DFS_INC) \
Venkata Sharath Chandra Manchala5d714d82017-01-18 14:56:32 -08001157 $(WCFG_INC)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001158
1159INCS += $(HIF_INC) \
Venkata Sharath Chandra Manchala5d714d82017-01-18 14:56:32 -08001160 $(BMI_INC)
1161
1162ifeq ($(CONFIG_LITHIUM), y)
1163INCS += $(HAL_INC) \
1164 $(DP_INC)
1165endif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001166
Selvaraj, Sridhar0672a122016-12-29 16:11:48 +05301167INCS += $(UMAC_OBJMGR_INC)
Himanshu Agarwal2fdf77a2016-12-29 11:41:00 +05301168INCS += $(UMAC_MGMT_TXRX_INC)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001169INCS += $(TARGET_INC)
1170
1171INCS += $(NLINK_INC) \
1172 $(PTT_INC) \
1173 $(WLAN_LOGGING_INC)
1174
Yuanyuan Liud9f7a362016-01-22 14:27:12 -08001175INCS += $(PLD_INC)
1176
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001177ifeq ($(CONFIG_REMOVE_PKT_LOG), 0)
1178INCS += $(PKTLOG_INC)
1179endif
1180
1181ifeq ($(BUILD_DIAG_VERSION), 1)
1182INCS += $(HOST_DIAG_LOG_INC)
1183endif
1184
Frank Liu65b17d92016-11-23 15:58:44 +08001185INCS += $(UMAC_DISP_INC)
Frank Liu65b17d92016-11-23 15:58:44 +08001186
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001187OBJS := $(HDD_OBJS) \
1188 $(EPPING_OBJS) \
1189 $(MAC_OBJS) \
1190 $(SAP_OBJS) \
1191 $(SME_OBJS) \
1192 $(SYS_OBJS) \
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -08001193 $(QDF_OBJS) \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001194 $(CDS_OBJS) \
1195 $(DFS_OBJS)
1196
1197OBJS += $(WMA_OBJS) \
1198 $(TXRX_OBJS) \
1199 $(WMI_OBJS) \
1200 $(FWLOG_OBJS) \
1201 $(HTC_OBJS) \
Rajeev Kumar97767a02016-11-30 11:20:40 -08001202 $(INIT_DEINIT_OBJS) \
Rajeev Kumarebb0a732016-12-24 19:05:44 -08001203 $(SCHEDULER_OBJS) \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001204 $(DFS_OBJS)
1205
1206OBJS += $(HIF_OBJS) \
1207 $(BMI_OBJS) \
Mukul Sharmac3e7a782017-02-03 12:16:11 +05301208 $(HTT_OBJS) \
1209 $(TARGET_IF_OBJ)
Venkata Sharath Chandra Manchala5d714d82017-01-18 14:56:32 -08001210
1211ifeq ($(CONFIG_LITHIUM), y)
1212OBJS += $(HAL_OBJS)
1213endif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001214
Selvaraj, Sridhar0672a122016-12-29 16:11:48 +05301215OBJS += $(UMAC_OBJMGR_OBJS)
Himanshu Agarwal2fdf77a2016-12-29 11:41:00 +05301216OBJS += $(UMAC_MGMT_TXRX_OBJS)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001217OBJS += $(WLAN_LOGGING_OBJS)
1218OBJS += $(NLINK_OBJS)
1219OBJS += $(PTT_OBJS)
1220
Yuanyuan Liud9f7a362016-01-22 14:27:12 -08001221OBJS += $(PLD_OBJS)
1222
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001223ifeq ($(CONFIG_REMOVE_PKT_LOG), 0)
1224OBJS += $(PKTLOG_OBJS)
1225endif
1226
1227ifeq ($(BUILD_DIAG_VERSION), 1)
1228OBJS += $(HOST_DIAG_LOG_OBJS)
1229endif
1230
Frank Liu65b17d92016-11-23 15:58:44 +08001231OBJS += $(UMAC_DISP_OBJS)
Frank Liu65b17d92016-11-23 15:58:44 +08001232
Venkata Sharath Chandra Manchala5d714d82017-01-18 14:56:32 -08001233OBJS += $(WCFG_OBJS)
1234
1235ifeq ($(CONFIG_LITHIUM), y)
1236OBJS += $(DP_OBJS)
1237endif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001238
1239EXTRA_CFLAGS += $(INCS)
1240
1241CDEFINES := -DANI_LITTLE_BYTE_ENDIAN \
1242 -DANI_LITTLE_BIT_ENDIAN \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001243 -DDOT11F_LITTLE_ENDIAN_HOST \
1244 -DANI_COMPILER_TYPE_GCC \
1245 -DANI_OS_TYPE_ANDROID=6 \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001246 -DPTT_SOCK_SVC_ENABLE \
1247 -Wall\
1248 -Werror\
1249 -D__linux__ \
1250 -DHAL_SELF_STA_PER_BSS=1 \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001251 -DFEATURE_WLAN_WAPI \
1252 -DFEATURE_OEM_DATA_SUPPORT\
1253 -DSOFTAP_CHANNEL_RANGE \
1254 -DWLAN_AP_STA_CONCURRENCY \
1255 -DFEATURE_WLAN_SCAN_PNO \
1256 -DWLAN_FEATURE_PACKET_FILTERING \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001257 -DWLAN_FEATURE_P2P_DEBUG \
1258 -DWLAN_ENABLE_AGEIE_ON_SCAN_RESULTS \
1259 -DWLANTL_DEBUG\
1260 -DWLAN_NS_OFFLOAD \
1261 -DWLAN_SOFTAP_VSTA_FEATURE \
1262 -DWLAN_FEATURE_GTK_OFFLOAD \
1263 -DWLAN_WAKEUP_EVENTS \
1264 -DFEATURE_WLAN_RA_FILTERING\
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001265 -DWLAN_NL80211_TESTMODE \
1266 -DFEATURE_WLAN_LPHB \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001267 -DQCA_SUPPORT_TX_THROTTLE \
1268 -DWMI_INTERFACE_EVENT_LOGGING \
1269 -DATH_SUPPORT_WAPI \
1270 -DWLAN_FEATURE_LINK_LAYER_STATS \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001271 -DFEATURE_WLAN_EXTSCAN \
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001272 -DWLAN_FEATURE_MBSSID \
Prashanth Bhatta7e58dd32016-02-16 15:46:46 -08001273 -DCONFIG_160MHZ_SUPPORT \
1274 -DCONFIG_MCL
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001275
Mohit Khannada4f4432016-05-17 15:02:09 -07001276ifneq ($(CONFIG_HIF_USB), 1)
1277CDEFINES += -DWLAN_LOGGING_SOCK_SVC_ENABLE
1278endif
1279
Yuanyuan Liu11f526a2016-05-18 10:22:07 -07001280ifeq ($(CONFIG_CNSS), y)
1281ifeq ($(CONFIG_CNSS_SDIO), y)
1282CDEFINES += -DCONFIG_PLD_SDIO_CNSS
1283else
1284CDEFINES += -DCONFIG_PLD_PCIE_CNSS
1285endif
1286endif
1287
Yue Mae6a7a322016-08-31 11:09:23 -07001288ifeq ($(CONFIG_CNSS2), y)
1289CDEFINES += -DCONFIG_PLD_PCIE_CNSS
Houston Hoffman435cd442016-11-23 14:20:42 -08001290CDEFINES += -DCONFIG_PLD_PCIE_INIT
Yue Mae6a7a322016-08-31 11:09:23 -07001291endif
1292
Yuanyuan Liu11f526a2016-05-18 10:22:07 -07001293ifeq ($(CONFIG_ICNSS), y)
1294CDEFINES += -DCONFIG_PLD_SNOC_ICNSS
1295endif
1296
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001297ifeq (y,$(filter y,$(CONFIG_CNSS_EOS) $(CONFIG_ICNSS)))
1298CDEFINES += -DQCA_WIFI_3_0
1299CDEFINES += -DQCA_WIFI_3_0_EMU
1300endif
1301
1302ifeq (y,$(filter y,$(CONFIG_CNSS_ADRASTEA) $(CONFIG_ICNSS)))
1303CDEFINES += -DQCA_WIFI_3_0_ADRASTEA
1304CDEFINES += -DADRASTEA_SHADOW_REGISTERS
Sanjay Devnanicdab59e2015-11-12 14:43:58 -08001305CDEFINES += -DADRASTEA_RRI_ON_DDR
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001306endif
1307
1308ifeq ($(CONFIG_WLAN_FASTPATH), y)
1309CDEFINES += -DWLAN_FEATURE_FASTPATH
1310endif
1311
Poddar, Siddartheefe3482016-09-21 18:12:59 +05301312ifeq ($(CONFIG_FEATURE_PKTLOG), y)
1313CDEFINES += -DFEATURE_PKTLOG
1314endif
1315
Nirav Shahcc1f1ae2016-04-26 11:41:29 +05301316ifeq ($(CONFIG_FEATURE_DP_TRACE), y)
1317CDEFINES += -DFEATURE_DP_TRACE
1318endif
1319
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001320ifeq ($(CONFIG_WLAN_NAPI), y)
1321CDEFINES += -DFEATURE_NAPI
1322ifeq ($(CONFIG_WLAN_NAPI_DEBUG), y)
1323CDEFINES += -DFEATURE_NAPI_DEBUG
1324endif
1325endif
1326
Yue Madf224b82016-04-21 12:46:04 -07001327ifeq (y,$(findstring y,$(CONFIG_ARCH_MSM) $(CONFIG_ARCH_QCOM)))
Yuanyuan Liu5af44362016-04-01 21:57:06 -07001328CDEFINES += -DMSM_PLATFORM
1329endif
1330
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001331CDEFINES += -DQCA_SUPPORT_TXRX_LOCAL_PEER_ID
1332
1333ifeq ($(CONFIG_WLAN_TX_FLOW_CONTROL_V2), y)
1334CDEFINES += -DQCA_LL_TX_FLOW_CONTROL_V2
1335CDEFINES += -DQCA_LL_TX_FLOW_GLOBAL_MGMT_POOL
1336else
1337ifeq ($(CONFIG_ROME_IF),pci)
Leo Chang5f7a1e02016-11-04 14:04:26 -07001338ifneq ($(CONFIG_LITHIUM),y)
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001339CDEFINES += -DQCA_LL_LEGACY_TX_FLOW_CONTROL
1340endif
1341endif
Leo Chang5f7a1e02016-11-04 14:04:26 -07001342endif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001343
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001344ifneq ($(CONFIG_QCA_CLD_WLAN),)
1345CDEFINES += -DWCN_PRONTO
1346CDEFINES += -DWCN_PRONTO_V1
1347endif
1348
1349ifeq ($(BUILD_DEBUG_VERSION),1)
1350CDEFINES += -DWLAN_DEBUG \
1351 -DTRACE_RECORD \
1352 -DLIM_TRACE_RECORD \
1353 -DSME_TRACE_RECORD \
1354 -DHDD_TRACE_RECORD \
1355 -DPE_DEBUG_LOGW \
Srinivas Girigowda6147c582016-10-18 12:26:15 -07001356 -DPE_DEBUG_LOGE
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001357endif
1358
1359ifeq ($(CONFIG_SLUB_DEBUG_ON),y)
1360CDEFINES += -DTIMER_MANAGER
1361CDEFINES += -DMEMORY_DEBUG
Dustin Brown8b28e082016-12-06 15:37:34 -08001362CDEFINES += -DWLAN_SUSPEND_RESUME_TEST
Houston Hoffmand4ba4312017-01-13 18:30:15 -08001363CONFIG_LOCK_STATS_ON := y
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001364endif
1365
Houston Hoffmand4ba4312017-01-13 18:30:15 -08001366ifeq ($(CONFIG_LOCK_STATS_ON),y)
1367CDEFINES += -DQDF_LOCK_STATS=1
1368CDEFINES += -DQDF_LOCK_STATS_DESTROY_PRINT=0
1369CDEFINES += -DQDF_LOCK_STATS_BUG_ON=1
1370CDEFINES += -DQDF_LOCK_STATS_LIST=1
1371CDEFINES += -DQDF_LOCK_STATS_LIST_SIZE=256
1372endif
1373
1374
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001375ifeq ($(HAVE_CFG80211),1)
1376CDEFINES += -DWLAN_FEATURE_P2P
1377CDEFINES += -DWLAN_FEATURE_WFD
1378ifeq ($(CONFIG_QCOM_VOWIFI_11R),y)
1379CDEFINES += -DKERNEL_SUPPORT_11R_CFG80211
1380CDEFINES += -DUSE_80211_WMMTSPEC_FOR_RIC
1381endif
1382endif
1383
1384ifeq ($(CONFIG_QCOM_ESE),y)
1385CDEFINES += -DFEATURE_WLAN_ESE
1386CDEFINES += -DQCA_COMPUTE_TX_DELAY
1387CDEFINES += -DQCA_COMPUTE_TX_DELAY_PER_TID
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001388endif
1389
1390#normally, TDLS negative behavior is not needed
1391ifeq ($(CONFIG_QCOM_TDLS),y)
1392CDEFINES += -DFEATURE_WLAN_TDLS
1393endif
1394
1395ifeq ($(CONFIG_QCACLD_WLAN_LFR3),y)
1396CDEFINES += -DWLAN_FEATURE_ROAM_OFFLOAD
1397endif
1398
Varun Reddy Yeturubbbbe232016-02-29 14:01:57 -08001399ifeq ($(CONFIG_QCACLD_WLAN_LFR2),y)
1400CDEFINES += -DWLAN_FEATURE_HOST_ROAM
1401endif
1402
Sridhar Selvarajdc400d22016-10-18 17:18:03 +05301403ifeq ($(CONFIG_WLAN_POWER_DEBUGFS), y)
1404CDEFINES += -DWLAN_POWER_DEBUGFS
1405endif
1406
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001407ifeq ($(BUILD_DIAG_VERSION),1)
1408CDEFINES += -DFEATURE_WLAN_DIAG_SUPPORT
1409CDEFINES += -DFEATURE_WLAN_DIAG_SUPPORT_CSR
1410CDEFINES += -DFEATURE_WLAN_DIAG_SUPPORT_LIM
1411ifeq ($(CONFIG_HIF_PCI), 1)
1412CDEFINES += -DCONFIG_ATH_PROCFS_DIAG_SUPPORT
1413endif
1414endif
1415
1416ifeq ($(CONFIG_HIF_USB), 1)
1417CDEFINES += -DCONFIG_ATH_PROCFS_DIAG_SUPPORT
1418CDEFINES += -DQCA_SUPPORT_OL_RX_REORDER_TIMEOUT
1419CDEFINES += -DCONFIG_ATH_PCIE_MAX_PERF=0 -DCONFIG_ATH_PCIE_AWAKE_WHILE_DRIVER_LOAD=0 -DCONFIG_DISABLE_CDC_MAX_PERF_WAR=0
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001420endif
1421
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001422ifeq ($(CONFIG_WLAN_FEATURE_11W),y)
1423CDEFINES += -DWLAN_FEATURE_11W
1424endif
1425
gbiane55c9562016-11-01 14:47:47 +08001426ifeq ($(CONFIG_QCA_TXDESC_SANITY_CHECKS), 1)
1427CDEFINES += -DQCA_SUPPORT_TXDESC_SANITY_CHECKS
1428endif
1429
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001430ifeq ($(CONFIG_QCOM_LTE_COEX),y)
1431CDEFINES += -DFEATURE_WLAN_CH_AVOID
1432endif
1433
1434ifeq ($(CONFIG_WLAN_FEATURE_LPSS),y)
1435CDEFINES += -DWLAN_FEATURE_LPSS
1436endif
1437
Nirav Shah76291962016-04-25 10:50:37 +05301438ifneq ($(TARGET_BUILD_VARIANT),user)
1439CDEFINES += -DDESC_DUP_DETECT_DEBUG
Manjunathappa Prakashc8e75642016-06-03 19:32:27 -07001440CDEFINES += -DDEBUG_RX_RING_BUFFER
Nirav Shah76291962016-04-25 10:50:37 +05301441endif
1442
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001443ifeq ($(PANIC_ON_BUG),1)
1444CDEFINES += -DPANIC_ON_BUG
1445endif
1446
1447ifeq ($(WLAN_OPEN_SOURCE), 1)
1448CDEFINES += -DWLAN_OPEN_SOURCE
1449endif
1450
1451ifeq ($(CONFIG_FEATURE_STATS_EXT), 1)
1452CDEFINES += -DWLAN_FEATURE_STATS_EXT
1453endif
1454
1455ifeq ($(CONFIG_QCACLD_FEATURE_NAN),y)
1456CDEFINES += -DWLAN_FEATURE_NAN
1457endif
1458
1459ifeq ($(CONFIG_QCA_IBSS_SUPPORT), 1)
1460CDEFINES += -DQCA_IBSS_SUPPORT
1461endif
1462
1463#Enable OL debug and wmi unified functions
1464ifeq ($(CONFIG_ATH_PERF_PWR_OFFLOAD), 1)
1465CDEFINES += -DATH_PERF_PWR_OFFLOAD
1466endif
1467
1468#Disable packet log
1469ifeq ($(CONFIG_REMOVE_PKT_LOG), 1)
1470CDEFINES += -DREMOVE_PKT_LOG
1471endif
1472
1473#Enable 11AC TX
1474ifeq ($(CONFIG_ATH_11AC_TXCOMPACT), 1)
1475CDEFINES += -DATH_11AC_TXCOMPACT
1476endif
1477
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001478#Enable OS specific IRQ abstraction
1479ifeq ($(CONFIG_ATH_SUPPORT_SHARED_IRQ), 1)
1480CDEFINES += -DATH_SUPPORT_SHARED_IRQ
1481endif
1482
1483#Enable message based HIF instead of RAW access in BMI
1484ifeq ($(CONFIG_HIF_MESSAGE_BASED), 1)
1485CDEFINES += -DHIF_MESSAGE_BASED
1486endif
1487
1488#Enable PCI specific APIS (dma, etc)
1489ifeq ($(CONFIG_HIF_PCI), 1)
1490CDEFINES += -DHIF_PCI
1491endif
1492
Houston Hoffman1edffd32016-01-27 16:30:34 -08001493ifeq ($(CONFIG_HIF_SNOC), 1)
1494CDEFINES += -DHIF_SNOC
1495endif
1496
Poddar, Siddarth29296fb2016-05-16 18:06:30 +05301497#Enable High Latency related Flags
1498ifeq ($(CONFIG_QCA_WIFI_SDIO), 1)
1499CDEFINES += -DCONFIG_HL_SUPPORT \
1500 -DCONFIG_AR6320_SUPPORT \
1501 -DSDIO_3_0 \
1502 -DHIF_SDIO \
1503 -DCONFIG_DISABLE_CDC_MAX_PERF_WAR=0 \
1504 -DCONFIG_ATH_PROCFS_DIAG_SUPPORT \
1505 -DFEATURE_HL_GROUP_CREDIT_FLOW_CONTROL \
1506 -DHIF_MBOX_SLEEP_WAR \
1507 -DDEBUG_HL_LOGGING \
1508 -DQCA_BAD_PEER_TX_FLOW_CL \
1509 -DCONFIG_TX_DESC_HI_PRIO_RESERVE \
1510 -DCONFIG_PER_VDEV_TX_DESC_POOL \
1511 -DCONFIG_SDIO \
1512 -DFEATURE_WLAN_FORCE_SAP_SCC
1513endif
1514
Agrawal Ashishb141b092016-09-02 19:59:26 +05301515ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
1516CDEFINES += -DWLAN_FEATURE_DSRC
1517endif
1518
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001519#Enable USB specific APIS
1520ifeq ($(CONFIG_HIF_USB), 1)
Mohit Khannada4f4432016-05-17 15:02:09 -07001521CDEFINES += -DHIF_USB \
Mohit Khannae7a43572016-10-10 17:34:21 -07001522 -DCONFIG_PLD_USB_CNSS \
1523 -DCONFIG_HL_SUPPORT
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001524endif
1525
1526#Enable FW logs through ini
1527CDEFINES += -DCONFIG_FW_LOGS_BASED_ON_INI
1528
1529#Enable pci read/write config functions
1530ifeq ($(CONFIG_ATH_PCI), 1)
1531CDEFINES += -DATH_PCI
1532endif
1533
1534#Enable power management suspend/resume functionality
1535ifeq ($(CONFIG_ATH_BUS_PM), 1)
1536CDEFINES += -DATH_BUS_PM
1537endif
1538
1539#Enable FLOWMAC module support
1540ifeq ($(CONFIG_ATH_SUPPORT_FLOWMAC_MODULE), 1)
1541CDEFINES += -DATH_SUPPORT_FLOWMAC_MODULE
1542endif
1543
1544#Enable spectral support
1545ifeq ($(CONFIG_ATH_SUPPORT_SPECTRAL), 1)
1546CDEFINES += -DATH_SUPPORT_SPECTRAL
1547endif
1548
1549#Enable WDI Event support
1550ifeq ($(CONFIG_WDI_EVENT_ENABLE), 1)
1551CDEFINES += -DWDI_EVENT_ENABLE
1552endif
1553
1554#Endianess selection
1555ifeq ($(CONFIG_LITTLE_ENDIAN), 1)
1556AH_LITTLE_ENDIAN=1234
1557CDEFINES += -DAH_BYTE_ORDER=$(AH_LITTLE_ENDIAN)
1558else
1559AH_BIG_ENDIAN=4321
1560CDEFINES += -DAH_BYTE_ORDER=$(AH_BIG_ENDIAN)
1561CDEFINES += -DBIG_ENDIAN_HOST
1562endif
1563
1564#Enable TX reclaim support
1565ifeq ($(CONFIG_TX_CREDIT_RECLAIM_SUPPORT), 1)
1566CDEFINES += -DTX_CREDIT_RECLAIM_SUPPORT
1567endif
1568
1569#Enable FTM support
1570ifeq ($(CONFIG_QCA_WIFI_FTM), 1)
1571CDEFINES += -DQCA_WIFI_FTM
1572endif
1573
1574#Enable Checksum Offload support
1575ifeq ($(CONFIG_CHECKSUM_OFFLOAD), 1)
1576CDEFINES += -DCHECKSUM_OFFLOAD
1577endif
1578
1579#Enable Checksum Offload support
1580ifeq ($(CONFIG_IPA_OFFLOAD), 1)
1581CDEFINES += -DIPA_OFFLOAD
1582endif
1583
1584ifneq ($(CONFIG_ARCH_MDM9630), y)
1585ifeq ($(CONFIG_ARCH_MDM9640), y)
1586CDEFINES += -DQCA_CONFIG_SMP
1587endif
1588endif
1589
1590#Enable GTK Offload
1591ifeq ($(CONFIG_GTK_OFFLOAD), 1)
1592CDEFINES += -DWLAN_FEATURE_GTK_OFFLOAD
1593CDEFINES += -DIGTK_OFFLOAD
1594endif
1595
1596#Enable GTK Offload
1597ifeq ($(CONFIG_EXT_WOW), 1)
1598CDEFINES += -DWLAN_FEATURE_EXTWOW_SUPPORT
1599endif
1600
1601#Mark it as SMP Kernel
1602ifeq ($(CONFIG_SMP),y)
1603CDEFINES += -DQCA_CONFIG_SMP
1604endif
1605
Sandeep Puligilla2111d3c2016-02-03 01:46:15 -08001606#Enable Channel Matrix restriction for all Rome only targets
1607ifneq (y,$(filter y,$(CONFIG_CNSS_EOS) $(CONFIG_ICNSS)))
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001608CDEFINES += -DWLAN_ENABLE_CHNL_MATRIX_RESTRICTION
Sandeep Puligilla2111d3c2016-02-03 01:46:15 -08001609endif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001610
Sandeep Puligilla0e64b612016-08-26 13:20:58 -07001611#Enable OBSS feature
1612CDEFINES += -DQCA_HT_2040_COEX
1613
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001614#features specific to mobile router use case
1615ifeq ($(CONFIG_MOBILE_ROUTER), y)
1616
1617#enable MCC TO SCC switch
1618CDEFINES += -DFEATURE_WLAN_MCC_TO_SCC_SWITCH
1619
1620#enable wlan auto shutdown feature
1621CDEFINES += -DFEATURE_WLAN_AUTO_SHUTDOWN
1622
1623#enable for MBSSID
1624CDEFINES += -DWLAN_FEATURE_MBSSID
1625
1626#enable AP-AP ACS Optimization
1627CDEFINES += -DFEATURE_WLAN_AP_AP_ACS_OPTIMIZE
1628
1629#Enable 4address scheme
1630CDEFINES += -DFEATURE_WLAN_STA_4ADDR_SCHEME
1631
1632#Disable STA-AP Mode DFS support
1633CDEFINES += -DFEATURE_WLAN_STA_AP_MODE_DFS_DISABLE
1634
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001635else #CONFIG_MOBILE_ROUTER
1636
1637#Open P2P device interface only for non-Mobile router use cases
1638CDEFINES += -DWLAN_OPEN_P2P_INTERFACE
1639
1640#Enable 2.4 GHz social channels in 5 GHz only mode for p2p usage
1641CDEFINES += -DWLAN_ENABLE_SOCIAL_CHANNELS_5G_ONLY
1642
1643endif #CONFIG_MOBILE_ROUTER
1644
1645#Green AP feature
1646ifeq ($(CONFIG_QCACLD_FEATURE_GREEN_AP),y)
1647CDEFINES += -DFEATURE_GREEN_AP
1648endif
1649
1650#Enable RX Full re-order OL feature only "LL and NON-MDM9630 platform"
1651ifneq ($(CONFIG_ARCH_MDM9630), y)
1652ifeq ($(CONFIG_HIF_PCI), 1)
1653CDEFINES += -DWLAN_FEATURE_RX_FULL_REORDER_OL
1654endif
1655endif
1656
1657#Enable Signed firmware support for split binary format
1658ifeq ($(CONFIG_QCA_SIGNED_SPLIT_BINARY_SUPPORT), 1)
1659CDEFINES += -DQCA_SIGNED_SPLIT_BINARY_SUPPORT
1660endif
1661
1662#Enable single firmware binary format
1663ifeq ($(CONFIG_QCA_SINGLE_BINARY_SUPPORT), 1)
1664CDEFINES += -DQCA_SINGLE_BINARY_SUPPORT
1665endif
1666
1667#Enable collecting target RAM dump after kernel panic
1668ifeq ($(CONFIG_TARGET_RAMDUMP_AFTER_KERNEL_PANIC), 1)
1669CDEFINES += -DTARGET_RAMDUMP_AFTER_KERNEL_PANIC
1670endif
1671
1672#Enable/disable secure firmware feature
1673ifeq ($(CONFIG_FEATURE_SECURE_FIRMWARE), 1)
1674CDEFINES += -DFEATURE_SECURE_FIRMWARE
1675endif
1676
1677ifeq ($(CONFIG_ATH_PCIE_ACCESS_DEBUG), 1)
1678CDEFINES += -DCONFIG_ATH_PCIE_ACCESS_DEBUG
1679endif
1680
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001681# Enable feature support fo Linux version QCMBR
1682ifeq ($(CONFIG_LINUX_QCMBR),y)
1683CDEFINES += -DLINUX_QCMBR
1684endif
1685
Manikandan Mohandcc21ba2016-03-15 14:31:56 -07001686# Enable featue sync tsf between multi devices
1687ifeq ($(CONFIG_WLAN_SYNC_TSF), y)
1688CDEFINES += -DWLAN_FEATURE_TSF
1689endif
Rajeev Kumare0fd9dd2015-11-16 13:33:07 -08001690
1691# Enable full rx re-order offload for adrastea
1692ifeq (y, $(filter y, $(CONFIG_CNSS_ADRASTEA) $(CONFIG_ICNSS)))
1693CDEFINES += -DWLAN_FEATURE_RX_FULL_REORDER_OL
1694endif
1695
Rajeev Kumar321a19a2015-12-08 12:54:46 -08001696# Enable athdiag procfs debug support for adrastea
1697ifeq (y, $(filter y, $(CONFIG_CNSS_ADRASTEA) $(CONFIG_ICNSS)))
1698CDEFINES += -DCONFIG_ATH_PROCFS_DIAG_SUPPORT
1699endif
1700
Rajeev Kumar9c4809e2016-01-13 18:32:40 -08001701# Enable 11AC TX compact feature for adrastea
1702ifeq (y, $(filter y, $(CONFIG_CNSS_ADRASTEA) $(CONFIG_ICNSS)))
1703CDEFINES += -DATH_11AC_TXCOMPACT
1704endif
1705
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001706# NOTE: CONFIG_64BIT_PADDR requires CONFIG_HELIUMPLUS
1707ifeq (y,$(filter y,$(CONFIG_CNSS_EOS) $(CONFIG_ICNSS)))
1708CONFIG_HELIUMPLUS := y
1709CONFIG_64BIT_PADDR := y
1710CONFIG_FEATURE_TSO := y
1711CONFIG_FEATURE_TSO_DEBUG := y
1712ifeq ($(CONFIG_HELIUMPLUS),y)
1713CDEFINES += -DHELIUMPLUS_PADDR64
1714CDEFINES += -DHELIUMPLUS
Dhanashri Atre48c2ae62015-12-15 18:07:10 -08001715CDEFINES += -DAR900B
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001716ifeq ($(CONFIG_64BIT_PADDR),y)
1717CDEFINES += -DHTT_PADDR64
1718endif
1719endif
1720endif
1721
1722ifeq ($(CONFIG_FEATURE_TSO),y)
1723CDEFINES += -DFEATURE_TSO
1724endif
1725ifeq ($(CONFIG_FEATURE_TSO_DEBUG),y)
1726CDEFINES += -DFEATURE_TSO_DEBUG
1727endif
1728
1729ifeq ($(CONFIG_WLAN_LRO), y)
1730CDEFINES += -DFEATURE_LRO
1731endif
1732
1733ifeq ($(CONFIG_MOBILE_ROUTER), y)
1734CDEFINES += -DFEATURE_AP_MCC_CH_AVOIDANCE
1735endif
1736
1737ifeq ($(CONFIG_MPC_UT_FRAMEWORK), y)
1738CDEFINES += -DMPC_UT_FRAMEWORK
1739endif
1740
1741ifeq ($(CONFIG_WLAN_OFFLOAD_PACKETS),y)
1742CDEFINES += -DWLAN_FEATURE_OFFLOAD_PACKETS
1743endif
1744
1745ifeq ($(CONFIG_WLAN_FEATURE_MEMDUMP),y)
1746CDEFINES += -DWLAN_FEATURE_MEMDUMP
1747endif
1748
Padma, Santhosh Kumard7cc0792016-06-28 18:54:12 +05301749ifeq ($(CONFIG_WLAN_FEATURE_DISA),y)
1750CDEFINES += -DWLAN_FEATURE_DISA
1751endif
1752
Ravi Joshi61c3c7a2015-11-09 18:41:20 -08001753ifeq ($(CONFIG_LFR_SUBNET_DETECTION), y)
1754CDEFINES += -DFEATURE_LFR_SUBNET_DETECTION
1755endif
1756
Chandrasekaran Manishekar068e25e2016-03-07 11:51:07 +05301757ifeq ($(CONFIG_MCC_TO_SCC_SWITCH), y)
1758CDEFINES += -DFEATURE_WLAN_MCC_TO_SCC_SWITCH
1759endif
1760
Ravi Joshia063dd92016-05-25 16:43:13 -07001761ifeq ($(CONFIG_WLAN_FEATURE_NAN_DATAPATH), y)
1762CDEFINES += -DWLAN_FEATURE_NAN_DATAPATH
1763endif
1764
Leo Chang5f7a1e02016-11-04 14:04:26 -07001765ifeq ($(CONFIG_LITHIUM),y)
Houston Hoffman06fd5662017-02-08 21:41:20 -08001766CDEFINES += -DCONFIG_SHADOW_V2
Aravind Narasimhan4ed314d2016-11-14 16:56:42 -08001767CDEFINES += -DQCA6290_HEADERS_DEF
Venkata Sharath Chandra Manchala5d714d82017-01-18 14:56:32 -08001768CDEFINES += -DQCA_WIFI_QCA6290
Leo Chang5f7a1e02016-11-04 14:04:26 -07001769CDEFINES += -DQCA_WIFI_QCA8074
Leo Chang395cbb52016-11-11 14:35:03 -08001770CDEFINES += -DQCA_WIFI_NAPIER_EMULATION
Leo Chang5f7a1e02016-11-04 14:04:26 -07001771CDEFINES += -DQCA_WIFI_QCA8074_VP
Ravi Joshifc2ed782016-11-22 17:36:50 -08001772CDEFINES += -DDP_INTR_POLL_BASED
Ankit Gupta120b9b02016-12-06 16:27:51 -08001773CDEFINES += -DTX_PER_VDEV_DESC_POOL
Leo Chang5f7a1e02016-11-04 14:04:26 -07001774endif
1775
1776# Dummy flag for WIN/MCL converged data path compilation
1777CDEFINES += -DDP_PRINT_ENABLE=0
1778CDEFINES += -DATH_SUPPORT_WRAP=0
Dhanashri Atre33e147e2017-01-20 14:52:18 -08001779CDEFINES += -DQCA_HOST2FW_RXBUF_RING
Leo Chang5f7a1e02016-11-04 14:04:26 -07001780#endof dummy flags
1781
Mahesh Kumar Kalikot Veetilc0233a72016-10-27 15:06:05 -07001782ifeq ($(CONFIG_WLAN_DEBUGFS), y)
1783CDEFINES += -DWLAN_DEBUGFS
1784endif
1785
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001786KBUILD_CPPFLAGS += $(CDEFINES)
1787
1788# Currently, for versions of gcc which support it, the kernel Makefile
1789# is disabling the maybe-uninitialized warning. Re-enable it for the
1790# WLAN driver. Note that we must use EXTRA_CFLAGS here so that it
1791# will override the kernel settings.
1792ifeq ($(call cc-option-yn, -Wmaybe-uninitialized),y)
1793EXTRA_CFLAGS += -Wmaybe-uninitialized
Houston Hoffmand4ba4312017-01-13 18:30:15 -08001794
Leo Chang5f7a1e02016-11-04 14:04:26 -07001795ifneq (y,$(CONFIG_ARCH_MSM))
1796EXTRA_CFLAGS += -Wframe-larger-than=4096
1797endif
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001798endif
Jeff Johnson522db002016-10-05 16:30:41 -07001799EXTRA_CFLAGS += -Wmissing-prototypes
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001800
Srinivas Girigowda0a85ccd2016-12-01 14:58:08 -08001801ifeq ($(call cc-option-yn, -Wheader-guard),y)
1802EXTRA_CFLAGS += -Wheader-guard
1803endif
Samuel Ahnc9c48ca2016-09-19 15:46:36 +05301804# If the module name is not "wlan", then the define MULTI_IF_NAME to be the
1805# same a the module name. The host driver will then append MULTI_IF_NAME to
1806# any string that must be unique for all instances of the driver on the system.
1807# This allows multiple instances of the driver with different module names.
1808# If the module name is wlan, leave MULTI_IF_NAME undefined and the code will
1809# treat the driver as the primary driver.
1810ifneq ($(MODNAME), wlan)
1811CDEFINES += -DMULTI_IF_NAME=\"$(MODNAME)\"
1812endif
1813
1814# WLAN_HDD_ADAPTER_MAGIC must be unique for all instances of the driver on the
1815# system. If it is not defined, then the host driver will use the first 4
1816# characters (including NULL) of MULTI_IF_NAME to construct
1817# WLAN_HDD_ADAPTER_MAGIC.
1818ifdef WLAN_HDD_ADAPTER_MAGIC
1819CDEFINES += -DWLAN_HDD_ADAPTER_MAGIC=$(WLAN_HDD_ADAPTER_MAGIC)
1820endif
Srinivas Girigowda0a85ccd2016-12-01 14:58:08 -08001821
Prakash Dhavali7090c5f2015-11-02 17:55:19 -08001822# Module information used by KBuild framework
1823obj-$(CONFIG_QCA_CLD_WLAN) += $(MODNAME).o
1824$(MODNAME)-y := $(OBJS)