xref: /wlan-driver/qcacld-3.0/Kbuild (revision 5113495b16420b49004c444715d2daae2066e7dc)
1# 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 := y
5else
6	KERNEL_BUILD := n
7endif
8
9ifeq ($(KERNEL_BUILD), y)
10	# These are provided in external module based builds
11	# Need to explicitly define for Kernel-based builds
12	MODNAME := wlan
13	WLAN_ROOT := drivers/staging/qcacld-3.0
14	WLAN_COMMON_ROOT := cmn
15	WLAN_COMMON_INC := $(WLAN_ROOT)/$(WLAN_COMMON_ROOT)
16	WLAN_FW_API := $(WLAN_ROOT)/../fw-api/
17	WLAN_PROFILE := default
18endif
19
20WLAN_COMMON_ROOT ?= cmn
21WLAN_COMMON_INC ?= $(WLAN_ROOT)/$(WLAN_COMMON_ROOT)
22WLAN_FW_API ?= $(WLAN_ROOT)/../fw-api/
23WLAN_PROFILE ?= default
24CONFIG_QCA_CLD_WLAN_PROFILE ?= $(WLAN_PROFILE)
25DEVNAME ?= wlan
26WLAN_PLATFORM_INC ?= $(WLAN_ROOT)/../platform/inc
27DATA_IPA_INC ?= $(WLAN_ROOT)/../dataipa/drivers/platform/msm/include
28DATA_IPA_UAPI_INC ?= $(DATA_IPA_INC)/uapi
29
30ifeq ($(KERNEL_BUILD), n)
31ifneq ($(ANDROID_BUILD_TOP),)
32      ANDROID_BUILD_TOP_REL := $(shell python -c "import os.path; print(os.path.relpath('$(ANDROID_BUILD_TOP)'))")
33      override WLAN_ROOT := $(ANDROID_BUILD_TOP_REL)/$(WLAN_ROOT)
34      override WLAN_COMMON_INC := $(ANDROID_BUILD_TOP_REL)/$(WLAN_COMMON_INC)
35      override WLAN_FW_API := $(ANDROID_BUILD_TOP_REL)/$(WLAN_FW_API)
36else ifneq ($(LINUX_BUILD_TOP),)
37      LINUX_BUILD_TOP_REL := $(shell python -c "import os.path; print(os.path.relpath('$(LINUX_BUILD_TOP)'))")
38      $(warning "LINUX_BUILD_TOP_REL=: $(LINUX_BUILD_TOP_REL)")
39      override WLAN_ROOT := $(LINUX_BUILD_TOP_REL)/qcacld-3.0
40      override WLAN_COMMON_ROOT ?= cmn
41      override WLAN_COMMON_INC ?= $(WLAN_ROOT)/$(WLAN_COMMON_ROOT)
42      override WLAN_FW_API := $(WLAN_ROOT)/../fw-api
43endif
44endif
45
46include $(WLAN_ROOT)/configs/$(CONFIG_QCA_CLD_WLAN_PROFILE)_defconfig
47
48# add configurations in WLAN_CFG_OVERRIDE
49$(foreach cfg, $(WLAN_CFG_OVERRIDE), \
50	$(eval $(cfg)) \
51	$(warning "Overriding WLAN config with: $(cfg)"))
52
53# KERNEL_SUPPORTS_NESTED_COMPOSITES := y is used to enable nested
54# composite support. The nested composite support is available in some
55# MSM kernels, and is available in 5.10 GKI kernels beginning with
56# 5.10.20, but unfortunately is not available in any upstream kernel.
57#
58# When the feature is present in an MSM kernel, the flag is explicitly
59# set in the kernel sources.  When a GKI kernel is used, there isn't a
60# flag set in the sources, so set the flag here if we are building
61# with GKI kernel where the feature is present
62KERNEL_VERSION = $(shell echo $$(( ( $1 << 16 ) + ( $2 << 8 ) + $3 )))
63LINUX_CODE := $(call KERNEL_VERSION,$(VERSION),$(PATCHLEVEL),$(SUBLEVEL))
64
65# Comosite feature was added to GKI 5.10.20
66COMPOSITE_CODE_ADDED := 330260 # hardcoded $(call KERNEL_VERSION,5,10,20)
67
68# Comosite feature was not ported beyond 5.10.x
69COMPOSITE_CODE_REMOVED := 330496 # hardcoded $(call KERNEL_VERSION,5,11,0)
70
71ifeq ($(KERNEL_SUPPORTS_NESTED_COMPOSITES),)
72  #flag is not explicitly present
73  ifneq ($(findstring gki,$(CONFIG_LOCALVERSION))$(findstring qki,$(CONFIG_LOCALVERSION)),)
74    # GKI kernel
75    ifeq ($(shell test $(LINUX_CODE) -ge $(COMPOSITE_CODE_ADDED); echo $$?),0)
76      # version >= 5.10.20
77      ifeq ($(shell test $(LINUX_CODE) -lt $(COMPOSITE_CODE_REMOVED); echo $$?),0)
78        # version < 5.11.0
79        KERNEL_SUPPORTS_NESTED_COMPOSITES := y
80      endif
81    endif
82  endif
83endif
84
85OBJS :=
86OBJS_DIRS :=
87
88define add-wlan-objs
89$(eval $(_add-wlan-objs))
90endef
91
92define _add-wlan-objs
93  ifneq ($(2),)
94    ifeq ($(KERNEL_SUPPORTS_NESTED_COMPOSITES),y)
95      OBJS_DIRS += $(dir $(2))
96      OBJS += $(1).o
97      $(1)-y := $(2)
98    else
99      OBJS += $(2)
100    endif
101  endif
102endef
103
104############ UAPI ############
105UAPI_DIR :=	uapi
106UAPI_INC :=	-I$(WLAN_ROOT)/$(UAPI_DIR)/linux
107
108############ COMMON ############
109COMMON_DIR :=	core/common
110COMMON_INC :=	-I$(WLAN_ROOT)/$(COMMON_DIR)
111
112############ HDD ############
113HDD_DIR :=	core/hdd
114HDD_INC_DIR :=	$(HDD_DIR)/inc
115HDD_SRC_DIR :=	$(HDD_DIR)/src
116
117HDD_INC := 	-I$(WLAN_ROOT)/$(HDD_INC_DIR) \
118		-I$(WLAN_ROOT)/$(HDD_SRC_DIR)
119
120HDD_OBJS := 	$(HDD_SRC_DIR)/wlan_hdd_assoc.o \
121		$(HDD_SRC_DIR)/wlan_hdd_cfg.o \
122		$(HDD_SRC_DIR)/wlan_hdd_cfg80211.o \
123		$(HDD_SRC_DIR)/wlan_hdd_data_stall_detection.o \
124		$(HDD_SRC_DIR)/wlan_hdd_driver_ops.o \
125		$(HDD_SRC_DIR)/wlan_hdd_ftm.o \
126		$(HDD_SRC_DIR)/wlan_hdd_hostapd.o \
127		$(HDD_SRC_DIR)/wlan_hdd_ioctl.o \
128		$(HDD_SRC_DIR)/wlan_hdd_main.o \
129		$(HDD_SRC_DIR)/wlan_hdd_object_manager.o \
130		$(HDD_SRC_DIR)/wlan_hdd_oemdata.o \
131		$(HDD_SRC_DIR)/wlan_hdd_p2p.o \
132		$(HDD_SRC_DIR)/wlan_hdd_power.o \
133		$(HDD_SRC_DIR)/wlan_hdd_regulatory.o \
134		$(HDD_SRC_DIR)/wlan_hdd_scan.o \
135		$(HDD_SRC_DIR)/wlan_hdd_softap_tx_rx.o \
136		$(HDD_SRC_DIR)/wlan_hdd_sta_info.o \
137		$(HDD_SRC_DIR)/wlan_hdd_stats.o \
138		$(HDD_SRC_DIR)/wlan_hdd_trace.o \
139		$(HDD_SRC_DIR)/wlan_hdd_tx_rx.o \
140		$(HDD_SRC_DIR)/wlan_hdd_wmm.o \
141		$(HDD_SRC_DIR)/wlan_hdd_wowl.o\
142		$(HDD_SRC_DIR)/wlan_hdd_ll_lt_sap.o\
143
144ifeq ($(CONFIG_UNIT_TEST), y)
145HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_unit_test.o
146endif
147
148ifeq ($(CONFIG_WLAN_WEXT_SUPPORT_ENABLE), y)
149HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_wext.o \
150	    $(HDD_SRC_DIR)/wlan_hdd_hostapd_wext.o
151endif
152
153ifeq ($(CONFIG_AFC_SUPPORT), y)
154HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_afc.o
155endif
156
157ifeq ($(CONFIG_DCS), y)
158HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_dcs.o
159endif
160
161ifeq ($(CONFIG_FEATURE_WLAN_EXTSCAN), y)
162HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_ext_scan.o
163endif
164
165ifeq ($(CONFIG_WLAN_DEBUGFS), y)
166HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_debugfs.o
167ifeq ($(CONFIG_WLAN_FEATURE_LINK_LAYER_STATS), y)
168HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_debugfs_llstat.o
169endif
170ifeq ($(CONFIG_WLAN_FEATURE_MIB_STATS), y)
171HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_debugfs_mibstat.o
172endif
173HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_debugfs_csr.o
174HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_debugfs_offload.o
175HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_debugfs_roam.o
176HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_debugfs_config.o
177HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_debugfs_unit_test.o
178ifeq ($(CONFIG_WLAN_MWS_INFO_DEBUGFS), y)
179HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_debugfs_coex.o
180endif
181endif
182
183ifeq ($(CONFIG_WLAN_CONV_SPECTRAL_ENABLE),y)
184HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_spectralscan.o
185endif
186
187ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
188HDD_OBJS+=	$(HDD_SRC_DIR)/wlan_hdd_ocb.o
189endif
190
191ifeq ($(CONFIG_FEATURE_MEMDUMP_ENABLE), y)
192HDD_OBJS+=	$(HDD_SRC_DIR)/wlan_hdd_memdump.o
193endif
194
195ifeq ($(CONFIG_WLAN_FEATURE_FIPS), y)
196HDD_OBJS+=	$(HDD_SRC_DIR)/wlan_hdd_fips.o
197endif
198
199ifeq ($(CONFIG_QCACLD_FEATURE_GREEN_AP), y)
200HDD_OBJS+=	$(HDD_SRC_DIR)/wlan_hdd_green_ap.o
201endif
202
203ifeq ($(CONFIG_QCACLD_FEATURE_APF), y)
204HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_apf.o
205endif
206
207ifeq ($(CONFIG_WLAN_FEATURE_LPSS), y)
208HDD_OBJS +=	$(HDD_SRC_DIR)/wlan_hdd_lpass.o
209endif
210
211ifeq ($(CONFIG_WLAN_NAPI), y)
212HDD_OBJS +=     $(HDD_SRC_DIR)/wlan_hdd_napi.o
213endif
214
215ifeq ($(CONFIG_IPA_OFFLOAD), y)
216HDD_OBJS +=	$(HDD_SRC_DIR)/wlan_hdd_ipa.o
217endif
218
219ifeq ($(CONFIG_QCACLD_FEATURE_SON), y)
220HDD_OBJS +=	$(HDD_SRC_DIR)/wlan_hdd_son.o
221endif
222
223ifeq ($(CONFIG_QCACLD_FEATURE_NAN), y)
224HDD_OBJS +=	$(HDD_SRC_DIR)/wlan_hdd_nan.o
225HDD_OBJS +=	$(HDD_SRC_DIR)/wlan_hdd_nan_datapath.o
226endif
227
228ifeq ($(CONFIG_QCOM_TDLS), y)
229HDD_OBJS +=	$(HDD_SRC_DIR)/wlan_hdd_tdls.o
230endif
231
232ifeq ($(CONFIG_WLAN_SYNC_TSF_PLUS), y)
233CONFIG_WLAN_SYNC_TSF := y
234endif
235
236ifeq ($(CONFIG_WLAN_SYNC_TSF), y)
237HDD_OBJS +=	$(HDD_SRC_DIR)/wlan_hdd_tsf.o
238endif
239
240ifeq ($(CONFIG_WLAN_FEATURE_DISA), y)
241HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_disa.o
242endif
243
244ifeq ($(CONFIG_LFR_SUBNET_DETECTION), y)
245HDD_OBJS +=	$(HDD_SRC_DIR)/wlan_hdd_subnet_detect.o
246endif
247
248ifeq ($(CONFIG_WLAN_FEATURE_11AX), y)
249HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_he.o
250endif
251
252ifeq ($(CONFIG_WLAN_FEATURE_11BE), y)
253HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_eht.o
254endif
255
256ifeq ($(CONFIG_WLAN_FEATURE_TWT), y)
257HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_twt.o
258endif
259
260ifeq ($(CONFIG_FEATURE_MONITOR_MODE_SUPPORT), y)
261HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_rx_monitor.o
262endif
263
264ifeq ($(CONFIG_WLAN_NUD_TRACKING), y)
265HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_nud_tracking.o
266endif
267
268ifeq ($(CONFIG_WLAN_FEATURE_PACKET_FILTERING), y)
269HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_packet_filter.o
270endif
271
272ifeq ($(CONFIG_FEATURE_RSSI_MONITOR), y)
273HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_rssi_monitor.o
274endif
275
276ifeq ($(CONFIG_FEATURE_BSS_TRANSITION), y)
277HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_bss_transition.o
278endif
279
280ifeq ($(CONFIG_FEATURE_STATION_INFO), y)
281HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_station_info.o
282endif
283
284ifeq ($(CONFIG_FEATURE_TX_POWER), y)
285HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_tx_power.o
286endif
287
288ifeq ($(CONFIG_FEATURE_OTA_TEST), y)
289HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_ota_test.o
290endif
291
292ifeq ($(CONFIG_FEATURE_ACTIVE_TOS), y)
293HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_active_tos.o
294endif
295
296ifeq ($(CONFIG_FEATURE_SAR_LIMITS), y)
297HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sar_limits.o
298endif
299
300ifeq ($(CONFIG_FEATURE_CONCURRENCY_MATRIX), y)
301HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_concurrency_matrix.o
302endif
303
304ifeq ($(CONFIG_FEATURE_SAP_COND_CHAN_SWITCH), y)
305HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sap_cond_chan_switch.o
306endif
307
308ifeq ($(CONFIG_FEATURE_P2P_LISTEN_OFFLOAD), y)
309HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_p2p_listen_offload.o
310endif
311
312ifeq ($(CONFIG_WLAN_SYSFS), y)
313HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs.o
314ifeq ($(CONFIG_WLAN_SYSFS_CHANNEL), y)
315HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_channel.o
316endif
317ifeq ($(CONFIG_WLAN_SYSFS_FW_MODE_CFG), y)
318HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_fw_mode_config.o
319endif
320ifeq ($(CONFIG_WLAN_REASSOC), y)
321HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_reassoc.o
322endif
323ifeq ($(CONFIG_WLAN_SYSFS_STA_INFO), y)
324HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_sta_info.o
325endif
326ifeq ($(CONFIG_WLAN_DEBUG_CRASH_INJECT), y)
327HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_crash_inject.o
328endif
329ifeq ($(CONFIG_FEATURE_UNIT_TEST_SUSPEND), y)
330HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_suspend_resume.o
331endif
332ifeq ($(CONFIG_WLAN_SYSFS_MEM_STATS), y)
333HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_mem_stats.o
334endif
335HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_unit_test.o
336HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_modify_acl.o
337ifeq ($(CONFIG_WLAN_SYSFS_CONNECT_INFO), y)
338HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_connect_info.o
339endif
340ifeq ($(CONFIG_WLAN_SCAN_DISABLE), y)
341HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_scan_disable.o
342endif
343ifeq ($(CONFIG_WLAN_SYSFS_DCM), y)
344HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_dcm.o
345endif
346ifeq ($(CONFIG_WLAN_WOW_ITO), y)
347HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_wow_ito.o
348endif
349ifeq ($(CONFIG_WLAN_WOWL_ADD_PTRN), y)
350HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_wowl_add_ptrn.o
351endif
352ifeq ($(CONFIG_WLAN_WOWL_DEL_PTRN), y)
353HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_wowl_del_ptrn.o
354endif
355ifeq ($(CONFIG_WLAN_SYSFS_TX_STBC), y)
356HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_tx_stbc.o
357endif
358ifeq ($(CONFIG_WLAN_SYSFS_SCAN_CFG), y)
359HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_scan_config.o
360endif
361ifeq ($(CONFIG_WLAN_SYSFS_MONITOR_MODE_CHANNEL), y)
362HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_monitor_mode_channel.o
363endif
364ifeq ($(CONFIG_WLAN_SYSFS_RANGE_EXT), y)
365HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_range_ext.o
366endif
367ifeq ($(CONFIG_WLAN_SYSFS_RADAR), y)
368HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_radar.o
369endif
370ifeq ($(CONFIG_WLAN_SYSFS_RTS_CTS), y)
371HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_rts_cts.o
372endif
373ifeq ($(CONFIG_WLAN_SYSFS_HE_BSS_COLOR), y)
374HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_he_bss_color.o
375endif
376ifeq ($(CONFIG_WLAN_TXRX_FW_STATS), y)
377HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_txrx_fw_stats.o
378endif
379ifeq ($(CONFIG_WLAN_TXRX_STATS), y)
380HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_txrx_stats.o
381endif
382ifeq ($(CONFIG_WLAN_SYSFS_DP_TRACE), y)
383HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_dp_trace.o
384endif
385ifeq ($(CONFIG_WLAN_SYSFS_STATS), y)
386HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_stats.o
387endif
388ifeq ($(CONFIG_WLAN_SYSFS_TDLS_PEERS), y)
389HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_tdls_peers.o
390endif
391ifeq ($(CONFIG_WLAN_SYSFS_TEMPERATURE), y)
392HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_temperature.o
393endif
394ifeq ($(CONFIG_WLAN_THERMAL_CFG), y)
395HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_thermal_cfg.o
396endif
397ifeq ($(CONFIG_FEATURE_MOTION_DETECTION), y)
398HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_motion_detection.o
399endif
400ifeq ($(CONFIG_WLAN_SYSFS_WLAN_DBG), y)
401HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_wlan_dbg.o
402endif
403ifeq ($(CONFIG_WLAN_TXRX_FW_ST_RST), y)
404HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_txrx_fw_st_rst.o
405endif
406ifeq ($(CONFIG_WLAN_GTX_BW_MASK), y)
407HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_gtx_bw_mask.o
408endif
409ifeq ($(CONFIG_IPA_OFFLOAD), y)
410HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_ipa.o
411endif
412ifeq ($(CONFIG_REMOVE_PKT_LOG), n)
413HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_pktlog.o
414endif
415ifeq ($(CONFIG_WLAN_DL_MODES), y)
416HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_dl_modes.o
417endif
418HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_policy_mgr.o
419HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_dp_aggregation.o
420ifeq ($(CONFIG_DP_SWLM), y)
421HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_swlm.o
422endif
423ifeq ($(CONFIG_WLAN_DUMP_IN_PROGRESS), y)
424HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_dump_in_progress.o
425endif
426ifeq ($(CONFIG_FEATURE_SET), y)
427HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_wifi_features.o
428endif
429ifeq ($(CONFIG_WLAN_BMISS), y)
430HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_bmiss.o
431endif
432ifeq ($(CONFIG_WLAN_FREQ_LIST), y)
433HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_get_freq_for_pwr.o
434endif
435ifeq ($(CONFIG_WLAN_SYSFS_DP_STATS), y)
436HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_txrx_stats_console.o
437endif
438
439ifeq ($(CONFIG_DP_PKT_ADD_TIMESTAMP), y)
440HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_add_timestamp.o
441endif
442
443ifeq ($(CONFIG_DP_TRAFFIC_END_INDICATION), y)
444HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_dp_traffic_end_indication.o
445endif
446
447ifeq ($(CONFIG_DP_HW_TX_DELAY_STATS_ENABLE), y)
448HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_dp_tx_delay_stats.o
449endif
450
451ifeq ($(CONFIG_WLAN_SYSFS_EHT_RATE), y)
452HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_eht_rate.o
453endif
454
455ifeq ($(CONFIG_FEATURE_DIRECT_LINK), y)
456HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_direct_link_ut_cmd.o
457endif
458
459ifeq ($(CONFIG_BUS_AUTO_SUSPEND), y)
460HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_runtime_pm.o
461endif
462
463ifeq ($(CONFIG_WLAN_SYSFS_LOG_BUFFER), y)
464HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_log_buffer.o
465endif
466
467ifeq ($(CONFIG_WLAN_SYSFS_DFSNOL), y)
468HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_dfsnol.o
469endif
470
471ifeq ($(CONFIG_WLAN_SYSFS_WDS_MODE), y)
472HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_wds_mode.o
473endif
474
475ifeq ($(CONFIG_WLAN_SYSFS_ROAM_TRIGGER_BITMAP), y)
476HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_roam_trigger_bitmap.o
477endif
478
479ifeq ($(CONFIG_WLAN_SYSFS_RF_TEST_MODE), y)
480HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_sysfs_rf_test_mode.o
481endif
482
483endif # CONFIG_WLAN_SYSFS
484
485ifeq ($(CONFIG_QCACLD_FEATURE_FW_STATE), y)
486HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_fw_state.o
487endif
488
489ifeq ($(CONFIG_QCACLD_FEATURE_COEX_CONFIG), y)
490HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_coex_config.o
491endif
492
493ifeq ($(CONFIG_QCACLD_FEATURE_MPTA_HELPER), y)
494HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_mpta_helper.o
495endif
496
497ifeq ($(CONFIG_WLAN_BCN_RECV_FEATURE), y)
498HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_bcn_recv.o
499endif
500
501ifeq ($(CONFIG_QCACLD_FEATURE_HW_CAPABILITY), y)
502HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_hw_capability.o
503endif
504
505ifeq ($(CONFIG_FW_THERMAL_THROTTLE), y)
506HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_thermal.o
507endif
508
509ifeq ($(CONFIG_QCACLD_FEATURE_BTC_CHAIN_MODE), y)
510HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_btc_chain_mode.o
511endif
512
513ifeq ($(CONFIG_FEATURE_WLAN_TIME_SYNC_FTM), y)
514HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_ftm_time_sync.o
515endif
516
517ifeq ($(CONFIG_WLAN_HANG_EVENT), y)
518HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_hang_event.o
519endif
520
521ifeq ($(CONFIG_WLAN_CFR_ENABLE), y)
522HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_cfr.o
523endif
524
525ifeq ($(CONFIG_FEATURE_GPIO_CFG),y)
526HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_gpio.o
527endif
528
529ifeq ($(CONFIG_WLAN_FEATURE_MEDIUM_ASSESS), y)
530HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_medium_assess.o
531endif
532
533ifeq ($(CONFIG_WLAN_ENABLE_GPIO_WAKEUP),y)
534HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_gpio_wakeup.o
535endif
536
537HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_cm_connect.o
538HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_cm_disconnect.o
539
540
541ifeq ($(CONFIG_WLAN_BOOTUP_MARKER), y)
542HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_bootup_marker.o
543endif
544
545ifeq ($(CONFIG_FEATURE_WLAN_CH_AVOID_EXT),y)
546HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_avoid_freq_ext.o
547endif
548
549ifeq ($(CONFIG_WLAN_FEATURE_11BE_MLO), y)
550HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_mlo.o
551endif
552
553
554ifeq ($(CONFIG_WLAN_FEATURE_MDNS_OFFLOAD),y)
555HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_mdns_offload.o
556endif
557
558ifeq ($(CONFIG_QCACLD_WLAN_CONNECTIVITY_DIAG_EVENT), y)
559HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_connectivity_logging.o
560else ifeq ($(CONFIG_QCACLD_WLAN_CONNECTIVITY_LOGGING), y)
561HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_connectivity_logging.o
562endif
563
564ifeq ($(CONFIG_WLAN_FEATURE_MCC_QUOTA), y)
565HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_mcc_quota.o
566endif
567
568ifeq ($(CONFIG_FEATURE_WDS), y)
569HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_wds.o
570endif
571
572ifeq ($(CONFIG_WLAN_FEATURE_PEER_TXQ_FLUSH_CONF), y)
573HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_peer_txq_flush.o
574endif
575
576ifeq ($(CONFIG_WIFI_POS_CONVERGED), y)
577ifeq ($(CONFIG_WIFI_POS_PASN), y)
578HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_wifi_pos_pasn.o
579endif
580endif
581
582$(call add-wlan-objs,hdd,$(HDD_OBJS))
583
584###### OSIF_SYNC ########
585SYNC_DIR := os_if/sync
586SYNC_INC_DIR := $(SYNC_DIR)/inc
587SYNC_SRC_DIR := $(SYNC_DIR)/src
588
589SYNC_INC := \
590	-I$(WLAN_ROOT)/$(SYNC_INC_DIR) \
591	-I$(WLAN_ROOT)/$(SYNC_SRC_DIR) \
592
593SYNC_OBJS := \
594	$(SYNC_SRC_DIR)/osif_sync.o \
595	$(SYNC_SRC_DIR)/osif_driver_sync.o \
596	$(SYNC_SRC_DIR)/osif_psoc_sync.o \
597	$(SYNC_SRC_DIR)/osif_vdev_sync.o \
598
599$(call add-wlan-objs,sync,$(SYNC_OBJS))
600
601########### Driver Synchronization Core (DSC) ###########
602DSC_DIR := components/dsc
603DSC_INC_DIR := $(DSC_DIR)/inc
604DSC_SRC_DIR := $(DSC_DIR)/src
605DSC_TEST_DIR := $(DSC_DIR)/test
606
607DSC_INC := \
608	-I$(WLAN_ROOT)/$(DSC_INC_DIR) \
609	-I$(WLAN_ROOT)/$(DSC_SRC_DIR) \
610	-I$(WLAN_ROOT)/$(DSC_TEST_DIR)
611
612DSC_OBJS := \
613	$(DSC_SRC_DIR)/__wlan_dsc.o \
614	$(DSC_SRC_DIR)/wlan_dsc_driver.o \
615	$(DSC_SRC_DIR)/wlan_dsc_psoc.o \
616	$(DSC_SRC_DIR)/wlan_dsc_vdev.o
617
618ifeq ($(CONFIG_DSC_TEST), y)
619	DSC_OBJS += $(DSC_TEST_DIR)/wlan_dsc_test.o
620endif
621
622$(call add-wlan-objs,dsc,$(DSC_OBJS))
623
624########### HOST DIAG LOG ###########
625HOST_DIAG_LOG_DIR :=	$(WLAN_COMMON_ROOT)/utils/host_diag_log
626
627HOST_DIAG_LOG_INC_DIR :=	$(HOST_DIAG_LOG_DIR)/inc
628HOST_DIAG_LOG_SRC_DIR :=	$(HOST_DIAG_LOG_DIR)/src
629
630HOST_DIAG_LOG_INC :=	-I$(WLAN_ROOT)/$(HOST_DIAG_LOG_INC_DIR) \
631			-I$(WLAN_ROOT)/$(HOST_DIAG_LOG_SRC_DIR)
632
633ifeq ($(CONFIG_WLAN_DIAG_VERSION), y)
634HOST_DIAG_LOG_OBJS +=	$(HOST_DIAG_LOG_SRC_DIR)/host_diag_log.o
635endif
636
637$(call add-wlan-objs,host_diag_log,$(HOST_DIAG_LOG_OBJS))
638
639############ EPPING ############
640EPPING_DIR :=	$(WLAN_COMMON_ROOT)/utils/epping
641EPPING_INC_DIR :=	$(EPPING_DIR)/inc
642EPPING_SRC_DIR :=	$(EPPING_DIR)/src
643
644EPPING_INC := 	-I$(WLAN_ROOT)/$(EPPING_INC_DIR)
645
646ifeq ($(CONFIG_FEATURE_EPPING), y)
647EPPING_OBJS := $(EPPING_SRC_DIR)/epping_main.o \
648		$(EPPING_SRC_DIR)/epping_txrx.o \
649		$(EPPING_SRC_DIR)/epping_tx.o \
650		$(EPPING_SRC_DIR)/epping_rx.o \
651		$(EPPING_SRC_DIR)/epping_helper.o
652endif
653
654$(call add-wlan-objs,epping,$(EPPING_OBJS))
655
656############ SYS ############
657CMN_SYS_DIR :=	$(WLAN_COMMON_ROOT)/utils/sys
658CMN_SYS_INC_DIR := 	$(CMN_SYS_DIR)
659CMN_SYS_INC :=	-I$(WLAN_ROOT)/$(CMN_SYS_INC_DIR)
660
661############ MAC ############
662MAC_DIR :=	core/mac
663MAC_INC_DIR :=	$(MAC_DIR)/inc
664MAC_SRC_DIR :=	$(MAC_DIR)/src
665
666MAC_INC := 	-I$(WLAN_ROOT)/$(MAC_INC_DIR) \
667		-I$(WLAN_ROOT)/$(MAC_SRC_DIR)/dph \
668		-I$(WLAN_ROOT)/$(MAC_SRC_DIR)/include \
669		-I$(WLAN_ROOT)/$(MAC_SRC_DIR)/pe/include \
670		-I$(WLAN_ROOT)/$(MAC_SRC_DIR)/pe/lim \
671		-I$(WLAN_ROOT)/$(MAC_SRC_DIR)/pe/nan
672
673MAC_DPH_OBJS :=	$(MAC_SRC_DIR)/dph/dph_hash_table.o
674
675ifeq ($(KERNEL_SUPPORTS_NESTED_COMPOSITES),y)
676MAC_LIM_OBJS := $(MAC_SRC_DIR)/pe/lim/lim_aid_mgmt.o \
677		$(MAC_SRC_DIR)/pe/lim/lim_admit_control.o \
678		$(MAC_SRC_DIR)/pe/lim/lim_api.o \
679		$(MAC_SRC_DIR)/pe/lim/lim_assoc_utils.o \
680		$(MAC_SRC_DIR)/pe/lim/lim_ft.o \
681		$(MAC_SRC_DIR)/pe/lim/lim_link_monitoring_algo.o \
682		$(MAC_SRC_DIR)/pe/lim/lim_process_action_frame.o \
683		$(MAC_SRC_DIR)/pe/lim/lim_process_assoc_req_frame.o \
684		$(MAC_SRC_DIR)/pe/lim/lim_process_assoc_rsp_frame.o \
685		$(MAC_SRC_DIR)/pe/lim/lim_process_auth_frame.o \
686		$(MAC_SRC_DIR)/pe/lim/lim_process_beacon_frame.o \
687		$(MAC_SRC_DIR)/pe/lim/lim_process_cfg_updates.o \
688		$(MAC_SRC_DIR)/pe/lim/lim_process_deauth_frame.o \
689		$(MAC_SRC_DIR)/pe/lim/lim_process_disassoc_frame.o \
690		$(MAC_SRC_DIR)/pe/lim/lim_process_message_queue.o \
691		$(MAC_SRC_DIR)/pe/lim/lim_process_mlm_req_messages.o \
692		$(MAC_SRC_DIR)/pe/lim/lim_process_mlm_rsp_messages.o \
693		$(MAC_SRC_DIR)/pe/lim/lim_process_probe_req_frame.o \
694		$(MAC_SRC_DIR)/pe/lim/lim_process_probe_rsp_frame.o \
695		$(MAC_SRC_DIR)/pe/lim/lim_process_sme_req_messages.o \
696		$(MAC_SRC_DIR)/pe/lim/lim_prop_exts_utils.o \
697		$(MAC_SRC_DIR)/pe/lim/lim_scan_result_utils.o \
698		$(MAC_SRC_DIR)/pe/lim/lim_security_utils.o \
699		$(MAC_SRC_DIR)/pe/lim/lim_send_management_frames.o \
700		$(MAC_SRC_DIR)/pe/lim/lim_send_messages.o \
701		$(MAC_SRC_DIR)/pe/lim/lim_send_sme_rsp_messages.o \
702		$(MAC_SRC_DIR)/pe/lim/lim_session.o \
703		$(MAC_SRC_DIR)/pe/lim/lim_session_utils.o \
704		$(MAC_SRC_DIR)/pe/lim/lim_sme_req_utils.o \
705		$(MAC_SRC_DIR)/pe/lim/lim_timer_utils.o \
706		$(MAC_SRC_DIR)/pe/lim/lim_trace.o \
707		$(MAC_SRC_DIR)/pe/lim/lim_utils.o
708else
709#composite of all of the above is in lim.c
710MAC_LIM_OBJS := $(MAC_SRC_DIR)/pe/lim/lim.o
711endif
712
713ifeq ($(CONFIG_QCOM_TDLS), y)
714MAC_LIM_OBJS += $(MAC_SRC_DIR)/pe/lim/lim_process_tdls.o
715endif
716
717ifeq ($(CONFIG_WLAN_FEATURE_FILS), y)
718MAC_LIM_OBJS += $(MAC_SRC_DIR)/pe/lim/lim_process_fils.o
719endif
720
721ifeq ($(CONFIG_QCACLD_FEATURE_NAN), y)
722MAC_NDP_OBJS += $(MAC_SRC_DIR)/pe/nan/nan_datapath.o
723endif
724
725ifeq ($(CONFIG_QCACLD_WLAN_LFR2), y)
726	MAC_LIM_OBJS += $(MAC_SRC_DIR)/pe/lim/lim_process_mlm_host_roam.o \
727		$(MAC_SRC_DIR)/pe/lim/lim_send_frames_host_roam.o \
728		$(MAC_SRC_DIR)/pe/lim/lim_roam_timer_utils.o \
729		$(MAC_SRC_DIR)/pe/lim/lim_ft_preauth.o \
730		$(MAC_SRC_DIR)/pe/lim/lim_reassoc_utils.o
731endif
732
733ifeq ($(CONFIG_WLAN_FEATURE_11BE_MLO), y)
734	MAC_LIM_OBJS += $(MAC_SRC_DIR)/pe/lim/lim_mlo.o
735endif
736
737MAC_SCH_OBJS := $(MAC_SRC_DIR)/pe/sch/sch_api.o \
738		$(MAC_SRC_DIR)/pe/sch/sch_beacon_gen.o \
739		$(MAC_SRC_DIR)/pe/sch/sch_beacon_process.o \
740		$(MAC_SRC_DIR)/pe/sch/sch_message.o
741
742MAC_RRM_OBJS :=	$(MAC_SRC_DIR)/pe/rrm/rrm_api.o
743
744MAC_OBJS := 	$(MAC_CFG_OBJS) \
745		$(MAC_DPH_OBJS) \
746		$(MAC_LIM_OBJS) \
747		$(MAC_SCH_OBJS) \
748		$(MAC_RRM_OBJS) \
749		$(MAC_NDP_OBJS)
750
751$(call add-wlan-objs,mac,$(MAC_OBJS))
752
753############ SAP ############
754SAP_DIR :=	core/sap
755SAP_INC_DIR :=	$(SAP_DIR)/inc
756SAP_SRC_DIR :=	$(SAP_DIR)/src
757
758SAP_INC := 	-I$(WLAN_ROOT)/$(SAP_INC_DIR) \
759		-I$(WLAN_ROOT)/$(SAP_SRC_DIR)
760
761SAP_OBJS :=	$(SAP_SRC_DIR)/sap_api_link_cntl.o \
762		$(SAP_SRC_DIR)/sap_ch_select.o \
763		$(SAP_SRC_DIR)/sap_fsm.o \
764		$(SAP_SRC_DIR)/sap_module.o
765
766$(call add-wlan-objs,sap,$(SAP_OBJS))
767
768############ CFG ############
769CFG_REL_DIR := $(WLAN_COMMON_ROOT)/cfg
770CFG_DIR := $(WLAN_ROOT)/$(CFG_REL_DIR)
771CFG_INC := \
772	-I$(CFG_DIR)/inc \
773	-I$(CFG_DIR)/dispatcher/inc \
774	-I$(WLAN_ROOT)/components/cfg
775CFG_OBJS := \
776	$(CFG_REL_DIR)/src/cfg.o
777
778$(call add-wlan-objs,cfg,$(CFG_OBJS))
779
780############ DFS ############
781DFS_DIR :=     $(WLAN_COMMON_ROOT)/umac/dfs
782DFS_CORE_INC_DIR := $(DFS_DIR)/core/inc
783DFS_CORE_SRC_DIR := $(DFS_DIR)/core/src
784
785DFS_DISP_INC_DIR := $(DFS_DIR)/dispatcher/inc
786DFS_DISP_SRC_DIR := $(DFS_DIR)/dispatcher/src
787DFS_TARGET_INC_DIR := $(WLAN_COMMON_ROOT)/target_if/dfs/inc
788DFS_CMN_SERVICES_INC_DIR := $(WLAN_COMMON_ROOT)/umac/cmn_services/dfs/inc
789
790DFS_INC :=	-I$(WLAN_ROOT)/$(DFS_DISP_INC_DIR) \
791		-I$(WLAN_ROOT)/$(DFS_TARGET_INC_DIR) \
792		-I$(WLAN_ROOT)/$(DFS_CMN_SERVICES_INC_DIR)
793
794ifeq ($(CONFIG_WLAN_DFS_MASTER_ENABLE), y)
795
796DFS_OBJS :=	$(DFS_CORE_SRC_DIR)/misc/dfs.o \
797		$(DFS_CORE_SRC_DIR)/misc/dfs_nol.o \
798		$(DFS_CORE_SRC_DIR)/misc/dfs_random_chan_sel.o \
799		$(DFS_CORE_SRC_DIR)/misc/dfs_process_radar_found_ind.o \
800		$(DFS_DISP_SRC_DIR)/wlan_dfs_init_deinit_api.o \
801		$(DFS_DISP_SRC_DIR)/wlan_dfs_lmac_api.o \
802		$(DFS_DISP_SRC_DIR)/wlan_dfs_mlme_api.o \
803		$(DFS_DISP_SRC_DIR)/wlan_dfs_tgt_api.o \
804		$(DFS_DISP_SRC_DIR)/wlan_dfs_ucfg_api.o \
805		$(DFS_DISP_SRC_DIR)/wlan_dfs_tgt_api.o \
806		$(DFS_DISP_SRC_DIR)/wlan_dfs_utils_api.o \
807		$(WLAN_COMMON_ROOT)/target_if/dfs/src/target_if_dfs.o
808
809ifeq ($(CONFIG_WLAN_FEATURE_DFS_OFFLOAD), y)
810DFS_OBJS +=	$(WLAN_COMMON_ROOT)/target_if/dfs/src/target_if_dfs_full_offload.o
811else
812DFS_OBJS +=	$(WLAN_COMMON_ROOT)/target_if/dfs/src/target_if_dfs_partial_offload.o \
813		$(DFS_CORE_SRC_DIR)/filtering/dfs_fcc_bin5.o \
814		$(DFS_CORE_SRC_DIR)/filtering/dfs_bindetects.o \
815		$(DFS_CORE_SRC_DIR)/filtering/dfs_debug.o \
816		$(DFS_CORE_SRC_DIR)/filtering/dfs_init.o \
817		$(DFS_CORE_SRC_DIR)/filtering/dfs_misc.o \
818		$(DFS_CORE_SRC_DIR)/filtering/dfs_phyerr_tlv.o \
819		$(DFS_CORE_SRC_DIR)/filtering/dfs_process_phyerr.o \
820		$(DFS_CORE_SRC_DIR)/filtering/dfs_process_radarevent.o \
821		$(DFS_CORE_SRC_DIR)/filtering/dfs_staggered.o \
822		$(DFS_CORE_SRC_DIR)/filtering/dfs_radar.o \
823		$(DFS_CORE_SRC_DIR)/filtering/dfs_partial_offload_radar.o \
824		$(DFS_CORE_SRC_DIR)/misc/dfs_filter_init.o
825endif
826endif
827
828$(call add-wlan-objs,dfs,$(DFS_OBJS))
829
830############ SME ############
831SME_DIR :=	core/sme
832SME_INC_DIR :=	$(SME_DIR)/inc
833SME_SRC_DIR :=	$(SME_DIR)/src
834
835SME_INC := 	-I$(WLAN_ROOT)/$(SME_INC_DIR) \
836		-I$(WLAN_ROOT)/$(SME_SRC_DIR)/csr \
837		-I$(WLAN_ROOT)/$(SME_SRC_DIR)/qos \
838		-I$(WLAN_ROOT)/$(SME_SRC_DIR)/common \
839		-I$(WLAN_ROOT)/$(SME_SRC_DIR)/rrm \
840		-I$(WLAN_ROOT)/$(SME_SRC_DIR)/nan
841
842ifeq ($(KERNEL_SUPPORTS_NESTED_COMPOSITES),y)
843SME_CSR_OBJS := $(SME_SRC_DIR)/csr/csr_api_roam.o \
844		$(SME_SRC_DIR)/csr/csr_api_scan.o \
845		$(SME_SRC_DIR)/csr/csr_cmd_process.o \
846		$(SME_SRC_DIR)/csr/csr_link_list.o \
847		$(SME_SRC_DIR)/csr/csr_util.o \
848
849SME_QOS_OBJS := $(SME_SRC_DIR)/qos/sme_qos.o
850
851SME_CMN_OBJS := $(SME_SRC_DIR)/common/sme_api.o \
852		$(SME_SRC_DIR)/common/sme_power_save.o \
853		$(SME_SRC_DIR)/common/sme_trace.o
854
855SME_RRM_OBJS := $(SME_SRC_DIR)/rrm/sme_rrm.o
856
857ifeq ($(CONFIG_QCACLD_FEATURE_NAN), y)
858SME_NDP_OBJS += $(SME_SRC_DIR)/nan/nan_datapath_api.o
859endif
860
861SME_OBJS :=	$(SME_CMN_OBJS) \
862		$(SME_CSR_OBJS) \
863		$(SME_QOS_OBJS) \
864		$(SME_RRM_OBJS) \
865		$(SME_NAN_OBJS) \
866		$(SME_NDP_OBJS)
867else # KERNEL_SUPPORTS_NESTED_COMPOSITES
868SME_OBJS := $(SME_SRC_DIR)/sme.o
869endif
870$(call add-wlan-objs,sme,$(SME_OBJS))
871
872############ NLINK ############
873NLINK_DIR     :=	$(WLAN_COMMON_ROOT)/utils/nlink
874NLINK_INC_DIR :=	$(NLINK_DIR)/inc
875NLINK_SRC_DIR :=	$(NLINK_DIR)/src
876
877NLINK_INC     := 	-I$(WLAN_ROOT)/$(NLINK_INC_DIR)
878NLINK_OBJS    :=	$(NLINK_SRC_DIR)/wlan_nlink_srv.o
879
880$(call add-wlan-objs,nlink,$(NLINK_OBJS))
881
882############ PTT ############
883PTT_DIR     :=	$(WLAN_COMMON_ROOT)/utils/ptt
884PTT_INC_DIR :=	$(PTT_DIR)/inc
885PTT_SRC_DIR :=	$(PTT_DIR)/src
886
887PTT_INC     := 	-I$(WLAN_ROOT)/$(PTT_INC_DIR)
888PTT_OBJS    :=	$(PTT_SRC_DIR)/wlan_ptt_sock_svc.o
889
890$(call add-wlan-objs,ptt,$(PTT_OBJS))
891
892############ WLAN_LOGGING ############
893WLAN_LOGGING_DIR     :=	$(WLAN_COMMON_ROOT)/utils/logging
894WLAN_LOGGING_INC_DIR :=	$(WLAN_LOGGING_DIR)/inc
895WLAN_LOGGING_SRC_DIR :=	$(WLAN_LOGGING_DIR)/src
896
897WLAN_LOGGING_INC     := -I$(WLAN_ROOT)/$(WLAN_LOGGING_INC_DIR)
898WLAN_LOGGING_OBJS    := $(WLAN_LOGGING_SRC_DIR)/wlan_logging_sock_svc.o \
899		$(WLAN_LOGGING_SRC_DIR)/wlan_roam_debug.o
900
901$(call add-wlan-objs,wlan_logging,$(WLAN_LOGGING_OBJS))
902
903############ SYS ############
904SYS_DIR :=	core/mac/src/sys
905
906SYS_INC := 	-I$(WLAN_ROOT)/$(SYS_DIR)/common/inc \
907		-I$(WLAN_ROOT)/$(SYS_DIR)/legacy/src/platform/inc \
908		-I$(WLAN_ROOT)/$(SYS_DIR)/legacy/src/system/inc \
909		-I$(WLAN_ROOT)/$(SYS_DIR)/legacy/src/utils/inc
910
911SYS_COMMON_SRC_DIR := $(SYS_DIR)/common/src
912SYS_LEGACY_SRC_DIR := $(SYS_DIR)/legacy/src
913SYS_OBJS :=	$(SYS_COMMON_SRC_DIR)/wlan_qct_sys.o \
914		$(SYS_LEGACY_SRC_DIR)/platform/src/sys_wrapper.o \
915		$(SYS_LEGACY_SRC_DIR)/system/src/mac_init_api.o \
916		$(SYS_LEGACY_SRC_DIR)/system/src/sys_entry_func.o \
917		$(SYS_LEGACY_SRC_DIR)/utils/src/dot11f.o \
918		$(SYS_LEGACY_SRC_DIR)/utils/src/mac_trace.o \
919		$(SYS_LEGACY_SRC_DIR)/utils/src/parser_api.o \
920		$(SYS_LEGACY_SRC_DIR)/utils/src/utils_parser.o
921
922$(call add-wlan-objs,sys,$(SYS_OBJS))
923
924############ Qcacld WMI ###################
925WMI_DIR := components/wmi
926
927CLD_WMI_INC  :=	-I$(WLAN_ROOT)/$(WMI_DIR)/inc
928
929ifeq ($(CONFIG_WMI_ROAM_SUPPORT), y)
930CLD_WMI_ROAM_OBJS +=	$(WMI_DIR)/src/wmi_unified_roam_tlv.o \
931			$(WMI_DIR)/src/wmi_unified_roam_api.o
932endif
933
934ifeq ($(CONFIG_CP_STATS), y)
935CLD_WMI_MC_CP_STATS_OBJS :=	$(WMI_DIR)/src/wmi_unified_mc_cp_stats_tlv.o \
936				$(WMI_DIR)/src/wmi_unified_mc_cp_stats_api.o
937endif
938
939ifeq ($(CONFIG_QCA_TARGET_IF_MLME), y)
940CLD_WMI_MLME_OBJS += $(WMI_DIR)/src/wmi_unified_mlme_tlv.o \
941		     $(WMI_DIR)/src/wmi_unified_mlme_api.o
942endif
943
944CLD_WMI_OBJS :=	$(CLD_WMI_ROAM_OBJS) \
945		$(CLD_WMI_MC_CP_STATS_OBJS) \
946		$(CLD_WMI_MLME_OBJS)
947
948$(call add-wlan-objs,cld_wmi,$(CLD_WMI_OBJS))
949
950############ Qca-wifi-host-cmn ############
951QDF_OS_DIR :=	qdf
952QDF_OS_INC_DIR := $(QDF_OS_DIR)/inc
953QDF_OS_SRC_DIR := $(QDF_OS_DIR)/src
954QDF_OS_LINUX_SRC_DIR := $(QDF_OS_DIR)/linux/src
955QDF_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(QDF_OS_SRC_DIR)
956QDF_LINUX_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(QDF_OS_LINUX_SRC_DIR)
957QDF_TEST_DIR := $(QDF_OS_DIR)/test
958QDF_TEST_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(QDF_TEST_DIR)
959
960QDF_INC := \
961	-I$(WLAN_COMMON_INC)/$(QDF_OS_INC_DIR) \
962	-I$(WLAN_COMMON_INC)/$(QDF_OS_LINUX_SRC_DIR) \
963	-I$(WLAN_COMMON_INC)/$(QDF_TEST_DIR)
964
965QDF_OBJS := \
966	$(QDF_LINUX_OBJ_DIR)/qdf_crypto.o \
967	$(QDF_LINUX_OBJ_DIR)/qdf_defer.o \
968	$(QDF_LINUX_OBJ_DIR)/qdf_delayed_work.o \
969	$(QDF_LINUX_OBJ_DIR)/qdf_event.o \
970	$(QDF_LINUX_OBJ_DIR)/qdf_file.o \
971	$(QDF_LINUX_OBJ_DIR)/qdf_func_tracker.o \
972	$(QDF_LINUX_OBJ_DIR)/qdf_idr.o \
973	$(QDF_LINUX_OBJ_DIR)/qdf_list.o \
974	$(QDF_LINUX_OBJ_DIR)/qdf_lock.o \
975	$(QDF_LINUX_OBJ_DIR)/qdf_mc_timer.o \
976	$(QDF_LINUX_OBJ_DIR)/qdf_mem.o \
977	$(QDF_LINUX_OBJ_DIR)/qdf_nbuf.o \
978	$(QDF_LINUX_OBJ_DIR)/qdf_periodic_work.o \
979	$(QDF_LINUX_OBJ_DIR)/qdf_status.o \
980	$(QDF_LINUX_OBJ_DIR)/qdf_threads.o \
981	$(QDF_LINUX_OBJ_DIR)/qdf_trace.o \
982	$(QDF_LINUX_OBJ_DIR)/qdf_nbuf_frag.o \
983	$(QDF_OBJ_DIR)/qdf_flex_mem.o \
984	$(QDF_OBJ_DIR)/qdf_parse.o \
985	$(QDF_OBJ_DIR)/qdf_platform.o \
986	$(QDF_OBJ_DIR)/qdf_str.o \
987	$(QDF_OBJ_DIR)/qdf_talloc.o \
988	$(QDF_OBJ_DIR)/qdf_types.o \
989
990ifeq ($(CONFIG_CNSS2_SSR_DRIVER_DUMP), y)
991QDF_OBJS += $(QDF_LINUX_OBJ_DIR)/qdf_ssr_driver_dump.o
992endif
993
994ifeq ($(CONFIG_WLAN_DEBUGFS), y)
995QDF_OBJS += $(QDF_LINUX_OBJ_DIR)/qdf_debugfs.o
996endif
997
998ifeq ($(CONFIG_WLAN_TRACEPOINTS), y)
999QDF_OBJS += $(QDF_LINUX_OBJ_DIR)/qdf_tracepoint.o
1000endif
1001
1002ifeq ($(CONFIG_WLAN_STREAMFS), y)
1003QDF_OBJS += $(QDF_LINUX_OBJ_DIR)/qdf_streamfs.o
1004endif
1005
1006ifeq ($(CONFIG_IPA_OFFLOAD), y)
1007QDF_OBJS += $(QDF_LINUX_OBJ_DIR)/qdf_ipa.o
1008endif
1009
1010ifeq ($(CONFIG_DP_PKT_ADD_TIMESTAMP), y)
1011QDF_OBJS += $(QDF_LINUX_OBJ_DIR)/qdf_pkt_add_timestamp.o
1012endif
1013
1014# enable CPU hotplug support if SMP is enabled
1015ifeq ($(CONFIG_SMP), y)
1016	QDF_OBJS += $(QDF_OBJ_DIR)/qdf_cpuhp.o
1017	QDF_OBJS += $(QDF_LINUX_OBJ_DIR)/qdf_cpuhp.o
1018endif
1019
1020ifeq ($(CONFIG_LEAK_DETECTION), y)
1021	QDF_OBJS += $(QDF_OBJ_DIR)/qdf_debug_domain.o
1022	QDF_OBJS += $(QDF_OBJ_DIR)/qdf_tracker.o
1023endif
1024
1025ifeq ($(CONFIG_WLAN_HANG_EVENT), y)
1026	QDF_OBJS += $(QDF_OBJ_DIR)/qdf_notifier.o
1027endif
1028
1029ifeq ($(CONFIG_QDF_TEST), y)
1030	QDF_OBJS += $(QDF_TEST_OBJ_DIR)/qdf_delayed_work_test.o
1031	QDF_OBJS += $(QDF_TEST_OBJ_DIR)/qdf_hashtable_test.o
1032	QDF_OBJS += $(QDF_TEST_OBJ_DIR)/qdf_periodic_work_test.o
1033	QDF_OBJS += $(QDF_TEST_OBJ_DIR)/qdf_ptr_hash_test.o
1034	QDF_OBJS += $(QDF_TEST_OBJ_DIR)/qdf_slist_test.o
1035	QDF_OBJS += $(QDF_TEST_OBJ_DIR)/qdf_talloc_test.o
1036	QDF_OBJS += $(QDF_TEST_OBJ_DIR)/qdf_tracker_test.o
1037	QDF_OBJS += $(QDF_TEST_OBJ_DIR)/qdf_types_test.o
1038endif
1039
1040ifeq ($(CONFIG_WLAN_HANG_EVENT), y)
1041	QDF_OBJS += $(QDF_OBJ_DIR)/qdf_hang_event_notifier.o
1042endif
1043
1044ifeq ($(CONFIG_WLAN_LRO), y)
1045QDF_OBJS +=     $(QDF_LINUX_OBJ_DIR)/qdf_lro.o
1046endif
1047
1048$(call add-wlan-objs,qdf,$(QDF_OBJS))
1049
1050############ WBUFF ############
1051WBUFF_OS_DIR :=	wbuff
1052WBUFF_OS_INC_DIR := $(WBUFF_OS_DIR)/inc
1053WBUFF_OS_SRC_DIR := $(WBUFF_OS_DIR)/src
1054WBUFF_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(WBUFF_OS_SRC_DIR)
1055
1056WBUFF_INC :=	-I$(WLAN_COMMON_INC)/$(WBUFF_OS_INC_DIR) \
1057
1058ifeq ($(CONFIG_WLAN_WBUFF), y)
1059WBUFF_OBJS += 	$(WBUFF_OBJ_DIR)/wbuff.o
1060endif
1061
1062$(call add-wlan-objs,wbuff,$(WBUFF_OBJS))
1063
1064##########QAL #######
1065QAL_OS_DIR :=	qal
1066QAL_OS_INC_DIR := $(QAL_OS_DIR)/inc
1067QAL_OS_LINUX_SRC_DIR := $(QAL_OS_DIR)/linux/src
1068
1069QAL_INC :=	-I$(WLAN_COMMON_INC)/$(QAL_OS_INC_DIR) \
1070		-I$(WLAN_COMMON_INC)/$(QAL_OS_LINUX_SRC_DIR)
1071
1072
1073##########OS_IF #######
1074OS_IF_DIR := $(WLAN_COMMON_ROOT)/os_if
1075
1076OS_IF_INC += -I$(WLAN_COMMON_INC)/os_if/linux \
1077            -I$(WLAN_COMMON_INC)/os_if/linux/scan/inc \
1078            -I$(WLAN_COMMON_INC)/os_if/linux/spectral/inc \
1079            -I$(WLAN_COMMON_INC)/os_if/linux/crypto/inc \
1080            -I$(WLAN_COMMON_INC)/os_if/linux/mlme/inc \
1081            -I$(WLAN_COMMON_INC)/os_if/linux/gpio/inc
1082
1083OS_IF_OBJ += $(OS_IF_DIR)/linux/wlan_osif_request_manager.o \
1084	     $(OS_IF_DIR)/linux/crypto/src/wlan_nl_to_crypto_params.o \
1085	     $(OS_IF_DIR)/linux/mlme/src/osif_cm_util.o \
1086	     $(OS_IF_DIR)/linux/mlme/src/osif_cm_connect_rsp.o \
1087	     $(OS_IF_DIR)/linux/mlme/src/osif_cm_disconnect_rsp.o \
1088	     $(OS_IF_DIR)/linux/mlme/src/osif_cm_req.o \
1089	     $(OS_IF_DIR)/linux/mlme/src/osif_cm_roam_rsp.o \
1090	     $(OS_IF_DIR)/linux/mlme/src/osif_vdev_mgr_util.o
1091
1092OS_IF_OBJ += $(OS_IF_DIR)/linux/crypto/src/wlan_cfg80211_crypto.o
1093
1094$(call add-wlan-objs,os_if,$(OS_IF_OBJ))
1095
1096############ UMAC_DISP ############
1097UMAC_DISP_DIR := umac/global_umac_dispatcher/lmac_if
1098UMAC_DISP_INC_DIR := $(UMAC_DISP_DIR)/inc
1099UMAC_DISP_SRC_DIR := $(UMAC_DISP_DIR)/src
1100UMAC_DISP_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_DISP_SRC_DIR)
1101
1102UMAC_DISP_INC := -I$(WLAN_COMMON_INC)/$(UMAC_DISP_INC_DIR)
1103
1104UMAC_DISP_OBJS := $(UMAC_DISP_OBJ_DIR)/wlan_lmac_if.o
1105
1106$(call add-wlan-objs,umac_disp,$(UMAC_DISP_OBJS))
1107
1108############# UMAC_SCAN ############
1109UMAC_SCAN_DIR := umac/scan
1110UMAC_SCAN_DISP_INC_DIR := $(UMAC_SCAN_DIR)/dispatcher/inc
1111UMAC_SCAN_CORE_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_SCAN_DIR)/core/src
1112UMAC_SCAN_DISP_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_SCAN_DIR)/dispatcher/src
1113UMAC_TARGET_SCAN_INC := -I$(WLAN_COMMON_INC)/target_if/scan/inc
1114
1115UMAC_SCAN_INC := -I$(WLAN_COMMON_INC)/$(UMAC_SCAN_DISP_INC_DIR)
1116UMAC_SCAN_OBJS := $(UMAC_SCAN_CORE_DIR)/wlan_scan_cache_db.o \
1117		$(UMAC_SCAN_CORE_DIR)/wlan_scan_11d.o \
1118		$(UMAC_SCAN_CORE_DIR)/wlan_scan_filter.o \
1119		$(UMAC_SCAN_CORE_DIR)/wlan_scan_main.o \
1120		$(UMAC_SCAN_CORE_DIR)/wlan_scan_manager.o \
1121		$(UMAC_SCAN_DISP_DIR)/wlan_scan_tgt_api.o \
1122		$(UMAC_SCAN_DISP_DIR)/wlan_scan_ucfg_api.o \
1123		$(UMAC_SCAN_DISP_DIR)/wlan_scan_api.o \
1124		$(UMAC_SCAN_DISP_DIR)/wlan_scan_utils_api.o \
1125		$(WLAN_COMMON_ROOT)/os_if/linux/scan/src/wlan_cfg80211_scan.o \
1126		$(WLAN_COMMON_ROOT)/os_if/linux/wlan_cfg80211.o \
1127		$(WLAN_COMMON_ROOT)/target_if/scan/src/target_if_scan.o
1128
1129ifeq ($(CONFIG_FEATURE_WLAN_EXTSCAN), y)
1130UMAC_SCAN_OBJS += $(UMAC_SCAN_DISP_DIR)/wlan_extscan_api.o
1131endif
1132
1133ifeq ($(CONFIG_BAND_6GHZ), y)
1134UMAC_SCAN_OBJS += $(UMAC_SCAN_CORE_DIR)/wlan_scan_manager_6ghz.o
1135endif
1136
1137$(call add-wlan-objs,umac_scan,$(UMAC_SCAN_OBJS))
1138
1139############# UMAC_SPECTRAL_SCAN ############
1140UMAC_SPECTRAL_DIR := spectral
1141UMAC_SPECTRAL_DISP_INC_DIR := $(UMAC_SPECTRAL_DIR)/dispatcher/inc
1142UMAC_SPECTRAL_CORE_INC_DIR := $(UMAC_SPECTRAL_DIR)/core
1143UMAC_SPECTRAL_CORE_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_SPECTRAL_DIR)/core
1144UMAC_SPECTRAL_DISP_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_SPECTRAL_DIR)/dispatcher/src
1145UMAC_TARGET_SPECTRAL_INC := -I$(WLAN_COMMON_INC)/target_if/spectral
1146
1147UMAC_SPECTRAL_INC := -I$(WLAN_COMMON_INC)/$(UMAC_SPECTRAL_DISP_INC_DIR) \
1148			-I$(WLAN_COMMON_INC)/$(UMAC_SPECTRAL_CORE_INC_DIR) \
1149			-I$(WLAN_COMMON_INC)/target_if/direct_buf_rx/inc
1150ifeq ($(CONFIG_WLAN_CONV_SPECTRAL_ENABLE),y)
1151UMAC_SPECTRAL_OBJS := $(UMAC_SPECTRAL_CORE_DIR)/spectral_offload.o \
1152		$(UMAC_SPECTRAL_CORE_DIR)/spectral_common.o \
1153		$(UMAC_SPECTRAL_DISP_DIR)/wlan_spectral_ucfg_api.o \
1154		$(UMAC_SPECTRAL_DISP_DIR)/wlan_spectral_utils_api.o \
1155		$(UMAC_SPECTRAL_DISP_DIR)/wlan_spectral_tgt_api.o \
1156		$(WLAN_COMMON_ROOT)/os_if/linux/spectral/src/wlan_cfg80211_spectral.o \
1157		$(WLAN_COMMON_ROOT)/os_if/linux/spectral/src/os_if_spectral_netlink.o \
1158		$(WLAN_COMMON_ROOT)/target_if/spectral/target_if_spectral_netlink.o \
1159		$(WLAN_COMMON_ROOT)/target_if/spectral/target_if_spectral_phyerr.o \
1160		$(WLAN_COMMON_ROOT)/target_if/spectral/target_if_spectral.o \
1161		$(WLAN_COMMON_ROOT)/target_if/spectral/target_if_spectral_sim.o
1162endif
1163
1164$(call add-wlan-objs,umac_spectral,$(UMAC_SPECTRAL_OBJS))
1165
1166############# WLAN_CFR ############
1167WLAN_CFR_DIR := umac/cfr
1168WLAN_CFR_DISP_INC_DIR := $(WLAN_CFR_DIR)/dispatcher/inc
1169WLAN_CFR_CORE_INC_DIR := $(WLAN_CFR_DIR)/core/inc
1170WLAN_CFR_CORE_DIR := $(WLAN_COMMON_ROOT)/$(WLAN_CFR_DIR)/core/src
1171WLAN_CFR_DISP_DIR := $(WLAN_COMMON_ROOT)/$(WLAN_CFR_DIR)/dispatcher/src
1172WLAN_CFR_TARGET_INC_DIR := target_if/cfr/inc
1173
1174WLAN_CFR_INC := -I$(WLAN_COMMON_INC)/$(WLAN_CFR_DISP_INC_DIR) \
1175			-I$(WLAN_COMMON_INC)/$(WLAN_CFR_CORE_INC_DIR) \
1176			-I$(WLAN_COMMON_INC)/$(WLAN_CFR_TARGET_INC_DIR)
1177ifeq ($(CONFIG_WLAN_CFR_ENABLE),y)
1178WLAN_CFR_OBJS := $(WLAN_CFR_CORE_DIR)/cfr_common.o \
1179                $(WLAN_CFR_DISP_DIR)/wlan_cfr_tgt_api.o \
1180                $(WLAN_CFR_DISP_DIR)/wlan_cfr_ucfg_api.o \
1181                $(WLAN_CFR_DISP_DIR)/wlan_cfr_utils_api.o \
1182		$(WLAN_COMMON_ROOT)/target_if/cfr/src/target_if_cfr.o \
1183		$(WLAN_COMMON_ROOT)/target_if/cfr/src/target_if_cfr_6490.o
1184ifeq ($(CONFIG_WLAN_ENH_CFR_ENABLE),y)
1185WLAN_CFR_OBJS += $(WLAN_COMMON_ROOT)/target_if/cfr/src/target_if_cfr_enh.o
1186endif
1187ifeq ($(CONFIG_WLAN_CFR_ADRASTEA),y)
1188WLAN_CFR_OBJS += $(WLAN_COMMON_ROOT)/target_if/cfr/src/target_if_cfr_adrastea.o
1189endif
1190ifeq ($(CONFIG_WLAN_CFR_DBR),y)
1191WLAN_CFR_OBJS += $(WLAN_COMMON_ROOT)/target_if/cfr/src/target_if_cfr_dbr.o
1192endif
1193endif
1194
1195$(call add-wlan-objs,wlan_cfr,$(WLAN_CFR_OBJS))
1196
1197############# GPIO_CFG ############
1198UMAC_GPIO_DIR := gpio
1199UMAC_GPIO_DISP_INC_DIR := $(UMAC_GPIO_DIR)/dispatcher/inc
1200UMAC_GPIO_CORE_INC_DIR := $(UMAC_GPIO_DIR)/core/inc
1201UMAC_GPIO_CORE_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_GPIO_DIR)/core/src
1202UMAC_GPIO_DISP_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_GPIO_DIR)/dispatcher/src
1203UMAC_TARGET_GPIO_INC := -I$(WLAN_COMMON_INC)/target_if/gpio
1204
1205UMAC_GPIO_INC := -I$(WLAN_COMMON_INC)/$(UMAC_GPIO_DISP_INC_DIR) \
1206			-I$(WLAN_COMMON_INC)/$(UMAC_GPIO_CORE_INC_DIR)
1207
1208ifeq ($(CONFIG_FEATURE_GPIO_CFG),y)
1209UMAC_GPIO_OBJS := $(UMAC_GPIO_DISP_DIR)/wlan_gpio_tgt_api.o \
1210		$(UMAC_GPIO_DISP_DIR)/wlan_gpio_ucfg_api.o \
1211		$(UMAC_GPIO_CORE_DIR)/wlan_gpio_api.o \
1212		$(WLAN_COMMON_ROOT)/os_if/linux/gpio/src/wlan_cfg80211_gpio.o \
1213		$(WLAN_COMMON_ROOT)/target_if/gpio/target_if_gpio.o
1214endif
1215
1216$(call add-wlan-objs,umac_gpio,$(UMAC_GPIO_OBJS))
1217
1218############# UMAC_GREEN_AP ############
1219UMAC_GREEN_AP_DIR := umac/green_ap
1220UMAC_GREEN_AP_DISP_INC_DIR := $(UMAC_GREEN_AP_DIR)/dispatcher/inc
1221UMAC_GREEN_AP_CORE_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_GREEN_AP_DIR)/core/src
1222UMAC_GREEN_AP_DISP_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_GREEN_AP_DIR)/dispatcher/src
1223UMAC_TARGET_GREEN_AP_INC := -I$(WLAN_COMMON_INC)/target_if/green_ap/inc
1224
1225UMAC_GREEN_AP_INC := -I$(WLAN_COMMON_INC)/$(UMAC_GREEN_AP_DISP_INC_DIR)
1226
1227ifeq ($(CONFIG_QCACLD_FEATURE_GREEN_AP), y)
1228UMAC_GREEN_AP_OBJS := $(UMAC_GREEN_AP_CORE_DIR)/wlan_green_ap_main.o \
1229		$(UMAC_GREEN_AP_DISP_DIR)/wlan_green_ap_api.o \
1230                $(UMAC_GREEN_AP_DISP_DIR)/wlan_green_ap_ucfg_api.o \
1231                $(WLAN_COMMON_ROOT)/target_if/green_ap/src/target_if_green_ap.o
1232endif
1233
1234$(call add-wlan-objs,umac_green_ap,$(UMAC_GREEN_AP_OBJS))
1235
1236############# WLAN_CONV_CRYPTO_SUPPORTED ############
1237UMAC_CRYPTO_DIR := umac/cmn_services/crypto
1238UMAC_CRYPTO_CORE_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_CRYPTO_DIR)/src
1239UMAC_CRYPTO_INC := -I$(WLAN_COMMON_INC)/$(UMAC_CRYPTO_DIR)/inc \
1240		-I$(WLAN_COMMON_INC)/$(UMAC_CRYPTO_DIR)/src
1241
1242UMAC_CRYPTO_OBJS := $(UMAC_CRYPTO_CORE_DIR)/wlan_crypto_global_api.o \
1243		$(UMAC_CRYPTO_CORE_DIR)/wlan_crypto_ucfg_api.o \
1244		$(UMAC_CRYPTO_CORE_DIR)/wlan_crypto_main.o \
1245		$(UMAC_CRYPTO_CORE_DIR)/wlan_crypto_obj_mgr.o \
1246		$(UMAC_CRYPTO_CORE_DIR)/wlan_crypto_param_handling.o
1247
1248$(call add-wlan-objs,umac_crypto,$(UMAC_CRYPTO_OBJS))
1249
1250############# FTM CORE ############
1251FTM_CORE_DIR := ftm
1252TARGET_IF_FTM_DIR := target_if/ftm
1253OS_IF_LINUX_FTM_DIR := os_if/linux/ftm
1254
1255FTM_CORE_SRC := $(WLAN_COMMON_ROOT)/$(FTM_CORE_DIR)/core/src
1256FTM_DISP_SRC := $(WLAN_COMMON_ROOT)/$(FTM_CORE_DIR)/dispatcher/src
1257TARGET_IF_FTM_SRC := $(WLAN_COMMON_ROOT)/$(TARGET_IF_FTM_DIR)/src
1258OS_IF_FTM_SRC := $(WLAN_COMMON_ROOT)/$(OS_IF_LINUX_FTM_DIR)/src
1259
1260FTM_CORE_INC := $(WLAN_COMMON_INC)/$(FTM_CORE_DIR)/core/src
1261FTM_DISP_INC := $(WLAN_COMMON_INC)/$(FTM_CORE_DIR)/dispatcher/inc
1262TARGET_IF_FTM_INC := $(WLAN_COMMON_INC)/$(TARGET_IF_FTM_DIR)/inc
1263OS_IF_FTM_INC := $(WLAN_COMMON_INC)/$(OS_IF_LINUX_FTM_DIR)/inc
1264
1265FTM_INC := -I$(FTM_DISP_INC)	\
1266	   -I$(FTM_CORE_INC)	\
1267	   -I$(OS_IF_FTM_INC)	\
1268	   -I$(TARGET_IF_FTM_INC)
1269
1270ifeq ($(CONFIG_QCA_WIFI_FTM), y)
1271FTM_OBJS := $(FTM_DISP_SRC)/wlan_ftm_init_deinit.o \
1272	    $(FTM_DISP_SRC)/wlan_ftm_ucfg_api.o \
1273	    $(FTM_CORE_SRC)/wlan_ftm_svc.o \
1274	    $(TARGET_IF_FTM_SRC)/target_if_ftm.o
1275
1276ifeq ($(QCA_WIFI_FTM_NL80211), y)
1277FTM_OBJS += $(OS_IF_FTM_SRC)/wlan_cfg80211_ftm.o
1278endif
1279
1280ifeq ($(CONFIG_LINUX_QCMBR), y)
1281FTM_OBJS += $(OS_IF_FTM_SRC)/wlan_ioctl_ftm.o
1282endif
1283
1284endif
1285
1286$(call add-wlan-objs,ftm,$(FTM_OBJS))
1287
1288############# UMAC_CMN_SERVICES ############
1289UMAC_COMMON_INC := -I$(WLAN_COMMON_INC)/umac/cmn_services/cmn_defs/inc \
1290		-I$(WLAN_COMMON_INC)/umac/cmn_services/utils/inc
1291UMAC_COMMON_OBJS := $(WLAN_COMMON_ROOT)/umac/cmn_services/utils/src/wlan_utility.o
1292
1293$(call add-wlan-objs,umac_common,$(UMAC_COMMON_OBJS))
1294
1295############ CDS (Connectivity driver services) ############
1296CDS_DIR :=	core/cds
1297CDS_INC_DIR :=	$(CDS_DIR)/inc
1298CDS_SRC_DIR :=	$(CDS_DIR)/src
1299
1300CDS_INC := 	-I$(WLAN_ROOT)/$(CDS_INC_DIR) \
1301		-I$(WLAN_ROOT)/$(CDS_SRC_DIR)
1302
1303CDS_OBJS :=	$(CDS_SRC_DIR)/cds_api.o \
1304		$(CDS_SRC_DIR)/cds_reg_service.o \
1305		$(CDS_SRC_DIR)/cds_packet.o \
1306		$(CDS_SRC_DIR)/cds_regdomain.o \
1307		$(CDS_SRC_DIR)/cds_sched.o \
1308		$(CDS_SRC_DIR)/cds_utils.o
1309
1310$(call add-wlan-objs,cds,$(CDS_OBJS))
1311
1312###### UMAC OBJMGR ########
1313UMAC_OBJMGR_DIR := $(WLAN_COMMON_ROOT)/umac/cmn_services/obj_mgr
1314
1315UMAC_OBJMGR_INC := -I$(WLAN_COMMON_INC)/umac/cmn_services/obj_mgr/inc \
1316		-I$(WLAN_COMMON_INC)/umac/cmn_services/obj_mgr/src \
1317		-I$(WLAN_COMMON_INC)/umac/cmn_services/inc
1318
1319UMAC_OBJMGR_OBJS := $(UMAC_OBJMGR_DIR)/src/wlan_objmgr_global_obj.o \
1320		$(UMAC_OBJMGR_DIR)/src/wlan_objmgr_pdev_obj.o \
1321		$(UMAC_OBJMGR_DIR)/src/wlan_objmgr_peer_obj.o \
1322		$(UMAC_OBJMGR_DIR)/src/wlan_objmgr_psoc_obj.o \
1323		$(UMAC_OBJMGR_DIR)/src/wlan_objmgr_vdev_obj.o
1324
1325ifeq ($(CONFIG_WLAN_OBJMGR_DEBUG), y)
1326UMAC_OBJMGR_OBJS += $(UMAC_OBJMGR_DIR)/src/wlan_objmgr_debug.o
1327endif
1328
1329$(call add-wlan-objs,umac_objmgr,$(UMAC_OBJMGR_OBJS))
1330
1331###########  UMAC MGMT TXRX ##########
1332UMAC_MGMT_TXRX_DIR := $(WLAN_COMMON_ROOT)/umac/cmn_services/mgmt_txrx
1333
1334UMAC_MGMT_TXRX_INC := -I$(WLAN_COMMON_INC)/umac/cmn_services/mgmt_txrx/dispatcher/inc \
1335
1336UMAC_MGMT_TXRX_OBJS := $(UMAC_MGMT_TXRX_DIR)/core/src/wlan_mgmt_txrx_main.o \
1337	$(UMAC_MGMT_TXRX_DIR)/dispatcher/src/wlan_mgmt_txrx_utils_api.o \
1338	$(UMAC_MGMT_TXRX_DIR)/dispatcher/src/wlan_mgmt_txrx_tgt_api.o
1339
1340$(call add-wlan-objs,umac_mgmt_txrx,$(UMAC_MGMT_TXRX_OBJS))
1341
1342###### UMAC INTERFACE_MGR ########
1343UMAC_INTERFACE_MGR_COMP_DIR :=	components/cmn_services/interface_mgr
1344UMAC_INTERFACE_MGR_CMN_DIR := $(WLAN_COMMON_ROOT)/umac/cmn_services/interface_mgr
1345
1346UMAC_INTERFACE_MGR_INC := -I$(WLAN_COMMON_INC)/umac/cmn_services/interface_mgr/inc \
1347			 -I$(WLAN_ROOT)/components/cmn_services/interface_mgr/inc
1348
1349UMAC_INTERFACE_MGR_OBJS := $(UMAC_INTERFACE_MGR_CMN_DIR)/src/wlan_if_mgr_main.o \
1350			  $(UMAC_INTERFACE_MGR_CMN_DIR)/src/wlan_if_mgr_core.o \
1351			  $(UMAC_INTERFACE_MGR_COMP_DIR)/src/wlan_if_mgr_sta.o \
1352			  $(UMAC_INTERFACE_MGR_COMP_DIR)/src/wlan_if_mgr_sap.o \
1353			  $(UMAC_INTERFACE_MGR_COMP_DIR)/src/wlan_if_mgr_roam.o
1354
1355$(call add-wlan-objs,umac_ifmgr,$(UMAC_INTERFACE_MGR_OBJS))
1356
1357###### UMAC MLO_MGR ########
1358UMAC_MLO_MGR_CMN_DIR :=	$(WLAN_COMMON_ROOT)/umac/mlo_mgr
1359MLO_MGR_TARGET_IF_DIR := $(WLAN_COMMON_ROOT)/target_if/mlo_mgr
1360
1361UMAC_MLO_MGR_CLD_DIR := components/umac/mlme/mlo_mgr
1362UMAC_MLO_MGR_CLD_INC := -I$(WLAN_ROOT)/$(UMAC_MLO_MGR_CLD_DIR)/inc \
1363			-I$(WLAN_ROOT)/$(UMAC_MLO_MGR_CLD_DIR)/dispatcher/inc \
1364
1365UMAC_MLO_MGR_INC := -I$(WLAN_COMMON_INC)/umac/mlo_mgr/inc \
1366		    -I$(WLAN_COMMON_INC)/target_if/mlo_mgr/inc
1367
1368ifeq ($(CONFIG_WLAN_FEATURE_11BE_MLO), y)
1369UMAC_MLO_MGR_OBJS := $(UMAC_MLO_MGR_CMN_DIR)/src/wlan_mlo_mgr_main.o \
1370			  $(UMAC_MLO_MGR_CMN_DIR)/src/wlan_mlo_mgr_cmn.o \
1371			  $(UMAC_MLO_MGR_CMN_DIR)/src/wlan_mlo_mgr_sta.o \
1372			  $(UMAC_MLO_MGR_CMN_DIR)/src/wlan_mlo_mgr_op.o \
1373			  $(UMAC_MLO_MGR_CMN_DIR)/src/utils_mlo.o \
1374			  $(UMAC_MLO_MGR_CMN_DIR)/src/wlan_mlo_mgr_ap.o \
1375			  $(UMAC_MLO_MGR_CMN_DIR)/src/wlan_mlo_mgr_peer_list.o \
1376			  $(UMAC_MLO_MGR_CMN_DIR)/src/wlan_mlo_mgr_aid.o \
1377			  $(UMAC_MLO_MGR_CMN_DIR)/src/wlan_mlo_mgr_peer.o \
1378			  $(UMAC_MLO_MGR_CMN_DIR)/src/wlan_mlo_mgr_msgq.o \
1379			  $(UMAC_MLO_MGR_CMN_DIR)/src/wlan_mlo_mgr_primary_umac.o \
1380			  $(MLO_MGR_TARGET_IF_DIR)/src/target_if_mlo_mgr.o \
1381			  $(UMAC_MLO_MGR_CLD_DIR)/src/wlan_mlo_link_force.o \
1382			  $(UMAC_MLO_MGR_CLD_DIR)/src/wlan_mlo_mgr_roam.o \
1383			  $(UMAC_MLO_MGR_CLD_DIR)/src/wlan_t2lm_api.o \
1384			  $(UMAC_MLO_MGR_CMN_DIR)/src/wlan_mlo_t2lm.o \
1385			  $(UMAC_MLO_MGR_CLD_DIR)/src/wlan_epcs_api.o \
1386			  $(UMAC_MLO_MGR_CMN_DIR)/src/wlan_mlo_epcs.o \
1387			  $(UMAC_MLO_MGR_CLD_DIR)/dispatcher/src/wlan_mlo_epcs_ucfg_api.o \
1388			  $(UMAC_MLO_MGR_CMN_DIR)/src/wlan_mlo_mgr_link_switch.o \
1389
1390$(call add-wlan-objs,umac_mlomgr,$(UMAC_MLO_MGR_OBJS))
1391endif
1392########## POWER MANAGEMENT OFFLOADS (PMO) ##########
1393PMO_DIR :=	components/pmo
1394PMO_INC :=	-I$(WLAN_ROOT)/$(PMO_DIR)/core/inc \
1395			-I$(WLAN_ROOT)/$(PMO_DIR)/dispatcher/inc \
1396
1397ifeq ($(CONFIG_POWER_MANAGEMENT_OFFLOAD), y)
1398PMO_OBJS :=     $(PMO_DIR)/core/src/wlan_pmo_main.o \
1399		$(PMO_DIR)/core/src/wlan_pmo_apf.o \
1400		$(PMO_DIR)/core/src/wlan_pmo_arp.o \
1401		$(PMO_DIR)/core/src/wlan_pmo_gtk.o \
1402		$(PMO_DIR)/core/src/wlan_pmo_mc_addr_filtering.o \
1403		$(PMO_DIR)/core/src/wlan_pmo_static_config.o \
1404		$(PMO_DIR)/core/src/wlan_pmo_wow.o \
1405		$(PMO_DIR)/core/src/wlan_pmo_lphb.o \
1406		$(PMO_DIR)/core/src/wlan_pmo_suspend_resume.o \
1407		$(PMO_DIR)/core/src/wlan_pmo_hw_filter.o \
1408		$(PMO_DIR)/dispatcher/src/wlan_pmo_obj_mgmt_api.o \
1409		$(PMO_DIR)/dispatcher/src/wlan_pmo_ucfg_api.o \
1410		$(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_arp.o \
1411		$(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_gtk.o \
1412		$(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_wow.o \
1413		$(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_static_config.o \
1414		$(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_mc_addr_filtering.o \
1415		$(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_lphb.o \
1416		$(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_suspend_resume.o \
1417		$(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_hw_filter.o \
1418
1419ifeq ($(CONFIG_WLAN_FEATURE_PACKET_FILTERING), y)
1420PMO_OBJS +=	$(PMO_DIR)/core/src/wlan_pmo_pkt_filter.o \
1421		$(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_pkt_filter.o
1422endif
1423endif
1424
1425ifeq ($(CONFIG_WLAN_NS_OFFLOAD), y)
1426PMO_OBJS +=     $(PMO_DIR)/core/src/wlan_pmo_ns.o \
1427		$(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_ns.o
1428endif
1429
1430ifeq ($(CONFIG_WLAN_FEATURE_ICMP_OFFLOAD), y)
1431PMO_OBJS +=     $(PMO_DIR)/core/src/wlan_pmo_icmp.o \
1432		$(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_icmp.o
1433endif
1434
1435$(call add-wlan-objs,pmo,$(PMO_OBJS))
1436
1437########## DISA (ENCRYPTION TEST) ##########
1438
1439DISA_DIR :=	components/disa
1440DISA_INC :=	-I$(WLAN_ROOT)/$(DISA_DIR)/core/inc \
1441		-I$(WLAN_ROOT)/$(DISA_DIR)/dispatcher/inc
1442
1443ifeq ($(CONFIG_WLAN_FEATURE_DISA), y)
1444DISA_OBJS :=	$(DISA_DIR)/core/src/wlan_disa_main.o \
1445		$(DISA_DIR)/dispatcher/src/wlan_disa_obj_mgmt_api.o \
1446		$(DISA_DIR)/dispatcher/src/wlan_disa_tgt_api.o \
1447		$(DISA_DIR)/dispatcher/src/wlan_disa_ucfg_api.o
1448endif
1449
1450$(call add-wlan-objs,disa,$(DISA_OBJS))
1451
1452######## OCB ##############
1453OCB_DIR := components/ocb
1454OCB_INC := -I$(WLAN_ROOT)/$(OCB_DIR)/core/inc \
1455		-I$(WLAN_ROOT)/$(OCB_DIR)/dispatcher/inc
1456
1457ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
1458OCB_OBJS :=	$(OCB_DIR)/dispatcher/src/wlan_ocb_ucfg_api.o \
1459		$(OCB_DIR)/dispatcher/src/wlan_ocb_tgt_api.o \
1460		$(OCB_DIR)/core/src/wlan_ocb_main.o
1461endif
1462
1463$(call add-wlan-objs,ocb,$(OCB_OBJS))
1464
1465######## IPA ##############
1466IPA_DIR := $(WLAN_COMMON_ROOT)/ipa
1467IPA_INC := -I$(WLAN_ROOT)/$(IPA_DIR)/core/inc \
1468		-I$(WLAN_ROOT)/$(IPA_DIR)/dispatcher/inc
1469
1470ifeq ($(CONFIG_IPA_OFFLOAD), y)
1471IPA_OBJS :=	$(IPA_DIR)/dispatcher/src/wlan_ipa_ucfg_api.o \
1472		$(IPA_DIR)/dispatcher/src/wlan_ipa_obj_mgmt_api.o \
1473		$(IPA_DIR)/dispatcher/src/wlan_ipa_tgt_api.o \
1474		$(IPA_DIR)/core/src/wlan_ipa_main.o \
1475		$(IPA_DIR)/core/src/wlan_ipa_core.o \
1476		$(IPA_DIR)/core/src/wlan_ipa_stats.o \
1477		$(IPA_DIR)/core/src/wlan_ipa_rm.o
1478endif
1479
1480$(call add-wlan-objs,ipa,$(IPA_OBJS))
1481
1482######## FWOL ##########
1483FWOL_CORE_INC := components/fw_offload/core/inc
1484FWOL_CORE_SRC := components/fw_offload/core/src
1485FWOL_DISPATCHER_INC := components/fw_offload/dispatcher/inc
1486FWOL_DISPATCHER_SRC := components/fw_offload/dispatcher/src
1487FWOL_TARGET_IF_INC := components/target_if/fw_offload/inc
1488FWOL_TARGET_IF_SRC := components/target_if/fw_offload/src
1489FWOL_OS_IF_INC := os_if/fw_offload/inc
1490FWOL_OS_IF_SRC := os_if/fw_offload/src
1491
1492FWOL_INC := -I$(WLAN_ROOT)/$(FWOL_CORE_INC) \
1493	    -I$(WLAN_ROOT)/$(FWOL_DISPATCHER_INC) \
1494	    -I$(WLAN_ROOT)/$(FWOL_TARGET_IF_INC) \
1495	    -I$(WLAN_ROOT)/$(FWOL_OS_IF_INC) \
1496	    -I$(WLAN_COMMON_INC)/umac/thermal/dispatcher/inc
1497
1498ifeq ($(CONFIG_WLAN_FW_OFFLOAD), y)
1499FWOL_OBJS :=	$(FWOL_CORE_SRC)/wlan_fw_offload_main.o \
1500		$(FWOL_DISPATCHER_SRC)/wlan_fwol_ucfg_api.o \
1501		$(FWOL_DISPATCHER_SRC)/wlan_fwol_tgt_api.o \
1502		$(FWOL_TARGET_IF_SRC)/target_if_fwol.o \
1503		$(FWOL_OS_IF_SRC)/os_if_fwol.o
1504endif
1505
1506$(call add-wlan-objs,fwol,$(FWOL_OBJS))
1507
1508######## SM FRAMEWORK  ##############
1509UMAC_SM_DIR := umac/cmn_services/sm_engine
1510UMAC_SM_INC := -I$(WLAN_COMMON_INC)/$(UMAC_SM_DIR)/inc
1511
1512UMAC_SM_OBJS := $(WLAN_COMMON_ROOT)/$(UMAC_SM_DIR)/src/wlan_sm_engine.o
1513
1514ifeq ($(CONFIG_SM_ENG_HIST), y)
1515UMAC_SM_OBJS +=	$(WLAN_COMMON_ROOT)/$(UMAC_SM_DIR)/src/wlan_sm_engine_dbg.o
1516endif
1517
1518$(call add-wlan-objs,umac_sm,$(UMAC_SM_OBJS))
1519
1520######## COMMON MLME ##############
1521UMAC_MLME_INC := -I$(WLAN_COMMON_INC)/umac/mlme \
1522		-I$(WLAN_COMMON_INC)/umac/mlme/mlme_objmgr/dispatcher/inc \
1523		-I$(WLAN_COMMON_INC)/umac/mlme/vdev_mgr/dispatcher/inc \
1524		-I$(WLAN_COMMON_INC)/umac/mlme/pdev_mgr/dispatcher/inc \
1525		-I$(WLAN_COMMON_INC)/umac/mlme/psoc_mgr/dispatcher/inc \
1526		-I$(WLAN_COMMON_INC)/umac/mlme/connection_mgr/dispatcher/inc \
1527		-I$(WLAN_COMMON_INC)/umac/mlme/connection_mgr/utf/inc \
1528		-I$(WLAN_COMMON_INC)/umac/mlme/include \
1529		-I$(WLAN_COMMON_INC)/umac/mlme/mlme_utils/
1530
1531UMAC_MLME_OBJS := $(WLAN_COMMON_ROOT)/umac/mlme/mlme_objmgr/dispatcher/src/wlan_vdev_mlme_main.o \
1532		$(WLAN_COMMON_ROOT)/umac/mlme/vdev_mgr/core/src/vdev_mlme_sm.o \
1533		$(WLAN_COMMON_ROOT)/umac/mlme/vdev_mgr/dispatcher/src/wlan_vdev_mlme_api.o \
1534		$(WLAN_COMMON_ROOT)/umac/mlme/vdev_mgr/core/src/vdev_mgr_ops.o \
1535		$(WLAN_COMMON_ROOT)/umac/mlme/vdev_mgr/dispatcher/src/wlan_vdev_mgr_tgt_if_rx_api.o \
1536		$(WLAN_COMMON_ROOT)/umac/mlme/vdev_mgr/dispatcher/src/wlan_vdev_mgr_tgt_if_tx_api.o \
1537		$(WLAN_COMMON_ROOT)/umac/mlme/vdev_mgr/dispatcher/src/wlan_vdev_mgr_ucfg_api.o \
1538		$(WLAN_COMMON_ROOT)/umac/mlme/vdev_mgr/dispatcher/src/wlan_vdev_mgr_api.o \
1539		$(WLAN_COMMON_ROOT)/umac/mlme/vdev_mgr/dispatcher/src/wlan_vdev_mgr_utils_api.o \
1540		$(WLAN_COMMON_ROOT)/umac/mlme/mlme_objmgr/dispatcher/src/wlan_cmn_mlme_main.o \
1541		$(WLAN_COMMON_ROOT)/umac/mlme/mlme_objmgr/dispatcher/src/wlan_pdev_mlme_main.o \
1542		$(WLAN_COMMON_ROOT)/umac/mlme/pdev_mgr/dispatcher/src/wlan_pdev_mlme_api.o \
1543		$(WLAN_COMMON_ROOT)/umac/mlme/mlme_objmgr/dispatcher/src/wlan_psoc_mlme_main.o \
1544		$(WLAN_COMMON_ROOT)/umac/mlme/psoc_mgr/dispatcher/src/wlan_psoc_mlme_api.o \
1545		$(WLAN_COMMON_ROOT)/umac/mlme/psoc_mgr/dispatcher/src/wlan_psoc_mlme_ucfg_api.o \
1546		$(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/core/src/wlan_cm_bss_scoring.o \
1547		$(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/core/src/wlan_cm_main.o \
1548		$(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/core/src/wlan_cm_sm.o \
1549		$(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/core/src/wlan_cm_roam_sm.o \
1550		$(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/core/src/wlan_cm_connect.o \
1551		$(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/core/src/wlan_cm_connect_scan.o \
1552		$(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/core/src/wlan_cm_disconnect.o \
1553		$(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/core/src/wlan_cm_util.o \
1554		$(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/dispatcher/src/wlan_cm_ucfg_api.o \
1555		$(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/dispatcher/src/wlan_cm_api.o \
1556		$(WLAN_COMMON_ROOT)/umac/mlme/mlme_utils/wlan_vdev_mlme_ser_if.o
1557ifeq ($(CONFIG_CM_UTF_ENABLE), y)
1558UMAC_MLME_OBJS += $(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/utf/src/wlan_cm_utf_main.o \
1559		$(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/utf/src/wlan_cm_utf_scan.o
1560endif
1561
1562ifeq ($(CONFIG_QCACLD_WLAN_LFR3), y)
1563# Add LFR3/FW roam specific connection manager files here
1564UMAC_MLME_OBJS += $(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/core/src/wlan_cm_roam_util.o
1565
1566endif
1567ifeq ($(CONFIG_QCACLD_WLAN_LFR2), y)
1568# Add LFR2/host roam specific connection manager files here
1569UMAC_MLME_OBJS += $(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/core/src/wlan_cm_roam_util.o \
1570		$(WLAN_COMMON_ROOT)/umac/mlme/connection_mgr/core/src/wlan_cm_host_roam.o
1571endif
1572
1573$(call add-wlan-objs,umac_mlme,$(UMAC_MLME_OBJS))
1574
1575######## MLME ##############
1576MLME_DIR := components/mlme
1577MLME_INC := -I$(WLAN_ROOT)/$(MLME_DIR)/core/inc \
1578		-I$(WLAN_ROOT)/$(MLME_DIR)/dispatcher/inc \
1579
1580MLME_OBJS :=	$(MLME_DIR)/core/src/wlan_mlme_main.o \
1581		$(MLME_DIR)/dispatcher/src/wlan_mlme_api.o \
1582		$(MLME_DIR)/dispatcher/src/wlan_mlme_ucfg_api.o
1583
1584MLME_OBJS += $(MLME_DIR)/core/src/wlan_mlme_vdev_mgr_interface.o
1585
1586ifeq ($(CONFIG_WLAN_FEATURE_TWT), y)
1587MLME_OBJS += $(MLME_DIR)/core/src/wlan_mlme_twt_api.o
1588MLME_OBJS += $(MLME_DIR)/dispatcher/src/wlan_mlme_twt_ucfg_api.o
1589endif
1590
1591CM_DIR := components/umac/mlme/connection_mgr
1592CM_TGT_IF_DIR := components/target_if/connection_mgr
1593
1594CM_INC := -I$(WLAN_ROOT)/$(CM_DIR)/dispatcher/inc \
1595		-I$(WLAN_ROOT)/$(CM_DIR)/utf/inc \
1596		-I$(WLAN_ROOT)/$(CM_TGT_IF_DIR)/inc
1597
1598MLME_INC += $(CM_INC)
1599
1600MLME_OBJS +=    $(CM_DIR)/dispatcher/src/wlan_cm_tgt_if_tx_api.o \
1601		$(CM_DIR)/dispatcher/src/wlan_cm_roam_api.o \
1602		$(CM_DIR)/dispatcher/src/wlan_cm_roam_ucfg_api.o \
1603		$(CM_TGT_IF_DIR)/src/target_if_cm_roam_offload.o \
1604		$(CM_TGT_IF_DIR)/src/target_if_cm_roam_event.o \
1605		$(CM_DIR)/core/src/wlan_cm_roam_offload.o \
1606		$(CM_DIR)/core/src/wlan_cm_vdev_connect.o \
1607		$(CM_DIR)/core/src/wlan_cm_vdev_disconnect.o
1608
1609ifeq ($(CONFIG_CM_UTF_ENABLE), y)
1610MLME_OBJS +=    $(CM_DIR)/utf/src/cm_utf.o
1611endif
1612
1613ifeq ($(CONFIG_QCACLD_WLAN_LFR3), y)
1614MLME_OBJS +=    $(CM_DIR)/core/src/wlan_cm_roam_fw_sync.o \
1615		$(CM_DIR)/core/src/wlan_cm_roam_offload_event.o
1616endif
1617
1618ifeq ($(CONFIG_QCACLD_WLAN_LFR2), y)
1619# Add LFR2/host roam specific connection manager files here
1620MLME_OBJS +=    $(CM_DIR)/core/src/wlan_cm_host_roam_preauth.o \
1621		$(CM_DIR)/core/src/wlan_cm_host_util.o
1622endif
1623
1624####### WFA_CONFIG ########
1625
1626WFA_DIR := components/umac/mlme/wfa_config
1627WFA_TGT_IF_DIR := components/target_if/wfa_config
1628
1629WFA_INC := -I$(WLAN_ROOT)/$(WFA_DIR)/dispatcher/inc \
1630		-I$(WLAN_ROOT)/$(WFA_TGT_IF_DIR)/inc
1631
1632MLME_INC += $(WFA_INC)
1633
1634MLME_OBJS += $(WFA_TGT_IF_DIR)/src/target_if_wfa_testcmd.o \
1635		$(WFA_DIR)/dispatcher/src/wlan_wfa_tgt_if_tx_api.o
1636
1637####### LL_SAP #######
1638LL_SAP_DIR := components/umac/mlme/sap/ll_sap
1639LL_SAP_OS_IF_DIR := os_if/mlme/sap/ll_sap
1640LL_SAP_TARGET_IF_DIR := components/target_if/sap/ll_sap
1641LL_SAP_WMI_DIR := components/wmi/
1642
1643LL_SAP_INC := -I$(WLAN_ROOT)/$(LL_SAP_DIR)/dispatcher/inc \
1644		-I$(WLAN_ROOT)/$(LL_SAP_OS_IF_DIR)/inc \
1645		-I$(WLAN_ROOT)/$(LL_SAP_TARGET_IF_DIR)/inc \
1646		-I$(WLAN_ROOT)/$(LL_SAP_WMI_DIR)/inc
1647
1648MLME_INC += $(LL_SAP_INC)
1649
1650ifeq ($(CONFIG_WLAN_FEATURE_LL_LT_SAP), y)
1651MLME_OBJS += $(LL_SAP_DIR)/dispatcher/src/wlan_ll_sap_ucfg_api.o \
1652		$(LL_SAP_DIR)/dispatcher/src/wlan_ll_sap_api.o \
1653		$(LL_SAP_DIR)/core/src/wlan_ll_sap_main.o \
1654		$(LL_SAP_DIR)/core/src/wlan_ll_lt_sap_main.o \
1655		$(LL_SAP_DIR)/core/src/wlan_ll_lt_sap_bearer_switch.o \
1656		$(LL_SAP_OS_IF_DIR)/src/os_if_ll_sap.o \
1657		$(LL_SAP_TARGET_IF_DIR)/src/target_if_ll_sap.o \
1658		$(LL_SAP_WMI_DIR)/src/wmi_unified_ll_sap_api.o \
1659		$(LL_SAP_WMI_DIR)/src/wmi_unified_ll_sap_tlv.o
1660endif
1661
1662$(call add-wlan-objs,mlme,$(MLME_OBJS))
1663
1664####### DENYLIST_MGR ########
1665
1666DLM_DIR := components/denylist_mgr
1667DLM_INC := -I$(WLAN_ROOT)/$(DLM_DIR)/core/inc \
1668                -I$(WLAN_ROOT)/$(DLM_DIR)/dispatcher/inc
1669ifeq ($(CONFIG_FEATURE_DENYLIST_MGR), y)
1670DLM_OBJS :=    $(DLM_DIR)/core/src/wlan_dlm_main.o \
1671                $(DLM_DIR)/core/src/wlan_dlm_core.o \
1672                $(DLM_DIR)/dispatcher/src/wlan_dlm_ucfg_api.o \
1673                $(DLM_DIR)/dispatcher/src/wlan_dlm_tgt_api.o
1674endif
1675
1676$(call add-wlan-objs,dlm,$(DLM_OBJS))
1677
1678######### CONNECTIVITY_LOGGING #########
1679CONN_LOGGING_DIR := components/cmn_services/logging
1680CONN_LOGGING_INC := -I$(WLAN_ROOT)/$(CONN_LOGGING_DIR)/inc
1681
1682ifeq ($(CONFIG_QCACLD_WLAN_CONNECTIVITY_DIAG_EVENT), y)
1683CONN_LOGGING_OBJS := $(CONN_LOGGING_DIR)/src/wlan_connectivity_logging.o
1684else ifeq ($(CONFIG_QCACLD_WLAN_CONNECTIVITY_LOGGING), y)
1685CONN_LOGGING_OBJS := $(CONN_LOGGING_DIR)/src/wlan_connectivity_logging.o
1686endif
1687
1688$(call add-wlan-objs,conn_logging,$(CONN_LOGGING_OBJS))
1689
1690########## ACTION OUI ##########
1691
1692ACTION_OUI_DIR := components/action_oui
1693ACTION_OUI_INC := -I$(WLAN_ROOT)/$(ACTION_OUI_DIR)/core/inc \
1694		  -I$(WLAN_ROOT)/$(ACTION_OUI_DIR)/dispatcher/inc
1695
1696ifeq ($(CONFIG_WLAN_FEATURE_ACTION_OUI), y)
1697ACTION_OUI_OBJS := $(ACTION_OUI_DIR)/core/src/wlan_action_oui_main.o \
1698		$(ACTION_OUI_DIR)/core/src/wlan_action_oui_parse.o \
1699		$(ACTION_OUI_DIR)/dispatcher/src/wlan_action_oui_tgt_api.o \
1700		$(ACTION_OUI_DIR)/dispatcher/src/wlan_action_oui_ucfg_api.o
1701endif
1702
1703$(call add-wlan-objs,action_oui,$(ACTION_OUI_OBJS))
1704
1705######## PACKET CAPTURE ########
1706
1707PKT_CAPTURE_DIR := components/pkt_capture
1708PKT_CAPTURE_OS_IF_DIR := os_if/pkt_capture
1709PKT_CAPTURE_TARGET_IF_DIR := components/target_if/pkt_capture/
1710PKT_CAPTURE_INC := -I$(WLAN_ROOT)/$(PKT_CAPTURE_DIR)/core/inc \
1711		  -I$(WLAN_ROOT)/$(PKT_CAPTURE_DIR)/dispatcher/inc \
1712		  -I$(WLAN_ROOT)/$(PKT_CAPTURE_TARGET_IF_DIR)/inc \
1713		  -I$(WLAN_ROOT)/$(PKT_CAPTURE_OS_IF_DIR)/inc
1714
1715ifeq ($(CONFIG_WLAN_FEATURE_PKT_CAPTURE), y)
1716PKT_CAPTURE_OBJS := $(PKT_CAPTURE_DIR)/core/src/wlan_pkt_capture_main.o \
1717		$(PKT_CAPTURE_DIR)/core/src/wlan_pkt_capture_mon_thread.o \
1718		$(PKT_CAPTURE_DIR)/core/src/wlan_pkt_capture_mgmt_txrx.o \
1719		$(PKT_CAPTURE_DIR)/core/src/wlan_pkt_capture_data_txrx.o \
1720		$(PKT_CAPTURE_DIR)/dispatcher/src/wlan_pkt_capture_ucfg_api.o \
1721		$(PKT_CAPTURE_DIR)/dispatcher/src/wlan_pkt_capture_tgt_api.o \
1722		$(PKT_CAPTURE_DIR)/dispatcher/src/wlan_pkt_capture_api.o \
1723		$(PKT_CAPTURE_TARGET_IF_DIR)/src/target_if_pkt_capture.o \
1724		$(PKT_CAPTURE_OS_IF_DIR)/src/os_if_pkt_capture.o
1725endif
1726
1727$(call add-wlan-objs,pkt_capture,$(PKT_CAPTURE_OBJS))
1728
1729########## FTM TIME SYNC ##########
1730
1731FTM_TIME_SYNC_DIR := components/ftm_time_sync
1732FTM_TIME_SYNC_INC := -I$(WLAN_ROOT)/$(FTM_TIME_SYNC_DIR)/core/inc \
1733		  -I$(WLAN_ROOT)/$(FTM_TIME_SYNC_DIR)/dispatcher/inc
1734
1735ifeq ($(CONFIG_FEATURE_WLAN_TIME_SYNC_FTM), y)
1736FTM_TIME_SYNC_OBJS := $(FTM_TIME_SYNC_DIR)/core/src/ftm_time_sync_main.o \
1737		$(FTM_TIME_SYNC_DIR)/dispatcher/src/ftm_time_sync_ucfg_api.o \
1738		$(FTM_TIME_SYNC_DIR)/dispatcher/src/wlan_ftm_time_sync_tgt_api.o
1739endif
1740
1741$(call add-wlan-objs,ftm_time_sync,$(FTM_TIME_SYNC_OBJS))
1742
1743########## WLAN PRE_CAC ##########
1744
1745WLAN_PRE_CAC_DIR := components/pre_cac
1746PRE_CAC_OSIF_DIR := os_if/pre_cac
1747WLAN_PRE_CAC_INC := -I$(WLAN_ROOT)/$(WLAN_PRE_CAC_DIR)/dispatcher/inc \
1748		  -I$(WLAN_ROOT)/$(WLAN_PRE_CAC_DIR)/core/src \
1749		  -I$(WLAN_ROOT)/$(PRE_CAC_OSIF_DIR)/inc
1750
1751ifeq ($(CONFIG_FEATURE_WLAN_PRE_CAC), y)
1752WLAN_PRE_CAC_OBJS := $(HDD_SRC_DIR)/wlan_hdd_pre_cac.o \
1753		$(WLAN_PRE_CAC_DIR)/core/src/wlan_pre_cac_main.o \
1754		$(WLAN_PRE_CAC_DIR)/dispatcher/src/wlan_pre_cac_ucfg_api.o \
1755		$(WLAN_PRE_CAC_DIR)/dispatcher/src/wlan_pre_cac_api.o \
1756		$(PRE_CAC_OSIF_DIR)/src/osif_pre_cac.o
1757endif
1758
1759$(call add-wlan-objs,wlan_pre_cac,$(WLAN_PRE_CAC_OBJS))
1760
1761########## CLD TARGET_IF #######
1762CLD_TARGET_IF_DIR := components/target_if
1763
1764CLD_TARGET_IF_INC := -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/pmo/inc \
1765		     -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/mlme/inc \
1766
1767ifeq ($(CONFIG_QCA_TARGET_IF_MLME), y)
1768CLD_TARGET_IF_OBJ := $(CLD_TARGET_IF_DIR)/mlme/src/target_if_mlme.o
1769endif
1770
1771ifeq ($(CONFIG_POWER_MANAGEMENT_OFFLOAD), y)
1772CLD_TARGET_IF_OBJ += $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_arp.o \
1773		$(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_gtk.o \
1774		$(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_hw_filter.o \
1775		$(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_lphb.o \
1776		$(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_main.o \
1777		$(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_mc_addr_filtering.o \
1778		$(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_static_config.o \
1779		$(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_suspend_resume.o \
1780		$(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_wow.o
1781ifeq ($(CONFIG_WLAN_NS_OFFLOAD), y)
1782CLD_TARGET_IF_OBJ += $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_ns.o
1783endif
1784ifeq ($(CONFIG_WLAN_FEATURE_PACKET_FILTERING), y)
1785CLD_TARGET_IF_OBJ += $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_pkt_filter.o
1786endif
1787ifeq ($(CONFIG_WLAN_FEATURE_ICMP_OFFLOAD), y)
1788CLD_TARGET_IF_OBJ += $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_icmp.o
1789endif
1790endif
1791
1792ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
1793CLD_TARGET_IF_INC += -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/ocb/inc
1794CLD_TARGET_IF_OBJ += $(CLD_TARGET_IF_DIR)/ocb/src/target_if_ocb.o
1795endif
1796
1797ifeq ($(CONFIG_WLAN_FEATURE_DISA), y)
1798CLD_TARGET_IF_INC += -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/disa/inc
1799CLD_TARGET_IF_OBJ += $(CLD_TARGET_IF_DIR)/disa/src/target_if_disa.o
1800endif
1801
1802ifeq ($(CONFIG_FEATURE_DENYLIST_MGR), y)
1803CLD_TARGET_IF_INC += -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/denylist_mgr/inc
1804CLD_TARGET_IF_OBJ += $(CLD_TARGET_IF_DIR)/denylist_mgr/src/target_if_dlm.o
1805endif
1806
1807ifeq ($(CONFIG_WLAN_FEATURE_ACTION_OUI), y)
1808CLD_TARGET_IF_INC += -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/action_oui/inc
1809CLD_TARGET_IF_OBJ += $(CLD_TARGET_IF_DIR)/action_oui/src/target_if_action_oui.o
1810endif
1811
1812ifeq ($(CONFIG_FEATURE_WLAN_TIME_SYNC_FTM), y)
1813CLD_TARGET_IF_INC += -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/ftm_time_sync/inc
1814CLD_TARGET_IF_OBJ += $(CLD_TARGET_IF_DIR)/ftm_time_sync/src/target_if_ftm_time_sync.o
1815endif
1816
1817$(call add-wlan-objs,cld_target_if,$(CLD_TARGET_IF_OBJ))
1818
1819############## UMAC P2P ###########
1820P2P_DIR := components/p2p
1821P2P_CORE_OBJ_DIR := $(P2P_DIR)/core/src
1822P2P_DISPATCHER_DIR := $(P2P_DIR)/dispatcher
1823P2P_DISPATCHER_INC_DIR := $(P2P_DISPATCHER_DIR)/inc
1824P2P_DISPATCHER_OBJ_DIR := $(P2P_DISPATCHER_DIR)/src
1825P2P_OS_IF_INC := os_if/p2p/inc
1826P2P_OS_IF_SRC := os_if/p2p/src
1827P2P_TARGET_IF_INC := components/target_if/p2p/inc
1828P2P_TARGET_IF_SRC := components/target_if/p2p/src
1829P2P_INC := -I$(WLAN_ROOT)/$(P2P_DISPATCHER_INC_DIR) \
1830	   -I$(WLAN_ROOT)/$(P2P_OS_IF_INC) \
1831	   -I$(WLAN_ROOT)/$(P2P_TARGET_IF_INC)
1832P2P_OBJS := $(P2P_DISPATCHER_OBJ_DIR)/wlan_p2p_ucfg_api.o \
1833	    $(P2P_DISPATCHER_OBJ_DIR)/wlan_p2p_tgt_api.o \
1834	    $(P2P_DISPATCHER_OBJ_DIR)/wlan_p2p_cfg.o \
1835	    $(P2P_DISPATCHER_OBJ_DIR)/wlan_p2p_api.o \
1836	    $(P2P_CORE_OBJ_DIR)/wlan_p2p_main.o \
1837	    $(P2P_CORE_OBJ_DIR)/wlan_p2p_roc.o \
1838	    $(P2P_CORE_OBJ_DIR)/wlan_p2p_off_chan_tx.o \
1839	    $(P2P_OS_IF_SRC)/wlan_cfg80211_p2p.o \
1840	    $(P2P_TARGET_IF_SRC)/target_if_p2p.o
1841ifeq ($(CONFIG_WLAN_FEATURE_MCC_QUOTA), y)
1842P2P_OBJS += $(P2P_DISPATCHER_OBJ_DIR)/wlan_p2p_mcc_quota_tgt_api.o \
1843	    $(P2P_CORE_OBJ_DIR)/wlan_p2p_mcc_quota.o \
1844	    $(P2P_TARGET_IF_SRC)/target_if_p2p_mcc_quota.o
1845endif
1846$(call add-wlan-objs,p2p,$(P2P_OBJS))
1847
1848###### UMAC POLICY MGR ########
1849POLICY_MGR_DIR := components/cmn_services/policy_mgr
1850
1851POLICY_MGR_INC := -I$(WLAN_ROOT)/$(POLICY_MGR_DIR)/inc \
1852		  -I$(WLAN_ROOT)/$(POLICY_MGR_DIR)/src
1853
1854POLICY_MGR_OBJS := $(POLICY_MGR_DIR)/src/wlan_policy_mgr_action.o \
1855	$(POLICY_MGR_DIR)/src/wlan_policy_mgr_core.o \
1856	$(POLICY_MGR_DIR)/src/wlan_policy_mgr_get_set_utils.o \
1857	$(POLICY_MGR_DIR)/src/wlan_policy_mgr_init_deinit.o \
1858	$(POLICY_MGR_DIR)/src/wlan_policy_mgr_ucfg.o \
1859	$(POLICY_MGR_DIR)/src/wlan_policy_mgr_pcl.o
1860ifeq ($(CONFIG_WLAN_FEATURE_LL_LT_SAP), y)
1861POLICY_MGR_OBJS += $(POLICY_MGR_DIR)/src/wlan_policy_mgr_ll_sap.o
1862endif
1863
1864$(call add-wlan-objs,policy_mgr,$(POLICY_MGR_OBJS))
1865
1866###### UMAC TDLS ########
1867TDLS_DIR := components/tdls
1868
1869TDLS_OS_IF_INC := os_if/tdls/inc
1870TDLS_OS_IF_SRC := os_if/tdls/src
1871TDLS_TARGET_IF_INC := components/target_if/tdls/inc
1872TDLS_TARGET_IF_SRC := components/target_if/tdls/src
1873TDLS_INC := -I$(WLAN_ROOT)/$(TDLS_DIR)/dispatcher/inc \
1874	    -I$(WLAN_ROOT)/$(TDLS_DIR)/core/src \
1875	    -I$(WLAN_ROOT)/$(TDLS_OS_IF_INC) \
1876	    -I$(WLAN_ROOT)/$(TDLS_TARGET_IF_INC)
1877
1878ifeq ($(CONFIG_QCOM_TDLS), y)
1879TDLS_OBJS := $(TDLS_DIR)/core/src/wlan_tdls_main.o \
1880       $(TDLS_DIR)/core/src/wlan_tdls_cmds_process.o \
1881       $(TDLS_DIR)/core/src/wlan_tdls_peer.o \
1882       $(TDLS_DIR)/core/src/wlan_tdls_mgmt.o \
1883       $(TDLS_DIR)/core/src/wlan_tdls_ct.o \
1884       $(TDLS_DIR)/dispatcher/src/wlan_tdls_tgt_api.o \
1885       $(TDLS_DIR)/dispatcher/src/wlan_tdls_ucfg_api.o \
1886       $(TDLS_DIR)/dispatcher/src/wlan_tdls_utils_api.o \
1887       $(TDLS_DIR)/dispatcher/src/wlan_tdls_cfg.o \
1888       $(TDLS_DIR)/dispatcher/src/wlan_tdls_api.o \
1889       $(TDLS_OS_IF_SRC)/wlan_cfg80211_tdls.o \
1890       $(TDLS_TARGET_IF_SRC)/target_if_tdls.o
1891endif
1892
1893$(call add-wlan-objs,tdls,$(TDLS_OBJS))
1894
1895########### BMI ###########
1896BMI_DIR := core/bmi
1897
1898BMI_INC := -I$(WLAN_ROOT)/$(BMI_DIR)/inc
1899
1900ifeq ($(CONFIG_WLAN_FEATURE_BMI), y)
1901BMI_OBJS := $(BMI_DIR)/src/bmi.o \
1902            $(BMI_DIR)/src/bmi_1.o \
1903            $(BMI_DIR)/src/ol_fw.o \
1904            $(BMI_DIR)/src/ol_fw_common.o
1905endif
1906
1907$(call add-wlan-objs,bmi,$(BMI_OBJS))
1908
1909##########  TARGET_IF #######
1910TARGET_IF_DIR := $(WLAN_COMMON_ROOT)/target_if
1911
1912TARGET_IF_INC := -I$(WLAN_COMMON_INC)/target_if/core/inc \
1913		 -I$(WLAN_COMMON_INC)/target_if/init_deinit/inc \
1914		 -I$(WLAN_COMMON_INC)/target_if/crypto/inc \
1915		 -I$(WLAN_COMMON_INC)/target_if/regulatory/inc \
1916		 -I$(WLAN_COMMON_INC)/target_if/mlme/vdev_mgr/inc \
1917		 -I$(WLAN_COMMON_INC)/target_if/dispatcher/inc \
1918		 -I$(WLAN_COMMON_INC)/target_if/mlme/psoc/inc \
1919		 -I$(WLAN_COMMON_INC)/target_if/ipa/inc
1920
1921TARGET_IF_OBJ := $(TARGET_IF_DIR)/core/src/target_if_main.o \
1922		$(TARGET_IF_DIR)/regulatory/src/target_if_reg.o \
1923		$(TARGET_IF_DIR)/regulatory/src/target_if_reg_lte.o \
1924		$(TARGET_IF_DIR)/regulatory/src/target_if_reg_11d.o \
1925		$(TARGET_IF_DIR)/init_deinit/src/init_cmd_api.o \
1926		$(TARGET_IF_DIR)/init_deinit/src/init_deinit_lmac.o \
1927		$(TARGET_IF_DIR)/init_deinit/src/init_event_handler.o \
1928		$(TARGET_IF_DIR)/init_deinit/src/service_ready_util.o \
1929		$(TARGET_IF_DIR)/mlme/vdev_mgr/src/target_if_vdev_mgr_tx_ops.o \
1930		$(TARGET_IF_DIR)/mlme/vdev_mgr/src/target_if_vdev_mgr_rx_ops.o \
1931		$(TARGET_IF_DIR)/mlme/psoc/src/target_if_psoc_timer_tx_ops.o
1932
1933ifeq ($(CONFIG_FEATURE_VDEV_OPS_WAKELOCK), y)
1934TARGET_IF_OBJ += $(TARGET_IF_DIR)/mlme/psoc/src/target_if_psoc_wake_lock.o
1935endif
1936
1937TARGET_IF_OBJ += $(TARGET_IF_DIR)/crypto/src/target_if_crypto.o
1938
1939ifeq ($(CONFIG_IPA_OFFLOAD), y)
1940TARGET_IF_OBJ += $(TARGET_IF_DIR)/ipa/src/target_if_ipa.o
1941endif
1942
1943$(call add-wlan-objs,target_if,$(TARGET_IF_OBJ))
1944
1945########### GLOBAL_LMAC_IF ##########
1946GLOBAL_LMAC_IF_DIR := $(WLAN_COMMON_ROOT)/global_lmac_if
1947
1948GLOBAL_LMAC_IF_INC := -I$(WLAN_COMMON_INC)/global_lmac_if/inc \
1949
1950GLOBAL_LMAC_IF_OBJ := $(GLOBAL_LMAC_IF_DIR)/src/wlan_global_lmac_if.o
1951
1952$(call add-wlan-objs,global_lmac_if,$(GLOBAL_LMAC_IF_OBJ))
1953
1954########### WMI ###########
1955WMI_ROOT_DIR := wmi
1956
1957WMI_SRC_DIR := $(WMI_ROOT_DIR)/src
1958WMI_INC_DIR := $(WMI_ROOT_DIR)/inc
1959WMI_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(WMI_SRC_DIR)
1960
1961WMI_INC := -I$(WLAN_COMMON_INC)/$(WMI_INC_DIR)
1962
1963WMI_OBJS := $(WMI_OBJ_DIR)/wmi_unified.o \
1964	    $(WMI_OBJ_DIR)/wmi_tlv_helper.o \
1965	    $(WMI_OBJ_DIR)/wmi_unified_tlv.o \
1966	    $(WMI_OBJ_DIR)/wmi_unified_api.o \
1967	    $(WMI_OBJ_DIR)/wmi_unified_reg_api.o \
1968	    $(WMI_OBJ_DIR)/wmi_unified_vdev_api.o \
1969	    $(WMI_OBJ_DIR)/wmi_unified_vdev_tlv.o \
1970	    $(WMI_OBJ_DIR)/wmi_unified_crypto_api.o
1971
1972ifeq ($(CONFIG_POWER_MANAGEMENT_OFFLOAD), y)
1973WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_pmo_api.o
1974WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_pmo_tlv.o
1975endif
1976
1977ifeq ($(CONFIG_QCACLD_FEATURE_APF), y)
1978WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_apf_tlv.o
1979endif
1980
1981ifeq ($(CONFIG_WLAN_FEATURE_ACTION_OUI), y)
1982WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_action_oui_tlv.o
1983endif
1984
1985ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
1986ifeq ($(CONFIG_OCB_UT_FRAMEWORK), y)
1987WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_ocb_ut.o
1988endif
1989endif
1990
1991ifeq ($(CONFIG_WLAN_DFS_MASTER_ENABLE), y)
1992WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_dfs_api.o
1993endif
1994
1995ifeq ($(CONFIG_WLAN_FEATURE_TWT), y)
1996WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_twt_api.o
1997WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_twt_tlv.o
1998endif
1999
2000ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
2001WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_ocb_api.o
2002WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_ocb_tlv.o
2003endif
2004
2005ifeq ($(CONFIG_FEATURE_WLAN_EXTSCAN), y)
2006WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_extscan_api.o
2007WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_extscan_tlv.o
2008endif
2009
2010ifeq ($(CONFIG_FEATURE_INTEROP_ISSUES_AP), y)
2011WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_interop_issues_ap_api.o
2012WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_interop_issues_ap_tlv.o
2013endif
2014
2015ifeq ($(CONFIG_DCS), y)
2016WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_dcs_api.o
2017WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_dcs_tlv.o
2018endif
2019
2020ifeq ($(CONFIG_QCACLD_FEATURE_NAN), y)
2021WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_nan_api.o
2022WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_nan_tlv.o
2023endif
2024
2025ifeq ($(CONFIG_CONVERGED_P2P_ENABLE), y)
2026WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_p2p_api.o
2027WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_p2p_tlv.o
2028endif
2029
2030ifeq ($(CONFIG_WMI_CONCURRENCY_SUPPORT), y)
2031WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_concurrency_api.o
2032WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_concurrency_tlv.o
2033endif
2034
2035ifeq ($(CONFIG_WMI_STA_SUPPORT), y)
2036WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_sta_api.o
2037WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_sta_tlv.o
2038endif
2039
2040ifeq ($(CONFIG_WMI_BCN_OFFLOAD), y)
2041WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_bcn_api.o
2042WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_bcn_tlv.o
2043endif
2044
2045ifeq ($(CONFIG_WLAN_FW_OFFLOAD), y)
2046WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_fwol_api.o
2047WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_fwol_tlv.o
2048endif
2049
2050ifeq ($(CONFIG_WLAN_HANG_EVENT), y)
2051WMI_OBJS += $(WMI_OBJ_DIR)/wmi_hang_event.o
2052endif
2053
2054ifeq ($(CONFIG_WLAN_CFR_ENABLE), y)
2055WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_cfr_tlv.o
2056WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_cfr_api.o
2057endif
2058
2059ifeq ($(CONFIG_CP_STATS), y)
2060WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_cp_stats_api.o
2061WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_cp_stats_tlv.o
2062endif
2063
2064ifeq ($(CONFIG_FEATURE_GPIO_CFG), y)
2065WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_gpio_api.o
2066WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_gpio_tlv.o
2067endif
2068
2069ifeq ($(CONFIG_WLAN_FEATURE_11BE_MLO), y)
2070WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_11be_tlv.o
2071WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_11be_api.o
2072endif
2073
2074ifeq ($(CONFIG_FEATURE_WDS), y)
2075WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_wds_api.o
2076WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_wds_tlv.o
2077endif
2078
2079$(call add-wlan-objs,wmi,$(WMI_OBJS))
2080
2081########### FWLOG ###########
2082FWLOG_DIR := $(WLAN_COMMON_ROOT)/utils/fwlog
2083
2084FWLOG_INC := -I$(WLAN_ROOT)/$(FWLOG_DIR)
2085
2086ifeq ($(CONFIG_FEATURE_FW_LOG_PARSING), y)
2087FWLOG_OBJS := $(FWLOG_DIR)/dbglog_host.o
2088endif
2089
2090$(call add-wlan-objs,fwlog,$(FWLOG_OBJS))
2091
2092############ TXRX ############
2093TXRX_DIR :=     core/dp/txrx
2094TXRX_INC :=     -I$(WLAN_ROOT)/$(TXRX_DIR)
2095
2096TXRX_OBJS :=
2097ifeq ($(CONFIG_WDI_EVENT_ENABLE), y)
2098TXRX_OBJS += 	$(TXRX_DIR)/ol_txrx_event.o
2099endif
2100
2101ifneq (y,$(filter y,$(CONFIG_LITHIUM) $(CONFIG_BERYLLIUM) $(CONFIG_RHINE)))
2102TXRX_OBJS += $(TXRX_DIR)/ol_txrx.o \
2103		$(TXRX_DIR)/ol_cfg.o \
2104                $(TXRX_DIR)/ol_rx.o \
2105                $(TXRX_DIR)/ol_rx_fwd.o \
2106                $(TXRX_DIR)/ol_txrx.o \
2107                $(TXRX_DIR)/ol_rx_defrag.o \
2108                $(TXRX_DIR)/ol_tx_desc.o \
2109                $(TXRX_DIR)/ol_tx.o \
2110                $(TXRX_DIR)/ol_rx_reorder_timeout.o \
2111                $(TXRX_DIR)/ol_rx_reorder.o \
2112                $(TXRX_DIR)/ol_rx_pn.o \
2113                $(TXRX_DIR)/ol_txrx_peer_find.o \
2114                $(TXRX_DIR)/ol_txrx_encap.o \
2115                $(TXRX_DIR)/ol_tx_send.o
2116
2117ifeq ($(CONFIG_LL_DP_SUPPORT), y)
2118
2119TXRX_OBJS +=     $(TXRX_DIR)/ol_tx_ll.o
2120
2121ifeq ($(CONFIG_WLAN_FASTPATH), y)
2122TXRX_OBJS +=     $(TXRX_DIR)/ol_tx_ll_fastpath.o
2123else
2124TXRX_OBJS +=     $(TXRX_DIR)/ol_tx_ll_legacy.o
2125endif
2126
2127ifeq ($(CONFIG_WLAN_TX_FLOW_CONTROL_V2), y)
2128TXRX_OBJS +=     $(TXRX_DIR)/ol_txrx_flow_control.o
2129endif
2130
2131endif #CONFIG_LL_DP_SUPPORT
2132
2133ifeq ($(CONFIG_HL_DP_SUPPORT), y)
2134TXRX_OBJS +=     $(TXRX_DIR)/ol_tx_hl.o
2135TXRX_OBJS +=     $(TXRX_DIR)/ol_tx_classify.o
2136TXRX_OBJS +=     $(TXRX_DIR)/ol_tx_sched.o
2137TXRX_OBJS +=     $(TXRX_DIR)/ol_tx_queue.o
2138endif #CONFIG_HL_DP_SUPPORT
2139
2140ifeq ($(CONFIG_WLAN_TX_FLOW_CONTROL_LEGACY), y)
2141TXRX_OBJS +=     $(TXRX_DIR)/ol_txrx_legacy_flow_control.o
2142endif
2143
2144ifeq ($(CONFIG_IPA_OFFLOAD), y)
2145TXRX_OBJS +=     $(TXRX_DIR)/ol_txrx_ipa.o
2146endif
2147
2148ifeq ($(CONFIG_QCA_SUPPORT_TX_THROTTLE), y)
2149TXRX_OBJS +=     $(TXRX_DIR)/ol_tx_throttle.o
2150endif
2151endif #LITHIUM/BERYLLIUM/RHINE
2152
2153$(call add-wlan-objs,txrx,$(TXRX_OBJS))
2154
2155ifeq (y,$(filter y,$(CONFIG_LITHIUM) $(CONFIG_BERYLLIUM) $(CONFIG_RHINE)))
2156############ DP 3.0 ############
2157DP_INC := -I$(WLAN_COMMON_INC)/dp/inc \
2158	-I$(WLAN_COMMON_INC)/dp/wifi3.0 \
2159	-I$(WLAN_COMMON_INC)/target_if/dp/inc \
2160	-I$(WLAN_COMMON_INC)/dp/cmn_dp_api
2161
2162DP_SRC := $(WLAN_COMMON_ROOT)/dp/wifi3.0
2163DP_OBJS := $(DP_SRC)/dp_main.o \
2164		$(DP_SRC)/dp_tx.o \
2165		$(DP_SRC)/dp_arch_ops.o \
2166		$(DP_SRC)/dp_tx_desc.o \
2167		$(DP_SRC)/dp_rx.o \
2168		$(DP_SRC)/dp_htt.o \
2169		$(DP_SRC)/dp_peer.o \
2170		$(DP_SRC)/dp_rx_desc.o \
2171		$(DP_SRC)/dp_rx_defrag.o \
2172		$(DP_SRC)/dp_stats.o \
2173		$(WLAN_COMMON_ROOT)/target_if/dp/src/target_if_dp.o
2174
2175ifneq ($(CONFIG_RHINE), y)
2176DP_OBJS += $(DP_SRC)/dp_rings_main.o
2177DP_OBJS += $(DP_SRC)/dp_reo.o
2178DP_OBJS += $(DP_SRC)/dp_rx_err.o
2179DP_OBJS += $(DP_SRC)/dp_rx_tid.o
2180endif
2181
2182ifeq ($(CONFIG_WIFI_MONITOR_SUPPORT), y)
2183DP_INC += -I$(WLAN_COMMON_INC)/dp/wifi3.0/monitor \
2184	-I$(WLAN_COMMON_INC)/dp/wifi3.0/monitor/1.0 \
2185	-I$(WLAN_COMMON_INC)/dp/wifi3.0/monitor/2.0 \
2186
2187DP_OBJS += $(DP_SRC)/monitor/dp_mon.o \
2188		$(DP_SRC)/monitor/dp_mon_filter.o \
2189		$(DP_SRC)/monitor/dp_rx_mon.o \
2190		$(DP_SRC)/monitor/1.0/dp_rx_mon_dest_1.0.o \
2191		$(DP_SRC)/monitor/1.0/dp_rx_mon_status_1.0.o \
2192		$(DP_SRC)/monitor/1.0/dp_mon_filter_1.0.o \
2193		$(DP_SRC)/monitor/1.0/dp_mon_1.0.o
2194endif
2195
2196DP_OBJS += $(DP_SRC)/../cmn_dp_api/dp_ratetable.o
2197
2198ifeq ($(CONFIG_BERYLLIUM), y)
2199DP_INC += -I$(WLAN_COMMON_INC)/dp/wifi3.0/be
2200
2201DP_OBJS += $(DP_SRC)/be/dp_be.o
2202DP_OBJS += $(DP_SRC)/be/dp_be_tx.o
2203DP_OBJS += $(DP_SRC)/be/dp_be_rx.o
2204
2205ifeq ($(CONFIG_WIFI_MONITOR_SUPPORT), y)
2206ifeq ($(CONFIG_WLAN_TX_MON_2_0), y)
2207DP_OBJS += $(DP_SRC)/monitor/2.0/dp_mon_2.0.o \
2208		$(DP_SRC)/monitor/2.0/dp_mon_filter_2.0.o
2209DP_OBJS += $(DP_SRC)/monitor/2.0/dp_tx_mon_2.0.o \
2210		$(DP_SRC)/monitor/2.0/dp_tx_mon_status_2.0.o
2211ccflags-$(CONFIG_WLAN_TX_MON_2_0) += -DWLAN_PKT_CAPTURE_TX_2_0
2212ccflags-y += -DWLAN_TX_PKT_CAPTURE_ENH_BE
2213ccflags-y += -DQDF_FRAG_CACHE_SUPPORT
2214endif
2215endif
2216endif
2217
2218ifeq ($(CONFIG_LITHIUM), y)
2219DP_OBJS += $(DP_SRC)/li/dp_li.o
2220DP_OBJS += $(DP_SRC)/li/dp_li_tx.o
2221DP_OBJS += $(DP_SRC)/li/dp_li_rx.o
2222endif
2223
2224ifeq ($(CONFIG_RHINE), y)
2225DP_OBJS += $(DP_SRC)/rh/dp_rh.o
2226DP_OBJS += $(DP_SRC)/rh/dp_rh_tx.o
2227DP_OBJS += $(DP_SRC)/rh/dp_rh_rx.o
2228DP_OBJS += $(DP_SRC)/rh/dp_rh_htt.o
2229endif
2230
2231ifeq ($(CONFIG_WLAN_TX_FLOW_CONTROL_V2), y)
2232DP_OBJS += $(DP_SRC)/dp_tx_flow_control.o
2233endif
2234
2235ifeq ($(CONFIG_WLAN_FEATURE_RX_BUFFER_POOL), y)
2236DP_OBJS += $(DP_SRC)/dp_rx_buffer_pool.o
2237endif
2238
2239ifeq ($(CONFIG_IPA_OFFLOAD), y)
2240DP_OBJS +=     $(DP_SRC)/dp_ipa.o
2241endif
2242
2243ifeq ($(CONFIG_WDI_EVENT_ENABLE), y)
2244DP_OBJS +=     $(DP_SRC)/dp_wdi_event.o
2245endif
2246
2247ifeq ($(CONFIG_FEATURE_MEC), y)
2248DP_OBJS += $(DP_SRC)/dp_txrx_wds.o
2249endif
2250
2251ifeq ($(CONFIG_QCACLD_FEATURE_SON), y)
2252DP_OBJS += $(WLAN_COMMON_ROOT)/dp/cmn_dp_api/dp_ratetable.o
2253DP_INC += -I$(WLAN_COMMON_INC)/dp/cmn_dp_api
2254endif
2255
2256endif #LITHIUM
2257
2258$(call add-wlan-objs,dp,$(DP_OBJS))
2259
2260############ CFG ############
2261WCFG_DIR := wlan_cfg
2262WCFG_INC := -I$(WLAN_COMMON_INC)/$(WCFG_DIR)
2263WCFG_SRC := $(WLAN_COMMON_ROOT)/$(WCFG_DIR)
2264
2265ifeq (y,$(filter y,$(CONFIG_LITHIUM) $(CONFIG_BERYLLIUM) $(CONFIG_RHINE)))
2266WCFG_OBJS := $(WCFG_SRC)/wlan_cfg.o
2267endif
2268
2269$(call add-wlan-objs,wcfg,$(WCFG_OBJS))
2270
2271############ OL ############
2272OL_DIR :=     core/dp/ol
2273OL_INC :=     -I$(WLAN_ROOT)/$(OL_DIR)/inc
2274
2275############ CDP ############
2276CDP_ROOT_DIR := dp
2277CDP_INC_DIR := $(CDP_ROOT_DIR)/inc
2278CDP_INC := -I$(WLAN_COMMON_INC)/$(CDP_INC_DIR)
2279
2280############ PKTLOG ############
2281PKTLOG_DIR :=      $(WLAN_COMMON_ROOT)/utils/pktlog
2282PKTLOG_INC :=      -I$(WLAN_ROOT)/$(PKTLOG_DIR)/include
2283
2284ifeq ($(CONFIG_REMOVE_PKT_LOG), n)
2285PKTLOG_OBJS :=	$(PKTLOG_DIR)/pktlog_ac.o \
2286		$(PKTLOG_DIR)/pktlog_internal.o \
2287		$(PKTLOG_DIR)/linux_ac.o
2288
2289ifeq ($(CONFIG_PKTLOG_LEGACY), y)
2290	PKTLOG_OBJS  += $(PKTLOG_DIR)/pktlog_wifi2.o
2291else
2292	PKTLOG_OBJS  += $(PKTLOG_DIR)/pktlog_wifi3.o
2293endif
2294
2295endif
2296
2297
2298$(call add-wlan-objs,pktlog,$(PKTLOG_OBJS))
2299
2300############ HTT ############
2301HTT_DIR :=      core/dp/htt
2302HTT_INC :=      -I$(WLAN_ROOT)/$(HTT_DIR)
2303
2304ifneq (y,$(filter y,$(CONFIG_LITHIUM) $(CONFIG_BERYLLIUM) $(CONFIG_RHINE)))
2305HTT_OBJS := $(HTT_DIR)/htt_tx.o \
2306            $(HTT_DIR)/htt.o \
2307            $(HTT_DIR)/htt_t2h.o \
2308            $(HTT_DIR)/htt_h2t.o \
2309            $(HTT_DIR)/htt_fw_stats.o \
2310            $(HTT_DIR)/htt_rx.o
2311
2312ifeq ($(CONFIG_FEATURE_MONITOR_MODE_SUPPORT), y)
2313HTT_OBJS += $(HTT_DIR)/htt_monitor_rx.o
2314endif
2315
2316ifeq ($(CONFIG_LL_DP_SUPPORT), y)
2317HTT_OBJS += $(HTT_DIR)/htt_rx_ll.o
2318endif
2319
2320ifeq ($(CONFIG_HL_DP_SUPPORT), y)
2321HTT_OBJS += $(HTT_DIR)/htt_rx_hl.o
2322endif
2323endif
2324
2325$(call add-wlan-objs,htt,$(HTT_OBJS))
2326
2327############## INIT-DEINIT ###########
2328INIT_DEINIT_DIR := init_deinit/dispatcher
2329INIT_DEINIT_INC_DIR := $(INIT_DEINIT_DIR)/inc
2330INIT_DEINIT_SRC_DIR := $(INIT_DEINIT_DIR)/src
2331INIT_DEINIT_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(INIT_DEINIT_SRC_DIR)
2332INIT_DEINIT_INC := -I$(WLAN_COMMON_INC)/$(INIT_DEINIT_INC_DIR)
2333INIT_DEINIT_OBJS := $(INIT_DEINIT_OBJ_DIR)/dispatcher_init_deinit.o
2334
2335$(call add-wlan-objs,init_deinit,$(INIT_DEINIT_OBJS))
2336
2337############## REGULATORY ###########
2338REGULATORY_DIR := umac/regulatory
2339REGULATORY_CORE_SRC_DIR := $(REGULATORY_DIR)/core/src
2340REG_DISPATCHER_INC_DIR := $(REGULATORY_DIR)/dispatcher/inc
2341REG_DISPATCHER_SRC_DIR := $(REGULATORY_DIR)/dispatcher/src
2342REG_CORE_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(REGULATORY_CORE_SRC_DIR)
2343REG_DISPATCHER_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(REG_DISPATCHER_SRC_DIR)
2344REGULATORY_INC := -I$(WLAN_COMMON_INC)/$(REGULATORY_CORE_SRC_DIR)
2345REGULATORY_INC += -I$(WLAN_COMMON_INC)/$(REG_DISPATCHER_INC_DIR)
2346REGULATORY_INC += -I$(WLAN_COMMON_INC)/umac/cmn_services/regulatory/inc
2347REGULATORY_OBJS := $(REG_CORE_OBJ_DIR)/reg_build_chan_list.o \
2348		    $(REG_CORE_OBJ_DIR)/reg_callbacks.o \
2349		    $(REG_CORE_OBJ_DIR)/reg_db.o \
2350		    $(REG_CORE_OBJ_DIR)/reg_db_parser.o \
2351		    $(REG_CORE_OBJ_DIR)/reg_utils.o \
2352		    $(REG_CORE_OBJ_DIR)/reg_lte.o \
2353		    $(REG_CORE_OBJ_DIR)/reg_offload_11d_scan.o \
2354		    $(REG_CORE_OBJ_DIR)/reg_opclass.o \
2355		    $(REG_CORE_OBJ_DIR)/reg_priv_objs.o \
2356		    $(REG_DISPATCHER_OBJ_DIR)/wlan_reg_services_api.o \
2357		    $(REG_CORE_OBJ_DIR)/reg_services_common.o \
2358		    $(REG_DISPATCHER_OBJ_DIR)/wlan_reg_tgt_api.o \
2359		    $(REG_DISPATCHER_OBJ_DIR)/wlan_reg_ucfg_api.o
2360ifeq ($(CONFIG_HOST_11D_SCAN), y)
2361REGULATORY_OBJS += $(REG_CORE_OBJ_DIR)/reg_host_11d.o
2362endif
2363
2364$(call add-wlan-objs,regulatory,$(REGULATORY_OBJS))
2365
2366############## Control path common scheduler ##########
2367SCHEDULER_DIR := scheduler
2368SCHEDULER_INC_DIR := $(SCHEDULER_DIR)/inc
2369SCHEDULER_SRC_DIR := $(SCHEDULER_DIR)/src
2370SCHEDULER_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(SCHEDULER_SRC_DIR)
2371SCHEDULER_INC := -I$(WLAN_COMMON_INC)/$(SCHEDULER_INC_DIR)
2372SCHEDULER_OBJS := $(SCHEDULER_OBJ_DIR)/scheduler_api.o \
2373                  $(SCHEDULER_OBJ_DIR)/scheduler_core.o
2374
2375$(call add-wlan-objs,scheduler,$(SCHEDULER_OBJS))
2376
2377###### UMAC SERIALIZATION ########
2378UMAC_SER_DIR := umac/cmn_services/serialization
2379UMAC_SER_INC_DIR := $(UMAC_SER_DIR)/inc
2380UMAC_SER_SRC_DIR := $(UMAC_SER_DIR)/src
2381UMAC_SER_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_SER_SRC_DIR)
2382
2383UMAC_SER_INC := -I$(WLAN_COMMON_INC)/$(UMAC_SER_INC_DIR)
2384UMAC_SER_OBJS := $(UMAC_SER_OBJ_DIR)/wlan_serialization_main.o \
2385		 $(UMAC_SER_OBJ_DIR)/wlan_serialization_api.o \
2386		 $(UMAC_SER_OBJ_DIR)/wlan_serialization_utils.o \
2387		 $(UMAC_SER_OBJ_DIR)/wlan_serialization_legacy_api.o \
2388		 $(UMAC_SER_OBJ_DIR)/wlan_serialization_rules.o \
2389		 $(UMAC_SER_OBJ_DIR)/wlan_serialization_internal.o \
2390		 $(UMAC_SER_OBJ_DIR)/wlan_serialization_non_scan.o \
2391		 $(UMAC_SER_OBJ_DIR)/wlan_serialization_queue.o \
2392		 $(UMAC_SER_OBJ_DIR)/wlan_serialization_scan.o
2393
2394$(call add-wlan-objs,umac_ser,$(UMAC_SER_OBJS))
2395
2396###### WIFI POS ########
2397WIFI_POS_OS_IF_DIR := $(WLAN_COMMON_ROOT)/os_if/linux/wifi_pos/src
2398WIFI_POS_OS_IF_INC := -I$(WLAN_COMMON_INC)/os_if/linux/wifi_pos/inc
2399WIFI_POS_TGT_DIR := $(WLAN_COMMON_ROOT)/target_if/wifi_pos/src
2400WIFI_POS_TGT_INC := -I$(WLAN_COMMON_INC)/target_if/wifi_pos/inc
2401WIFI_POS_CORE_DIR := $(WLAN_COMMON_ROOT)/umac/wifi_pos/src
2402WIFI_POS_API_INC := -I$(WLAN_COMMON_INC)/umac/wifi_pos/inc
2403
2404
2405ifeq ($(CONFIG_WIFI_POS_CONVERGED), y)
2406
2407WIFI_POS_CLD_DIR := components/wifi_pos
2408WIFI_POS_CLD_CORE_DIR := $(WIFI_POS_CLD_DIR)/core
2409WIFI_POS_CLD_CORE_SRC := $(WIFI_POS_CLD_CORE_DIR)/src
2410WIFI_POS_CLD_DISP_DIR := $(WIFI_POS_CLD_DIR)/dispatcher
2411
2412WIFI_POS_OBJS := $(WIFI_POS_CORE_DIR)/wifi_pos_api.o \
2413		 $(WIFI_POS_CORE_DIR)/wifi_pos_main.o \
2414		 $(WIFI_POS_CORE_DIR)/wifi_pos_ucfg.o \
2415		 $(WIFI_POS_CORE_DIR)/wifi_pos_utils.o \
2416		 $(WIFI_POS_CLD_DISP_DIR)/src/wifi_pos_ucfg_api.o \
2417		 $(WIFI_POS_OS_IF_DIR)/os_if_wifi_pos.o \
2418		 $(WIFI_POS_OS_IF_DIR)/os_if_wifi_pos_utils.o \
2419		 $(WIFI_POS_OS_IF_DIR)/wlan_cfg80211_wifi_pos.o \
2420		 $(WIFI_POS_TGT_DIR)/target_if_wifi_pos.o \
2421		 $(WIFI_POS_TGT_DIR)/target_if_wifi_pos_rx_ops.o \
2422		 $(WIFI_POS_TGT_DIR)/target_if_wifi_pos_tx_ops.o
2423
2424ifeq ($(CONFIG_WIFI_POS_PASN), y)
2425WIFI_POS_OBJS += $(WIFI_POS_CORE_DIR)/wifi_pos_pasn_api.o
2426WIFI_POS_OBJS += $(WIFI_POS_CLD_CORE_SRC)/wlan_wifi_pos_interface.o
2427endif
2428
2429WIFI_POS_CLD_INC :=	-I$(WLAN_ROOT)/$(WIFI_POS_CLD_CORE_DIR)/inc \
2430			-I$(WLAN_ROOT)/$(WIFI_POS_CLD_DISP_DIR)/inc
2431endif
2432
2433$(call add-wlan-objs,wifi_pos,$(WIFI_POS_OBJS))
2434
2435###### TWT CONVERGED ########
2436TWT_CONV_CMN_OSIF_SRC := $(WLAN_COMMON_ROOT)/os_if/linux/twt/src
2437TWT_CONV_CMN_DISPATCHER_SRC := $(WLAN_COMMON_ROOT)/umac/twt/dispatcher/src
2438TWT_CONV_CMN_CORE_SRC := $(WLAN_COMMON_ROOT)/umac/twt/core/src
2439TWT_CONV_CMN_TGT_SRC := $(WLAN_COMMON_ROOT)/target_if/twt/src
2440TWT_CONV_OSIF_SRC := os_if/twt/src
2441TWT_CONV_DISPATCHER_SRC := components/umac/twt/dispatcher/src
2442TWT_CONV_CORE_SRC := components/umac/twt/core/src
2443TWT_CONV_TGT_SRC := components/target_if/twt/src
2444
2445TWT_CONV_INCS := -I$(WLAN_COMMON_INC)/umac \
2446		 -I$(WLAN_ROOT)/components/umac \
2447		 -I$(WLAN_COMMON_INC)/os_if/linux/twt/inc \
2448		 -I$(WLAN_COMMON_INC)/umac/twt/dispatcher/inc \
2449		 -I$(WLAN_COMMON_INC)/target_if/twt/inc \
2450		 -I$(WLAN_ROOT)/os_if/twt/inc \
2451		 -I$(WLAN_ROOT)/components/umac/twt/dispatcher/inc \
2452		 -I$(WLAN_ROOT)/components/target_if/twt/inc
2453
2454
2455ifeq ($(CONFIG_WLAN_TWT_CONVERGED), y)
2456TWT_CONV_OBJS := $(TWT_CONV_CMN_OSIF_SRC)/osif_twt_req.o \
2457		 $(TWT_CONV_CMN_OSIF_SRC)/osif_twt_rsp.o \
2458		 $(TWT_CONV_CMN_DISPATCHER_SRC)/wlan_twt_api.o \
2459		 $(TWT_CONV_CMN_DISPATCHER_SRC)/wlan_twt_tgt_if_rx_api.o \
2460		 $(TWT_CONV_CMN_DISPATCHER_SRC)/wlan_twt_tgt_if_tx_api.o \
2461		 $(TWT_CONV_CMN_DISPATCHER_SRC)/wlan_twt_ucfg_api.o \
2462		 $(TWT_CONV_CMN_CORE_SRC)/wlan_twt_common.o \
2463		 $(TWT_CONV_CMN_CORE_SRC)/wlan_twt_objmgr.o \
2464		 $(TWT_CONV_CMN_TGT_SRC)/target_if_twt_cmd.o \
2465		 $(TWT_CONV_CMN_TGT_SRC)/target_if_twt_evt.o \
2466		 $(TWT_CONV_CMN_TGT_SRC)/target_if_twt.o \
2467		 $(TWT_CONV_OSIF_SRC)/osif_twt_ext_req.o \
2468		 $(TWT_CONV_OSIF_SRC)/osif_twt_ext_rsp.o \
2469		 $(TWT_CONV_OSIF_SRC)/osif_twt_ext_util.o \
2470		 $(TWT_CONV_DISPATCHER_SRC)/wlan_twt_ucfg_ext_api.o \
2471		 $(TWT_CONV_DISPATCHER_SRC)/wlan_twt_cfg_ext_api.o \
2472		 $(TWT_CONV_DISPATCHER_SRC)/wlan_twt_tgt_if_ext_rx_api.o \
2473		 $(TWT_CONV_DISPATCHER_SRC)/wlan_twt_tgt_if_ext_tx_api.o \
2474		 $(TWT_CONV_CORE_SRC)/wlan_twt_cfg.o \
2475		 $(TWT_CONV_CORE_SRC)/wlan_twt_main.o \
2476		 $(TWT_CONV_TGT_SRC)/target_if_ext_twt_cmd.o \
2477		 $(TWT_CONV_TGT_SRC)/target_if_ext_twt_evt.o
2478endif
2479
2480$(call add-wlan-objs,twt_conv,$(TWT_CONV_OBJS))
2481
2482###### CP STATS ########
2483CP_MC_STATS_OS_IF_SRC           := os_if/cp_stats/src
2484CP_STATS_TGT_SRC                := $(WLAN_COMMON_ROOT)/target_if/cp_stats/src
2485CP_STATS_CORE_SRC               := $(WLAN_COMMON_ROOT)/umac/cp_stats/core/src
2486CP_STATS_DISPATCHER_SRC         := $(WLAN_COMMON_ROOT)/umac/cp_stats/dispatcher/src
2487CP_MC_STATS_COMPONENT_SRC       := components/cp_stats/dispatcher/src
2488CP_MC_STATS_COMPONENT_TGT_SRC   := $(CLD_TARGET_IF_DIR)/cp_stats/src
2489
2490CP_STATS_OS_IF_INC              := -I$(WLAN_COMMON_INC)/os_if/linux/cp_stats/inc
2491CP_STATS_TGT_INC                := -I$(WLAN_COMMON_INC)/target_if/cp_stats/inc
2492CP_STATS_DISPATCHER_INC         := -I$(WLAN_COMMON_INC)/umac/cp_stats/dispatcher/inc
2493CP_MC_STATS_COMPONENT_INC       := -I$(WLAN_ROOT)/components/cp_stats/dispatcher/inc
2494CP_STATS_CFG80211_OS_IF_INC     := -I$(WLAN_ROOT)/os_if/cp_stats/inc
2495
2496ifeq ($(CONFIG_CP_STATS), y)
2497CP_STATS_OBJS := $(CP_MC_STATS_COMPONENT_SRC)/wlan_cp_stats_mc_tgt_api.o	\
2498		 $(CP_MC_STATS_COMPONENT_SRC)/wlan_cp_stats_mc_ucfg_api.o	\
2499		 $(CP_MC_STATS_COMPONENT_TGT_SRC)/target_if_mc_cp_stats.o	\
2500		 $(CP_STATS_CORE_SRC)/wlan_cp_stats_comp_handler.o		\
2501		 $(CP_STATS_CORE_SRC)/wlan_cp_stats_obj_mgr_handler.o		\
2502		 $(CP_STATS_CORE_SRC)/wlan_cp_stats_ol_api.o			\
2503		 $(CP_MC_STATS_OS_IF_SRC)/wlan_cfg80211_mc_cp_stats.o		\
2504		 $(CP_STATS_DISPATCHER_SRC)/wlan_cp_stats_utils_api.o		\
2505		 $(WLAN_COMMON_ROOT)/target_if/cp_stats/src/target_if_cp_stats.o	\
2506		 $(CP_STATS_DISPATCHER_SRC)/wlan_cp_stats_ucfg_api.o
2507
2508endif
2509
2510$(call add-wlan-objs,cp_stats,$(CP_STATS_OBJS))
2511
2512###### DCS ######
2513DCS_TGT_IF_SRC := $(WLAN_COMMON_ROOT)/target_if/dcs/src
2514DCS_CORE_SRC   := $(WLAN_COMMON_ROOT)/umac/dcs/core/src
2515DCS_DISP_SRC   := $(WLAN_COMMON_ROOT)/umac/dcs/dispatcher/src
2516
2517DCS_TGT_IF_INC := -I$(WLAN_COMMON_INC)/target_if/dcs/inc
2518DCS_DISP_INC   := -I$(WLAN_COMMON_INC)/umac/dcs/dispatcher/inc
2519
2520ifeq ($(CONFIG_DCS), y)
2521DCS_OBJS := $(DCS_TGT_IF_SRC)/target_if_dcs.o \
2522	$(DCS_CORE_SRC)/wlan_dcs.o \
2523	$(DCS_DISP_SRC)/wlan_dcs_init_deinit_api.o \
2524	$(DCS_DISP_SRC)/wlan_dcs_ucfg_api.o \
2525	$(DCS_DISP_SRC)/wlan_dcs_tgt_api.o
2526endif
2527
2528$(call add-wlan-objs,dcs,$(DCS_OBJS))
2529
2530####### AFC ######
2531AFC_CMN_OSIF_SRC  := $(WLAN_COMMON_ROOT)/os_if/linux/afc/src
2532AFC_CMN_CORE_SRC  := $(WLAN_COMMON_ROOT)/umac/afc/core/src
2533AFC_CMN_DISP_SRC  := $(WLAN_COMMON_ROOT)/umac/afc/dispatcher/src
2534
2535AFC_CMN_OSIF_INC  := -I$(WLAN_COMMON_INC)/os_if/linux/afc/inc
2536AFC_CMN_DISP_INC  := -I$(WLAN_COMMON_INC)/umac/afc/dispatcher/inc
2537AFC_CMN_CORE_INC  := -I$(WLAN_COMMON_INC)/umac/afc/core/inc
2538
2539ifeq ($(CONFIG_AFC_SUPPORT), y)
2540AFC_OBJS := $(AFC_CMN_OSIF_SRC)/wlan_cfg80211_afc.o \
2541	    $(AFC_CMN_CORE_SRC)/wlan_afc_main.o \
2542	    $(AFC_CMN_DISP_SRC)/wlan_afc_ucfg_api.o
2543endif
2544
2545$(call add-wlan-objs,afc,$(AFC_OBJS))
2546
2547###### INTEROP ISSUES AP ########
2548INTEROP_ISSUES_AP_OS_IF_SRC      := os_if/interop_issues_ap/src
2549INTEROP_ISSUES_AP_TGT_SRC        := components/target_if/interop_issues_ap/src
2550INTEROP_ISSUES_AP_CORE_SRC       := components/interop_issues_ap/core/src
2551INTEROP_ISSUES_AP_DISPATCHER_SRC := components/interop_issues_ap/dispatcher/src
2552
2553INTEROP_ISSUES_AP_OS_IF_INC      := -I$(WLAN_ROOT)/os_if/interop_issues_ap/inc
2554INTEROP_ISSUES_AP_TGT_INC        := -I$(WLAN_ROOT)/components/target_if/interop_issues_ap/inc
2555INTEROP_ISSUES_AP_DISPATCHER_INC := -I$(WLAN_ROOT)/components/interop_issues_ap/dispatcher/inc
2556INTEROP_ISSUES_AP_CORE_INC       := -I$(WLAN_ROOT)/components/interop_issues_ap/core/inc
2557
2558ifeq ($(CONFIG_FEATURE_INTEROP_ISSUES_AP), y)
2559INTEROP_ISSUES_AP_OBJS := $(INTEROP_ISSUES_AP_TGT_SRC)/target_if_interop_issues_ap.o \
2560		$(INTEROP_ISSUES_AP_CORE_SRC)/wlan_interop_issues_ap_api.o \
2561		$(INTEROP_ISSUES_AP_OS_IF_SRC)/wlan_cfg80211_interop_issues_ap.o \
2562		$(INTEROP_ISSUES_AP_DISPATCHER_SRC)/wlan_interop_issues_ap_tgt_api.o \
2563		$(INTEROP_ISSUES_AP_DISPATCHER_SRC)/wlan_interop_issues_ap_ucfg_api.o
2564endif
2565
2566$(call add-wlan-objs,interop_issues_ap,$(INTEROP_ISSUES_AP_OBJS))
2567
2568######################### NAN #########################
2569NAN_CORE_DIR := components/nan/core/src
2570NAN_CORE_INC := -I$(WLAN_ROOT)/components/nan/core/inc
2571NAN_UCFG_DIR := components/nan/dispatcher/src
2572NAN_UCFG_INC := -I$(WLAN_ROOT)/components/nan/dispatcher/inc
2573NAN_TGT_DIR  := components/target_if/nan/src
2574NAN_TGT_INC  := -I$(WLAN_ROOT)/components/target_if/nan/inc
2575
2576NAN_OS_IF_DIR  := os_if/nan/src
2577NAN_OS_IF_INC  := -I$(WLAN_ROOT)/os_if/nan/inc
2578
2579ifeq ($(CONFIG_QCACLD_FEATURE_NAN), y)
2580WLAN_NAN_OBJS := $(NAN_CORE_DIR)/nan_main.o \
2581		 $(NAN_CORE_DIR)/nan_api.o \
2582		 $(NAN_UCFG_DIR)/nan_ucfg_api.o \
2583		 $(NAN_UCFG_DIR)/wlan_nan_api.o \
2584		 $(NAN_UCFG_DIR)/cfg_nan.o \
2585		 $(NAN_TGT_DIR)/target_if_nan.o \
2586		 $(NAN_OS_IF_DIR)/os_if_nan.o
2587endif
2588
2589$(call add-wlan-objs,nan,$(WLAN_NAN_OBJS))
2590
2591#######################################################
2592
2593######################### DP_COMPONENT #########################
2594DP_COMP_CORE_DIR := components/dp/core/src
2595DP_COMP_UCFG_DIR := components/dp/dispatcher/src
2596DP_COMP_TGT_DIR  := components/target_if/dp/src
2597DP_COMP_OS_IF_DIR  := os_if/dp/src
2598
2599DP_COMP_INC	:= -I$(WLAN_ROOT)/components/dp/core/inc	\
2600		-I$(WLAN_ROOT)/components/dp/core/src		\
2601		-I$(WLAN_ROOT)/components/dp/dispatcher/inc	\
2602		-I$(WLAN_ROOT)/components/target_if/dp/inc	\
2603		-I$(WLAN_ROOT)/os_if/dp/inc
2604
2605WLAN_DP_COMP_OBJS := $(DP_COMP_CORE_DIR)/wlan_dp_main.o \
2606		 $(DP_COMP_UCFG_DIR)/wlan_dp_ucfg_api.o \
2607		$(DP_COMP_UCFG_DIR)/wlan_dp_api.o \
2608		 $(DP_COMP_OS_IF_DIR)/os_if_dp.o \
2609		 $(DP_COMP_OS_IF_DIR)/os_if_dp_txrx.o \
2610		 $(DP_COMP_CORE_DIR)/wlan_dp_bus_bandwidth.o \
2611		 $(DP_COMP_CORE_DIR)/wlan_dp_softap_txrx.o \
2612		 $(DP_COMP_CORE_DIR)/wlan_dp_txrx.o \
2613		 $(DP_COMP_TGT_DIR)/target_if_dp_comp.o
2614
2615ifeq ($(CONFIG_WLAN_LRO), y)
2616WLAN_DP_COMP_OBJS += $(DP_COMP_OS_IF_DIR)/os_if_dp_lro.o
2617endif
2618
2619ifeq ($(CONFIG_WLAN_NUD_TRACKING), y)
2620WLAN_DP_COMP_OBJS += $(DP_COMP_CORE_DIR)/wlan_dp_nud_tracking.o
2621endif
2622
2623ifeq ($(CONFIG_WLAN_FEATURE_PERIODIC_STA_STATS), y)
2624WLAN_DP_COMP_OBJS += $(DP_COMP_CORE_DIR)/wlan_dp_periodic_sta_stats.o
2625endif
2626
2627ifeq ($(CONFIG_DP_SWLM), y)
2628WLAN_DP_COMP_OBJS += $(DP_COMP_CORE_DIR)/wlan_dp_swlm.o
2629endif
2630
2631ifeq (y,$(filter y,$(CONFIG_LITHIUM) $(CONFIG_BERYLLIUM) $(CONFIG_RHINE)))
2632WLAN_DP_COMP_OBJS += $(DP_COMP_CORE_DIR)/wlan_dp_prealloc.o
2633
2634ifeq ($(CONFIG_WLAN_TX_MON_2_0), y)
2635ifeq ($(CONFIG_WLAN_DP_LOCAL_PKT_CAPTURE), y)
2636WLAN_DP_COMP_OBJS += $(DP_COMP_OS_IF_DIR)/os_if_dp_local_pkt_capture.o
2637endif #CONFIG_WLAN_DP_LOCAL_PKT_CAPTURE
2638endif #CONFIG_WLAN_TX_MON_2_0
2639endif
2640
2641ifeq ($(CONFIG_WLAN_FEATURE_DP_RX_THREADS), y)
2642WLAN_DP_COMP_OBJS += $(DP_COMP_CORE_DIR)/wlan_dp_rx_thread.o
2643endif
2644
2645ifeq ($(CONFIG_RX_FISA), y)
2646WLAN_DP_COMP_OBJS += $(DP_COMP_CORE_DIR)/wlan_dp_fisa_rx.o
2647WLAN_DP_COMP_OBJS += $(DP_COMP_CORE_DIR)/wlan_dp_rx_fst.o
2648endif
2649
2650ifeq ($(CONFIG_FEATURE_DIRECT_LINK), y)
2651WLAN_DP_COMP_OBJS += $(DP_COMP_CORE_DIR)/wlan_dp_wfds.o
2652endif
2653
2654$(call add-wlan-objs,dp_comp,$(WLAN_DP_COMP_OBJS))
2655
2656#######################################################
2657
2658######################### QMI_COMPONENT #########################
2659QMI_COMP_CORE_DIR := components/qmi/core/src
2660QMI_COMP_UCFG_DIR := components/qmi/dispatcher/src
2661QMI_COMP_OS_IF_DIR := os_if/qmi/src
2662
2663QMI_COMP_INC := -I$(WLAN_ROOT)/components/qmi/core/inc       \
2664		-I$(WLAN_ROOT)/components/qmi/core/src       \
2665		-I$(WLAN_ROOT)/components/qmi/dispatcher/inc \
2666		-I$(WLAN_ROOT)/os_if/qmi/inc
2667
2668ifeq ($(CONFIG_QMI_COMPONENT_ENABLE), y)
2669WLAN_QMI_COMP_OBJS := $(QMI_COMP_CORE_DIR)/wlan_qmi_main.o \
2670		 $(QMI_COMP_UCFG_DIR)/wlan_qmi_ucfg_api.o  \
2671		 $(QMI_COMP_OS_IF_DIR)/os_if_qmi.o
2672
2673ifeq ($(CONFIG_QMI_WFDS), y)
2674WLAN_QMI_COMP_OBJS += $(QMI_COMP_OS_IF_DIR)/os_if_qmi_wifi_driver_service_v01.o
2675WLAN_QMI_COMP_OBJS += $(QMI_COMP_OS_IF_DIR)/os_if_qmi_wfds.o
2676WLAN_QMI_COMP_OBJS += $(QMI_COMP_UCFG_DIR)/wlan_qmi_wfds_api.o
2677endif
2678endif
2679
2680$(call add-wlan-objs,qmi_comp,$(WLAN_QMI_COMP_OBJS))
2681
2682#######################################################
2683
2684######################### SON #########################
2685#SON_CORE_DIR := components/son/core/src
2686#SON_CORE_INC := -I$(WLAN_ROOT)/components/son/core/inc
2687SON_UCFG_DIR := components/son/dispatcher/src
2688SON_UCFG_INC := -I$(WLAN_ROOT)/components/son/dispatcher/inc
2689SON_TGT_DIR  := $(WLAN_COMMON_ROOT)/target_if/son/src
2690SON_TGT_INC  := -I$(WLAN_COMMON_INC)/target_if/son/inc/
2691
2692SON_OS_IF_DIR  := os_if/son/src
2693SON_OS_IF_INC  := -I$(WLAN_ROOT)/os_if/son/inc
2694
2695ifeq ($(CONFIG_QCACLD_FEATURE_SON), y)
2696WLAN_SON_OBJS := $(SON_UCFG_DIR)/son_ucfg_api.o \
2697		 $(SON_UCFG_DIR)/son_api.o \
2698		 $(SON_OS_IF_DIR)/os_if_son.o \
2699		 $(SON_TGT_DIR)/target_if_son.o
2700endif
2701
2702$(call add-wlan-objs,son,$(WLAN_SON_OBJS))
2703
2704#######################################################
2705
2706######################### SPATIAL_REUSE #########################
2707SR_UCFG_DIR := components/spatial_reuse/dispatcher/src
2708SR_UCFG_INC := -I$(WLAN_ROOT)/components/spatial_reuse/dispatcher/inc
2709SR_TGT_DIR  := $(WLAN_COMMON_ROOT)/target_if/spatial_reuse/src
2710SR_TGT_INC  := -I$(WLAN_COMMON_INC)/target_if/spatial_reuse/inc/
2711
2712ifeq ($(CONFIG_WLAN_FEATURE_SR), y)
2713WLAN_SR_OBJS := $(SR_UCFG_DIR)/spatial_reuse_ucfg_api.o \
2714		 $(SR_UCFG_DIR)/spatial_reuse_api.o \
2715		 $(SR_TGT_DIR)/target_if_spatial_reuse.o
2716endif
2717
2718$(call add-wlan-objs,spatial_reuse,$(WLAN_SR_OBJS))
2719
2720#######################################################
2721
2722###### COEX ########
2723COEX_OS_IF_SRC      := os_if/coex/src
2724COEX_TGT_SRC        := components/target_if/coex/src
2725COEX_CORE_SRC       := components/coex/core/src
2726COEX_DISPATCHER_SRC := components/coex/dispatcher/src
2727
2728COEX_OS_IF_INC      := -I$(WLAN_ROOT)/os_if/coex/inc
2729COEX_TGT_INC        := -I$(WLAN_ROOT)/components/target_if/coex/inc
2730COEX_DISPATCHER_INC := -I$(WLAN_ROOT)/components/coex/dispatcher/inc
2731COEX_CORE_INC       := -I$(WLAN_ROOT)/components/coex/core/inc
2732COEX_STRUCT_INC     := -I$(WLAN_COMMON_INC)/coex/dispatcher/inc
2733
2734ifeq ($(CONFIG_FEATURE_COEX), y)
2735COEX_OBJS := $(COEX_TGT_SRC)/target_if_coex.o                 \
2736		 $(COEX_CORE_SRC)/wlan_coex_main.o                 \
2737		 $(COEX_OS_IF_SRC)/wlan_cfg80211_coex.o           \
2738		 $(COEX_DISPATCHER_SRC)/wlan_coex_tgt_api.o       \
2739		 $(COEX_DISPATCHER_SRC)/wlan_coex_utils_api.o       \
2740		 $(COEX_DISPATCHER_SRC)/wlan_coex_ucfg_api.o
2741endif
2742
2743$(call add-wlan-objs,coex,$(COEX_OBJS))
2744
2745###### COAP ########
2746ifeq ($(CONFIG_WLAN_FEATURE_COAP), y)
2747COAP_HDD_SRC := core/hdd/src
2748COAP_OS_IF_SRC := os_if/coap/src
2749COAP_TGT_SRC := components/target_if/coap/src
2750COAP_CORE_SRC  := components/coap/core/src
2751COAP_DISPATCHER_SRC := components/coap/dispatcher/src
2752COAP_WMI_SRC := components/wmi/src
2753
2754COAP_OS_IF_INC  := -I$(WLAN_ROOT)/os_if/coap/inc
2755COAP_TGT_INC := -I$(WLAN_ROOT)/components/target_if/coap/inc
2756COAP_DISPATCHER_INC := -I$(WLAN_ROOT)/components/coap/dispatcher/inc
2757COAP_CORE_INC := -I$(WLAN_ROOT)/components/coap/core/inc
2758COAP_WMI_INC := -I$(WLAN_ROOT)/components/wmi/inc
2759
2760COAP_OBJS := \
2761	$(COAP_HDD_SRC)/wlan_hdd_coap.o \
2762	$(COAP_OS_IF_SRC)/wlan_cfg80211_coap.o \
2763	$(COAP_TGT_SRC)/target_if_coap.o  \
2764	$(COAP_CORE_SRC)/wlan_coap_main.o  \
2765	$(COAP_DISPATCHER_SRC)/wlan_coap_tgt_api.o \
2766	$(COAP_DISPATCHER_SRC)/wlan_coap_ucfg_api.o \
2767	$(COAP_WMI_SRC)/wmi_unified_coap_tlv.o
2768$(call add-wlan-objs,coap,$(COAP_OBJS))
2769endif
2770
2771############## HTC ##########
2772HTC_DIR := htc
2773HTC_INC := -I$(WLAN_COMMON_INC)/$(HTC_DIR)
2774
2775HTC_OBJS := $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc.o \
2776            $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc_send.o \
2777            $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc_recv.o \
2778            $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc_services.o
2779
2780ifeq ($(CONFIG_FEATURE_HTC_CREDIT_HISTORY), y)
2781HTC_OBJS += $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc_credit_history.o
2782endif
2783
2784ifeq ($(CONFIG_WLAN_HANG_EVENT), y)
2785HTC_OBJS += $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc_hang_event.o
2786endif
2787
2788$(call add-wlan-objs,htc,$(HTC_OBJS))
2789
2790########### HIF ###########
2791HIF_DIR := hif
2792HIF_CE_DIR := $(HIF_DIR)/src/ce
2793
2794HIF_DISPATCHER_DIR := $(HIF_DIR)/src/dispatcher
2795
2796HIF_PCIE_DIR := $(HIF_DIR)/src/pcie
2797HIF_IPCIE_DIR := $(HIF_DIR)/src/ipcie
2798HIF_SNOC_DIR := $(HIF_DIR)/src/snoc
2799HIF_USB_DIR := $(HIF_DIR)/src/usb
2800HIF_SDIO_DIR := $(HIF_DIR)/src/sdio
2801
2802HIF_SDIO_NATIVE_DIR := $(HIF_SDIO_DIR)/native_sdio
2803HIF_SDIO_NATIVE_INC_DIR := $(HIF_SDIO_NATIVE_DIR)/include
2804HIF_SDIO_NATIVE_SRC_DIR := $(HIF_SDIO_NATIVE_DIR)/src
2805
2806HIF_INC := -I$(WLAN_COMMON_INC)/$(HIF_DIR)/inc \
2807	   -I$(WLAN_COMMON_INC)/$(HIF_DIR)/src
2808
2809ifeq ($(CONFIG_HIF_PCI), y)
2810HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_DISPATCHER_DIR)
2811HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_PCIE_DIR)
2812HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_CE_DIR)
2813endif
2814
2815ifeq ($(CONFIG_HIF_IPCI), y)
2816HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_DISPATCHER_DIR)
2817HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_IPCIE_DIR)
2818HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_CE_DIR)
2819endif
2820
2821ifeq ($(CONFIG_HIF_SNOC), y)
2822HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_DISPATCHER_DIR)
2823HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_SNOC_DIR)
2824HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_CE_DIR)
2825endif
2826
2827ifeq ($(CONFIG_HIF_USB), y)
2828HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_DISPATCHER_DIR)
2829HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_USB_DIR)
2830HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_CE_DIR)
2831endif
2832
2833ifeq ($(CONFIG_HIF_SDIO), y)
2834HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_DISPATCHER_DIR)
2835HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_SDIO_DIR)
2836HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_SDIO_NATIVE_INC_DIR)
2837HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_CE_DIR)
2838endif
2839
2840HIF_COMMON_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/ath_procfs.o \
2841		   $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_main.o \
2842		   $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_runtime_pm.o \
2843		   $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_exec.o
2844
2845ifneq (y,$(filter y,$(CONFIG_LITHIUM) $(CONFIG_BERYLLIUM)))
2846HIF_COMMON_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_main_legacy.o
2847endif
2848
2849ifeq ($(CONFIG_WLAN_NAPI), y)
2850HIF_COMMON_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_irq_affinity.o
2851endif
2852
2853HIF_CE_OBJS :=  $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_diag.o \
2854                $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_main.o \
2855                $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_service.o \
2856                $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_tasklet.o \
2857                $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/mp_dev.o \
2858                $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/regtable.o
2859
2860ifeq ($(CONFIG_WLAN_FEATURE_BMI), y)
2861HIF_CE_OBJS +=  $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_bmi.o
2862endif
2863
2864ifeq ($(CONFIG_LITHIUM), y)
2865ifeq ($(CONFIG_CNSS_QCA6290), y)
2866HIF_CE_OBJS +=  $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/qca6290def.o
2867endif
2868
2869ifeq ($(CONFIG_CNSS_QCA6390), y)
2870HIF_CE_OBJS +=  $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/qca6390def.o
2871endif
2872
2873ifeq ($(CONFIG_CNSS_QCA6490), y)
2874HIF_CE_OBJS +=  $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/qca6490def.o
2875endif
2876
2877ifeq ($(CONFIG_CNSS_QCA6750), y)
2878HIF_CE_OBJS +=  $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/qca6750def.o
2879endif
2880
2881HIF_CE_OBJS +=  $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_service_srng.o
2882else ifeq ($(CONFIG_BERYLLIUM), y)
2883ifeq (y,$(findstring y,$(CONFIG_CNSS_KIWI) $(CONFIG_CNSS_KIWI_V2) $CONFIG_CNSS_PEACH))
2884HIF_CE_OBJS +=  $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/kiwidef.o
2885endif
2886
2887HIF_CE_OBJS +=  $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_service_srng.o
2888else
2889HIF_CE_OBJS +=  $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_service_legacy.o
2890endif
2891
2892HIF_USB_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_USB_DIR)/usbdrv.o \
2893                $(WLAN_COMMON_ROOT)/$(HIF_USB_DIR)/hif_usb.o \
2894                $(WLAN_COMMON_ROOT)/$(HIF_USB_DIR)/if_usb.o \
2895                $(WLAN_COMMON_ROOT)/$(HIF_USB_DIR)/regtable_usb.o
2896
2897HIF_SDIO_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_diag_reg_access.o \
2898                 $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_sdio_dev.o \
2899                 $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_sdio.o \
2900                 $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/regtable_sdio.o \
2901                 $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/transfer/transfer.o
2902
2903ifeq ($(CONFIG_WLAN_FEATURE_BMI), y)
2904HIF_SDIO_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_bmi_reg_access.o
2905endif
2906
2907ifeq ($(CONFIG_SDIO_TRANSFER), adma)
2908HIF_SDIO_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/transfer/adma.o
2909else
2910HIF_SDIO_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/transfer/mailbox.o
2911endif
2912
2913HIF_SDIO_NATIVE_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_SDIO_NATIVE_SRC_DIR)/hif.o \
2914                        $(WLAN_COMMON_ROOT)/$(HIF_SDIO_NATIVE_SRC_DIR)/hif_scatter.o \
2915                        $(WLAN_COMMON_ROOT)/$(HIF_SDIO_NATIVE_SRC_DIR)/dev_quirks.o
2916
2917ifeq ($(CONFIG_WLAN_NAPI), y)
2918HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_napi.o
2919endif
2920
2921ifeq ($(CONFIG_FEATURE_UNIT_TEST_SUSPEND), y)
2922	HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_unit_test_suspend.o
2923endif
2924
2925HIF_PCIE_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_PCIE_DIR)/if_pci.o
2926HIF_IPCIE_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_IPCIE_DIR)/if_ipci.o
2927HIF_SNOC_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_SNOC_DIR)/if_snoc.o
2928HIF_SDIO_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/if_sdio.o
2929
2930HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus.o
2931HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/dummy.o
2932HIF_OBJS += $(HIF_COMMON_OBJS)
2933
2934ifeq ($(CONFIG_HIF_PCI), y)
2935HIF_OBJS += $(HIF_PCIE_OBJS)
2936HIF_OBJS += $(HIF_CE_OBJS)
2937HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus_pci.o
2938endif
2939
2940ifeq ($(CONFIG_HIF_IPCI), y)
2941HIF_OBJS += $(HIF_IPCIE_OBJS)
2942HIF_OBJS += $(HIF_CE_OBJS)
2943HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus_ipci.o
2944endif
2945
2946ifeq ($(CONFIG_HIF_SNOC), y)
2947HIF_OBJS += $(HIF_SNOC_OBJS)
2948HIF_OBJS += $(HIF_CE_OBJS)
2949HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus_snoc.o
2950endif
2951
2952ifeq ($(CONFIG_HIF_SDIO), y)
2953HIF_OBJS += $(HIF_SDIO_OBJS)
2954HIF_OBJS += $(HIF_SDIO_NATIVE_OBJS)
2955HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus_sdio.o
2956endif
2957
2958ifeq ($(CONFIG_HIF_USB), y)
2959HIF_OBJS += $(HIF_USB_OBJS)
2960HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus_usb.o
2961endif
2962
2963$(call add-wlan-objs,hif,$(HIF_OBJS))
2964
2965############ HAL ############
2966ifeq (y,$(filter y,$(CONFIG_LITHIUM) $(CONFIG_BERYLLIUM) $(CONFIG_RHINE)))
2967HAL_DIR :=	hal
2968HAL_INC :=	-I$(WLAN_COMMON_INC)/$(HAL_DIR)/inc \
2969		-I$(WLAN_COMMON_INC)/$(HAL_DIR)/wifi3.0
2970
2971#TODO fix hal_reo for RHINE
2972HAL_OBJS :=	$(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/hal_srng.o \
2973		$(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/hal_reo.o
2974
2975ifeq ($(CONFIG_RX_FISA), y)
2976HAL_OBJS += $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/hal_rx_flow.o
2977endif
2978endif #### CONFIG LITHIUM/BERYLLIUM/RHINE ####
2979
2980ifeq ($(CONFIG_LITHIUM), y)
2981HAL_INC += 	-I$(WLAN_COMMON_INC)/$(HAL_DIR)/wifi3.0/li
2982
2983HAL_OBJS +=	$(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/li/hal_li_generic_api.o
2984
2985HAL_OBJS +=	$(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/li/hal_li_reo.o
2986
2987ifeq ($(CONFIG_CNSS_QCA6290), y)
2988HAL_INC += -I$(WLAN_COMMON_INC)/$(HAL_DIR)/wifi3.0/qca6290
2989HAL_OBJS += $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/qca6290/hal_6290.o
2990else ifeq ($(CONFIG_CNSS_QCA6390), y)
2991HAL_INC += -I$(WLAN_COMMON_INC)/$(HAL_DIR)/wifi3.0/qca6390
2992HAL_OBJS += $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/qca6390/hal_6390.o
2993else ifeq ($(CONFIG_CNSS_QCA6490), y)
2994HAL_INC += -I$(WLAN_COMMON_INC)/$(HAL_DIR)/wifi3.0/qca6490
2995HAL_OBJS += $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/qca6490/hal_6490.o
2996else ifeq ($(CONFIG_CNSS_QCA6750), y)
2997HAL_INC += -I$(WLAN_COMMON_INC)/$(HAL_DIR)/wifi3.0/qca6750
2998HAL_OBJS += $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/qca6750/hal_6750.o
2999else
3000#error "Not 11ax"
3001endif
3002
3003endif #####CONFIG_LITHIUM####
3004
3005ifeq ($(CONFIG_BERYLLIUM), y)
3006HAL_INC += 	-I$(WLAN_COMMON_INC)/$(HAL_DIR)/wifi3.0/be
3007
3008HAL_OBJS +=	$(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/be/hal_be_generic_api.o
3009
3010HAL_OBJS +=	$(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/be/hal_be_reo.o \
3011
3012ifeq (y,$(findstring y,$(CONFIG_CNSS_KIWI) $(CONFIG_CNSS_KIWI_V2) $(CONFIG_CNSS_PEACH)))
3013HAL_INC += -I$(WLAN_COMMON_INC)/$(HAL_DIR)/wifi3.0/kiwi
3014HAL_OBJS += $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/kiwi/hal_kiwi.o
3015else
3016#error "Not Beryllium"
3017endif
3018
3019endif #### CONFIG_BERYLLIUM ####
3020
3021ifeq ($(CONFIG_RHINE), y)
3022HAL_INC += 	-I$(WLAN_COMMON_INC)/$(HAL_DIR)/wifi3.0/rh
3023
3024HAL_OBJS +=	$(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/rh/hal_rh_generic_api.o
3025
3026ifeq ($(CONFIG_CNSS_WCN6450), y)
3027#TODO fix this for RHINE
3028HAL_INC += -I$(WLAN_COMMON_INC)/$(HAL_DIR)/wifi3.0/wcn6450
3029HAL_OBJS += $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/wcn6450/hal_wcn6450.o
3030else
3031#error "Not RHINE"
3032endif
3033
3034endif #####CONFIG_RHINE####
3035
3036$(call add-wlan-objs,hal,$(HAL_OBJS))
3037
3038############ WMA ############
3039WMA_DIR :=	core/wma
3040
3041WMA_INC_DIR :=  $(WMA_DIR)/inc
3042WMA_SRC_DIR :=  $(WMA_DIR)/src
3043
3044WMA_INC :=	-I$(WLAN_ROOT)/$(WMA_INC_DIR) \
3045		-I$(WLAN_ROOT)/$(WMA_SRC_DIR)
3046
3047ifeq ($(CONFIG_QCACLD_FEATURE_NAN), y)
3048WMA_NDP_OBJS += $(WMA_SRC_DIR)/wma_nan_datapath.o
3049endif
3050
3051WMA_OBJS :=	$(WMA_SRC_DIR)/wma_main.o \
3052		$(WMA_SRC_DIR)/wma_scan_roam.o \
3053		$(WMA_SRC_DIR)/wma_dev_if.o \
3054		$(WMA_SRC_DIR)/wma_mgmt.o \
3055		$(WMA_SRC_DIR)/wma_power.o \
3056		$(WMA_SRC_DIR)/wma_data.o \
3057		$(WMA_SRC_DIR)/wma_utils.o \
3058		$(WMA_SRC_DIR)/wma_features.o \
3059		$(WMA_SRC_DIR)/wlan_qct_wma_legacy.o\
3060		$(WMA_NDP_OBJS)
3061
3062ifeq ($(CONFIG_WLAN_FEATURE_11BE), y)
3063WMA_OBJS +=	$(WMA_SRC_DIR)/wma_eht.o
3064endif
3065ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
3066WMA_OBJS+=	$(WMA_SRC_DIR)/wma_ocb.o
3067endif
3068ifeq ($(CONFIG_WLAN_FEATURE_FIPS), y)
3069WMA_OBJS+=	$(WMA_SRC_DIR)/wma_fips_api.o
3070endif
3071ifeq ($(CONFIG_WLAN_FEATURE_11AX), y)
3072WMA_OBJS+=	$(WMA_SRC_DIR)/wma_he.o
3073endif
3074ifeq ($(CONFIG_WLAN_FEATURE_TWT), y)
3075WMA_OBJS +=	$(WMA_SRC_DIR)/wma_twt.o
3076endif
3077ifeq ($(CONFIG_QCACLD_FEATURE_FW_STATE), y)
3078WMA_OBJS +=	$(WMA_SRC_DIR)/wma_fw_state.o
3079endif
3080ifeq ($(CONFIG_WLAN_MWS_INFO_DEBUGFS), y)
3081WMA_OBJS +=	$(WMA_SRC_DIR)/wma_coex.o
3082endif
3083ifeq ($(CONFIG_WIFI_POS_CONVERGED), y)
3084ifeq ($(CONFIG_WIFI_POS_PASN), y)
3085WMA_OBJS +=	$(WMA_SRC_DIR)/wma_pasn_peer_api.o
3086endif
3087endif
3088
3089$(call add-wlan-objs,wma,$(WMA_OBJS))
3090
3091#######DIRECT_BUFFER_RX#########
3092ifeq ($(CONFIG_DIRECT_BUF_RX_ENABLE), y)
3093DBR_DIR = $(WLAN_COMMON_ROOT)/target_if/direct_buf_rx
3094UMAC_DBR_INC := -I$(WLAN_COMMON_INC)/target_if/direct_buf_tx/inc
3095UMAC_DBR_OBJS := $(DBR_DIR)/src/target_if_direct_buf_rx_api.o \
3096		 $(DBR_DIR)/src/target_if_direct_buf_rx_main.o \
3097		 $(WLAN_COMMON_ROOT)/wmi/src/wmi_unified_dbr_api.o \
3098		 $(WLAN_COMMON_ROOT)/wmi/src/wmi_unified_dbr_tlv.o
3099endif
3100
3101$(call add-wlan-objs,umac_dbr,$(UMAC_DBR_OBJS))
3102
3103############## PLD ##########
3104PLD_DIR := core/pld
3105PLD_INC_DIR := $(PLD_DIR)/inc
3106PLD_SRC_DIR := $(PLD_DIR)/src
3107
3108PLD_INC :=	-I$(WLAN_ROOT)/$(PLD_INC_DIR) \
3109		-I$(WLAN_ROOT)/$(PLD_SRC_DIR)
3110
3111PLD_OBJS :=	$(PLD_SRC_DIR)/pld_common.o
3112
3113ifeq ($(CONFIG_IPCIE_FW_SIM), y)
3114PLD_OBJS +=     $(PLD_SRC_DIR)/pld_pcie_fw_sim.o
3115endif
3116ifeq ($(CONFIG_PCIE_FW_SIM), y)
3117PLD_OBJS +=     $(PLD_SRC_DIR)/pld_pcie_fw_sim.o
3118else ifeq ($(CONFIG_HIF_PCI), y)
3119PLD_OBJS +=     $(PLD_SRC_DIR)/pld_pcie.o
3120endif
3121ifeq ($(CONFIG_SNOC_FW_SIM),y)
3122PLD_OBJS +=     $(PLD_SRC_DIR)/pld_snoc_fw_sim.o
3123else ifeq (y,$(findstring y, $(CONFIG_ICNSS) $(CONFIG_PLD_SNOC_ICNSS_FLAG)))
3124PLD_OBJS +=     $(PLD_SRC_DIR)/pld_snoc.o
3125else ifeq (y,$(findstring y, $(CONFIG_PLD_IPCI_ICNSS_FLAG)))
3126PLD_OBJS +=     $(PLD_SRC_DIR)/pld_ipci.o
3127endif
3128
3129ifeq ($(CONFIG_QCA_WIFI_SDIO), y)
3130PLD_OBJS +=	$(PLD_SRC_DIR)/pld_sdio.o
3131endif
3132ifeq ($(CONFIG_HIF_USB), y)
3133PLD_OBJS +=	$(PLD_SRC_DIR)/pld_usb.o
3134endif
3135
3136$(call add-wlan-objs,pld,$(PLD_OBJS))
3137
3138
3139TARGET_INC := 	-I$(WLAN_FW_API)/fw
3140
3141ifeq ($(CONFIG_CNSS_QCA6290), y)
3142ifeq ($(CONFIG_QCA6290_11AX), y)
3143TARGET_INC +=	-I$(WLAN_FW_API)/hw/qca6290/11ax/v2
3144else
3145TARGET_INC +=	-I$(WLAN_FW_API)/hw/qca6290/v2
3146endif
3147endif
3148
3149ifeq ($(CONFIG_CNSS_QCA6390), y)
3150TARGET_INC +=	-I$(WLAN_FW_API)/hw/qca6390/v1
3151endif
3152
3153ifeq ($(CONFIG_CNSS_QCA6490), y)
3154TARGET_INC +=	-I$(WLAN_FW_API)/hw/qca6490/v1
3155endif
3156
3157ifeq ($(CONFIG_CNSS_QCA6750), y)
3158TARGET_INC +=	-I$(WLAN_FW_API)/hw/qca6750/v1
3159endif
3160
3161ifeq ($(CONFIG_CNSS_WCN6450), y)
3162TARGET_INC +=	-I$(WLAN_FW_API)/hw/wcn6450/v1
3163endif
3164
3165ifeq ($(CONFIG_CNSS_PEACH), y)
3166TARGET_INC +=	-I$(WLAN_FW_API)/hw/peach/v1/
3167else
3168ifeq ($(CONFIG_CNSS_KIWI_V2), y)
3169TARGET_INC +=	-I$(WLAN_FW_API)/hw/kiwi/v2/
3170else
3171ifeq ($(CONFIG_CNSS_KIWI), y)
3172TARGET_INC +=	-I$(WLAN_FW_API)/hw/kiwi/v1/
3173endif
3174endif
3175endif
3176
3177LINUX_INC :=	-Iinclude
3178
3179INCS :=		$(HDD_INC) \
3180		$(SYNC_INC) \
3181		$(DSC_INC) \
3182		$(EPPING_INC) \
3183		$(LINUX_INC) \
3184		$(MAC_INC) \
3185		$(SAP_INC) \
3186		$(SME_INC) \
3187		$(SYS_INC) \
3188		$(CLD_WMI_INC) \
3189		$(QAL_INC) \
3190		$(QDF_INC) \
3191		$(WBUFF_INC) \
3192		$(CDS_INC) \
3193		$(CFG_INC) \
3194		$(DFS_INC) \
3195		$(TARGET_IF_INC) \
3196		$(CLD_TARGET_IF_INC) \
3197		$(OS_IF_INC) \
3198		$(GLOBAL_LMAC_IF_INC) \
3199		$(FTM_INC)
3200
3201INCS +=		$(WMA_INC) \
3202		$(UAPI_INC) \
3203		$(COMMON_INC) \
3204		$(WMI_INC) \
3205		$(FWLOG_INC) \
3206		$(TXRX_INC) \
3207		$(OL_INC) \
3208		$(CDP_INC) \
3209		$(PKTLOG_INC) \
3210		$(HTT_INC) \
3211		$(INIT_DEINIT_INC) \
3212		$(SCHEDULER_INC) \
3213		$(REGULATORY_INC) \
3214		$(HTC_INC) \
3215		$(WCFG_INC)
3216
3217INCS +=		$(HIF_INC) \
3218		$(BMI_INC) \
3219		$(CMN_SYS_INC)
3220
3221ifeq (y,$(filter y,$(CONFIG_LITHIUM) $(CONFIG_BERYLLIUM) $(CONFIG_RHINE)))
3222INCS += 	$(HAL_INC) \
3223		$(DP_INC)
3224endif
3225
3226################ WIFI POS ################
3227INCS +=		$(WIFI_POS_CLD_INC)
3228INCS +=		$(WIFI_POS_API_INC)
3229INCS +=		$(WIFI_POS_TGT_INC)
3230INCS +=		$(WIFI_POS_OS_IF_INC)
3231################ CP STATS ################
3232INCS +=		$(CP_STATS_OS_IF_INC)
3233INCS +=		$(CP_STATS_TGT_INC)
3234INCS +=		$(CP_STATS_DISPATCHER_INC)
3235INCS +=		$(CP_MC_STATS_COMPONENT_INC)
3236INCS +=		$(CP_STATS_CFG80211_OS_IF_INC)
3237################ TWT CONVERGED ################
3238INCS +=		$(TWT_CONV_INCS)
3239################ Dynamic ACS ####################
3240INCS +=		$(DCS_TGT_IF_INC)
3241INCS +=		$(DCS_DISP_INC)
3242################ AFC #################
3243INCS +=		$(AFC_CMN_OSIF_INC)
3244INCS +=		$(AFC_CMN_DISP_INC)
3245INCS +=		$(AFC_CMN_CORE_INC)
3246################ INTEROP ISSUES AP ################
3247INCS +=		$(INTEROP_ISSUES_AP_OS_IF_INC)
3248INCS +=		$(INTEROP_ISSUES_AP_TGT_INC)
3249INCS +=		$(INTEROP_ISSUES_AP_DISPATCHER_INC)
3250INCS +=		$(INTEROP_ISSUES_AP_CORE_INC)
3251################ NAN POS ################
3252INCS +=		$(NAN_CORE_INC)
3253INCS +=		$(NAN_UCFG_INC)
3254INCS +=		$(NAN_TGT_INC)
3255INCS +=		$(NAN_OS_IF_INC)
3256###########DP_COMPONENT ####################
3257INCS +=		$(DP_COMP_INC)
3258###########QMI_COMPONENT ####################
3259INCS +=		$(QMI_COMP_INC)
3260################ SON ################
3261INCS +=		$(SON_CORE_INC)
3262INCS +=		$(SON_UCFG_INC)
3263INCS +=		$(SON_TGT_INC)
3264INCS +=		$(SON_OS_IF_INC)
3265################ SPATIAL_REUSE ################
3266INCS +=		$(SR_UCFG_INC)
3267INCS +=		$(SR_TGT_INC)
3268##########################################
3269
3270INCS +=		$(UMAC_OBJMGR_INC)
3271INCS +=		$(UMAC_MGMT_TXRX_INC)
3272INCS +=		$(PMO_INC)
3273INCS +=		$(P2P_INC)
3274INCS +=		$(POLICY_MGR_INC)
3275INCS +=		$(TARGET_INC)
3276INCS +=		$(TDLS_INC)
3277INCS +=		$(UMAC_SER_INC)
3278INCS +=		$(NLINK_INC) \
3279		$(PTT_INC) \
3280		$(WLAN_LOGGING_INC)
3281
3282INCS +=		$(PLD_INC)
3283INCS +=		$(OCB_INC)
3284
3285INCS +=		$(IPA_INC)
3286INCS +=		$(UMAC_SM_INC)
3287INCS +=		$(UMAC_MLME_INC)
3288INCS +=		$(MLME_INC)
3289INCS +=		$(FWOL_INC)
3290INCS +=		$(DLM_INC)
3291INCS +=		$(CONN_LOGGING_INC)
3292
3293ifeq ($(CONFIG_REMOVE_PKT_LOG), n)
3294INCS +=		$(PKTLOG_INC)
3295endif
3296
3297INCS +=		$(HOST_DIAG_LOG_INC)
3298
3299INCS +=		$(DISA_INC)
3300INCS +=		$(ACTION_OUI_INC)
3301INCS +=		$(PKT_CAPTURE_INC)
3302INCS +=		$(FTM_TIME_SYNC_INC)
3303INCS +=		$(WLAN_PRE_CAC_INC)
3304
3305INCS +=		$(UMAC_DISP_INC)
3306INCS +=		$(UMAC_SCAN_INC)
3307INCS +=		$(UMAC_TARGET_SCAN_INC)
3308INCS +=		$(UMAC_GREEN_AP_INC)
3309INCS +=		$(UMAC_TARGET_GREEN_AP_INC)
3310INCS +=		$(UMAC_COMMON_INC)
3311INCS +=		$(UMAC_SPECTRAL_INC)
3312INCS +=		$(WLAN_CFR_INC)
3313INCS +=		$(UMAC_TARGET_SPECTRAL_INC)
3314INCS +=		$(UMAC_GPIO_INC)
3315INCS +=		$(UMAC_TARGET_GPIO_INC)
3316INCS +=		$(UMAC_DBR_INC)
3317INCS +=		$(UMAC_CRYPTO_INC)
3318INCS +=		$(UMAC_INTERFACE_MGR_INC)
3319INCS +=		$(UMAC_MLO_MGR_INC)
3320INCS +=		$(UMAC_MLO_MGR_CLD_INC)
3321INCS +=		$(COEX_OS_IF_INC)
3322INCS +=		$(COEX_TGT_INC)
3323INCS +=		$(COEX_DISPATCHER_INC)
3324INCS +=		$(COEX_CORE_INC)
3325INCS +=		$(COEX_STRUCT_INC)
3326################ COAP ################
3327INCS +=		$(COAP_OS_IF_INC)
3328INCS +=		$(COAP_TGT_INC)
3329INCS +=		$(COAP_DISPATCHER_INC)
3330INCS +=		$(COAP_CORE_INC)
3331INCS +=		$(COAP_WMI_INC)
3332
3333ccflags-y += $(INCS)
3334
3335ccflags-y += -include $(WLAN_ROOT)/configs/default_config.h
3336
3337# CFG80211_MLO_KEY_OPERATION_SUPPORT
3338# Used to indicate the Linux Kernel contains support for ML key operation
3339# support.
3340#
3341# This feature was backported to Android Common Kernel 5.15 via:
3342# https://android-review.googlesource.com/c/kernel/common/+/2173923
3343found = $(shell if grep -qF "nl80211_validate_key_link_id" $(srctree)/net/wireless/nl80211.c; then echo "yes" ;else echo "no" ;fi;)
3344ifeq ($(findstring yes, $(found)), yes)
3345ccflags-y += -DCFG80211_MLO_KEY_OPERATION_SUPPORT
3346endif
3347
3348found = $(shell if grep -qF "struct link_station_parameters" $(srctree)/include/net/cfg80211.h; then echo "yes"; else echo "no"; fi;)
3349ifeq ($(findstring yes, $(found)), yes)
3350ccflags-y += -DCFG80211_LINK_STA_PARAMS_PRESENT
3351endif
3352
3353found = $(shell if grep -qF "NL80211_EXT_FEATURE_PUNCT" $(srctree)/include/uapi/linux/nl80211.h; then echo "yes" ;else echo "no" ;fi;)
3354ifeq ($(findstring yes, $(found)), yes)
3355ccflags-y += -DNL80211_EXT_FEATURE_PUNCT_SUPPORT
3356endif
3357
3358found = $(shell if grep -qF "unsigned int link_id, u16 punct_bitmap" $(srctree)/include/net/cfg80211.h; then echo "yes" ;else echo "no" ;fi;)
3359ifeq ($(findstring yes, $(found)), yes)
3360ccflags-y += -DCFG80211_RU_PUNCT_NOTIFY
3361endif
3362
3363found = $(shell if grep -qF "NL80211_EXT_FEATURE_AUTH_AND_DEAUTH_RANDOM_TA" $(srctree)/include/uapi/linux/nl80211.h; then echo "yes"; else echo "no"; fi;)
3364ifeq ($(findstring yes, $(found)), yes)
3365ccflags-y += -DCFG80211_EXT_FEATURE_AUTH_AND_DEAUTH_RANDOM_TA
3366endif
3367
3368# CFG80211_EXTERNAL_AUTH_MLO_SUPPORT
3369# Used to indicate Linux kernel contains support for ML external auth support.
3370#
3371# This feature was backported to Android Common Kernel 5.15 via:
3372# https://android-review.googlesource.com/c/kernel/common/+/2450264
3373found = $(shell if grep -qF "MLD address of the peer. Used by the authentication request event" $(srctree)/include/net/cfg80211.h; then echo "yes" ;else echo "no" ;fi;)
3374ifeq ($(findstring yes, $(found)), yes)
3375ccflags-y += -DCFG80211_EXTERNAL_AUTH_MLO_SUPPORT
3376endif
3377
3378found = $(shell if grep -qF "NL80211_EXT_FEATURE_SECURE_NAN" $(srctree)/include/uapi/linux/nl80211.h; then echo "yes"; else echo "no"; fi;)
3379ifeq ($(findstring yes, $(found)), yes)
3380ccflags-y += -DCFG80211_EXT_FEATURE_SECURE_NAN
3381endif
3382
3383found = $(shell if grep -qF "bool mlo_params_valid;" $(srctree)/include/net/cfg80211.h; then echo "yes" ;else echo "no" ;fi;)
3384ifeq ($(findstring yes, $(found)), yes)
3385ccflags-y += -DCFG80211_MLD_AP_STA_CONNECT_UPSTREAM_SUPPORT
3386endif
3387
3388ifeq (qca_cld3, $(WLAN_WEAR_CHIPSET))
3389	ccflags-y += -DWLAN_WEAR_CHIPSET
3390endif
3391
3392ccflags-$(CONFIG_ONE_MSI_VECTOR) += -DWLAN_ONE_MSI_VECTOR
3393
3394ccflags-$(CONFIG_DSC_DEBUG) += -DWLAN_DSC_DEBUG
3395ccflags-$(CONFIG_DSC_TEST) += -DWLAN_DSC_TEST
3396
3397ifeq ($(CONFIG_LITHIUM), y)
3398ccflags-y += -DCONFIG_LITHIUM
3399endif
3400
3401ifeq ($(CONFIG_BERYLLIUM), y)
3402ccflags-y += -DCONFIG_BERYLLIUM
3403ccflags-y += -DDP_OFFLOAD_FRAME_WITH_SW_EXCEPTION
3404endif
3405
3406ifeq ($(CONFIG_RHINE), y)
3407ccflags-y += -DCONFIG_RHINE
3408ccflags-y += -DDP_OFFLOAD_FRAME_WITH_SW_EXCEPTION
3409endif
3410
3411ccflags-$(CONFIG_TALLOC_DEBUG) += -DWLAN_TALLOC_DEBUG
3412ccflags-$(CONFIG_QDF_TEST) += -DWLAN_DELAYED_WORK_TEST
3413ccflags-$(CONFIG_QDF_TEST) += -DWLAN_HASHTABLE_TEST
3414ccflags-$(CONFIG_QDF_TEST) += -DWLAN_PERIODIC_WORK_TEST
3415ccflags-$(CONFIG_QDF_TEST) += -DWLAN_PTR_HASH_TEST
3416ccflags-$(CONFIG_QDF_TEST) += -DWLAN_SLIST_TEST
3417ccflags-$(CONFIG_QDF_TEST) += -DWLAN_TALLOC_TEST
3418ccflags-$(CONFIG_QDF_TEST) += -DWLAN_TRACKER_TEST
3419ccflags-$(CONFIG_QDF_TEST) += -DWLAN_TYPES_TEST
3420ccflags-$(CONFIG_WLAN_HANG_EVENT) += -DWLAN_HANG_EVENT
3421
3422#Flag to enable pre_cac
3423ccflags-$(CONFIG_FEATURE_WLAN_PRE_CAC)  += -DPRE_CAC_SUPPORT
3424
3425ccflags-$(CONFIG_WIFI_POS_PASN) += -DWLAN_FEATURE_RTT_11AZ_SUPPORT
3426
3427ifeq ($(CONFIG_DIRECT_BUF_RX_ENABLE), y)
3428ifeq ($(CONFIG_DBR_HOLD_LARGE_MEM), y)
3429ccflags-y += -DDBR_HOLD_LARGE_MEM
3430endif
3431endif
3432
3433ccflags-$(CONFIG_QCA_DMA_PADDR_CHECK) += -DQCA_DMA_PADDR_CHECK
3434ccflags-$(CONFIG_PADDR_CHECK_ON_3RD_PARTY_PLATFORM) += -DQCA_PADDR_CHECK_ON_3RD_PARTY_PLATFORM
3435ccflags-$(CONFIG_DP_TRAFFIC_END_INDICATION) += -DDP_TRAFFIC_END_INDICATION
3436ccflags-$(CONFIG_THERMAL_STATS_SUPPORT) += -DTHERMAL_STATS_SUPPORT
3437ccflags-$(CONFIG_PTT_SOCK_SVC_ENABLE) += -DPTT_SOCK_SVC_ENABLE
3438ccflags-$(CONFIG_FEATURE_WLAN_WAPI) += -DFEATURE_WLAN_WAPI
3439ccflags-$(CONFIG_FEATURE_WLAN_WAPI) += -DATH_SUPPORT_WAPI
3440ccflags-$(CONFIG_SOFTAP_CHANNEL_RANGE) += -DSOFTAP_CHANNEL_RANGE
3441ccflags-$(CONFIG_FEATURE_WLAN_SCAN_PNO) += -DFEATURE_WLAN_SCAN_PNO
3442ccflags-$(CONFIG_WLAN_FEATURE_PACKET_FILTERING) += -DWLAN_FEATURE_PACKET_FILTERING
3443ccflags-$(CONFIG_DHCP_SERVER_OFFLOAD) += -DDHCP_SERVER_OFFLOAD
3444ccflags-$(CONFIG_WLAN_NS_OFFLOAD) += -DWLAN_NS_OFFLOAD
3445ccflags-$(CONFIG_QCA_TARGET_IF_MLME) += -DQCA_TARGET_IF_MLME
3446ccflags-$(CONFIG_WLAN_DYNAMIC_ARP_NS_OFFLOAD) += -DFEATURE_WLAN_DYNAMIC_ARP_NS_OFFLOAD
3447ccflags-$(CONFIG_WLAN_FEATURE_ICMP_OFFLOAD) += -DWLAN_FEATURE_ICMP_OFFLOAD
3448ccflags-$(CONFIG_FEATURE_WLAN_RA_FILTERING) += -DFEATURE_WLAN_RA_FILTERING
3449ccflags-$(CONFIG_FEATURE_WLAN_LPHB) += -DFEATURE_WLAN_LPHB
3450ccflags-$(CONFIG_QCA_SUPPORT_TX_THROTTLE) += -DQCA_SUPPORT_TX_THROTTLE
3451ccflags-$(CONFIG_WMI_INTERFACE_EVENT_LOGGING) += -DWMI_INTERFACE_EVENT_LOGGING
3452ccflags-$(CONFIG_WLAN_FEATURE_LINK_LAYER_STATS) += -DWLAN_FEATURE_LINK_LAYER_STATS
3453ccflags-$(CONFIG_FEATURE_CLUB_LL_STATS_AND_GET_STATION) += -DFEATURE_CLUB_LL_STATS_AND_GET_STATION
3454ccflags-$(CONFIG_WLAN_FEATURE_MIB_STATS) += -DWLAN_FEATURE_MIB_STATS
3455ccflags-$(CONFIG_FEATURE_WLAN_EXTSCAN) += -DFEATURE_WLAN_EXTSCAN
3456ccflags-$(CONFIG_160MHZ_SUPPORT) += -DCONFIG_160MHZ_SUPPORT
3457ccflags-$(CONFIG_REG_CLIENT) += -DCONFIG_REG_CLIENT
3458ccflags-$(CONFIG_WLAN_PMO_ENABLE) += -DWLAN_PMO_ENABLE
3459ccflags-$(CONFIG_CONVERGED_P2P_ENABLE) += -DCONVERGED_P2P_ENABLE
3460ccflags-$(CONFIG_WLAN_POLICY_MGR_ENABLE) += -DWLAN_POLICY_MGR_ENABLE
3461ccflags-$(CONFIG_FEATURE_DENYLIST_MGR) += -DFEATURE_DENYLIST_MGR
3462ccflags-$(CONFIG_WAPI_BIG_ENDIAN) += -DFEATURE_WAPI_BIG_ENDIAN
3463ccflags-$(CONFIG_SUPPORT_11AX) += -DSUPPORT_11AX
3464ccflags-$(CONFIG_HDD_INIT_WITH_RTNL_LOCK) += -DCONFIG_HDD_INIT_WITH_RTNL_LOCK
3465ccflags-$(CONFIG_WLAN_CONV_SPECTRAL_ENABLE) += -DWLAN_CONV_SPECTRAL_ENABLE
3466ccflags-$(CONFIG_WLAN_CFR_ENABLE) += -DWLAN_CFR_ENABLE
3467ccflags-$(CONFIG_WLAN_ENH_CFR_ENABLE) += -DWLAN_ENH_CFR_ENABLE
3468ccflags-$(CONFIG_WLAN_ENH_CFR_ENABLE) += -DWLAN_CFR_PM
3469ccflags-$(CONFIG_WLAN_CFR_ADRASTEA) += -DWLAN_CFR_ADRASTEA
3470ccflags-$(CONFIG_WLAN_CFR_DBR) += -DWLAN_CFR_DBR
3471ccflags-$(CONFIG_WLAN_CFR_ENABLE) += -DCFR_USE_FIXED_FOLDER
3472ccflags-$(CONFIG_WLAN_FEATURE_MEDIUM_ASSESS) += -DWLAN_FEATURE_MEDIUM_ASSESS
3473ccflags-$(CONFIG_FEATURE_RADAR_HISTORY) += -DFEATURE_RADAR_HISTORY
3474ccflags-$(CONFIG_DIRECT_BUF_RX_ENABLE) += -DDIRECT_BUF_RX_ENABLE
3475ccflags-$(CONFIG_WMI_DBR_SUPPORT) += -DWMI_DBR_SUPPORT
3476ifneq ($(CONFIG_CNSS_QCA6750), y)
3477ccflags-$(CONFIG_DIRECT_BUF_RX_ENABLE) += -DDBR_MULTI_SRNG_ENABLE
3478endif
3479ifneq ($(CONFIG_CNSS_WCN6450), y)
3480ccflags-$(CONFIG_DIRECT_BUF_RX_ENABLE) += -DDBR_MULTI_SRNG_ENABLE
3481endif
3482ccflags-$(CONFIG_WMI_CMD_STRINGS) += -DWMI_CMD_STRINGS
3483ccflags-$(CONFIG_WLAN_FEATURE_TWT) += -DWLAN_SUPPORT_TWT
3484ifeq ($(CONFIG_WLAN_FEATURE_11BE_MLO), y)
3485ifeq ($(CONFIG_DP_USE_REDUCED_PEER_ID_FIELD_WIDTH), y)
3486ccflags-y += -DDP_USE_REDUCED_PEER_ID_FIELD_WIDTH
3487endif
3488endif
3489ccflags-$(CONFIG_DP_MULTIPASS_SUPPORT) += -DQCA_MULTIPASS_SUPPORT
3490ccflags-$(CONFIG_DP_MULTIPASS_SUPPORT) += -DWLAN_REPEATER_NOT_SUPPORTED
3491ccflags-$(CONFIG_DP_MULTIPASS_SUPPORT) += -DQCA_SUPPORT_PEER_ISOLATION
3492ccflags-$(CONFIG_WLAN_DP_PROFILE_SUPPORT) += -DWLAN_DP_PROFILE_SUPPORT
3493
3494ifdef CONFIG_WLAN_TWT_SAP_STA_COUNT
3495WLAN_TWT_SAP_STA_COUNT ?= 32
3496ccflags-y += -DWLAN_TWT_SAP_STA_COUNT=$(WLAN_TWT_SAP_STA_COUNT)
3497endif
3498
3499ccflags-$(CONFIG_ENABLE_LOW_POWER_MODE) += -DCONFIG_ENABLE_LOW_POWER_MODE
3500ccflags-$(CONFIG_WLAN_TWT_SAP_PDEV_COUNT) += -DWLAN_TWT_AP_PDEV_COUNT_NUM_PHY
3501ccflags-$(CONFIG_WLAN_DISABLE_EXPORT_SYMBOL) += -DWLAN_DISABLE_EXPORT_SYMBOL
3502ccflags-$(CONFIG_WIFI_POS_CONVERGED) += -DWIFI_POS_CONVERGED
3503ccflags-$(CONFIG_WLAN_TWT_CONVERGED) += -DWLAN_TWT_CONV_SUPPORTED
3504ccflags-$(CONFIG_WIFI_POS_LEGACY) += -DFEATURE_OEM_DATA_SUPPORT
3505ccflags-$(CONFIG_FEATURE_HTC_CREDIT_HISTORY) += -DFEATURE_HTC_CREDIT_HISTORY
3506ccflags-$(CONFIG_WLAN_FEATURE_P2P_DEBUG) += -DWLAN_FEATURE_P2P_DEBUG
3507ccflags-$(CONFIG_WLAN_WEXT_SUPPORT_ENABLE) += -DWLAN_WEXT_SUPPORT_ENABLE
3508ccflags-$(CONFIG_WLAN_LOGGING_SOCK_SVC) += -DWLAN_LOGGING_SOCK_SVC_ENABLE
3509ccflags-$(CONFIG_WLAN_LOGGING_BUFFERS_DYNAMICALLY) += -DWLAN_LOGGING_BUFFERS_DYNAMICALLY
3510ccflags-$(CONFIG_WLAN_FEATURE_FILS) += -DWLAN_FEATURE_FILS_SK
3511ccflags-$(CONFIG_CP_STATS) += -DWLAN_SUPPORT_INFRA_CTRL_PATH_STATS
3512ccflags-$(CONFIG_CP_STATS) += -DQCA_SUPPORT_CP_STATS
3513ccflags-$(CONFIG_CP_STATS) += -DQCA_SUPPORT_MC_CP_STATS
3514ccflags-$(CONFIG_CP_STATS) += -DWLAN_SUPPORT_LEGACY_CP_STATS_HANDLERS
3515ccflags-$(CONFIG_DCS) += -DDCS_INTERFERENCE_DETECTION
3516ccflags-$(CONFIG_FEATURE_INTEROP_ISSUES_AP) += -DWLAN_FEATURE_INTEROP_ISSUES_AP
3517ccflags-$(CONFIG_FEATURE_MEMDUMP_ENABLE) += -DWLAN_FEATURE_MEMDUMP_ENABLE
3518ccflags-$(CONFIG_FEATURE_FW_LOG_PARSING) += -DFEATURE_FW_LOG_PARSING
3519ccflags-$(CONFIG_FEATURE_OEM_DATA) += -DFEATURE_OEM_DATA
3520ccflags-$(CONFIG_FEATURE_MOTION_DETECTION) += -DWLAN_FEATURE_MOTION_DETECTION
3521ccflags-$(CONFIG_WLAN_FW_OFFLOAD) += -DWLAN_FW_OFFLOAD
3522ccflags-$(CONFIG_WLAN_FEATURE_ELNA) += -DWLAN_FEATURE_ELNA
3523ccflags-$(CONFIG_FEATURE_COEX) += -DFEATURE_COEX
3524ccflags-$(CONFIG_HOST_WAKEUP_OVER_QMI) += -DHOST_WAKEUP_OVER_QMI
3525ccflags-$(CONFIG_DISABLE_STATUS_RING_TIMER_WAR) += -DWLAN_DISABLE_STATUS_RING_TIMER_WAR
3526ccflags-$(CONFIG_CE_DISABLE_SRNG_TIMER_IRQ) += -DWLAN_WAR_CE_DISABLE_SRNG_TIMER_IRQ
3527
3528ccflags-$(CONFIG_PLD_IPCI_ICNSS_FLAG) += -DCONFIG_PLD_IPCI_ICNSS
3529ccflags-$(CONFIG_PLD_SDIO_CNSS_FLAG) += -DCONFIG_PLD_SDIO_CNSS
3530ccflags-$(CONFIG_WLAN_RESIDENT_DRIVER) += -DFEATURE_WLAN_RESIDENT_DRIVER
3531ccflags-$(CONFIG_FEATURE_GPIO_CFG) += -DWLAN_FEATURE_GPIO_CFG
3532ccflags-$(CONFIG_FEATURE_BUS_BANDWIDTH_MGR) += -DFEATURE_BUS_BANDWIDTH_MGR
3533ccflags-$(CONFIG_DP_BE_WAR) += -DDP_BE_WAR
3534
3535ifeq ($(CONFIG_IPCIE_FW_SIM), y)
3536ccflags-y += -DCONFIG_PLD_IPCIE_FW_SIM
3537endif
3538ifeq ($(CONFIG_PLD_PCIE_CNSS_FLAG), y)
3539ifeq ($(CONFIG_PCIE_FW_SIM), y)
3540ccflags-y += -DCONFIG_PLD_PCIE_FW_SIM
3541else
3542ccflags-y += -DCONFIG_PLD_PCIE_CNSS
3543endif
3544endif
3545
3546ccflags-$(CONFIG_PLD_PCIE_INIT_FLAG) += -DCONFIG_PLD_PCIE_INIT
3547ccflags-$(CONFIG_WLAN_FEATURE_DP_RX_THREADS) += -DFEATURE_WLAN_DP_RX_THREADS
3548ccflags-$(CONFIG_WLAN_DP_LOCAL_PKT_CAPTURE) += -DWLAN_FEATURE_LOCAL_PKT_CAPTURE
3549ccflags-$(CONFIG_WLAN_FEATURE_RX_SOFTIRQ_TIME_LIMIT) += -DWLAN_FEATURE_RX_SOFTIRQ_TIME_LIMIT
3550ccflags-$(CONFIG_FEATURE_HIF_LATENCY_PROFILE_ENABLE) += -DHIF_LATENCY_PROFILE_ENABLE
3551ccflags-$(CONFIG_FEATURE_HAL_DELAYED_REG_WRITE) += -DFEATURE_HAL_DELAYED_REG_WRITE
3552ccflags-$(CONFIG_FEATURE_HAL_RECORD_SUSPEND_WRITE) += -DFEATURE_HAL_RECORD_SUSPEND_WRITE
3553ccflags-$(CONFIG_QCA_OL_DP_SRNG_LOCK_LESS_ACCESS) += -DQCA_OL_DP_SRNG_LOCK_LESS_ACCESS
3554ccflags-$(CONFIG_SHADOW_WRITE_DELAY) += -DSHADOW_WRITE_DELAY
3555
3556ccflags-$(CONFIG_PLD_USB_CNSS) += -DCONFIG_PLD_USB_CNSS
3557ccflags-$(CONFIG_PLD_SDIO_CNSS2) += -DCONFIG_PLD_SDIO_CNSS2
3558ccflags-$(CONFIG_WLAN_RECORD_RX_PADDR) += -DHIF_RECORD_RX_PADDR
3559ccflags-$(CONFIG_FEATURE_WLAN_TIME_SYNC_FTM) += -DFEATURE_WLAN_TIME_SYNC_FTM
3560
3561ccflags-$(CONFIG_WLAN_FEATURE_LRO_CTX_IN_CB) += -DWLAN_FEATURE_LRO_CTX_IN_CB
3562
3563#For both legacy and lithium chip's monitor mode config
3564ifeq ($(CONFIG_FEATURE_MONITOR_MODE_SUPPORT), y)
3565ccflags-y += -DFEATURE_MONITOR_MODE_SUPPORT
3566ccflags-$(CONFIG_DP_CON_MON_MSI_ENABLED) += -DDP_CON_MON_MSI_ENABLED
3567ccflags-$(CONFIG_WLAN_RX_MON_PARSE_CMN_USER_INFO) += -DWLAN_RX_MON_PARSE_CMN_USER_INFO
3568ccflags-$(CONFIG_DP_CON_MON_MSI_SKIP_SET) += -DDP_CON_MON_MSI_SKIP_SET
3569ccflags-$(CONFIG_QCA_WIFI_MONITOR_MODE_NO_MSDU_START_TLV_SUPPORT) += -DQCA_WIFI_MONITOR_MODE_NO_MSDU_START_TLV_SUPPORT
3570else
3571ccflags-y += -DDISABLE_MON_CONFIG
3572endif
3573
3574ifeq ($(CONFIG_SMP), y)
3575ifneq (y,$(filter y,$(CONFIG_LITHIUM) $(CONFIG_BERYLLIUM) $(CONFIG_RHINE)))
3576ccflags-y += -DWLAN_DP_LEGACY_OL_RX_THREAD
3577endif
3578endif
3579
3580#Enable NL80211 test mode
3581ccflags-$(CONFIG_NL80211_TESTMODE) += -DWLAN_NL80211_TESTMODE
3582
3583# Flag to enable bus auto suspend
3584ifeq ($(CONFIG_BUS_AUTO_SUSPEND), y)
3585ccflags-y += -DFEATURE_RUNTIME_PM
3586endif
3587
3588ifeq (y,$(findstring y, $(CONFIG_ICNSS) $(CONFIG_ICNSS_MODULE)))
3589ifeq ($(CONFIG_SNOC_FW_SIM), y)
3590ccflags-y += -DCONFIG_PLD_SNOC_FW_SIM
3591else
3592ccflags-y += -DCONFIG_PLD_SNOC_ICNSS
3593endif
3594endif
3595
3596ccflags-$(CONFIG_PLD_SNOC_ICNSS_FLAG) += -DCONFIG_PLD_SNOC_ICNSS
3597ccflags-$(CONFIG_ICNSS2_HELIUM) += -DCONFIG_PLD_SNOC_ICNSS2
3598
3599ccflags-$(CONFIG_WIFI_3_0_ADRASTEA) += -DQCA_WIFI_3_0_ADRASTEA
3600ccflags-$(CONFIG_WIFI_3_0_ADRASTEA) += -DQCA_WIFI_3_0
3601ccflags-$(CONFIG_ADRASTEA_SHADOW_REGISTERS) += -DADRASTEA_SHADOW_REGISTERS
3602ccflags-$(CONFIG_ADRASTEA_RRI_ON_DDR) += -DADRASTEA_RRI_ON_DDR
3603
3604ifeq ($(CONFIG_QMI_SUPPORT), n)
3605ccflags-y += -DCONFIG_BYPASS_QMI
3606endif
3607
3608ccflags-$(CONFIG_WLAN_FASTPATH) +=	-DWLAN_FEATURE_FASTPATH
3609
3610ccflags-$(CONFIG_FEATURE_PKTLOG) +=     -DFEATURE_PKTLOG
3611
3612ccflags-$(CONFIG_CONNECTIVITY_PKTLOG) += -DCONNECTIVITY_PKTLOG
3613
3614ifeq ($(CONFIG_WLAN_NAPI), y)
3615ccflags-y += -DFEATURE_NAPI
3616ccflags-y += -DHIF_IRQ_AFFINITY
3617ifeq ($(CONFIG_WLAN_NAPI_DEBUG), y)
3618ccflags-y += -DFEATURE_NAPI_DEBUG
3619endif
3620endif
3621
3622ifeq (y,$(findstring y,$(CONFIG_ARCH_MSM) $(CONFIG_ARCH_QCOM)))
3623ccflags-y += -DMSM_PLATFORM
3624endif
3625
3626ccflags-$(CONFIG_CNSS_OUT_OF_TREE) += -DCONFIG_CNSS_OUT_OF_TREE
3627ccflags-$(CONFIG_CNSS_OUT_OF_TREE) += -I$(WLAN_PLATFORM_INC)
3628ccflags-$(CONFIG_IPA_OUT_OF_TREE) += -I$(DATA_IPA_INC)
3629ccflags-$(CONFIG_IPA_OUT_OF_TREE) += -I$(DATA_IPA_UAPI_INC)
3630
3631ccflags-$(CONFIG_WLAN_FEATURE_DP_BUS_BANDWIDTH) += -DWLAN_FEATURE_DP_BUS_BANDWIDTH
3632ccflags-$(CONFIG_WLAN_FEATURE_PERIODIC_STA_STATS) += -DWLAN_FEATURE_PERIODIC_STA_STATS
3633
3634ccflags-$(CONFIG_WLAN_TX_FLOW_CONTROL_V2) += -DQCA_LL_TX_FLOW_CONTROL_V2
3635ccflags-$(CONFIG_WLAN_TX_FLOW_CONTROL_V2) += -DQCA_LL_TX_FLOW_GLOBAL_MGMT_POOL
3636ccflags-$(CONFIG_WLAN_TX_FLOW_CONTROL_LEGACY) += -DQCA_LL_LEGACY_TX_FLOW_CONTROL
3637ccflags-$(CONFIG_WLAN_PDEV_TX_FLOW_CONTROL) += -DQCA_LL_PDEV_TX_FLOW_CONTROL
3638
3639ifeq ($(CONFIG_WLAN_DEBUG_VERSION), y)
3640ccflags-y +=	-DWLAN_DEBUG
3641ifeq ($(CONFIG_TRACE_RECORD_FEATURE), y)
3642ccflags-y +=	-DTRACE_RECORD \
3643		-DLIM_TRACE_RECORD \
3644		-DSME_TRACE_RECORD \
3645		-DHDD_TRACE_RECORD
3646endif
3647endif
3648ccflags-$(CONFIG_UNIT_TEST) += -DWLAN_UNIT_TEST
3649ccflags-$(CONFIG_WLAN_DEBUG_CRASH_INJECT) += -DCONFIG_WLAN_DEBUG_CRASH_INJECT
3650ccflags-$(CONFIG_WLAN_SYSFS_FW_MODE_CFG) += -DCONFIG_WLAN_SYSFS_FW_MODE_CFG
3651ccflags-$(CONFIG_WLAN_REASSOC) += -DCONFIG_WLAN_REASSOC
3652ccflags-$(CONFIG_WLAN_SCAN_DISABLE) += -DCONFIG_WLAN_SCAN_DISABLE
3653ccflags-$(CONFIG_WLAN_WOW_ITO) += -DCONFIG_WLAN_WOW_ITO
3654ccflags-$(CONFIG_WLAN_WOWL_ADD_PTRN) += -DCONFIG_WLAN_WOWL_ADD_PTRN
3655ccflags-$(CONFIG_WLAN_WOWL_DEL_PTRN) += -DCONFIG_WLAN_WOWL_DEL_PTRN
3656ccflags-$(CONFIG_WLAN_SYSFS_TX_STBC) += -DCONFIG_WLAN_SYSFS_TX_STBC
3657ccflags-$(CONFIG_WLAN_GET_STATS) += -DCONFIG_WLAN_GET_STATS
3658ccflags-$(CONFIG_WLAN_SYSFS_WLAN_DBG) += -DCONFIG_WLAN_SYSFS_WLAN_DBG
3659ccflags-$(CONFIG_WLAN_TXRX_FW_ST_RST) += -DCONFIG_WLAN_TXRX_FW_ST_RST
3660ccflags-$(CONFIG_WLAN_GTX_BW_MASK) += -DCONFIG_WLAN_GTX_BW_MASK
3661ccflags-$(CONFIG_WLAN_SYSFS_SCAN_CFG) += -DCONFIG_WLAN_SYSFS_SCAN_CFG
3662ccflags-$(CONFIG_WLAN_SYSFS_MONITOR_MODE_CHANNEL) += -DCONFIG_WLAN_SYSFS_MONITOR_MODE_CHANNEL
3663ccflags-$(CONFIG_WLAN_SYSFS_RADAR) += -DCONFIG_WLAN_SYSFS_RADAR
3664ccflags-$(CONFIG_WLAN_SYSFS_RTS_CTS) += -DWLAN_SYSFS_RTS_CTS
3665ccflags-$(CONFIG_WLAN_TXRX_FW_STATS) += -DCONFIG_WLAN_TXRX_FW_STATS
3666ccflags-$(CONFIG_WLAN_TXRX_STATS) += -DCONFIG_WLAN_TXRX_STATS
3667ccflags-$(CONFIG_WLAN_SYSFS_DP_TRACE) += -DWLAN_SYSFS_DP_TRACE
3668ccflags-$(CONFIG_WLAN_SYSFS_STATS) += -DWLAN_SYSFS_STATS
3669ccflags-$(CONFIG_WLAN_SYSFS_TEMPERATURE) += -DCONFIG_WLAN_SYSFS_TEMPERATURE
3670ccflags-$(CONFIG_WLAN_THERMAL_CFG) += -DCONFIG_WLAN_THERMAL_CFG
3671ccflags-$(CONFIG_FEATURE_UNIT_TEST_SUSPEND) += -DWLAN_SUSPEND_RESUME_TEST
3672ccflags-$(CONFIG_FEATURE_WLM_STATS) += -DFEATURE_WLM_STATS
3673ccflags-$(CONFIG_WLAN_SYSFS_MEM_STATS) += -DCONFIG_WLAN_SYSFS_MEM_STATS
3674ccflags-$(CONFIG_WLAN_SYSFS_DCM) += -DWLAN_SYSFS_DCM
3675ccflags-$(CONFIG_WLAN_SYSFS_HE_BSS_COLOR) += -DWLAN_SYSFS_HE_BSS_COLOR
3676ccflags-$(CONFIG_WLAN_SYSFS_STA_INFO) += -DWLAN_SYSFS_STA_INFO
3677ccflags-$(CONFIG_WLAN_DL_MODES) += -DCONFIG_WLAN_DL_MODES
3678ccflags-$(CONFIG_WLAN_THERMAL_MULTI_CLIENT_SUPPORT) += -DFEATURE_WPSS_THERMAL_MITIGATION
3679ccflags-$(CONFIG_WLAN_DUMP_IN_PROGRESS) += -DCONFIG_WLAN_DUMP_IN_PROGRESS
3680ccflags-$(CONFIG_WLAN_BMISS) += -DCONFIG_WLAN_BMISS
3681ccflags-$(CONFIG_WLAN_SYSFS_DP_STATS) += -DWLAN_SYSFS_DP_STATS
3682ccflags-$(CONFIG_WLAN_FREQ_LIST) += -DCONFIG_WLAN_FREQ_LIST
3683
3684ccflags-$(CONFIG_WIFI_MONITOR_SUPPORT) += -DWIFI_MONITOR_SUPPORT
3685ccflags-$(CONFIG_QCA_MONITOR_PKT_SUPPORT) += -DQCA_MONITOR_PKT_SUPPORT
3686ccflags-$(CONFIG_MONITOR_MODULARIZED_ENABLE) += -DMONITOR_MODULARIZED_ENABLE
3687ccflags-$(CONFIG_DP_PKT_ADD_TIMESTAMP) += -DCONFIG_DP_PKT_ADD_TIMESTAMP
3688ccflags-$(CONFIG_WLAN_PDEV_VDEV_SEND_MULTI_PARAM) += -DWLAN_PDEV_VDEV_SEND_MULTI_PARAM
3689ccflags-$(CONFIG_WLAN_SYSFS_LOG_BUFFER) += -DFEATURE_SYSFS_LOG_BUFFER
3690ccflags-$(CONFIG_ENABLE_VALLOC_REPLACE_MALLOC) += -DENABLE_VALLOC_REPLACE_MALLOC
3691ccflags-$(CONFIG_WLAN_SYSFS_DFSNOL) += -DCONFIG_WLAN_SYSFS_DFSNOL
3692ccflags-$(CONFIG_WLAN_SYSFS_WDS_MODE) += -DFEATURE_SYSFS_WDS_MODE
3693ccflags-$(CONFIG_WLAN_SYSFS_ROAM_TRIGGER_BITMAP) += -DFEATURE_SYSFS_ROAM_TRIGGER_BITMAP
3694cppflags-$(CONFIG_BCN_RATECODE_ENABLE) += -DWLAN_BCN_RATECODE_ENABLE
3695ccflags-$(CONFIG_WLAN_SYSFS_RF_TEST_MODE) += -DFEATURE_SYSFS_RF_TEST_MODE
3696
3697ifeq ($(CONFIG_LEAK_DETECTION), y)
3698ccflags-y += \
3699	-DCONFIG_HALT_KMEMLEAK \
3700	-DCONFIG_LEAK_DETECTION \
3701	-DMEMORY_DEBUG \
3702	-DNBUF_MEMORY_DEBUG \
3703	-DNBUF_MAP_UNMAP_DEBUG \
3704	-DTIMER_MANAGER \
3705	-DWLAN_DELAYED_WORK_DEBUG \
3706	-DWLAN_WAKE_LOCK_DEBUG \
3707	-DWLAN_PERIODIC_WORK_DEBUG
3708endif
3709
3710cppflags-$(CONFIG_ALLOC_CONTIGUOUS_MULTI_PAGE) += -DALLOC_CONTIGUOUS_MULTI_PAGE
3711
3712ifeq ($(CONFIG_QCOM_VOWIFI_11R), y)
3713ccflags-y += -DKERNEL_SUPPORT_11R_CFG80211
3714ccflags-y += -DUSE_80211_WMMTSPEC_FOR_RIC
3715endif
3716
3717ifeq ($(CONFIG_QCOM_ESE), y)
3718ccflags-y += -DFEATURE_WLAN_ESE
3719endif
3720
3721#normally, TDLS negative behavior is not needed
3722ccflags-$(CONFIG_QCOM_TDLS) += -DFEATURE_WLAN_TDLS
3723ccflags-$(CONFIG_QCOM_TDLS) += -DWLAN_FEATURE_TDLS_CONCURRENCIES
3724
3725ifeq (y,$(filter y,$(CONFIG_LITHIUM) $(CONFIG_BERYLLIUM)))
3726ccflags-$(CONFIG_QCOM_TDLS) += -DTDLS_WOW_ENABLED
3727endif
3728
3729ccflags-$(CONFIG_WLAN_SYSFS_TDLS_PEERS) += -DWLAN_SYSFS_TDLS_PEERS
3730ccflags-$(CONFIG_WLAN_SYSFS_RANGE_EXT) += -DWLAN_SYSFS_RANGE_EXT
3731
3732ccflags-$(CONFIG_QCACLD_WLAN_LFR2) += -DWLAN_FEATURE_PREAUTH_ENABLE
3733
3734ifeq ($(CONFIG_CM_UTF_ENABLE), y)
3735ccflags-y += -DFEATURE_CM_UTF_ENABLE
3736endif
3737
3738ccflags-$(CONFIG_QCACLD_WLAN_LFR3) += -DWLAN_FEATURE_ROAM_OFFLOAD
3739ccflags-$(CONFIG_WLAN_FEATURE_ROAM_INFO_STATS) += -DWLAN_FEATURE_ROAM_INFO_STATS
3740ccflags-$(CONFIG_QCACLD_WLAN_CONNECTIVITY_LOGGING) += -DWLAN_FEATURE_CONNECTIVITY_LOGGING
3741ccflags-$(CONFIG_QCACLD_WLAN_CONNECTIVITY_DIAG_EVENT) += -DCONNECTIVITY_DIAG_EVENT
3742ccflags-$(CONFIG_OFDM_SCRAMBLER_SEED) += -DWLAN_FEATURE_OFDM_SCRAMBLER_SEED
3743
3744ccflags-$(CONFIG_WLAN_FEATURE_MBSSID) += -DWLAN_FEATURE_MBSSID
3745ccflags-$(CONFIG_WLAN_FEATURE_P2P_P2P_STA) += -DWLAN_FEATURE_P2P_P2P_STA
3746
3747ifeq (y,$(findstring y, $(CONFIG_CNSS_GENL) $(CONFIG_CNSS_GENL_MODULE)))
3748ccflags-y += -DCNSS_GENL
3749endif
3750
3751ifeq (y,$(findstring y, $(CONFIG_CNSS_UTILS) $(CONFIG_CNSS_UTILS_MODULE)))
3752ccflags-y += -DCNSS_UTILS
3753endif
3754
3755ifeq (y,$(findstring y, $(CONFIG_WCNSS_MEM_PRE_ALLOC) $(CONFIG_WCNSS_MEM_PRE_ALLOC_MODULE)))
3756ccflags-y += -DCNSS_MEM_PRE_ALLOC
3757endif
3758
3759ccflags-$(CONFIG_QCACLD_WLAN_LFR2) += -DWLAN_FEATURE_HOST_ROAM
3760
3761ccflags-$(CONFIG_FEATURE_ROAM_DEBUG) += -DFEATURE_ROAM_DEBUG
3762
3763ccflags-$(CONFIG_WLAN_POWER_DEBUG) += -DWLAN_POWER_DEBUG
3764
3765ccflags-$(CONFIG_WLAN_MWS_INFO_DEBUGFS) += -DWLAN_MWS_INFO_DEBUGFS
3766
3767ifeq ($(CONFIG_WLAN_DEBUG_LINK_VOTE), y)
3768ccflags-$(CONFIG_WLAN_DEBUG_LINK_VOTE) += -DWLAN_DEBUG_LINK_VOTE
3769endif
3770# Enable object manager reference count debug infrastructure
3771ccflags-$(CONFIG_WLAN_OBJMGR_DEBUG) += -DWLAN_OBJMGR_DEBUG
3772ccflags-$(CONFIG_WLAN_OBJMGR_DEBUG) += -DWLAN_OBJMGR_REF_ID_DEBUG
3773ccflags-$(CONFIG_WLAN_OBJMGR_REF_ID_TRACE) += -DWLAN_OBJMGR_REF_ID_TRACE
3774ccflags-$(CONFIG_FEATURE_DELAYED_PEER_OBJ_DESTROY) += -DFEATURE_DELAYED_PEER_OBJ_DESTROY
3775
3776ccflags-$(CONFIG_WLAN_FEATURE_SAE) += -DWLAN_FEATURE_SAE
3777
3778ifeq ($(CONFIG_WLAN_DIAG_VERSION), y)
3779ccflags-y += -DFEATURE_WLAN_DIAG_SUPPORT
3780ccflags-y += -DFEATURE_WLAN_DIAG_SUPPORT_CSR
3781ccflags-y += -DFEATURE_WLAN_DIAG_SUPPORT_LIM
3782ifeq ($(CONFIG_HIF_PCI), y)
3783ccflags-y += -DCONFIG_ATH_PROCFS_DIAG_SUPPORT
3784endif
3785ifeq ($(CONFIG_HIF_IPCI), y)
3786ccflags-y += -DCONFIG_ATH_PROCFS_DIAG_SUPPORT
3787endif
3788endif
3789
3790ifeq ($(CONFIG_HIF_USB), y)
3791ccflags-y += -DCONFIG_ATH_PROCFS_DIAG_SUPPORT
3792ccflags-y += -DQCA_SUPPORT_OL_RX_REORDER_TIMEOUT
3793ccflags-y += -DCONFIG_ATH_PCIE_MAX_PERF=0 -DCONFIG_ATH_PCIE_AWAKE_WHILE_DRIVER_LOAD=0 -DCONFIG_DISABLE_CDC_MAX_PERF_WAR=0
3794endif
3795
3796ccflags-$(CONFIG_QCA_SUPPORT_TXRX_DRIVER_TCP_DEL_ACK) += -DQCA_SUPPORT_TXRX_DRIVER_TCP_DEL_ACK
3797
3798ccflags-$(CONFIG_QCA_TXDESC_SANITY_CHECKS) += -DQCA_SUPPORT_TXDESC_SANITY_CHECKS
3799
3800ccflags-$(CONFIG_QCOM_LTE_COEX) += -DFEATURE_WLAN_CH_AVOID
3801
3802ccflags-$(CONFIG_WLAN_FEATURE_LPSS) += -DWLAN_FEATURE_LPSS
3803
3804ccflags-$(CONFIG_DESC_DUP_DETECT_DEBUG) += -DDESC_DUP_DETECT_DEBUG
3805ccflags-$(CONFIG_DEBUG_RX_RING_BUFFER) += -DDEBUG_RX_RING_BUFFER
3806
3807ccflags-$(CONFIG_DESC_TIMESTAMP_DEBUG_INFO) += -DDESC_TIMESTAMP_DEBUG_INFO
3808
3809ccflags-$(PANIC_ON_BUG) += -DPANIC_ON_BUG
3810
3811ccflags-$(WLAN_WARN_ON_ASSERT) += -DWLAN_WARN_ON_ASSERT
3812
3813ccflags-$(CONFIG_POWER_MANAGEMENT_OFFLOAD) += -DWLAN_POWER_MANAGEMENT_OFFLOAD
3814
3815ccflags-$(CONFIG_WLAN_LOG_FATAL) += -DWLAN_LOG_FATAL
3816ccflags-$(CONFIG_WLAN_LOG_ERROR) += -DWLAN_LOG_ERROR
3817ccflags-$(CONFIG_WLAN_LOG_WARN) += -DWLAN_LOG_WARN
3818ccflags-$(CONFIG_WLAN_LOG_INFO) += -DWLAN_LOG_INFO
3819ccflags-$(CONFIG_WLAN_LOG_DEBUG) += -DWLAN_LOG_DEBUG
3820ccflags-$(CONFIG_WLAN_LOG_ENTER) += -DWLAN_LOG_ENTER
3821ccflags-$(CONFIG_WLAN_LOG_EXIT) += -DWLAN_LOG_EXIT
3822ccflags-$(WLAN_OPEN_SOURCE) += -DWLAN_OPEN_SOURCE
3823ccflags-$(CONFIG_FEATURE_STATS_EXT) += -DWLAN_FEATURE_STATS_EXT
3824ccflags-$(CONFIG_QCACLD_FEATURE_NAN) += -DWLAN_FEATURE_NAN
3825ccflags-$(CONFIG_QCACLD_FEATURE_SON) += -DWLAN_FEATURE_SON
3826ccflags-$(CONFIG_NDP_SAP_CONCURRENCY_ENABLE) += -DNDP_SAP_CONCURRENCY_ENABLE
3827ccflags-$(CONFIG_ENFORCE_PLD_REMOVE) += -DENFORCE_PLD_REMOVE
3828
3829ifeq ($(CONFIG_DFS_FCC_TYPE4_DURATION_CHECK), y)
3830ccflags-$(CONFIG_DFS_FCC_TYPE4_DURATION_CHECK) += -DDFS_FCC_TYPE4_DURATION_CHECK
3831endif
3832
3833ccflags-$(CONFIG_WLAN_SYSFS) += -DWLAN_SYSFS
3834ccflags-$(CONFIG_WLAN_SYSFS_CHANNEL) += -DWLAN_SYSFS_CHANNEL
3835ccflags-$(CONFIG_FEATURE_BECN_STATS) += -DWLAN_FEATURE_BEACON_RECEPTION_STATS
3836
3837ccflags-$(CONFIG_WLAN_SYSFS_CONNECT_INFO) += -DWLAN_SYSFS_CONNECT_INFO
3838ccflags-$(CONFIG_WLAN_SYSFS_EHT_RATE) += -DWLAN_SYSFS_EHT_RATE
3839
3840#Set RX_PERFORMANCE
3841ccflags-$(CONFIG_RX_PERFORMANCE) += -DRX_PERFORMANCE
3842
3843#Set MULTI_IF_LOG
3844ccflags-$(CONFIG_MULTI_IF_LOG) += -DMULTI_IF_LOG
3845
3846#Set SLUB_MEM_OPTIMIZE
3847ccflags-$(CONFIG_SLUB_MEM_OPTIMIZE) += -DSLUB_MEM_OPTIMIZE
3848
3849ifeq ($(CONFIG_ARCH_SDXBAAGHA), y)
3850ccflags-$(CONFIG_WLAN_MEMORY_OPT) += -DWLAN_MEMORY_OPT
3851endif
3852
3853#Set DFS_PRI_MULTIPLIER
3854ccflags-$(CONFIG_DFS_PRI_MULTIPLIER) += -DDFS_PRI_MULTIPLIER
3855
3856#Set DFS_OVERRIDE_RF_THRESHOLD
3857ccflags-$(CONFIG_DFS_OVERRIDE_RF_THRESHOLD) += -DDFS_OVERRIDE_RF_THRESHOLD
3858
3859#Enable OL debug and wmi unified functions
3860ccflags-$(CONFIG_ATH_PERF_PWR_OFFLOAD) += -DATH_PERF_PWR_OFFLOAD
3861
3862#Disable packet log
3863ccflags-$(CONFIG_REMOVE_PKT_LOG) += -DREMOVE_PKT_LOG
3864
3865#Enable 11AC TX
3866ccflags-$(CONFIG_ATH_11AC_TXCOMPACT) += -DATH_11AC_TXCOMPACT
3867
3868#ENABLE HTT HTC tx completion
3869ccflags-$(ENABLE_CE4_COMP_DISABLE_HTT_HTC_MISC_LIST) += -DENABLE_CE4_COMP_DISABLE_HTT_HTC_MISC_LIST
3870
3871#Enable PCI specific APIS (dma, etc)
3872ccflags-$(CONFIG_HIF_PCI) += -DHIF_PCI
3873
3874ccflags-$(CONFIG_HIF_IPCI) += -DHIF_IPCI
3875
3876ccflags-$(CONFIG_HIF_SNOC) += -DHIF_SNOC
3877
3878ccflags-$(CONFIG_HL_DP_SUPPORT) += -DCONFIG_HL_SUPPORT
3879ccflags-$(CONFIG_HL_DP_SUPPORT) += -DWLAN_PARTIAL_REORDER_OFFLOAD
3880ccflags-$(CONFIG_HL_DP_SUPPORT) += -DQCA_COMPUTE_TX_DELAY
3881ccflags-$(CONFIG_HL_DP_SUPPORT) += -DQCA_COMPUTE_TX_DELAY_PER_TID
3882ccflags-$(CONFIG_LL_DP_SUPPORT) += -DCONFIG_LL_DP_SUPPORT
3883ccflags-$(CONFIG_LL_DP_SUPPORT) += -DWLAN_FULL_REORDER_OFFLOAD
3884ccflags-$(CONFIG_WLAN_FEATURE_BIG_DATA_STATS) += -DWLAN_FEATURE_BIG_DATA_STATS
3885ifeq ($(CONFIG_WLAN_FEATURE_11AX), y)
3886ccflags-$(CONFIG_WLAN_FEATURE_SR) += -DWLAN_FEATURE_SR
3887ccflags-$(CONFIG_OBSS_PD) += -DOBSS_PD
3888endif
3889ccflags-$(CONFIG_WLAN_FEATURE_IGMP_OFFLOAD) += -DWLAN_FEATURE_IGMP_OFFLOAD
3890ccflags-$(CONFIG_WLAN_FEATURE_GET_USABLE_CHAN_LIST) += -DWLAN_FEATURE_GET_USABLE_CHAN_LIST
3891
3892# For PCIe GEN switch
3893ccflags-$(CONFIG_PCIE_GEN_SWITCH) += -DPCIE_GEN_SWITCH
3894
3895# For OOB testing
3896ccflags-$(CONFIG_WLAN_FEATURE_WOW_PULSE) += -DWLAN_FEATURE_WOW_PULSE
3897
3898#Enable High Latency related Flags
3899ifeq ($(CONFIG_QCA_WIFI_SDIO), y)
3900ccflags-y += -DCONFIG_AR6320_SUPPORT \
3901            -DSDIO_3_0 \
3902            -DHIF_SDIO \
3903            -DCONFIG_DISABLE_CDC_MAX_PERF_WAR=0 \
3904            -DCONFIG_ATH_PROCFS_DIAG_SUPPORT \
3905            -DHIF_MBOX_SLEEP_WAR \
3906            -DDEBUG_HL_LOGGING \
3907            -DQCA_BAD_PEER_TX_FLOW_CL \
3908            -DCONFIG_SDIO \
3909            -DFEATURE_WLAN_FORCE_SAP_SCC
3910
3911ifeq ($(CONFIG_SDIO_TRANSFER), adma)
3912ccflags-y += -DCONFIG_SDIO_TRANSFER_ADMA
3913else
3914ccflags-y += -DCONFIG_SDIO_TRANSFER_MAILBOX
3915endif
3916endif
3917
3918ccflags-$(CONFIG_AR6320_SUPPORT) += -DCONFIG_AR6320_SUPPORT
3919
3920ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
3921ccflags-y += -DWLAN_FEATURE_DSRC
3922ifeq ($(CONFIG_OCB_UT_FRAMEWORK), y)
3923ccflags-y += -DWLAN_OCB_UT
3924endif
3925
3926else ifeq ($(CONFIG_WLAN_REG_AUTO), y)
3927ccflags-y += -DWLAN_REG_AUTO
3928endif
3929
3930ccflags-$(CONFIG_FEATURE_SKB_PRE_ALLOC) += -DFEATURE_SKB_PRE_ALLOC
3931
3932#Enable USB specific APIS
3933ifeq ($(CONFIG_HIF_USB), y)
3934ccflags-y += -DHIF_USB \
3935            -DDEBUG_HL_LOGGING
3936endif
3937
3938#Enable Genoa specific features.
3939ccflags-$(CONFIG_QCA_HL_NETDEV_FLOW_CONTROL) += -DQCA_HL_NETDEV_FLOW_CONTROL
3940ccflags-$(CONFIG_FEATURE_HL_GROUP_CREDIT_FLOW_CONTROL) += -DFEATURE_HL_GROUP_CREDIT_FLOW_CONTROL
3941ccflags-$(CONFIG_FEATURE_HL_DBS_GROUP_CREDIT_SHARING) += -DFEATURE_HL_DBS_GROUP_CREDIT_SHARING
3942ccflags-$(CONFIG_CREDIT_REP_THROUGH_CREDIT_UPDATE) += -DCONFIG_CREDIT_REP_THROUGH_CREDIT_UPDATE
3943ccflags-$(CONFIG_RX_PN_CHECK_OFFLOAD) += -DCONFIG_RX_PN_CHECK_OFFLOAD
3944
3945ccflags-$(CONFIG_WLAN_SYNC_TSF_TIMER) += -DWLAN_FEATURE_TSF_TIMER_SYNC
3946ccflags-$(CONFIG_WLAN_SYNC_TSF_PTP) += -DWLAN_FEATURE_TSF_PTP
3947ccflags-$(CONFIG_WLAN_SYNC_TSF_PLUS_EXT_GPIO_IRQ) += -DWLAN_FEATURE_TSF_PLUS_EXT_GPIO_IRQ
3948ccflags-$(CONFIG_WLAN_SYNC_TSF_PLUS_EXT_GPIO_SYNC) += -DWLAN_FEATURE_TSF_PLUS_EXT_GPIO_SYNC
3949ccflags-$(CONFIG_TX_DESC_HI_PRIO_RESERVE) += -DCONFIG_TX_DESC_HI_PRIO_RESERVE
3950
3951#Enable power management suspend/resume functionality
3952ccflags-$(CONFIG_ATH_BUS_PM) += -DATH_BUS_PM
3953
3954#Enable FLOWMAC module support
3955ccflags-$(CONFIG_ATH_SUPPORT_FLOWMAC_MODULE) += -DATH_SUPPORT_FLOWMAC_MODULE
3956
3957#Enable spectral support
3958ccflags-$(CONFIG_ATH_SUPPORT_SPECTRAL) += -DATH_SUPPORT_SPECTRAL
3959
3960#Enable legacy pktlog
3961ccflags-$(CONFIG_PKTLOG_LEGACY) += -DPKTLOG_LEGACY
3962
3963#Enable WDI Event support
3964ccflags-$(CONFIG_WDI_EVENT_ENABLE) += -DWDI_EVENT_ENABLE
3965
3966#Enable the type_specific_data in the struct ath_pktlog_arg
3967ccflags-$(CONFIG_PKTLOG_HAS_SPECIFIC_DATA) += -DPKTLOG_HAS_SPECIFIC_DATA
3968
3969#Endianness selection
3970ifeq ($(CONFIG_LITTLE_ENDIAN), y)
3971ccflags-y += -DANI_LITTLE_BYTE_ENDIAN
3972ccflags-y += -DANI_LITTLE_BIT_ENDIAN
3973ccflags-y += -DDOT11F_LITTLE_ENDIAN_HOST
3974else
3975ccflags-y += -DANI_BIG_BYTE_ENDIAN
3976ccflags-y += -DBIG_ENDIAN_HOST
3977endif
3978
3979#Enable TX reclaim support
3980ccflags-$(CONFIG_TX_CREDIT_RECLAIM_SUPPORT) += -DTX_CREDIT_RECLAIM_SUPPORT
3981
3982#Enable FTM support
3983ccflags-$(CONFIG_QCA_WIFI_FTM) += -DQCA_WIFI_FTM
3984ccflags-$(CONFIG_NL80211_TESTMODE) += -DQCA_WIFI_FTM_NL80211
3985ccflags-$(CONFIG_LINUX_QCMBR) += -DLINUX_QCMBR -DQCA_WIFI_FTM_IOCTL
3986
3987#Enable Checksum Offload support
3988ccflags-$(CONFIG_CHECKSUM_OFFLOAD) += -DCHECKSUM_OFFLOAD
3989
3990#Enable IPA Offload support
3991ccflags-$(CONFIG_IPA_OFFLOAD) += -DIPA_OFFLOAD
3992
3993#Enable IPA optional Wifi datapath
3994ifeq ($(CONFIG_IPA_OPT_WIFI_DP), y)
3995ifeq ($(CONFIG_IPA_OFFLOAD), y)
3996ccflags-$(CONFIG_IPA_OPT_WIFI_DP) += -DIPA_OPT_WIFI_DP
3997endif
3998endif
3999
4000ccflags-$(CONFIG_WDI3_IPA_OVER_GSI) += -DIPA_WDI3_GSI
4001ccflags-$(CONFIG_WDI2_IPA_OVER_GSI) += -DIPA_WDI2_GSI
4002
4003#Enable WMI DIAG log over CE7
4004ccflags-$(CONFIG_WLAN_FEATURE_WMI_DIAG_OVER_CE7) += -DWLAN_FEATURE_WMI_DIAG_OVER_CE7
4005
4006ifdef CONFIG_WLAN_DP_FEATURE_DEFERRED_REO_QDESC_DESTROY
4007ccflags-y += -DWLAN_DP_FEATURE_DEFERRED_REO_QDESC_DESTROY
4008endif
4009
4010ifeq ($(CONFIG_ARCH_SDX20), y)
4011ccflags-y += -DSYNC_IPA_READY
4012endif
4013
4014ifeq ($(CONFIG_ARCH_SDXPOORWILLS), y)
4015CONFIG_FEATURE_SG := y
4016endif
4017
4018ifeq ($(CONFIG_ARCH_MSM8996), y)
4019ifneq ($(CONFIG_QCN7605_SUPPORT), y)
4020CONFIG_FEATURE_SG := y
4021CONFIG_RX_THREAD_PRIORITY := y
4022endif
4023endif
4024
4025ifeq ($(CONFIG_FEATURE_SG), y)
4026ccflags-y += -DFEATURE_SG
4027endif
4028
4029ifeq ($(CONFIG_RX_THREAD_PRIORITY), y)
4030ccflags-y += -DRX_THREAD_PRIORITY
4031endif
4032
4033ifeq ($(CONFIG_SUPPORT_P2P_BY_ONE_INTF_WLAN), y)
4034#sta support to tx P2P action frames
4035ccflags-y += -DSUPPORT_P2P_BY_ONE_INTF_WLAN
4036else
4037#Open P2P device interface only for non-Mobile router use cases
4038ccflags-$(CONFIG_WLAN_OPEN_P2P_INTERFACE) += -DWLAN_OPEN_P2P_INTERFACE
4039endif
4040
4041ccflags-$(CONFIG_WMI_BCN_OFFLOAD) += -DWLAN_WMI_BCN
4042
4043#Enable wbuff
4044ccflags-$(CONFIG_WLAN_WBUFF) += -DWLAN_FEATURE_WBUFF
4045
4046#Enable GTK Offload
4047ccflags-$(CONFIG_GTK_OFFLOAD) += -DWLAN_FEATURE_GTK_OFFLOAD
4048
4049#Enable External WoW
4050ccflags-$(CONFIG_EXT_WOW) += -DWLAN_FEATURE_EXTWOW_SUPPORT
4051
4052#Mark it as SMP Kernel
4053ccflags-$(CONFIG_SMP) += -DQCA_CONFIG_SMP
4054
4055#CONFIG_RPS default Y, but depend on CONFIG_SMP
4056ccflags-$(CONFIG_RPS) += -DQCA_CONFIG_RPS
4057
4058ccflags-$(CONFIG_CHNL_MATRIX_RESTRICTION) += -DWLAN_ENABLE_CHNL_MATRIX_RESTRICTION
4059
4060#Enable ICMP packet disable powersave feature
4061ccflags-$(CONFIG_ICMP_DISABLE_PS) += -DWLAN_ICMP_DISABLE_PS
4062
4063#enable MCC TO SCC switch
4064ccflags-$(CONFIG_FEATURE_WLAN_MCC_TO_SCC_SWITCH) += -DFEATURE_WLAN_MCC_TO_SCC_SWITCH
4065
4066#enable wlan auto shutdown feature
4067ccflags-$(CONFIG_FEATURE_WLAN_AUTO_SHUTDOWN) += -DFEATURE_WLAN_AUTO_SHUTDOWN
4068
4069#enable AP-AP ACS Optimization
4070ccflags-$(CONFIG_FEATURE_WLAN_AP_AP_ACS_OPTIMIZE) += -DFEATURE_WLAN_AP_AP_ACS_OPTIMIZE
4071
4072#Enable 4address scheme
4073ccflags-$(CONFIG_FEATURE_WLAN_STA_4ADDR_SCHEME) += -DFEATURE_WLAN_STA_4ADDR_SCHEME
4074
4075#Optimize GC connection speed by skipping JOIN
4076ccflags-$(CONFIG_FEATURE_WLAN_GC_SKIP_JOIN) += -DFEATURE_WLAN_GC_SKIP_JOIN
4077
4078#enable MDM/SDX special config
4079ccflags-$(CONFIG_MDM_PLATFORM) += -DMDM_PLATFORM
4080
4081#Disable STA-AP Mode DFS support
4082ccflags-$(CONFIG_FEATURE_WLAN_STA_AP_MODE_DFS_DISABLE) += -DFEATURE_WLAN_STA_AP_MODE_DFS_DISABLE
4083
4084#Enable 2.4 GHz social channels in 5 GHz only mode for p2p usage
4085ccflags-$(CONFIG_WLAN_ENABLE_SOCIAL_CHANNELS_5G_ONLY) += -DWLAN_ENABLE_SOCIAL_CHANNELS_5G_ONLY
4086
4087#Green AP feature
4088ccflags-$(CONFIG_QCACLD_FEATURE_GREEN_AP) += -DWLAN_SUPPORT_GREEN_AP
4089
4090ccflags-$(CONFIG_QCACLD_FEATURE_GAP_LL_PS_MODE) += -DWLAN_SUPPORT_GAP_LL_PS_MODE
4091
4092ccflags-$(CONFIG_QCACLD_FEATURE_APF) += -DFEATURE_WLAN_APF
4093
4094ccflags-$(CONFIG_WLAN_FEATURE_SARV1_TO_SARV2) += -DWLAN_FEATURE_SARV1_TO_SARV2
4095
4096ccflags-$(CONFIG_FEATURE_WLAN_FT_IEEE8021X) += -DFEATURE_WLAN_FT_IEEE8021X
4097ccflags-$(CONFIG_FEATURE_WLAN_FT_PSK) += -DFEATURE_WLAN_FT_PSK
4098
4099#Enable host 11d scan
4100ccflags-$(CONFIG_HOST_11D_SCAN) += -DHOST_11D_SCAN
4101
4102#Stats & Quota Metering feature
4103ifeq ($(CONFIG_IPA_OFFLOAD), y)
4104ifeq ($(CONFIG_QCACLD_FEATURE_METERING), y)
4105ccflags-y += -DFEATURE_METERING
4106endif
4107endif
4108
4109#Define Max IPA interface
4110ifeq ($(CONFIG_IPA_OFFLOAD), y)
4111ifdef CONFIG_NUM_IPA_IFACE
4112ccflags-y += -DMAX_IPA_IFACE=$(CONFIG_NUM_IPA_IFACE)
4113else
4114NUM_IPA_IFACE ?= 3
4115ccflags-y += -DMAX_IPA_IFACE=$(NUM_IPA_IFACE)
4116endif
4117endif
4118
4119
4120ccflags-$(CONFIG_TUFELLO_DUAL_FW_SUPPORT) += -DCONFIG_TUFELLO_DUAL_FW_SUPPORT
4121ccflags-$(CONFIG_CHANNEL_HOPPING_ALL_BANDS) += -DCHANNEL_HOPPING_ALL_BANDS
4122
4123#Enable Signed firmware support for split binary format
4124ccflags-$(CONFIG_QCA_SIGNED_SPLIT_BINARY_SUPPORT) += -DQCA_SIGNED_SPLIT_BINARY_SUPPORT
4125
4126#Enable single firmware binary format
4127ccflags-$(CONFIG_QCA_SINGLE_BINARY_SUPPORT) += -DQCA_SINGLE_BINARY_SUPPORT
4128
4129#Enable collecting target RAM dump after kernel panic
4130ccflags-$(CONFIG_TARGET_RAMDUMP_AFTER_KERNEL_PANIC) += -DTARGET_RAMDUMP_AFTER_KERNEL_PANIC
4131
4132#Enable/disable secure firmware feature
4133ccflags-$(CONFIG_FEATURE_SECURE_FIRMWARE) += -DFEATURE_SECURE_FIRMWARE
4134
4135ccflags-$(CONFIG_ATH_PCIE_ACCESS_DEBUG) += -DCONFIG_ATH_PCIE_ACCESS_DEBUG
4136
4137# Enable feature support for Linux version QCMBR
4138ccflags-$(CONFIG_LINUX_QCMBR) += -DLINUX_QCMBR
4139
4140# Enable feature sync tsf between multi devices
4141ccflags-$(CONFIG_WLAN_SYNC_TSF) += -DWLAN_FEATURE_TSF
4142
4143ifeq ($(CONFIG_WLAN_SYNC_TSF_PLUS), y)
4144ccflags-y += -DWLAN_FEATURE_TSF_PLUS
4145
4146ccflags-$(CONFIG_WLAN_SYNC_TSF_ACCURACY) += -DWLAN_FEATURE_TSF_ACCURACY
4147
4148ifneq ($(CONFIG_WLAN_SYNC_TSF_PLUS_DISABLE_SOCK_TS), y)
4149ccflags-y += -DWLAN_FEATURE_TSF_PLUS_SOCK_TS
4150endif
4151
4152endif
4153
4154# Enable feature sync tsf for chips based on Adrastea arch
4155ccflags-$(CONFIG_WLAN_SYNC_TSF_PLUS_NOIRQ) += -DWLAN_FEATURE_TSF_PLUS_NOIRQ
4156
4157ifeq ($(CONFIG_WLAN_TSF_UPLINK_DELAY), y)
4158# Enable uplink delay report feature
4159ccflags-y += -DWLAN_FEATURE_TSF_UPLINK_DELAY
4160CONFIG_WLAN_TSF_AUTO_REPORT := y
4161endif
4162
4163# Enable tx latency stats feature
4164ifeq ($(CONFIG_WLAN_TX_LATENCY_STATS), y)
4165ccflags-y += -DWLAN_FEATURE_TX_LATENCY_STATS
4166CONFIG_WLAN_TSF_AUTO_REPORT := y
4167endif
4168
4169# Enable TSF auto report feature
4170ccflags-$(CONFIG_WLAN_TSF_AUTO_REPORT) += -DWLAN_FEATURE_TSF_AUTO_REPORT
4171
4172ccflags-$(CONFIG_ATH_PROCFS_DIAG_SUPPORT) += -DCONFIG_ATH_PROCFS_DIAG_SUPPORT
4173
4174ccflags-$(CONFIG_HELIUMPLUS) += -DHELIUMPLUS
4175ccflags-$(CONFIG_RX_OL) += -DRECEIVE_OFFLOAD
4176ccflags-$(CONFIG_TX_TID_OVERRIDE) += -DATH_TX_PRI_OVERRIDE
4177ccflags-$(CONFIG_AR900B) += -DAR900B
4178ccflags-$(CONFIG_HTT_PADDR64) += -DHTT_PADDR64
4179ccflags-$(CONFIG_OL_RX_INDICATION_RECORD) += -DOL_RX_INDICATION_RECORD
4180ccflags-$(CONFIG_TSOSEG_DEBUG) += -DTSOSEG_DEBUG
4181ccflags-$(CONFIG_ALLOW_PKT_DROPPING) += -DFEATURE_ALLOW_PKT_DROPPING
4182
4183# Enable feature for athdiag live debug mode
4184ccflags-$(CONFIG_ATH_DIAG_EXT_DIRECT) += -DATH_DIAG_EXT_DIRECT
4185
4186ccflags-$(CONFIG_ENABLE_DEBUG_ADDRESS_MARKING) += -DENABLE_DEBUG_ADDRESS_MARKING
4187ccflags-$(CONFIG_FEATURE_TSO) += -DFEATURE_TSO
4188ccflags-$(CONFIG_FEATURE_TSO_DEBUG) += -DFEATURE_TSO_DEBUG
4189ccflags-$(CONFIG_FEATURE_TSO_STATS) += -DFEATURE_TSO_STATS
4190ccflags-$(CONFIG_FEATURE_FORCE_WAKE) += -DFORCE_WAKE
4191ccflags-$(CONFIG_WLAN_LRO) += -DFEATURE_LRO
4192
4193ccflags-$(CONFIG_FEATURE_AP_MCC_CH_AVOIDANCE) += -DFEATURE_AP_MCC_CH_AVOIDANCE
4194
4195ccflags-$(CONFIG_FEATURE_EPPING) += -DWLAN_FEATURE_EPPING
4196
4197ccflags-$(CONFIG_WLAN_OFFLOAD_PACKETS) += -DWLAN_FEATURE_OFFLOAD_PACKETS
4198
4199ccflags-$(CONFIG_WLAN_FEATURE_DISA) += -DWLAN_FEATURE_DISA
4200
4201ccflags-$(CONFIG_WLAN_FEATURE_ACTION_OUI) += -DWLAN_FEATURE_ACTION_OUI
4202
4203ccflags-$(CONFIG_WLAN_FEATURE_FIPS) += -DWLAN_FEATURE_FIPS
4204
4205ccflags-$(CONFIG_LFR_SUBNET_DETECTION) += -DFEATURE_LFR_SUBNET_DETECTION
4206
4207ccflags-$(CONFIG_MCC_TO_SCC_SWITCH) += -DFEATURE_WLAN_MCC_TO_SCC_SWITCH
4208
4209ccflags-$(CONFIG_FEATURE_WLAN_D0WOW) += -DFEATURE_WLAN_D0WOW
4210
4211ccflags-$(CONFIG_WLAN_FEATURE_PKT_CAPTURE) += -DWLAN_FEATURE_PKT_CAPTURE
4212
4213ccflags-$(CONFIG_WLAN_FEATURE_PKT_CAPTURE_V2) += -DWLAN_FEATURE_PKT_CAPTURE_V2
4214
4215ccflags-$(CONFIG_DP_RX_UDP_OVER_PEER_ROAM) += -DDP_RX_UDP_OVER_PEER_ROAM
4216
4217cppflags-$(CONFIG_WLAN_BOOST_CPU_FREQ_IN_ROAM) += -DWLAN_BOOST_CPU_FREQ_IN_ROAM
4218
4219ccflags-$(CONFIG_QCA_WIFI_EMULATION) += -DQCA_WIFI_EMULATION
4220ccflags-$(CONFIG_SAP_MULTI_LINK_EMULATION) += -DSAP_MULTI_LINK_EMULATION
4221ccflags-$(CONFIG_SHADOW_V2) += -DCONFIG_SHADOW_V2
4222ccflags-$(CONFIG_SHADOW_V3) += -DCONFIG_SHADOW_V3
4223ccflags-$(CONFIG_QCA6290_HEADERS_DEF) += -DQCA6290_HEADERS_DEF
4224ccflags-$(CONFIG_QCA_WIFI_QCA6290) += -DQCA_WIFI_QCA6290
4225ccflags-$(CONFIG_QCA6390_HEADERS_DEF) += -DQCA6390_HEADERS_DEF
4226ccflags-$(CONFIG_QCA6750_HEADERS_DEF) += -DQCA6750_HEADERS_DEF
4227ccflags-$(CONFIG_QCA_WIFI_QCA6390) += -DQCA_WIFI_QCA6390
4228ccflags-$(CONFIG_QCA6490_HEADERS_DEF) += -DQCA6490_HEADERS_DEF
4229ccflags-$(CONFIG_KIWI_HEADERS_DEF) += -DKIWI_HEADERS_DEF
4230ccflags-$(CONFIG_WCN6450_HEADERS_DEF) += -DWCN6450_HEADERS_DEF
4231ccflags-$(CONFIG_QCA_WIFI_QCA6490) += -DQCA_WIFI_QCA6490
4232ccflags-$(CONFIG_QCA_WIFI_QCA6750) += -DQCA_WIFI_QCA6750
4233ccflags-$(CONFIG_QCA_WIFI_KIWI) += -DQCA_WIFI_KIWI
4234ccflags-$(CONFIG_QCA_WIFI_WCN6450) += -DQCA_WIFI_WCN6450
4235ccflags-$(CONFIG_QCA_WIFI_WCN6450) += -DWLAN_40BIT_ADDRESSING_SUPPORT
4236ccflags-$(CONFIG_QCA_WIFI_WCN6450) += -DWLAN_64BIT_DATA_SUPPORT
4237ccflags-$(CONFIG_CE_LEGACY_MSI_SUPPORT) += -DCE_LEGACY_MSI_SUPPORT
4238ccflags-$(CONFIG_HIF_HAL_REG_ACCESS_SUPPORT) += -DHIF_HAL_REG_ACCESS_SUPPORT
4239ccflags-$(CONFIG_FEATURE_HIF_DELAYED_REG_WRITE) += -DFEATURE_HIF_DELAYED_REG_WRITE
4240ccflags-$(CONFIG_CNSS_KIWI_V2) += -DQCA_WIFI_KIWI_V2
4241ccflags-$(CONFIG_CNSS_MANGO) += -DQCA_WIFI_MANGO
4242ccflags-$(CONFIG_CNSS_PEACH) += -DQCA_WIFI_PEACH
4243ccflags-$(CONFIG_QCA_WIFI_QCA8074) += -DQCA_WIFI_QCA8074
4244ccflags-$(CONFIG_SCALE_INCLUDES) += -DSCALE_INCLUDES
4245ccflags-$(CONFIG_QCA_WIFI_QCA8074_VP) += -DQCA_WIFI_QCA8074_VP
4246ccflags-$(CONFIG_DP_INTR_POLL_BASED) += -DDP_INTR_POLL_BASED
4247ccflags-$(CONFIG_TX_PER_PDEV_DESC_POOL) += -DTX_PER_PDEV_DESC_POOL
4248ccflags-$(CONFIG_DP_TRACE) += -DCONFIG_DP_TRACE
4249ccflags-$(CONFIG_FEATURE_TSO) += -DFEATURE_TSO
4250ccflags-$(CONFIG_TSO_DEBUG_LOG_ENABLE) += -DTSO_DEBUG_LOG_ENABLE
4251ccflags-$(CONFIG_DP_LFR) += -DDP_LFR
4252ccflags-$(CONFIG_DUP_RX_DESC_WAR) += -DDUP_RX_DESC_WAR
4253ccflags-$(CONFIG_DP_MEM_PRE_ALLOC) += -DDP_MEM_PRE_ALLOC
4254ccflags-$(CONFIG_DP_TXRX_SOC_ATTACH) += -DDP_TXRX_SOC_ATTACH
4255ccflags-$(CONFIG_WLAN_FEATURE_BMI) += -DWLAN_FEATURE_BMI
4256ccflags-$(CONFIG_QCA_TX_PADDING_CREDIT_SUPPORT) += -DQCA_TX_PADDING_CREDIT_SUPPORT
4257ccflags-$(CONFIG_QCN7605_SUPPORT) += -DQCN7605_SUPPORT -DPLATFORM_GENOA
4258ccflags-$(CONFIG_HIF_REG_WINDOW_SUPPORT) += -DHIF_REG_WINDOW_SUPPORT
4259ccflags-$(CONFIG_WLAN_ALLOCATE_GLOBAL_BUFFERS_DYNAMICALLY) += -DWLAN_ALLOCATE_GLOBAL_BUFFERS_DYNAMICALLY
4260ccflags-$(CONFIG_HIF_CE_DEBUG_DATA_BUF) += -DHIF_CE_DEBUG_DATA_BUF
4261ccflags-$(CONFIG_IPA_DISABLE_OVERRIDE) += -DIPA_DISABLE_OVERRIDE
4262ccflags-$(CONFIG_QCA_LL_TX_FLOW_CONTROL_RESIZE) += -DQCA_LL_TX_FLOW_CONTROL_RESIZE
4263ccflags-$(CONFIG_HIF_PCI) += -DCE_SVC_CMN_INIT
4264ccflags-$(CONFIG_HIF_IPCI) += -DCE_SVC_CMN_INIT
4265ccflags-$(CONFIG_HIF_SNOC) += -DCE_SVC_CMN_INIT
4266ccflags-$(CONFIG_RX_DESC_SANITY_WAR) += -DRX_DESC_SANITY_WAR
4267ccflags-$(CONFIG_WBM_IDLE_LSB_WR_CNF_WAR) += -DWBM_IDLE_LSB_WRITE_CONFIRM_WAR
4268ccflags-$(CONFIG_DYNAMIC_RX_AGGREGATION) += -DWLAN_FEATURE_DYNAMIC_RX_AGGREGATION
4269ccflags-$(CONFIG_DP_FEATURE_HW_COOKIE_CONVERSION) += -DDP_FEATURE_HW_COOKIE_CONVERSION
4270ccflags-$(CONFIG_DP_HW_COOKIE_CONVERT_EXCEPTION) += -DDP_HW_COOKIE_CONVERT_EXCEPTION
4271ccflags-$(CONFIG_TX_ADDR_INDEX_SEARCH) += -DTX_ADDR_INDEX_SEARCH
4272ccflags-$(CONFIG_QCA_SUPPORT_TX_MIN_RATES_FOR_SPECIAL_FRAMES) += -DQCA_SUPPORT_TX_MIN_RATES_FOR_SPECIAL_FRAMES
4273ccflags-$(CONFIG_QCA_GET_TSF_VIA_REG) += -DQCA_GET_TSF_VIA_REG
4274ccflags-$(CONFIG_DP_TX_COMP_RING_DESC_SANITY_CHECK) += -DDP_TX_COMP_RING_DESC_SANITY_CHECK
4275ccflags-$(CONFIG_HAL_SRNG_REG_HIS_DEBUG) += -DHAL_SRNG_REG_HIS_DEBUG
4276ccflags-$(CONFIG_DP_MLO_LINK_STATS_SUPPORT) += -DDP_MLO_LINK_STATS_SUPPORT
4277
4278ccflags-$(CONFIG_RX_HASH_DEBUG) += -DRX_HASH_DEBUG
4279ccflags-$(CONFIG_DP_PKT_STATS_PER_LMAC) += -DDP_PKT_STATS_PER_LMAC
4280ccflags-$(CONFIG_NO_RX_PKT_HDR_TLV) += -DNO_RX_PKT_HDR_TLV
4281ccflags-$(CONFIG_DP_TX_PACKET_INSPECT_FOR_ILP) += -DDP_TX_PACKET_INSPECT_FOR_ILP
4282
4283ifeq ($(CONFIG_QCA6290_11AX), y)
4284ccflags-y += -DQCA_WIFI_QCA6290_11AX -DQCA_WIFI_QCA6290_11AX_MU_UL
4285endif
4286
4287ccflags-$(CONFIG_WLAN_TX_FLOW_CONTROL_V2) += -DQCA_AC_BASED_FLOW_CONTROL
4288
4289# Enable Low latency optimisation mode
4290ccflags-$(CONFIG_FEATURE_NO_DBS_INTRABAND_MCC_SUPPORT) += -DFEATURE_NO_DBS_INTRABAND_MCC_SUPPORT
4291ccflags-$(CONFIG_HAL_DISABLE_NON_BA_2K_JUMP_ERROR) += -DHAL_DISABLE_NON_BA_2K_JUMP_ERROR
4292ccflags-$(CONFIG_ENABLE_HAL_SOC_STATS) += -DENABLE_HAL_SOC_STATS
4293ccflags-$(CONFIG_ENABLE_HAL_REG_WR_HISTORY) += -DENABLE_HAL_REG_WR_HISTORY
4294ccflags-$(CONFIG_DP_RX_DESC_COOKIE_INVALIDATE) += -DDP_RX_DESC_COOKIE_INVALIDATE
4295ccflags-$(CONFIG_MON_ENABLE_DROP_FOR_MAC) += -DMON_ENABLE_DROP_FOR_MAC
4296ccflags-$(CONFIG_MON_ENABLE_DROP_FOR_NON_MON_PMAC) += -DMON_ENABLE_DROP_FOR_NON_MON_PMAC
4297ccflags-$(CONFIG_DP_WAR_INVALID_FIRST_MSDU_FLAG) += -DDP_WAR_INVALID_FIRST_MSDU_FLAG
4298ccflags-$(CONFIG_LITHIUM) += -DDISABLE_MON_RING_MSI_CFG
4299ccflags-$(CONFIG_LITHIUM) += -DFEATURE_IRQ_AFFINITY
4300ccflags-$(CONFIG_RHINE) += -DFEATURE_IRQ_AFFINITY
4301ccflags-$(CONFIG_RHINE) += -DWLAN_SOFTUMAC_SUPPORT
4302ccflags-$(CONFIG_BERYLLIUM) += -DFEATURE_IRQ_AFFINITY
4303ccflags-$(CONFIG_TX_MULTIQ_PER_AC) += -DTX_MULTIQ_PER_AC
4304ccflags-$(CONFIG_PCI_LINK_STATUS_SANITY) += -DPCI_LINK_STATUS_SANITY
4305ccflags-$(CONFIG_DDP_MON_RSSI_IN_DBM) += -DDP_MON_RSSI_IN_DBM
4306ccflags-$(CONFIG_SYSTEM_PM_CHECK) += -DSYSTEM_PM_CHECK
4307ccflags-$(CONFIG_DISABLE_EAPOL_INTRABSS_FWD) += -DDISABLE_EAPOL_INTRABSS_FWD
4308ccflags-$(CONFIG_TX_AGGREGATION_SIZE_ENABLE) += -DTX_AGGREGATION_SIZE_ENABLE
4309ccflags-$(CONFIG_TX_MULTI_TCL) += -DTX_MULTI_TCL
4310ccflags-$(CONFIG_WLAN_DP_DISABLE_TCL_CMD_CRED_SRNG) += -DWLAN_DP_DISABLE_TCL_CMD_CRED_SRNG
4311ccflags-$(CONFIG_WLAN_DP_DISABLE_TCL_STATUS_SRNG) += -DWLAN_DP_DISABLE_TCL_STATUS_SRNG
4312ccflags-$(CONFIG_DP_WAR_VALIDATE_RX_ERR_MSDU_COOKIE) += -DDP_WAR_VALIDATE_RX_ERR_MSDU_COOKIE
4313ccflags-$(CONFIG_WLAN_DP_SRNG_USAGE_WM_TRACKING) += -DWLAN_DP_SRNG_USAGE_WM_TRACKING
4314ccflags-$(CONFIG_WLAN_FEATURE_DP_CFG_EVENT_HISTORY) += -DWLAN_FEATURE_DP_CFG_EVENT_HISTORY
4315ccflags-$(CONFIG_WLAN_DP_VDEV_NO_SELF_PEER) += -DWLAN_DP_VDEV_NO_SELF_PEER
4316ccflags-$(CONFIG_DP_RX_MSDU_DONE_FAIL_HISTORY) += -DDP_RX_MSDU_DONE_FAIL_HISTORY
4317ccflags-$(CONFIG_DP_RX_PEEK_MSDU_DONE_WAR) += -DDP_RX_PEEK_MSDU_DONE_WAR
4318
4319# Enable Low latency
4320ccflags-$(CONFIG_WLAN_FEATURE_LL_MODE) += -DWLAN_FEATURE_LL_MODE
4321
4322# Enable PCI low power interrupt register configuration
4323ccflags-$(CONFIG_PCI_LOW_POWER_INT_REG) += -DCONFIG_PCI_LOW_POWER_INT_REG
4324
4325ccflags-$(CONFIG_WLAN_CLD_PM_QOS) += -DCLD_PM_QOS
4326ccflags-$(CONFIG_WLAN_CLD_DEV_PM_QOS) += -DCLD_DEV_PM_QOS
4327ccflags-$(CONFIG_REO_DESC_DEFER_FREE) += -DREO_DESC_DEFER_FREE
4328ccflags-$(CONFIG_WLAN_FEATURE_11AX) += -DWLAN_FEATURE_11AX
4329ccflags-$(CONFIG_WLAN_FEATURE_11AX) += -DWLAN_FEATURE_11AX_BSS_COLOR
4330ccflags-$(CONFIG_WLAN_FEATURE_11AX) += -DSUPPORT_11AX_D3
4331ccflags-$(CONFIG_RXDMA_ERR_PKT_DROP) += -DRXDMA_ERR_PKT_DROP
4332ccflags-$(CONFIG_MAX_ALLOC_PAGE_SIZE) += -DMAX_ALLOC_PAGE_SIZE
4333ccflags-$(CONFIG_DELIVERY_TO_STACK_STATUS_CHECK) += -DDELIVERY_TO_STACK_STATUS_CHECK
4334ccflags-$(CONFIG_WLAN_TRACE_HIDE_MAC_ADDRESS) += -DWLAN_TRACE_HIDE_MAC_ADDRESS
4335ccflags-$(CONFIG_WLAN_TRACE_HIDE_SSID) += -DWLAN_TRACE_HIDE_SSID
4336ccflags-$(CONFIG_WLAN_FEATURE_11BE) += -DWLAN_FEATURE_11BE
4337ccflags-$(CONFIG_WLAN_FEATURE_11BE_MLO) += -DWLAN_FEATURE_11BE_MLO
4338ccflags-$(CONFIG_WLAN_FEATURE_11BE_MLO) += -DWLAN_FEATURE_11BE_MLO_ADV_FEATURE
4339ccflags-$(CONFIG_WLAN_HDD_MULTI_VDEV_SINGLE_NDEV) += -DWLAN_HDD_MULTI_VDEV_SINGLE_NDEV
4340ccflags-$(CONFIG_WLAN_FEATURE_11BE_MLO) += -DWLAN_SUPPORT_11BE_D3_0
4341ccflags-$(CONFIG_FIX_TXDMA_LIMITATION) += -DFIX_TXDMA_LIMITATION
4342ccflags-$(CONFIG_FEATURE_AST) += -DFEATURE_AST
4343ccflags-$(CONFIG_PEER_PROTECTED_ACCESS) += -DPEER_PROTECTED_ACCESS
4344ccflags-$(CONFIG_SERIALIZE_QUEUE_SETUP) += -DSERIALIZE_QUEUE_SETUP
4345ccflags-$(CONFIG_DP_RX_PKT_NO_PEER_DELIVER) += -DDP_RX_PKT_NO_PEER_DELIVER
4346ccflags-$(CONFIG_DP_RX_DROP_RAW_FRM) += -DDP_RX_DROP_RAW_FRM
4347ccflags-$(CONFIG_FEATURE_ALIGN_STATS_FROM_DP) += -DFEATURE_ALIGN_STATS_FROM_DP
4348ccflags-$(CONFIG_DP_RX_SPECIAL_FRAME_NEED) += -DDP_RX_SPECIAL_FRAME_NEED
4349ccflags-$(CONFIG_FEATURE_STATS_EXT_V2) += -DFEATURE_STATS_EXT_V2
4350ccflags-$(CONFIG_WLAN_FEATURE_CAL_FAILURE_TRIGGER) += -DWLAN_FEATURE_CAL_FAILURE_TRIGGER
4351ccflags-$(CONFIG_WLAN_FEATURE_DYNAMIC_MAC_ADDR_UPDATE) += -DWLAN_FEATURE_DYNAMIC_MAC_ADDR_UPDATE
4352ccflags-$(CONFIG_WLAN_FEATURE_SAP_ACS_OPTIMIZE) += -DWLAN_FEATURE_SAP_ACS_OPTIMIZE
4353ccflags-$(CONFIG_WLAN_FEATURE_NO_STA_SAP_CONCURRENCY) += -DWLAN_FEATURE_NO_STA_SAP_CONCURRENCY
4354ccflags-$(CONFIG_WLAN_FEATURE_NO_STA_NAN_CONCURRENCY) += -DWLAN_FEATURE_NO_STA_NAN_CONCURRENCY
4355ccflags-$(CONFIG_WLAN_FEATURE_NO_P2P_CONCURRENCY) += -DWLAN_FEATURE_NO_P2P_CONCURRENCY
4356ccflags-$(CONFIG_WLAN_FEATURE_NO_SAP_NAN_CONCURRENCY) += -DWLAN_FEATURE_NO_SAP_NAN_CONCURRENCY
4357
4358ccflags-$(CONFIG_VERBOSE_DEBUG) += -DENABLE_VERBOSE_DEBUG
4359ccflags-$(CONFIG_RX_DESC_DEBUG_CHECK) += -DRX_DESC_DEBUG_CHECK
4360ccflags-$(CONFIG_REGISTER_OP_DEBUG) += -DHAL_REGISTER_WRITE_DEBUG
4361ccflags-$(CONFIG_ENABLE_QDF_PTR_HASH_DEBUG) += -DENABLE_QDF_PTR_HASH_DEBUG
4362#Enable STATE MACHINE HISTORY
4363ccflags-$(CONFIG_SM_ENG_HIST) += -DSM_ENG_HIST_ENABLE
4364ccflags-$(CONFIG_FEATURE_VDEV_OPS_WAKELOCK) += -DFEATURE_VDEV_OPS_WAKELOCK
4365
4366# Vendor Commands
4367ccflags-$(CONFIG_FEATURE_RSSI_MONITOR) += -DFEATURE_RSSI_MONITOR
4368ccflags-$(CONFIG_FEATURE_BSS_TRANSITION) += -DFEATURE_BSS_TRANSITION
4369ccflags-$(CONFIG_FEATURE_STATION_INFO) += -DFEATURE_STATION_INFO
4370ccflags-$(CONFIG_FEATURE_TX_POWER) += -DFEATURE_TX_POWER
4371ccflags-$(CONFIG_FEATURE_OTA_TEST) += -DFEATURE_OTA_TEST
4372ccflags-$(CONFIG_FEATURE_ACTIVE_TOS) += -DFEATURE_ACTIVE_TOS
4373ccflags-$(CONFIG_FEATURE_SAR_LIMITS) += -DFEATURE_SAR_LIMITS
4374ccflags-$(CONFIG_FEATURE_CONCURRENCY_MATRIX) += -DFEATURE_CONCURRENCY_MATRIX
4375ccflags-$(CONFIG_FEATURE_SAP_COND_CHAN_SWITCH) += -DFEATURE_SAP_COND_CHAN_SWITCH
4376ccflags-$(CONFIG_FEATURE_WLAN_CH_AVOID_EXT) += -DFEATURE_WLAN_CH_AVOID_EXT
4377ccflags-$(CONFIG_WLAN_FEATURE_MDNS_OFFLOAD) += -DWLAN_FEATURE_MDNS_OFFLOAD
4378
4379#if converged p2p is enabled
4380ifeq ($(CONFIG_CONVERGED_P2P_ENABLE), y)
4381ccflags-$(CONFIG_FEATURE_P2P_LISTEN_OFFLOAD) += -DFEATURE_P2P_LISTEN_OFFLOAD
4382endif
4383
4384#Enable support to get ANI value
4385ifeq ($(CONFIG_ANI_LEVEL_REQUEST), y)
4386ccflags-y += -DFEATURE_ANI_LEVEL_REQUEST
4387endif
4388
4389#Flags to enable/disable WMI APIs
4390ccflags-$(CONFIG_WMI_ROAM_SUPPORT) += -DWMI_ROAM_SUPPORT
4391ccflags-$(CONFIG_WMI_CONCURRENCY_SUPPORT) += -DWMI_CONCURRENCY_SUPPORT
4392ccflags-$(CONFIG_WMI_STA_SUPPORT) += -DWMI_STA_SUPPORT
4393
4394ifdef CONFIG_HIF_LARGE_CE_RING_HISTORY
4395ccflags-y += -DHIF_CE_HISTORY_MAX=$(CONFIG_HIF_LARGE_CE_RING_HISTORY)
4396endif
4397
4398ccflags-$(CONFIG_WLAN_HANG_EVENT) += -DHIF_CE_LOG_INFO
4399ccflags-$(CONFIG_WLAN_HANG_EVENT) += -DHIF_BUS_LOG_INFO
4400ccflags-$(CONFIG_WLAN_HANG_EVENT) += -DDP_SUPPORT_RECOVERY_NOTIFY
4401
4402ccflags-$(CONFIG_ENABLE_SIZE_OPTIMIZE) += -Os
4403
4404# DFS component
4405ccflags-$(CONFIG_WLAN_DFS_STATIC_MEM_ALLOC) += -DWLAN_DFS_STATIC_MEM_ALLOC
4406ccflags-$(CONFIG_WLAN_DFS_MASTER_ENABLE) += -DMOBILE_DFS_SUPPORT
4407ifeq ($(CONFIG_WLAN_FEATURE_DFS_OFFLOAD), y)
4408ccflags-$(CONFIG_WLAN_DFS_MASTER_ENABLE) += -DWLAN_DFS_FULL_OFFLOAD
4409else
4410ccflags-$(CONFIG_WLAN_DFS_MASTER_ENABLE) += -DWLAN_DFS_PARTIAL_OFFLOAD
4411endif
4412ccflags-$(CONFIG_WLAN_DFS_MASTER_ENABLE) += -DDFS_COMPONENT_ENABLE
4413ccflags-$(CONFIG_WLAN_DFS_MASTER_ENABLE) += -DQCA_DFS_USE_POLICY_MANAGER
4414ccflags-$(CONFIG_WLAN_DFS_MASTER_ENABLE) += -DQCA_DFS_NOL_PLATFORM_DRV_SUPPORT
4415ccflags-$(CONFIG_QCA_DFS_BW_PUNCTURE) += -DQCA_DFS_BW_PUNCTURE
4416
4417ccflags-$(CONFIG_WLAN_DEBUGFS) += -DWLAN_DEBUGFS
4418ccflags-$(CONFIG_WLAN_DEBUGFS) += -DWLAN_DBGLOG_DEBUGFS
4419ccflags-$(CONFIG_WLAN_STREAMFS) += -DWLAN_STREAMFS
4420
4421ccflags-$(CONFIG_DYNAMIC_DEBUG) += -DFEATURE_MULTICAST_HOST_FW_MSGS
4422
4423ccflags-$(CONFIG_ENABLE_SMMU_S1_TRANSLATION) += -DENABLE_SMMU_S1_TRANSLATION
4424
4425#Flag to enable/disable Line number logging
4426ccflags-$(CONFIG_LOG_LINE_NUMBER) += -DLOG_LINE_NUMBER
4427
4428#Flag to enable/disable MTRACE feature
4429ccflags-$(CONFIG_ENABLE_MTRACE_LOG) += -DENABLE_MTRACE_LOG
4430
4431ccflags-$(CONFIG_FUNC_CALL_MAP) += -DFUNC_CALL_MAP
4432
4433#Flag to enable/disable Adaptive 11r feature
4434ccflags-$(CONFIG_ADAPTIVE_11R) += -DWLAN_ADAPTIVE_11R
4435
4436#Flag to enable/disable sae single pmk feature feature
4437ccflags-$(CONFIG_SAE_SINGLE_PMK) += -DWLAN_SAE_SINGLE_PMK
4438
4439#Flag to enable/disable multi client low latency feature support
4440ccflags-$(CONFIG_MULTI_CLIENT_LL_SUPPORT) += -DMULTI_CLIENT_LL_SUPPORT
4441
4442#Flag to enable/disable vendor handoff control feature support
4443ccflags-$(CONFIG_WLAN_VENDOR_HANDOFF_CONTROL) += -DWLAN_VENDOR_HANDOFF_CONTROL
4444
4445#Flag to enable/disable mscs feature
4446ccflags-$(CONFIG_FEATURE_MSCS) += -DWLAN_FEATURE_MSCS
4447
4448#Flag to enable NUD tracking
4449ccflags-$(CONFIG_WLAN_NUD_TRACKING) += -DWLAN_NUD_TRACKING
4450
4451#Flag to enable set and get disable channel list feature
4452ccflags-$(CONFIG_DISABLE_CHANNEL_LIST) += -DDISABLE_CHANNEL_LIST
4453
4454#Flag to enable/disable WIPS feature
4455ccflags-$(CONFIG_WLAN_BCN_RECV_FEATURE) += -DWLAN_BCN_RECV_FEATURE
4456
4457#Flag to enable/disable thermal mitigation
4458ccflags-$(CONFIG_FW_THERMAL_THROTTLE) += -DFW_THERMAL_THROTTLE
4459
4460#Flag to enable/disable LTE COEX support
4461ccflags-$(CONFIG_LTE_COEX) += -DLTE_COEX
4462
4463#Flag to enable/disable HOST_OPCLASS
4464ccflags-$(CONFIG_HOST_OPCLASS) += -DHOST_OPCLASS
4465ccflags-$(CONFIG_HOST_OPCLASS) += -DHOST_OPCLASS_EXT
4466
4467#Flag to enable/disable TARGET_11D_SCAN
4468ccflags-$(CONFIG_TARGET_11D_SCAN) += -DTARGET_11D_SCAN
4469
4470#Flag to enable/disable avoid acs frequency list feature
4471ccflags-$(CONFIG_SAP_AVOID_ACS_FREQ_LIST) += -DSAP_AVOID_ACS_FREQ_LIST
4472
4473#Flag to enable Dynamic Voltage WDCVS (Config Voltage Mode)
4474ccflags-$(CONFIG_WLAN_DYNAMIC_CVM) += -DFEATURE_WLAN_DYNAMIC_CVM
4475
4476#Flag to enable get firmware state feature
4477ccflags-$(CONFIG_QCACLD_FEATURE_FW_STATE) += -DFEATURE_FW_STATE
4478
4479#Flag to enable set coex configuration feature
4480ccflags-$(CONFIG_QCACLD_FEATURE_COEX_CONFIG) += -DFEATURE_COEX_CONFIG
4481
4482#Flag to enable MPTA helper feature
4483ccflags-$(CONFIG_QCACLD_FEATURE_MPTA_HELPER) += -DFEATURE_MPTA_HELPER
4484
4485#Flag to enable get hw capability
4486ccflags-$(CONFIG_QCACLD_FEATURE_HW_CAPABILITY) += -DFEATURE_HW_CAPABILITY
4487
4488#Flag to enable set btc chain mode feature
4489ccflags-$(CONFIG_QCACLD_FEATURE_BTC_CHAIN_MODE) += -DFEATURE_BTC_CHAIN_MODE
4490
4491ccflags-$(CONFIG_DATA_CE_SW_INDEX_NO_INLINE_UPDATE) += -DDATA_CE_SW_INDEX_NO_INLINE_UPDATE
4492
4493#Flag to enable Multi page memory allocation for RX descriptor pool
4494ccflags-$(CONFIG_QCACLD_RX_DESC_MULTI_PAGE_ALLOC) += -DRX_DESC_MULTI_PAGE_ALLOC
4495
4496#Flag to enable SAR Safety Feature
4497ccflags-$(CONFIG_SAR_SAFETY_FEATURE) += -DSAR_SAFETY_FEATURE
4498
4499ccflags-$(CONFIG_CONNECTION_ROAMING_CFG) += -DCONNECTION_ROAMING_CFG
4500ccflags-$(CONFIG_FEATURE_SET) += -DFEATURE_SET
4501ccflags-$(CONFIG_WLAN_FEATURE_LL_LT_SAP) += -DWLAN_FEATURE_LL_LT_SAP
4502
4503ccflags-$(CONFIG_WLAN_FEATURE_NEAR_FULL_IRQ) += -DWLAN_FEATURE_NEAR_FULL_IRQ
4504ccflags-$(CONFIG_WLAN_FEATURE_DP_EVENT_HISTORY) += -DWLAN_FEATURE_DP_EVENT_HISTORY
4505ccflags-$(CONFIG_WLAN_FEATURE_DP_RX_RING_HISTORY) += -DWLAN_FEATURE_DP_RX_RING_HISTORY
4506ccflags-$(CONFIG_WLAN_FEATURE_DP_MON_STATUS_RING_HISTORY) += -DWLAN_FEATURE_DP_MON_STATUS_RING_HISTORY
4507ccflags-$(CONFIG_WLAN_FEATURE_DP_TX_DESC_HISTORY) += -DWLAN_FEATURE_DP_TX_DESC_HISTORY
4508ccflags-$(CONFIG_REO_QDESC_HISTORY) += -DREO_QDESC_HISTORY
4509ccflags-$(CONFIG_DP_TX_HW_DESC_HISTORY) += -DDP_TX_HW_DESC_HISTORY
4510ifdef CONFIG_QDF_NBUF_HISTORY_SIZE
4511ccflags-y += -DQDF_NBUF_HISTORY_SIZE=$(CONFIG_QDF_NBUF_HISTORY_SIZE)
4512endif
4513ccflags-$(CONFIG_WLAN_DP_PER_RING_TYPE_CONFIG) += -DWLAN_DP_PER_RING_TYPE_CONFIG
4514ccflags-$(CONFIG_WLAN_CE_INTERRUPT_THRESHOLD_CONFIG) += -DWLAN_CE_INTERRUPT_THRESHOLD_CONFIG
4515ccflags-$(CONFIG_SAP_DHCP_FW_IND) += -DSAP_DHCP_FW_IND
4516ccflags-$(CONFIG_WLAN_DP_PENDING_MEM_FLUSH) += -DWLAN_DP_PENDING_MEM_FLUSH
4517ccflags-$(CONFIG_WLAN_SUPPORT_DATA_STALL) += -DWLAN_SUPPORT_DATA_STALL
4518ccflags-$(CONFIG_WLAN_SUPPORT_TXRX_HL_BUNDLE) += -DWLAN_SUPPORT_TXRX_HL_BUNDLE
4519ccflags-$(CONFIG_QCN7605_PCIE_SHADOW_REG_SUPPORT) += -DQCN7605_PCIE_SHADOW_REG_SUPPORT
4520ccflags-$(CONFIG_QCN7605_PCIE_GOLBAL_RESET_SUPPORT) += -DQCN7605_PCIE_GOLBAL_RESET_SUPPORT
4521ccflags-$(CONFIG_MARK_ICMP_REQ_TO_FW) += -DWLAN_DP_FEATURE_MARK_ICMP_REQ_TO_FW
4522ccflags-$(CONFIG_EMULATION_2_0) += -DCONFIG_KIWI_EMULATION_2_0
4523ccflags-$(CONFIG_WORD_BASED_TLV) += -DCONFIG_WORD_BASED_TLV
4524ccflags-$(CONFIG_4_BYTES_TLV_TAG) += -DCONFIG_4_BYTES_TLV_TAG
4525ccflags-$(CONFIG_WLAN_SKIP_BAR_UPDATE) += -DWLAN_SKIP_BAR_UPDATE
4526ccflags-$(CONFIG_WLAN_TRACEPOINTS) += -DWLAN_TRACEPOINTS
4527
4528ccflags-$(CONFIG_QCACLD_FEATURE_SON) += -DFEATURE_PERPKT_INFO
4529ccflags-$(CONFIG_QCACLD_FEATURE_SON) += -DQCA_ENHANCED_STATS_SUPPORT
4530ccflags-$(CONFIG_WLAN_FEATURE_CE_RX_BUFFER_REUSE) += -DWLAN_FEATURE_CE_RX_BUFFER_REUSE
4531
4532CONFIG_NUM_SOC_PERF_CLUSTER ?= 1
4533ccflags-y += -DNUM_SOC_PERF_CLUSTER=$(CONFIG_NUM_SOC_PERF_CLUSTER)
4534
4535ifeq ($(CONFIG_QMI_COMPONENT_ENABLE), y)
4536ccflags-y += -DQMI_COMPONENT_ENABLE
4537ifeq ($(CONFIG_QMI_WFDS), y)
4538ccflags-y += -DQMI_WFDS
4539endif
4540endif
4541
4542ifdef CONFIG_MAX_LOGS_PER_SEC
4543ccflags-y += -DWLAN_MAX_LOGS_PER_SEC=$(CONFIG_MAX_LOGS_PER_SEC)
4544endif
4545
4546ifeq ($(CONFIG_NON_QC_PLATFORM), y)
4547ccflags-y += -DWLAN_DUMP_LOG_BUF_CNT=$(CONFIG_DUMP_LOG_BUF_CNT)
4548endif
4549
4550ifdef CONFIG_SCHED_HISTORY_SIZE
4551ccflags-y += -DWLAN_SCHED_HISTORY_SIZE=$(CONFIG_SCHED_HISTORY_SIZE)
4552endif
4553
4554ifdef CONFIG_QDF_TIMER_MULTIPLIER_FRAC
4555ccflags-y += -DQDF_TIMER_MULTIPLIER_FRAC=$(CONFIG_QDF_TIMER_MULTIPLIER_FRAC)
4556endif
4557
4558ifdef CONFIG_DP_LEGACY_MODE_CSM_DEFAULT_DISABLE
4559ccflags-y += -DDP_LEGACY_MODE_CSM_DEFAULT_DISABLE=$(CONFIG_DP_LEGACY_MODE_CSM_DEFAULT_DISABLE)
4560endif
4561
4562ifdef CONFIG_HANDLE_RX_REROUTE_ERR
4563ccflags-y += -DHANDLE_RX_REROUTE_ERR
4564endif
4565
4566# configure log buffer size
4567ifdef CONFIG_CFG_NUM_DP_TRACE_RECORD
4568ccflags-y += -DMAX_QDF_DP_TRACE_RECORDS=$(CONFIG_CFG_NUM_DP_TRACE_RECORD)
4569endif
4570
4571ifdef CONFIG_CFG_NUM_HTC_CREDIT_HISTORY
4572ccflags-y += -DHTC_CREDIT_HISTORY_MAX=$(CONFIG_CFG_NUM_HTC_CREDIT_HISTORY)
4573endif
4574
4575ifdef CONFIG_CFG_NUM_WMI_EVENT_HISTORY
4576ccflags-y += -DWMI_EVENT_DEBUG_MAX_ENTRY=$(CONFIG_CFG_NUM_WMI_EVENT_HISTORY)
4577endif
4578
4579ifdef CONFIG_CFG_NUM_WMI_MGMT_EVENT_HISTORY
4580ccflags-y += -DWMI_MGMT_EVENT_DEBUG_MAX_ENTRY=$(CONFIG_CFG_NUM_WMI_MGMT_EVENT_HISTORY)
4581endif
4582
4583ifdef CONFIG_CFG_NUM_TX_RX_HISTOGRAM
4584ccflags-y += -DNUM_TX_RX_HISTOGRAM=$(CONFIG_CFG_NUM_TX_RX_HISTOGRAM)
4585endif
4586
4587ifdef CONFIG_CFG_NUM_RX_IND_RECORD
4588ccflags-y += -DOL_RX_INDICATION_MAX_RECORDS=$(CONFIG_CFG_NUM_RX_IND_RECORD)
4589endif
4590
4591ifdef CONFIG_CFG_NUM_ROAM_DEBUG_RECORD
4592ccflags-y += -DWLAN_ROAM_DEBUG_MAX_REC=$(CONFIG_CFG_NUM_ROAM_DEBUG_RECORD)
4593endif
4594
4595ifdef CONFIG_CFG_PMO_WOW_FILTERS_MAX
4596ccflags-y += -DPMO_WOW_FILTERS_MAX=$(CONFIG_CFG_PMO_WOW_FILTERS_MAX)
4597endif
4598
4599ifdef CONFIG_CFG_GTK_OFFLOAD_MAX_VDEV
4600ccflags-y += -DCFG_TGT_DEFAULT_GTK_OFFLOAD_MAX_VDEV=$(CONFIG_CFG_GTK_OFFLOAD_MAX_VDEV)
4601endif
4602
4603ifdef CONFIG_TGT_NUM_MSDU_DESC
4604ccflags-y += -DCFG_TGT_NUM_MSDU_DESC=$(CONFIG_TGT_NUM_MSDU_DESC)
4605endif
4606
4607ifdef CONFIG_HTC_MAX_MSG_PER_BUNDLE_TX
4608ccflags-y += -DCFG_HTC_MAX_MSG_PER_BUNDLE_TX=$(CONFIG_HTC_MAX_MSG_PER_BUNDLE_TX)
4609endif
4610
4611ifdef CONFIG_CFG_BMISS_OFFLOAD_MAX_VDEV
4612ccflags-y += -DCFG_TGT_DEFAULT_BMISS_OFFLOAD_MAX_VDEV=$(CONFIG_CFG_BMISS_OFFLOAD_MAX_VDEV)
4613endif
4614
4615ifdef CONFIG_WLAN_UMAC_MLO_MAX_DEV
4616ccflags-y += -DWLAN_UMAC_MLO_MAX_DEV=$(CONFIG_WLAN_UMAC_MLO_MAX_DEV)
4617endif
4618
4619ifdef CONFIG_CFG_ROAM_OFFLOAD_MAX_VDEV
4620ccflags-y += -DCFG_TGT_DEFAULT_ROAM_OFFLOAD_MAX_VDEV=$(CONFIG_CFG_ROAM_OFFLOAD_MAX_VDEV)
4621endif
4622
4623ifdef CONFIG_CFG_MAX_PERIODIC_TX_PTRNS
4624ccflags-y += -DMAXNUM_PERIODIC_TX_PTRNS=$(CONFIG_CFG_MAX_PERIODIC_TX_PTRNS)
4625endif
4626
4627ifdef CONFIG_CFG_MAX_STA_VDEVS
4628ccflags-y += -DCFG_TGT_DEFAULT_MAX_STA_VDEVS=$(CONFIG_CFG_MAX_STA_VDEVS)
4629endif
4630
4631ifdef CONFIG_CFG_NUM_OF_ADDITIONAL_FW_PEERS
4632ccflags-y += -DNUM_OF_ADDITIONAL_FW_PEERS=$(CONFIG_CFG_NUM_OF_ADDITIONAL_FW_PEERS)
4633endif
4634
4635ifdef CONFIG_CFG_NUM_OF_TDLS_CONN_TABLE_ENTRIES
4636ccflags-y += -DCFG_TGT_NUM_TDLS_CONN_TABLE_ENTRIES=$(CONFIG_CFG_NUM_OF_TDLS_CONN_TABLE_ENTRIES)
4637endif
4638
4639ifdef CONFIG_CFG_TGT_AST_SKID_LIMIT
4640ccflags-y += -DCFG_TGT_AST_SKID_LIMIT=$(CONFIG_CFG_TGT_AST_SKID_LIMIT)
4641endif
4642
4643ifdef CONFIG_TX_RESOURCE_HIGH_TH_IN_PER
4644ccflags-y += -DTX_RESOURCE_HIGH_TH_IN_PER=$(CONFIG_TX_RESOURCE_HIGH_TH_IN_PER)
4645endif
4646
4647ifdef CONFIG_TX_RESOURCE_LOW_TH_IN_PER
4648ccflags-y += -DTX_RESOURCE_LOW_TH_IN_PER=$(CONFIG_TX_RESOURCE_LOW_TH_IN_PER)
4649endif
4650
4651CONFIG_WLAN_MAX_PSOCS ?= 1
4652ccflags-y += -DWLAN_MAX_PSOCS=$(CONFIG_WLAN_MAX_PSOCS)
4653
4654CONFIG_WLAN_MAX_PDEVS ?= 1
4655ccflags-y += -DWLAN_MAX_PDEVS=$(CONFIG_WLAN_MAX_PDEVS)
4656
4657ifeq ($(CONFIG_WLAN_FEATURE_11BE_MLO), y)
4658CONFIG_WLAN_MAX_ML_VDEVS ?= 3
4659else
4660CONFIG_WLAN_MAX_ML_VDEVS ?= 0
4661endif
4662ccflags-y += -DWLAN_MAX_ML_VDEVS=$(CONFIG_WLAN_MAX_ML_VDEVS)
4663
4664CONFIG_WLAN_MAX_VDEVS ?= 6
4665ccflags-y += -DWLAN_MAX_VDEVS=$(CONFIG_WLAN_MAX_VDEVS)
4666
4667ifdef CONFIG_WLAN_FEATURE_11BE_MLO
4668CONFIG_WLAN_MAX_MLD ?= 2
4669else
4670CONFIG_WLAN_MAX_MLD ?= 1
4671endif
4672ccflags-y += -DWLAN_MAX_MLD=$(CONFIG_WLAN_MAX_MLD)
4673
4674ifdef CONFIG_WLAN_FEATURE_11BE_MLO
4675CONFIG_WLAN_MAX_ML_DEFAULT_LINK ?= 2
4676else
4677CONFIG_WLAN_MAX_ML_DEFAULT_LINK  ?= 1
4678endif
4679ccflags-y += -DWLAN_MAX_ML_DEFAULT_LINK=$(CONFIG_WLAN_MAX_ML_DEFAULT_LINK)
4680
4681ifdef CONFIG_WLAN_FEATURE_11BE_MLO
4682ifndef CONFIG_WLAN_DEFAULT_REC_LINK_VALUE
4683CONFIG_WLAN_DEFAULT_REC_LINK_VALUE  ?= 2
4684endif
4685else
4686ifndef CONFIG_WLAN_DEFAULT_REC_LINK_VALUE
4687CONFIG_WLAN_DEFAULT_REC_LINK_VALUE  ?= 2
4688endif
4689endif
4690ccflags-y += -DWLAN_DEFAULT_REC_LINK_VALUE=$(CONFIG_WLAN_DEFAULT_REC_LINK_VALUE)
4691
4692ifdef CONFIG_WLAN_FEATURE_11BE_MLO
4693CONFIG_WLAN_MAX_ML_BSS_LINKS ?= 3
4694else
4695CONFIG_WLAN_MAX_ML_BSS_LINKS ?= 1
4696endif
4697ccflags-y += -DWLAN_MAX_ML_BSS_LINKS=$(CONFIG_WLAN_MAX_ML_BSS_LINKS)
4698
4699#Maximum pending commands for a vdev is calculated in vdev create handler
4700#by WLAN_SER_MAX_PENDING_CMDS/WLAN_SER_MAX_VDEVS. For SAP case, we will need
4701#to accommodate 32 Pending commands to handle multiple STA sending
4702#deauth/disassoc at the same time and for STA vdev,4 non scan pending commands
4703#are supported. So calculate WLAN_SER_MAX_PENDING_COMMANDS based on the SAP
4704#modes supported and no of STA vdev total non scan pending queue. Reserve
4705#additional 3 pending commands for WLAN_SER_MAX_PENDING_CMDS_AP to account for
4706#other commands like hardware mode change.
4707
4708ifdef CONFIG_SIR_SAP_MAX_NUM_PEERS
4709CONFIG_WLAN_SER_MAX_PENDING_CMDS_AP ?=$(CONFIG_SIR_SAP_MAX_NUM_PEERS)
4710else
4711CONFIG_WLAN_SER_MAX_PENDING_CMDS_AP ?=32
4712endif
4713ccflags-y += -DWLAN_SER_MAX_PENDING_CMDS_AP=$(CONFIG_WLAN_SER_MAX_PENDING_CMDS_AP)+3
4714
4715CONFIG_WLAN_SER_MAX_PENDING_CMDS_STA ?= 4
4716ccflags-y += -DWLAN_SER_MAX_PENDING_CMDS_STA=$(CONFIG_WLAN_SER_MAX_PENDING_CMDS_STA)
4717
4718CONFIG_WLAN_MAX_PENDING_CMDS ?= $(CONFIG_WLAN_SER_MAX_PENDING_CMDS_AP)*3+$(CONFIG_WLAN_SER_MAX_PENDING_CMDS_STA)*2
4719
4720ccflags-y += -DWLAN_SER_MAX_PENDING_CMDS=$(CONFIG_WLAN_MAX_PENDING_CMDS)
4721
4722CONFIG_WLAN_PDEV_MAX_VDEVS ?= $(CONFIG_WLAN_MAX_VDEVS)
4723ccflags-y += -DWLAN_PDEV_MAX_VDEVS=$(CONFIG_WLAN_PDEV_MAX_VDEVS)
4724
4725CONFIG_WLAN_PSOC_MAX_VDEVS ?= $(CONFIG_WLAN_MAX_VDEVS)
4726ccflags-y += -DWLAN_PSOC_MAX_VDEVS=$(CONFIG_WLAN_PSOC_MAX_VDEVS)
4727
4728CONFIG_MAX_SCAN_CACHE_SIZE ?= 500
4729ccflags-y += -DMAX_SCAN_CACHE_SIZE=$(CONFIG_MAX_SCAN_CACHE_SIZE)
4730CONFIG_SCAN_MAX_REST_TIME ?= 0
4731ccflags-y += -DSCAN_MAX_REST_TIME=$(CONFIG_SCAN_MAX_REST_TIME)
4732CONFIG_SCAN_MIN_REST_TIME ?= 0
4733ccflags-y += -DSCAN_MIN_REST_TIME=$(CONFIG_SCAN_MIN_REST_TIME)
4734CONFIG_SCAN_BURST_DURATION ?= 0
4735ccflags-y += -DSCAN_BURST_DURATION=$(CONFIG_SCAN_BURST_DURATION)
4736CONFIG_SCAN_PROBE_SPACING_TIME ?= 0
4737ccflags-y += -DSCAN_PROBE_SPACING_TIME=$(CONFIG_SCAN_PROBE_SPACING_TIME)
4738CONFIG_SCAN_PROBE_DELAY ?= 0
4739ccflags-y += -DSCAN_PROBE_DELAY=$(CONFIG_SCAN_PROBE_DELAY)
4740CONFIG_SCAN_MAX_SCAN_TIME ?= 30000
4741ccflags-y += -DSCAN_MAX_SCAN_TIME=$(CONFIG_SCAN_MAX_SCAN_TIME)
4742CONFIG_SCAN_NETWORK_IDLE_TIMEOUT ?= 0
4743ccflags-y += -DSCAN_NETWORK_IDLE_TIMEOUT=$(CONFIG_SCAN_NETWORK_IDLE_TIMEOUT)
4744CONFIG_HIDDEN_SSID_TIME ?= 0xFFFFFFFF
4745ccflags-y += -DHIDDEN_SSID_TIME=$(CONFIG_HIDDEN_SSID_TIME)
4746CONFIG_SCAN_CHAN_STATS_EVENT_ENAB ?= false
4747ccflags-y += -DSCAN_CHAN_STATS_EVENT_ENAB=$(CONFIG_SCAN_CHAN_STATS_EVENT_ENAB)
4748CONFIG_MAX_BCN_PROBE_IN_SCAN_QUEUE ?= 150
4749ccflags-y += -DMAX_BCN_PROBE_IN_SCAN_QUEUE=$(CONFIG_MAX_BCN_PROBE_IN_SCAN_QUEUE)
4750
4751#CONFIG_RX_DIAG_WQ_MAX_SIZE maximum number FW diag events that can be queued in
4752#FW diag events work queue. Host driver will discard the all diag events after
4753#this limit is reached.
4754#
4755# Value 0 represents no limit and any non zero value represents the maximum
4756# size of the work queue.
4757CONFIG_RX_DIAG_WQ_MAX_SIZE ?= 1000
4758ccflags-y += -DRX_DIAG_WQ_MAX_SIZE=$(CONFIG_RX_DIAG_WQ_MAX_SIZE)
4759
4760CONFIG_MGMT_DESC_POOL_MAX ?= 64
4761ccflags-y += -DMGMT_DESC_POOL_MAX=$(CONFIG_MGMT_DESC_POOL_MAX)
4762
4763ifdef CONFIG_SIR_SAP_MAX_NUM_PEERS
4764ccflags-y += -DSIR_SAP_MAX_NUM_PEERS=$(CONFIG_SIR_SAP_MAX_NUM_PEERS)
4765endif
4766
4767ifdef CONFIG_BEACON_TX_OFFLOAD_MAX_VDEV
4768ccflags-y += -DCFG_TGT_DEFAULT_BEACON_TX_OFFLOAD_MAX_VDEV=$(CONFIG_BEACON_TX_OFFLOAD_MAX_VDEV)
4769endif
4770
4771ifdef CONFIG_LIMIT_IPA_TX_BUFFER
4772ccflags-y += -DLIMIT_IPA_TX_BUFFER=$(CONFIG_LIMIT_IPA_TX_BUFFER)
4773endif
4774
4775ifdef CONFIG_LOCK_STATS_ON
4776ccflags-y += -DQDF_LOCK_STATS=1
4777ccflags-y += -DQDF_LOCK_STATS_DESTROY_PRINT=0
4778ifneq ($(CONFIG_ARCH_SDXPRAIRIE), y)
4779ccflags-y += -DQDF_LOCK_STATS_BUG_ON=1
4780endif
4781ccflags-$(CONFIG_VCPU_TIMESTOLEN) += -DVCPU_TIMESTOLEN
4782ccflags-y += -DQDF_LOCK_STATS_LIST=1
4783ccflags-y += -DQDF_LOCK_STATS_LIST_SIZE=256
4784endif
4785
4786ifdef CONFIG_FW_THERMAL_THROTTLE
4787ccflags-y += -DFW_THERMAL_THROTTLE_SUPPORT
4788endif
4789
4790ccflags-$(CONFIG_FEATURE_RX_LINKSPEED_ROAM_TRIGGER) += -DFEATURE_RX_LINKSPEED_ROAM_TRIGGER
4791#DP_RATETABLE_SUPPORT is enabled when CONFIG_FEATURE_RX_LINKSPEED_ROAM_TRIGGER is enabled
4792ccflags-$(CONFIG_FEATURE_RX_LINKSPEED_ROAM_TRIGGER) += -DDP_RATETABLE_SUPPORT
4793
4794ccflags-$(CONFIG_BAND_6GHZ) += -DCONFIG_BAND_6GHZ
4795ccflags-$(CONFIG_6G_SCAN_CHAN_SORT_ALGO) += -DFEATURE_6G_SCAN_CHAN_SORT_ALGO
4796ccflags-$(CONFIG_AFC_SUPPORT) += -DCONFIG_AFC_SUPPORT
4797ccflags-$(CONFIG_WLAN_FEATURE_AFC_DCS_SKIP_ACS_RANGE) += -DWLAN_FEATURE_AFC_DCS_SKIP_ACS_RANGE
4798
4799ccflags-$(CONFIG_RX_FISA) += -DWLAN_SUPPORT_RX_FISA
4800ccflags-$(CONFIG_RX_FISA_HISTORY) += -DWLAN_SUPPORT_RX_FISA_HIST
4801
4802ccflags-$(CONFIG_DP_SWLM) += -DWLAN_DP_FEATURE_SW_LATENCY_MGR
4803
4804ccflags-$(CONFIG_RX_DEFRAG_DO_NOT_REINJECT) += -DRX_DEFRAG_DO_NOT_REINJECT
4805
4806ccflags-$(CONFIG_HANDLE_BC_EAP_TX_FRM) += -DHANDLE_BROADCAST_EAPOL_TX_FRAME
4807
4808ccflags-$(CONFIG_MORE_TX_DESC) += -DTX_TO_NPEERS_INC_TX_DESCS
4809
4810ccflags-$(CONFIG_HASTINGS_BT_WAR) += -DHASTINGS_BT_WAR
4811
4812ccflags-$(CONFIG_HIF_DEBUG) += -DHIF_CONFIG_SLUB_DEBUG_ON
4813ccflags-$(CONFIG_HAL_DEBUG) += -DHAL_CONFIG_SLUB_DEBUG_ON
4814
4815ccflags-$(CONFIG_FOURTH_CONNECTION) += -DFEATURE_FOURTH_CONNECTION
4816ccflags-$(CONFIG_FOURTH_CONNECTION_AUTO) += -DFOURTH_CONNECTION_AUTO
4817ccflags-$(CONFIG_WMI_SEND_RECV_QMI) += -DWLAN_FEATURE_WMI_SEND_RECV_QMI
4818
4819ccflags-$(CONFIG_WDI3_STATS_UPDATE) += -DWDI3_STATS_UPDATE
4820ccflags-$(CONFIG_WDI3_STATS_BW_MONITOR) += -DWDI3_STATS_BW_MONITOR
4821
4822ccflags-$(CONFIG_IPA_P2P_SUPPORT) += -DIPA_P2P_SUPPORT
4823
4824ccflags-$(CONFIG_WLAN_CUSTOM_DSCP_UP_MAP) += -DWLAN_CUSTOM_DSCP_UP_MAP
4825ccflags-$(CONFIG_WLAN_SEND_DSCP_UP_MAP_TO_FW) += -DWLAN_SEND_DSCP_UP_MAP_TO_FW
4826
4827ccflags-$(CONFIG_SMMU_S1_UNMAP) += -DCONFIG_SMMU_S1_UNMAP
4828ccflags-$(CONFIG_HIF_CPU_PERF_AFFINE_MASK) += -DHIF_CPU_PERF_AFFINE_MASK
4829ccflags-$(CONFIG_HIF_CPU_CLEAR_AFFINITY) += -DHIF_CPU_CLEAR_AFFINITY
4830
4831ccflags-$(CONFIG_GENERIC_SHADOW_REGISTER_ACCESS_ENABLE) += -DGENERIC_SHADOW_REGISTER_ACCESS_ENABLE
4832ccflags-$(CONFIG_IPA_SET_RESET_TX_DB_PA) += -DIPA_SET_RESET_TX_DB_PA
4833ccflags-$(CONFIG_DEVICE_FORCE_WAKE_ENABLE) += -DDEVICE_FORCE_WAKE_ENABLE
4834ccflags-$(CONFIG_WINDOW_REG_PLD_LOCK_ENABLE) += -DWINDOW_REG_PLD_LOCK_ENABLE
4835ccflags-$(CONFIG_DUMP_REO_QUEUE_INFO_IN_DDR) += -DDUMP_REO_QUEUE_INFO_IN_DDR
4836ccflags-$(CONFIG_DP_RX_REFILL_CPU_PERF_AFFINE_MASK) += -DDP_RX_REFILL_CPU_PERF_AFFINE_MASK
4837ccflags-$(CONFIG_WLAN_FEATURE_AFFINITY_MGR) += -DWLAN_FEATURE_AFFINITY_MGR
4838ccflags-$(CONFIG_FEATURE_ENABLE_CE_DP_IRQ_AFFINE) += -DFEATURE_ENABLE_CE_DP_IRQ_AFFINE
4839found = $(shell if grep -qF "walt_get_cpus_taken" $(srctree)/kernel/sched/walt/walt.c; then echo "yes" ;else echo "no" ;fi;)
4840ifeq ($(findstring yes, $(found)), yes)
4841ccflags-y += -DWALT_GET_CPU_TAKEN_SUPPORT
4842endif
4843
4844ifdef CONFIG_MAX_CLIENTS_ALLOWED
4845ccflags-y += -DWLAN_MAX_CLIENTS_ALLOWED=$(CONFIG_MAX_CLIENTS_ALLOWED)
4846endif
4847
4848ifeq ($(CONFIG_WLAN_FEATURE_RX_BUFFER_POOL), y)
4849ccflags-y += -DWLAN_FEATURE_RX_PREALLOC_BUFFER_POOL
4850ifdef CONFIG_DP_RX_BUFFER_POOL_SIZE
4851ccflags-y += -DDP_RX_BUFFER_POOL_SIZE=$(CONFIG_DP_RX_BUFFER_POOL_SIZE)
4852endif
4853ifdef CONFIG_DP_RX_BUFFER_POOL_ALLOC_THRES
4854ccflags-y += -DDP_RX_BUFFER_POOL_ALLOC_THRES=$(CONFIG_DP_RX_BUFFER_POOL_ALLOC_THRES)
4855endif
4856ifdef CONFIG_DP_RX_REFILL_BUFF_POOL_SIZE
4857ccflags-y += -DDP_RX_REFILL_BUFF_POOL_SIZE=$(CONFIG_DP_RX_REFILL_BUFF_POOL_SIZE)
4858endif
4859ifdef CONFIG_DP_RX_REFILL_THRD_THRESHOLD
4860ccflags-y += -DDP_RX_REFILL_THRD_THRESHOLD=$(CONFIG_DP_RX_REFILL_THRD_THRESHOLD)
4861endif
4862endif
4863
4864ccflags-$(CONFIG_DP_FT_LOCK_HISTORY) += -DDP_FT_LOCK_HISTORY
4865
4866ccflags-$(CONFIG_INTRA_BSS_FWD_OFFLOAD) += -DINTRA_BSS_FWD_OFFLOAD
4867ccflags-$(CONFIG_GET_DRIVER_MODE) += -DFEATURE_GET_DRIVER_MODE
4868
4869ifeq ($(CONFIG_FEATURE_IPA_PIPE_CHANGE_WDI1), y)
4870ccflags-y += -DFEATURE_IPA_PIPE_CHANGE_WDI1
4871endif
4872
4873ccflags-$(CONFIG_WLAN_BOOTUP_MARKER) += -DWLAN_BOOTUP_MARKER
4874ifdef CONFIG_WLAN_PLACEMARKER_PREFIX
4875ccflags-y += -DWLAN_PLACEMARKER_PREFIX=\"$(CONFIG_WLAN_PLACEMARKER_PREFIX)\"
4876endif
4877
4878ccflags-$(CONFIG_FEATURE_STA_MODE_VOTE_LINK) += -DFEATURE_STA_MODE_VOTE_LINK
4879ccflags-$(CONFIG_WLAN_ENABLE_GPIO_WAKEUP) += -DWLAN_ENABLE_GPIO_WAKEUP
4880ccflags-$(CONFIG_WLAN_MAC_ADDR_UPDATE_DISABLE) += -DWLAN_MAC_ADDR_UPDATE_DISABLE
4881
4882ifeq ($(CONFIG_SMP), y)
4883ifeq ($(CONFIG_HIF_DETECTION_LATENCY_ENABLE), y)
4884ccflags-y += -DHIF_DETECTION_LATENCY_ENABLE
4885ccflags-y += -DDETECTION_TIMER_TIMEOUT=4000
4886ccflags-y += -DDETECTION_LATENCY_THRESHOLD=3900
4887endif
4888endif
4889
4890#Flags to enable/disable WDS specific features
4891ccflags-$(CONFIG_FEATURE_WDS) += -DFEATURE_WDS
4892ccflags-$(CONFIG_FEATURE_MEC) += -DFEATURE_MEC
4893ccflags-$(CONFIG_FEATURE_MCL_REPEATER) += -DFEATURE_MCL_REPEATER
4894ccflags-$(CONFIG_WDS_CONV_TARGET_IF_OPS_ENABLE) += -DWDS_CONV_TARGET_IF_OPS_ENABLE
4895ccflags-$(CONFIG_BYPASS_WDS_OL_OPS) += -DBYPASS_OL_OPS
4896
4897ccflags-$(CONFIG_IPA_WDI3_TX_TWO_PIPES) += -DIPA_WDI3_TX_TWO_PIPES
4898
4899ccflags-$(CONFIG_DP_TX_TRACKING) += -DDP_TX_TRACKING
4900
4901ifdef CONFIG_CHIP_VERSION
4902ccflags-y += -DCHIP_VERSION=$(CONFIG_CHIP_VERSION)
4903endif
4904
4905ccflags-$(CONFIG_WLAN_FEATURE_MARK_FIRST_WAKEUP_PACKET) += -DWLAN_FEATURE_MARK_FIRST_WAKEUP_PACKET
4906
4907ccflags-$(CONFIG_SHUTDOWN_WLAN_IN_SYSTEM_SUSPEND) += -DSHUTDOWN_WLAN_IN_SYSTEM_SUSPEND
4908
4909ifeq ($(CONFIG_WLAN_FEATURE_MCC_QUOTA), y)
4910ccflags-y += -DWLAN_FEATURE_MCC_QUOTA
4911ifdef CONFIG_WLAN_MCC_MIN_CHANNEL_QUOTA
4912ccflags-y += -DWLAN_MCC_MIN_CHANNEL_QUOTA=$(CONFIG_WLAN_MCC_MIN_CHANNEL_QUOTA)
4913endif
4914endif
4915
4916ccflags-$(CONFIG_WLAN_FEATURE_PEER_TXQ_FLUSH_CONF) += -DWLAN_FEATURE_PEER_TXQ_FLUSH_CONF
4917
4918ifeq ($(CONFIG_DP_HW_TX_DELAY_STATS_ENABLE), y)
4919ccflags-y += -DHW_TX_DELAY_STATS_ENABLE
4920endif
4921
4922# Config MAX SAP interface number
4923ifdef CONFIG_QDF_MAX_NO_OF_SAP_MODE
4924ccflags-y += -DQDF_MAX_NO_OF_SAP_MODE=$(CONFIG_QDF_MAX_NO_OF_SAP_MODE)
4925endif
4926
4927#Flags to enable/disable Dynamic WLAN interface control feature
4928ifeq ($(CONFIG_CNSS_HW_SECURE_DISABLE), y)
4929ccflags-y += -DFEATURE_CNSS_HW_SECURE_DISABLE
4930endif
4931
4932#DBAM feature needs COEX feature to be enabled
4933ifeq ($(CONFIG_FEATURE_COEX), y)
4934ccflags-$(CONFIG_WLAN_FEATURE_COEX_DBAM) += -DWLAN_FEATURE_DBAM_CONFIG
4935endif
4936
4937# Flag to enable Constrained Application Protocol feature
4938ccflags-$(CONFIG_WLAN_FEATURE_COAP) += -DWLAN_FEATURE_COAP
4939
4940# SSR driver dump config
4941ccflags-$(CONFIG_CNSS2_SSR_DRIVER_DUMP) += -DWLAN_FEATURE_SSR_DRIVER_DUMP
4942
4943# Currently, for versions of gcc which support it, the kernel Makefile
4944# is disabling the maybe-uninitialized warning.  Re-enable it for the
4945# WLAN driver.  Note that we must use ccflags-y here so that it
4946# will override the kernel settings.
4947ifeq ($(call cc-option-yn, -Wmaybe-uninitialized), y)
4948ccflags-y += -Wmaybe-uninitialized
4949ifneq (y,$(CONFIG_ARCH_MSM))
4950ccflags-y += -Wframe-larger-than=4096
4951endif
4952endif
4953ccflags-y += -Wmissing-prototypes
4954
4955ifeq ($(call cc-option-yn, -Wheader-guard), y)
4956ccflags-y += -Wheader-guard
4957endif
4958# If the module name is not "wlan", then the define MULTI_IF_NAME to be the
4959# same a the QCA CHIP name. The host driver will then append MULTI_IF_NAME to
4960# any string that must be unique for all instances of the driver on the system.
4961# This allows multiple instances of the driver with different module names.
4962# If the module name is wlan, leave MULTI_IF_NAME undefined and the code will
4963# treat the driver as the primary driver.
4964#
4965# If DYNAMIC_SINGLE_CHIP is defined and MULTI_IF_NAME is undefined, which means
4966# there are multiple possible drivers, but only 1 driver will be loaded at
4967# a time(WLAN dynamic detect), no matter what the module name is, then
4968# host driver will only append DYNAMIC_SINGLE_CHIP to the path of
4969# firmware/mac/ini file.
4970#
4971# If DYNAMIC_SINGLE_CHIP & MULTI_IF_NAME defined, which means there are
4972# multiple possible drivers, we also can load multiple drivers together.
4973# And we can use DYNAMIC_SINGLE_CHIP to distinguish the ko name, and use
4974# MULTI_IF_NAME to make cnss2 platform driver to figure out which wlanhost
4975# driver attached. Moreover, as the first priority, host driver will only
4976# append DYNAMIC_SINGLE_CHIP to the path of firmware/mac/ini file.
4977
4978ifneq ($(DYNAMIC_SINGLE_CHIP),)
4979ccflags-y += -DDYNAMIC_SINGLE_CHIP=\"$(DYNAMIC_SINGLE_CHIP)\"
4980ifneq ($(MULTI_IF_NAME),)
4981ccflags-y += -DMULTI_IF_NAME=\"$(MULTI_IF_NAME)\"
4982endif
4983#
4984else
4985
4986ifneq ($(MODNAME), wlan)
4987CHIP_NAME ?= $(MODNAME)
4988ccflags-y += -DMULTI_IF_NAME=\"$(CHIP_NAME)\"
4989endif
4990
4991endif #DYNAMIC_SINGLE_CHIP
4992
4993# WLAN_HDD_ADAPTER_MAGIC must be unique for all instances of the driver on the
4994# system. If it is not defined, then the host driver will use the first 4
4995# characters (including NULL) of MULTI_IF_NAME to construct
4996# WLAN_HDD_ADAPTER_MAGIC.
4997ifdef WLAN_HDD_ADAPTER_MAGIC
4998ccflags-y += -DWLAN_HDD_ADAPTER_MAGIC=$(WLAN_HDD_ADAPTER_MAGIC)
4999endif
5000
5001# Determine if we are building against an arm architecture host
5002ifeq ($(findstring arm, $(ARCH)),)
5003	ccflags-y += -DWLAN_HOST_ARCH_ARM=0
5004else
5005	ccflags-y += -DWLAN_HOST_ARCH_ARM=1
5006endif
5007
5008# Android wifi state control interface
5009ifneq ($(WLAN_CTRL_NAME),)
5010ccflags-y += -DWLAN_CTRL_NAME=\"$(WLAN_CTRL_NAME)\"
5011endif
5012
5013# inject some build related information
5014ifeq ($(CONFIG_BUILD_TAG), y)
5015CLD_CHECKOUT = $(shell cd "$(WLAN_ROOT)" && \
5016	git reflog | grep -vm1 "}: cherry-pick: " | grep -oE ^[0-f]+)
5017CLD_IDS = $(shell cd "$(WLAN_ROOT)" && \
5018	git log -50 $(CLD_CHECKOUT)~..HEAD | \
5019		sed -nE 's/^\s*Change-Id: (I[0-f]{10})[0-f]{30}\s*$$/\1/p' | \
5020		paste -sd "," -)
5021
5022CMN_CHECKOUT = $(shell cd "$(WLAN_COMMON_INC)" && \
5023	git reflog | grep -vm1 "}: cherry-pick: " | grep -oE ^[0-f]+)
5024CMN_IDS = $(shell cd "$(WLAN_COMMON_INC)" && \
5025	git log -50 $(CMN_CHECKOUT)~..HEAD | \
5026		sed -nE 's/^\s*Change-Id: (I[0-f]{10})[0-f]{30}\s*$$/\1/p' | \
5027		paste -sd "," -)
5028BUILD_TAG = "cld:$(CLD_IDS); cmn:$(CMN_IDS); dev:$(DEVNAME)"
5029ccflags-y += -DBUILD_TAG=\"$(BUILD_TAG)\"
5030endif
5031
5032ifeq ($(CONFIG_ARCH_PINEAPPLE), y)
5033ccflags-y += -gdwarf-4
5034endif
5035
5036# Module information used by KBuild framework
5037obj-$(CONFIG_QCA_CLD_WLAN) += $(MODNAME).o
5038ifeq ($(CONFIG_WLAN_RESIDENT_DRIVER), y)
5039$(MODNAME)-y := $(HDD_SRC_DIR)/wlan_hdd_main_module.o
5040obj-$(CONFIG_QCA_CLD_WLAN) += wlan_resident.o
5041wlan_resident-y := $(OBJS)
5042else
5043$(MODNAME)-y := $(OBJS)
5044endif
5045OBJS_DIRS += $(dir $(OBJS)) \
5046	     $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ \
5047	     $(QDF_OBJ_DIR)/ \
5048	     $(WLAN_COMMON_ROOT)/$(HIF_PCIE_DIR)/ \
5049	     $(WLAN_COMMON_ROOT)/$(HIF_SNOC_DIR)/ \
5050	     $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/
5051CLEAN_DIRS := $(addsuffix *.o,$(sort $(OBJS_DIRS))) \
5052	      $(addsuffix .*.o.cmd,$(sort $(OBJS_DIRS)))
5053clean-files := $(CLEAN_DIRS)
5054