Kbuild 74 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657
  1. # We can build either as part of a standalone Kernel build or as
  2. # an external module. Determine which mechanism is being used
  3. ifeq ($(MODNAME),)
  4. KERNEL_BUILD := 1
  5. else
  6. KERNEL_BUILD := 0
  7. endif
  8. ifeq ($(CONFIG_CNSS_QCA6290), y)
  9. CONFIG_LITHIUM := y
  10. CONFIG_WLAN_FEATURE_11AX := y
  11. CONFIG_WLAN_FEATURE_DFS_OFFLOAD := y
  12. CONFIG_IPA3 := n
  13. endif
  14. ifeq ($(CONFIG_CLD_HL_SDIO_CORE), y)
  15. CONFIG_QCA_WIFI_SDIO := 1
  16. endif
  17. ifeq ($(CONFIG_QCA_WIFI_SDIO), 1)
  18. CONFIG_ROME_IF = sdio
  19. endif
  20. ifdef CONFIG_ICNSS
  21. CONFIG_ROME_IF = snoc
  22. endif
  23. ifeq (y,$(findstring y,$(CONFIG_CNSS) $(CONFIG_CNSS2)))
  24. ifndef CONFIG_ROME_IF
  25. #use pci as default interface
  26. CONFIG_ROME_IF = pci
  27. endif
  28. endif
  29. ifeq ($(KERNEL_BUILD),1)
  30. # These are provided in external module based builds
  31. # Need to explicitly define for Kernel-based builds
  32. MODNAME := wlan
  33. WLAN_ROOT := drivers/staging/qcacld-3.0
  34. WLAN_COMMON_ROOT := ../qca-wifi-host-cmn
  35. WLAN_COMMON_INC := $(WLAN_ROOT)/$(WLAN_COMMON_ROOT)
  36. endif
  37. # Make WLAN as open-source driver by default
  38. WLAN_OPEN_SOURCE := 1
  39. ifeq ($(KERNEL_BUILD), 0)
  40. # These are configurable via Kconfig for kernel-based builds
  41. # Need to explicitly configure for Android-based builds
  42. ifneq ($(DEVELOPER_DISABLE_BUILD_TIMESTAMP),y)
  43. ifneq ($(WLAN_DISABLE_BUILD_TAG),y)
  44. CONFIG_BUILD_TAG := y
  45. endif
  46. endif
  47. ifeq ($(CONFIG_ARCH_MDM9630), y)
  48. CONFIG_MOBILE_ROUTER := y
  49. endif
  50. ifeq ($(CONFIG_ARCH_MDM9640), y)
  51. CONFIG_MOBILE_ROUTER := y
  52. endif
  53. ifeq ($(CONFIG_ARCH_SDX20), y)
  54. CONFIG_MOBILE_ROUTER := y
  55. endif
  56. ifeq ($(CONFIG_ARCH_MSM8917), y)
  57. ifeq ($(CONFIG_ROME_IF), sdio)
  58. CONFIG_WLAN_SYNC_TSF_PLUS := y
  59. endif
  60. endif
  61. #Flag to enable Legacy Fast Roaming2(LFR2)
  62. CONFIG_QCACLD_WLAN_LFR2 := y
  63. #Flag to enable Legacy Fast Roaming3(LFR3)
  64. ifneq ($(CONFIG_ARCH_SDX20), y)
  65. CONFIG_QCACLD_WLAN_LFR3 := y
  66. endif
  67. # JB kernel has CPU enablement patches, so enable
  68. ifeq ($(CONFIG_ROME_IF),pci)
  69. CONFIG_PRIMA_WLAN_11AC_HIGH_TP := y
  70. endif
  71. ifeq ($(CONFIG_ROME_IF),usb)
  72. CONFIG_PRIMA_WLAN_11AC_HIGH_TP := n
  73. endif
  74. ifeq ($(CONFIG_ROME_IF),sdio)
  75. CONFIG_PRIMA_WLAN_11AC_HIGH_TP := n
  76. endif
  77. ifneq ($(CONFIG_MOBILE_ROUTER), y)
  78. #Flag to enable TDLS feature
  79. CONFIG_QCOM_TDLS := y
  80. endif
  81. CONFIG_QCACLD_FEATURE_GREEN_AP := y
  82. ifeq ($(CONFIG_ARCH_MSM8998), y)
  83. CONFIG_QCACLD_FEATURE_METERING := y
  84. endif
  85. ifeq ($(CONFIG_ARCH_SDM660), y)
  86. CONFIG_QCACLD_FEATURE_METERING := y
  87. endif
  88. ifeq ($(CONFIG_ARCH_SDM630), y)
  89. CONFIG_QCACLD_FEATURE_METERING := y
  90. endif
  91. ifeq ($(CONFIG_ARCH_SDM845), y)
  92. CONFIG_QCACLD_FEATURE_METERING := y
  93. endif
  94. ifeq ($(CONFIG_ARCH_SDM670), y)
  95. CONFIG_QCACLD_FEATURE_METERING := y
  96. endif
  97. #Flag to enable Fast Transition (11r) feature
  98. CONFIG_QCOM_VOWIFI_11R := y
  99. #Flag to enable FILS Feature (11ai)
  100. CONFIG_WLAN_FEATURE_FILS := y
  101. ifneq ($(CONFIG_QCA_CLD_WLAN),)
  102. ifeq (y,$(findstring y,$(CONFIG_CNSS) $(CONFIG_CNSS2) $(CONFIG_ICNSS)))
  103. #Flag to enable Protected Managment Frames (11w) feature
  104. CONFIG_WLAN_FEATURE_11W := y
  105. #Flag to enable LTE CoEx feature
  106. CONFIG_QCOM_LTE_COEX := y
  107. ifneq ($(CONFIG_MOBILE_ROUTER), y)
  108. #Flag to enable LPSS feature
  109. CONFIG_WLAN_FEATURE_LPSS := y
  110. endif
  111. endif
  112. endif
  113. #Flag to enable Protected Managment Frames (11w) feature
  114. ifeq ($(CONFIG_ROME_IF),usb)
  115. CONFIG_WLAN_FEATURE_11W := y
  116. endif
  117. ifeq ($(CONFIG_ROME_IF),sdio)
  118. CONFIG_WLAN_FEATURE_11W := y
  119. endif
  120. #Flag to enable the tx desc sanity check
  121. ifeq ($(CONFIG_ROME_IF),usb)
  122. CONFIG_QCA_TXDESC_SANITY_CHECKS := y
  123. endif
  124. ifneq ($(CONFIG_MOBILE_ROUTER), y)
  125. #Flag to enable NAN
  126. CONFIG_QCACLD_FEATURE_NAN := y
  127. endif
  128. ifneq ($(CONFIG_MOBILE_ROUTER), y)
  129. #Flag to enable NAN Data path
  130. CONFIG_WLAN_FEATURE_NAN_DATAPATH := y
  131. CONFIG_NAN_CONVERGENCE := y
  132. endif
  133. #Flag to enable Linux QCMBR feature as default feature
  134. ifeq ($(CONFIG_ROME_IF),usb)
  135. CONFIG_LINUX_QCMBR :=y
  136. endif
  137. CONFIG_MPC_UT_FRAMEWORK := y
  138. CONFIG_FEATURE_EPPING := y
  139. #Flag to enable offload packets feature
  140. CONFIG_WLAN_OFFLOAD_PACKETS := y
  141. #enable TSF get feature
  142. CONFIG_WLAN_SYNC_TSF := y
  143. #Enable DSRC feature
  144. ifeq ($(CONFIG_QCA_WIFI_SDIO), 1)
  145. CONFIG_WLAN_FEATURE_DSRC := y
  146. endif
  147. ifneq ($(CONFIG_ROME_IF),usb)
  148. ifneq ($(CONFIG_ROME_IF),sdio)
  149. #Flag to enable DISA
  150. CONFIG_WLAN_FEATURE_DISA := y
  151. #Flag to enable FIPS
  152. CONFIG_WLAN_FEATURE_FIPS := y
  153. #Flag to enable SAE
  154. CONFIG_WLAN_FEATURE_SAE := y
  155. #Flag to enable Fast Path feature
  156. CONFIG_WLAN_FASTPATH := y
  157. # Flag to enable NAPI
  158. CONFIG_WLAN_NAPI := y
  159. CONFIG_WLAN_NAPI_DEBUG := n
  160. # Flag to enable FW based TX Flow control
  161. ifeq (y,$(findstring y,$(CONFIG_CNSS_EOS) $(CONFIG_LITHIUM)))
  162. CONFIG_WLAN_TX_FLOW_CONTROL_V2 := y
  163. else
  164. CONFIG_WLAN_TX_FLOW_CONTROL_V2 := n
  165. endif
  166. # Flag to enable LRO (Large Receive Offload)
  167. ifeq ($(CONFIG_INET_LRO), y)
  168. CONFIG_WLAN_LRO := y
  169. else
  170. CONFIG_WLAN_LRO := n
  171. endif
  172. endif
  173. endif
  174. ifeq ($(CONFIG_ROME_IF), snoc)
  175. CONFIG_WLAN_TX_FLOW_CONTROL_V2 := y
  176. endif
  177. # Flag to enable LFR Subnet Detection
  178. CONFIG_LFR_SUBNET_DETECTION := y
  179. # Flag to enable MCC to SCC switch feature
  180. CONFIG_MCC_TO_SCC_SWITCH := y
  181. ifeq ($(CONFIG_SLUB_DEBUG), y)
  182. # Enable Obj Mgr Degug services if slub build
  183. CONFIG_WLAN_OBJMGR_DEBUG:= y
  184. endif
  185. endif
  186. # As per target team, build is done as follows:
  187. # Defconfig : build with default flags
  188. # Slub : defconfig + CONFIG_SLUB_DEBUG=y +
  189. # CONFIG_SLUB_DEBUG_ON=y + CONFIG_PAGE_POISONING=y
  190. # Perf : Using appropriate msmXXXX-perf_defconfig
  191. #
  192. # Shipment builds (user variants) should not have any debug feature
  193. # enabled. This is identified using 'TARGET_BUILD_VARIANT'. Slub builds
  194. # are identified using the CONFIG_SLUB_DEBUG_ON configuration. Since
  195. # there is no other way to identify defconfig builds, QCOMs internal
  196. # representation of perf builds (identified using the string 'perf'),
  197. # is used to identify if the build is a slub or defconfig one. This
  198. # way no critical debug feature will be enabled for perf and shipment
  199. # builds. Other OEMs are also protected using the TARGET_BUILD_VARIANT
  200. # config.
  201. ifneq ($(TARGET_BUILD_VARIANT),user)
  202. ifeq ($(CONFIG_LITHIUM), y)
  203. CONFIG_FEATURE_PKTLOG := n
  204. else
  205. CONFIG_FEATURE_PKTLOG := y
  206. endif
  207. endif
  208. #Enable WLAN/Power debugfs feature only if debug_fs is enabled
  209. ifeq ($(CONFIG_DEBUG_FS), y)
  210. # Flag to enable debugfs. Depends on CONFIG_DEBUG_FS in kernel
  211. # configuration.
  212. CONFIG_WLAN_DEBUGFS := y
  213. CONFIG_WLAN_POWER_DEBUGFS := y
  214. endif
  215. # If not set, assume, Common driver is with in the build tree
  216. WLAN_COMMON_ROOT ?= ../qca-wifi-host-cmn
  217. WLAN_COMMON_INC ?= $(WLAN_ROOT)/$(WLAN_COMMON_ROOT)
  218. ifneq ($(CONFIG_MOBILE_ROUTER), y)
  219. CONFIG_QCOM_ESE := y
  220. endif
  221. # Feature flags which are not (currently) configurable via Kconfig
  222. #Whether to build debug version
  223. BUILD_DEBUG_VERSION := 1
  224. #Enable this flag to build driver in diag version
  225. BUILD_DIAG_VERSION := 1
  226. ifeq ($(CONFIG_SLUB_DEBUG), y)
  227. PANIC_ON_BUG := 1
  228. WLAN_WARN_ON_ASSERT := 1
  229. else ifeq ($(CONFIG_PERF_DEBUG), y)
  230. PANIC_ON_BUG := 1
  231. WLAN_WARN_ON_ASSERT := 1
  232. else
  233. PANIC_ON_BUG := 0
  234. WLAN_WARN_ON_ASSERT := 0
  235. endif
  236. # Compile all log levels by default
  237. CONFIG_WLAN_LOG_FATAL := y
  238. CONFIG_WLAN_LOG_ERROR := y
  239. CONFIG_WLAN_LOG_WARN := y
  240. CONFIG_WLAN_LOG_INFO := y
  241. CONFIG_WLAN_LOG_DEBUG := y
  242. #Enable OL debug and wmi unified functions
  243. CONFIG_ATH_PERF_PWR_OFFLOAD := 1
  244. #Disable packet log
  245. CONFIG_REMOVE_PKT_LOG := 0
  246. #Whether have QMI support
  247. CONFIG_QMI_SUPPORT := 1
  248. #Enable 11AC TX
  249. ifeq ($(CONFIG_ROME_IF),pci)
  250. CONFIG_ATH_11AC_TXCOMPACT := 1
  251. endif
  252. ifeq ($(CONFIG_ROME_IF),usb)
  253. CONFIG_ATH_11AC_TXCOMPACT := 0
  254. endif
  255. #Enable OS specific IRQ abstraction
  256. CONFIG_ATH_SUPPORT_SHARED_IRQ := 1
  257. #Enable message based HIF instead of RAW access in BMI
  258. ifeq ($(CONFIG_QCA_WIFI_SDIO), 1)
  259. CONFIG_HIF_MESSAGE_BASED := 0
  260. else
  261. CONFIG_HIF_MESSAGE_BASED := 1
  262. endif
  263. #Enable PCI specific APIS (dma, etc)
  264. ifeq ($(CONFIG_ROME_IF),pci)
  265. CONFIG_HIF_PCI := 1
  266. endif
  267. #Enable USB specific APIS
  268. ifeq ($(CONFIG_ROME_IF),usb)
  269. CONFIG_HIF_USB := 1
  270. CONFIG_PLD_USB_CNSS := y
  271. endif
  272. #Enable SDIO specific APIS
  273. ifeq ($(CONFIG_ROME_IF),sdio)
  274. CONFIG_HIF_SDIO := 1
  275. endif
  276. #Enable pci read/write config functions
  277. ifeq ($(CONFIG_ROME_IF),pci)
  278. CONFIG_ATH_PCI := 1
  279. endif
  280. ifeq ($(CONFIG_ROME_IF),snoc)
  281. CONFIG_HIF_SNOC:= 1
  282. endif
  283. ifneq ($(CONFIG_MOBILE_ROUTER), y)
  284. #Enable IBSS support on CLD
  285. CONFIG_QCA_IBSS_SUPPORT := 1
  286. endif
  287. #Enable power management suspend/resume functionality to PCI
  288. CONFIG_ATH_BUS_PM := 1
  289. #Enable FLOWMAC module support
  290. CONFIG_ATH_SUPPORT_FLOWMAC_MODULE := 0
  291. #Enable spectral support
  292. CONFIG_ATH_SUPPORT_SPECTRAL := 0
  293. #Enable HOST statistics support
  294. CONFIG_SUPPORT_HOST_STATISTICS := 0
  295. #Enable WDI Event support
  296. CONFIG_WDI_EVENT_ENABLE := 1
  297. #Endianess selection
  298. CONFIG_LITTLE_ENDIAN := 1
  299. #Enable TX reclaim support
  300. CONFIG_TX_CREDIT_RECLAIM_SUPPORT := 0
  301. #Enable FTM support
  302. CONFIG_QCA_WIFI_FTM := 1
  303. #Enable Checksum Offload
  304. CONFIG_CHECKSUM_OFFLOAD := 1
  305. #Enable GTK offload
  306. CONFIG_GTK_OFFLOAD := 1
  307. #Enable EXT WOW
  308. ifeq ($(CONFIG_ROME_IF),pci)
  309. CONFIG_EXT_WOW := 1
  310. endif
  311. #Set this to 1 to catch erroneous Target accesses during debug.
  312. CONFIG_ATH_PCIE_ACCESS_DEBUG := 0
  313. #Enable IPA offload
  314. ifeq ($(CONFIG_IPA), y)
  315. CONFIG_IPA_OFFLOAD := 1
  316. endif
  317. ifeq ($(CONFIG_IPA3), y)
  318. CONFIG_IPA_OFFLOAD := 1
  319. endif
  320. #Enable Signed firmware support for split binary format
  321. CONFIG_QCA_SIGNED_SPLIT_BINARY_SUPPORT := 0
  322. #Enable single firmware binary format
  323. CONFIG_QCA_SINGLE_BINARY_SUPPORT := 0
  324. #Enable collecting target RAM dump after kernel panic
  325. CONFIG_TARGET_RAMDUMP_AFTER_KERNEL_PANIC := 1
  326. #Flag to enable/disable secure firmware feature
  327. CONFIG_FEATURE_SECURE_FIRMWARE := 0
  328. #Flag to enable Stats Ext implementation
  329. CONFIG_FEATURE_STATS_EXT := 1
  330. #Flag to enable HTC credit history feature
  331. CONFIG_FEATURE_HTC_CREDIT_HISTORY := 1
  332. #Flag to enable MTRACE feature
  333. CONFIG_TRACE_RECORD_FEATURE := 1
  334. #Flag to enable p2p debug feature
  335. CONFIG_WLAN_FEATURE_P2P_DEBUG := 1
  336. #Flag to enable nud tracking feature
  337. CONFIG_WLAN_NUD_TRACKING := 1
  338. ifeq ($(CONFIG_CFG80211),y)
  339. HAVE_CFG80211 := 1
  340. else
  341. ifeq ($(CONFIG_CFG80211),m)
  342. HAVE_CFG80211 := 1
  343. else
  344. HAVE_CFG80211 := 0
  345. endif
  346. endif
  347. ifeq ($(CONFIG_SLUB_DEBUG_ON), y)
  348. CONFIG_FEATURE_UNIT_TEST_SUSPEND := 1
  349. CONFIG_LEAK_DETECTION := 1
  350. endif
  351. # enable unit-test suspend for napier builds
  352. ifeq ($(CONFIG_LITHIUM), y)
  353. CONFIG_FEATURE_UNIT_TEST_SUSPEND := 1
  354. endif
  355. ############ UAPI ############
  356. UAPI_DIR := uapi
  357. UAPI_INC := -I$(WLAN_ROOT)/$(UAPI_DIR)/linux
  358. ############ COMMON ############
  359. COMMON_DIR := core/common
  360. COMMON_INC := -I$(WLAN_ROOT)/$(COMMON_DIR)
  361. ############ HDD ############
  362. HDD_DIR := core/hdd
  363. HDD_INC_DIR := $(HDD_DIR)/inc
  364. HDD_SRC_DIR := $(HDD_DIR)/src
  365. HDD_INC := -I$(WLAN_ROOT)/$(HDD_INC_DIR) \
  366. -I$(WLAN_ROOT)/$(HDD_SRC_DIR)
  367. HDD_OBJS := $(HDD_SRC_DIR)/wlan_hdd_assoc.o \
  368. $(HDD_SRC_DIR)/wlan_hdd_cfg.o \
  369. $(HDD_SRC_DIR)/wlan_hdd_data_stall_detection.o \
  370. $(HDD_SRC_DIR)/wlan_hdd_driver_ops.o \
  371. $(HDD_SRC_DIR)/wlan_hdd_ftm.o \
  372. $(HDD_SRC_DIR)/wlan_hdd_hostapd.o \
  373. $(HDD_SRC_DIR)/wlan_hdd_ioctl.o \
  374. $(HDD_SRC_DIR)/wlan_hdd_main.o \
  375. $(HDD_SRC_DIR)/wlan_hdd_object_manager.o \
  376. $(HDD_SRC_DIR)/wlan_hdd_memdump.o \
  377. $(HDD_SRC_DIR)/wlan_hdd_oemdata.o \
  378. $(HDD_SRC_DIR)/wlan_hdd_packet_filter.o \
  379. $(HDD_SRC_DIR)/wlan_hdd_power.o \
  380. $(HDD_SRC_DIR)/wlan_hdd_regulatory.o \
  381. $(HDD_SRC_DIR)/wlan_hdd_request_manager.o \
  382. $(HDD_SRC_DIR)/wlan_hdd_scan.o \
  383. $(HDD_SRC_DIR)/wlan_hdd_spectralscan.o \
  384. $(HDD_SRC_DIR)/wlan_hdd_softap_tx_rx.o \
  385. $(HDD_SRC_DIR)/wlan_hdd_sysfs.o \
  386. $(HDD_SRC_DIR)/wlan_hdd_tx_rx.o \
  387. $(HDD_SRC_DIR)/wlan_hdd_trace.o \
  388. $(HDD_SRC_DIR)/wlan_hdd_wext.o \
  389. $(HDD_SRC_DIR)/wlan_hdd_wmm.o \
  390. $(HDD_SRC_DIR)/wlan_hdd_wowl.o
  391. ifeq ($(CONFIG_WLAN_DEBUGFS), y)
  392. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_debugfs.o
  393. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_debugfs_llstat.o
  394. endif
  395. ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
  396. HDD_OBJS+= $(HDD_SRC_DIR)/wlan_hdd_ocb.o
  397. endif
  398. ifeq ($(CONFIG_WLAN_FEATURE_FIPS), y)
  399. HDD_OBJS+= $(HDD_SRC_DIR)/wlan_hdd_fips.o
  400. endif
  401. ifeq ($(CONFIG_WLAN_FEATURE_LPSS),y)
  402. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_lpass.o
  403. endif
  404. ifeq ($(CONFIG_WLAN_LRO), y)
  405. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_lro.o
  406. endif
  407. ifeq ($(CONFIG_WLAN_NAPI), y)
  408. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_napi.o
  409. endif
  410. ifeq ($(CONFIG_IPA_OFFLOAD), 1)
  411. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_ipa.o
  412. endif
  413. ifeq ($(HAVE_CFG80211),1)
  414. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_cfg80211.o \
  415. $(HDD_SRC_DIR)/wlan_hdd_ext_scan.o \
  416. $(HDD_SRC_DIR)/wlan_hdd_stats.o \
  417. $(HDD_SRC_DIR)/wlan_hdd_p2p.o
  418. endif
  419. ifeq ($(CONFIG_QCACLD_FEATURE_NAN),y)
  420. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_nan.o
  421. endif
  422. ifeq ($(CONFIG_QCOM_TDLS),y)
  423. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_tdls.o
  424. endif
  425. ifeq ($(CONFIG_WLAN_SYNC_TSF_PLUS), y)
  426. CONFIG_WLAN_SYNC_TSF := y
  427. endif
  428. ifeq ($(CONFIG_WLAN_SYNC_TSF),y)
  429. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_tsf.o
  430. endif
  431. ifeq ($(CONFIG_MPC_UT_FRAMEWORK),y)
  432. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_conc_ut.o
  433. endif
  434. ifeq ($(CONFIG_WLAN_FEATURE_DISA), y)
  435. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_disa.o
  436. endif
  437. ifeq ($(CONFIG_LFR_SUBNET_DETECTION), y)
  438. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_subnet_detect.o
  439. endif
  440. ifeq ($(CONFIG_WLAN_FEATURE_NAN_DATAPATH), y)
  441. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_nan_datapath.o
  442. endif
  443. ifeq ($(CONFIG_WLAN_FEATURE_11AX),y)
  444. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_he.o
  445. endif
  446. ifeq ($(CONFIG_LITHIUM), y)
  447. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_rx_monitor.o
  448. endif
  449. ifeq ($(CONFIG_WLAN_NUD_TRACKING), 1)
  450. HDD_OBJS += $(HDD_SRC_DIR)/wlan_hdd_nud_tracking.o
  451. endif
  452. ########### HOST DIAG LOG ###########
  453. HOST_DIAG_LOG_DIR := $(WLAN_COMMON_ROOT)/utils/host_diag_log
  454. HOST_DIAG_LOG_INC_DIR := $(HOST_DIAG_LOG_DIR)/inc
  455. HOST_DIAG_LOG_SRC_DIR := $(HOST_DIAG_LOG_DIR)/src
  456. HOST_DIAG_LOG_INC := -I$(WLAN_ROOT)/$(HOST_DIAG_LOG_INC_DIR) \
  457. -I$(WLAN_ROOT)/$(HOST_DIAG_LOG_SRC_DIR)
  458. HOST_DIAG_LOG_OBJS += $(HOST_DIAG_LOG_SRC_DIR)/host_diag_log.o
  459. ############ EPPING ############
  460. EPPING_DIR := $(WLAN_COMMON_ROOT)/utils/epping
  461. EPPING_INC_DIR := $(EPPING_DIR)/inc
  462. EPPING_SRC_DIR := $(EPPING_DIR)/src
  463. EPPING_INC := -I$(WLAN_ROOT)/$(EPPING_INC_DIR)
  464. EPPING_OBJS := $(EPPING_SRC_DIR)/epping_main.o \
  465. $(EPPING_SRC_DIR)/epping_txrx.o \
  466. $(EPPING_SRC_DIR)/epping_tx.o \
  467. $(EPPING_SRC_DIR)/epping_rx.o \
  468. $(EPPING_SRC_DIR)/epping_helper.o \
  469. ############ MAC ############
  470. MAC_DIR := core/mac
  471. MAC_INC_DIR := $(MAC_DIR)/inc
  472. MAC_SRC_DIR := $(MAC_DIR)/src
  473. MAC_INC := -I$(WLAN_ROOT)/$(MAC_INC_DIR) \
  474. -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/dph \
  475. -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/include \
  476. -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/pe/include \
  477. -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/pe/lim \
  478. -I$(WLAN_ROOT)/$(MAC_SRC_DIR)/pe/nan
  479. MAC_CFG_OBJS := $(MAC_SRC_DIR)/cfg/cfg_api.o \
  480. $(MAC_SRC_DIR)/cfg/cfg_param_name.o \
  481. $(MAC_SRC_DIR)/cfg/cfg_proc_msg.o \
  482. $(MAC_SRC_DIR)/cfg/cfg_send_msg.o
  483. MAC_DPH_OBJS := $(MAC_SRC_DIR)/dph/dph_hash_table.o
  484. MAC_LIM_OBJS := $(MAC_SRC_DIR)/pe/lim/lim_aid_mgmt.o \
  485. $(MAC_SRC_DIR)/pe/lim/lim_admit_control.o \
  486. $(MAC_SRC_DIR)/pe/lim/lim_api.o \
  487. $(MAC_SRC_DIR)/pe/lim/lim_assoc_utils.o \
  488. $(MAC_SRC_DIR)/pe/lim/lim_ft.o \
  489. $(MAC_SRC_DIR)/pe/lim/lim_ibss_peer_mgmt.o \
  490. $(MAC_SRC_DIR)/pe/lim/lim_link_monitoring_algo.o \
  491. $(MAC_SRC_DIR)/pe/lim/lim_process_action_frame.o \
  492. $(MAC_SRC_DIR)/pe/lim/lim_process_assoc_req_frame.o \
  493. $(MAC_SRC_DIR)/pe/lim/lim_process_assoc_rsp_frame.o \
  494. $(MAC_SRC_DIR)/pe/lim/lim_process_auth_frame.o \
  495. $(MAC_SRC_DIR)/pe/lim/lim_process_beacon_frame.o \
  496. $(MAC_SRC_DIR)/pe/lim/lim_process_cfg_updates.o \
  497. $(MAC_SRC_DIR)/pe/lim/lim_process_deauth_frame.o \
  498. $(MAC_SRC_DIR)/pe/lim/lim_process_disassoc_frame.o \
  499. $(MAC_SRC_DIR)/pe/lim/lim_process_message_queue.o \
  500. $(MAC_SRC_DIR)/pe/lim/lim_process_mlm_req_messages.o \
  501. $(MAC_SRC_DIR)/pe/lim/lim_process_mlm_rsp_messages.o \
  502. $(MAC_SRC_DIR)/pe/lim/lim_process_probe_req_frame.o \
  503. $(MAC_SRC_DIR)/pe/lim/lim_process_probe_rsp_frame.o \
  504. $(MAC_SRC_DIR)/pe/lim/lim_process_sme_req_messages.o \
  505. $(MAC_SRC_DIR)/pe/lim/lim_prop_exts_utils.o \
  506. $(MAC_SRC_DIR)/pe/lim/lim_scan_result_utils.o \
  507. $(MAC_SRC_DIR)/pe/lim/lim_security_utils.o \
  508. $(MAC_SRC_DIR)/pe/lim/lim_send_management_frames.o \
  509. $(MAC_SRC_DIR)/pe/lim/lim_send_messages.o \
  510. $(MAC_SRC_DIR)/pe/lim/lim_send_sme_rsp_messages.o \
  511. $(MAC_SRC_DIR)/pe/lim/lim_ser_des_utils.o \
  512. $(MAC_SRC_DIR)/pe/lim/lim_session.o \
  513. $(MAC_SRC_DIR)/pe/lim/lim_session_utils.o \
  514. $(MAC_SRC_DIR)/pe/lim/lim_sme_req_utils.o \
  515. $(MAC_SRC_DIR)/pe/lim/lim_sta_hash_api.o \
  516. $(MAC_SRC_DIR)/pe/lim/lim_timer_utils.o \
  517. $(MAC_SRC_DIR)/pe/lim/lim_trace.o \
  518. $(MAC_SRC_DIR)/pe/lim/lim_utils.o
  519. ifeq ($(CONFIG_QCOM_TDLS),y)
  520. MAC_LIM_OBJS += $(MAC_SRC_DIR)/pe/lim/lim_process_tdls.o
  521. endif
  522. ifeq ($(CONFIG_WLAN_FEATURE_FILS),y)
  523. MAC_LIM_OBJS += $(MAC_SRC_DIR)/pe/lim/lim_process_fils.o
  524. endif
  525. ifeq ($(CONFIG_WLAN_FEATURE_NAN_DATAPATH), y)
  526. MAC_NDP_OBJS += $(MAC_SRC_DIR)/pe/nan/nan_datapath.o
  527. endif
  528. ifeq ($(CONFIG_QCACLD_WLAN_LFR2),y)
  529. MAC_LIM_OBJS += $(MAC_SRC_DIR)/pe/lim/lim_process_mlm_host_roam.o \
  530. $(MAC_SRC_DIR)/pe/lim/lim_send_frames_host_roam.o \
  531. $(MAC_SRC_DIR)/pe/lim/lim_roam_timer_utils.o \
  532. $(MAC_SRC_DIR)/pe/lim/lim_ft_preauth.o \
  533. $(MAC_SRC_DIR)/pe/lim/lim_reassoc_utils.o
  534. endif
  535. MAC_SCH_OBJS := $(MAC_SRC_DIR)/pe/sch/sch_api.o \
  536. $(MAC_SRC_DIR)/pe/sch/sch_beacon_gen.o \
  537. $(MAC_SRC_DIR)/pe/sch/sch_beacon_process.o \
  538. $(MAC_SRC_DIR)/pe/sch/sch_message.o
  539. MAC_RRM_OBJS := $(MAC_SRC_DIR)/pe/rrm/rrm_api.o
  540. MAC_OBJS := $(MAC_CFG_OBJS) \
  541. $(MAC_DPH_OBJS) \
  542. $(MAC_LIM_OBJS) \
  543. $(MAC_SCH_OBJS) \
  544. $(MAC_RRM_OBJS) \
  545. $(MAC_NDP_OBJS)
  546. ############ SAP ############
  547. SAP_DIR := core/sap
  548. SAP_INC_DIR := $(SAP_DIR)/inc
  549. SAP_SRC_DIR := $(SAP_DIR)/src
  550. SAP_INC := -I$(WLAN_ROOT)/$(SAP_INC_DIR) \
  551. -I$(WLAN_ROOT)/$(SAP_SRC_DIR)
  552. SAP_OBJS := $(SAP_SRC_DIR)/sap_api_link_cntl.o \
  553. $(SAP_SRC_DIR)/sap_ch_select.o \
  554. $(SAP_SRC_DIR)/sap_fsm.o \
  555. $(SAP_SRC_DIR)/sap_module.o
  556. ############ DFS ############ 350
  557. DFS_DIR := $(WLAN_COMMON_ROOT)/umac/dfs
  558. DFS_CORE_INC_DIR := $(DFS_DIR)/core/inc
  559. DFS_CORE_SRC_DIR := $(DFS_DIR)/core/src
  560. DFS_DISP_INC_DIR := $(DFS_DIR)/dispatcher/inc
  561. DFS_DISP_SRC_DIR := $(DFS_DIR)/dispatcher/src
  562. DFS_TARGET_INC_DIR := $(WLAN_COMMON_ROOT)/target_if/dfs/inc
  563. DFS_CMN_SERVICES_INC_DIR := $(WLAN_COMMON_ROOT)/umac/cmn_services/dfs/inc
  564. DFS_INC := -I$(WLAN_ROOT)/$(DFS_DISP_INC_DIR) \
  565. -I$(WLAN_ROOT)/$(DFS_TARGET_INC_DIR) \
  566. -I$(WLAN_ROOT)/$(DFS_CMN_SERVICES_INC_DIR)
  567. DFS_OBJS := $(DFS_CORE_SRC_DIR)/misc/dfs.o \
  568. $(DFS_CORE_SRC_DIR)/misc/dfs_cac.o \
  569. $(DFS_CORE_SRC_DIR)/misc/dfs_nol.o \
  570. $(DFS_CORE_SRC_DIR)/misc/dfs_random_chan_sel.o \
  571. $(DFS_CORE_SRC_DIR)/misc/dfs_process_radar_found_ind.o \
  572. $(DFS_DISP_SRC_DIR)/wlan_dfs_init_deinit_api.o \
  573. $(DFS_DISP_SRC_DIR)/wlan_dfs_lmac_api.o \
  574. $(DFS_DISP_SRC_DIR)/wlan_dfs_mlme_api.o \
  575. $(DFS_DISP_SRC_DIR)/wlan_dfs_tgt_api.o \
  576. $(DFS_DISP_SRC_DIR)/wlan_dfs_ucfg_api.o \
  577. $(DFS_DISP_SRC_DIR)/wlan_dfs_tgt_api.o \
  578. $(DFS_DISP_SRC_DIR)/wlan_dfs_utils_api.o \
  579. $(WLAN_COMMON_ROOT)/target_if/dfs/src/target_if_dfs.o
  580. ifeq ($(CONFIG_WLAN_FEATURE_DFS_OFFLOAD),y)
  581. DFS_OBJS += $(WLAN_COMMON_ROOT)/target_if/dfs/src/target_if_dfs_full_offload.o \
  582. $(DFS_CORE_SRC_DIR)/misc/dfs_full_offload.o
  583. else
  584. DFS_OBJS += $(WLAN_COMMON_ROOT)/target_if/dfs/src/target_if_dfs_partial_offload.o \
  585. $(DFS_CORE_SRC_DIR)/filtering/dfs_fcc_bin5.o \
  586. $(DFS_CORE_SRC_DIR)/filtering/dfs_bindetects.o \
  587. $(DFS_CORE_SRC_DIR)/filtering/dfs_debug.o \
  588. $(DFS_CORE_SRC_DIR)/filtering/dfs_init.o \
  589. $(DFS_CORE_SRC_DIR)/filtering/dfs_misc.o \
  590. $(DFS_CORE_SRC_DIR)/filtering/dfs_phyerr_tlv.o \
  591. $(DFS_CORE_SRC_DIR)/filtering/dfs_process_phyerr.o \
  592. $(DFS_CORE_SRC_DIR)/filtering/dfs_process_radarevent.o \
  593. $(DFS_CORE_SRC_DIR)/filtering/dfs_staggered.o \
  594. $(DFS_CORE_SRC_DIR)/filtering/dfs_radar.o \
  595. $(DFS_CORE_SRC_DIR)/filtering/dfs_ar.o \
  596. $(DFS_CORE_SRC_DIR)/filtering/dfs_partial_offload_radar.o \
  597. $(DFS_CORE_SRC_DIR)/misc/dfs_filter_init.o \
  598. $(DFS_CORE_SRC_DIR)/misc/dfs_zero_cac.o
  599. endif
  600. ############ SME ############
  601. SME_DIR := core/sme
  602. SME_INC_DIR := $(SME_DIR)/inc
  603. SME_SRC_DIR := $(SME_DIR)/src
  604. SME_INC := -I$(WLAN_ROOT)/$(SME_INC_DIR) \
  605. -I$(WLAN_ROOT)/$(SME_SRC_DIR)/csr
  606. SME_CSR_OBJS := $(SME_SRC_DIR)/csr/csr_api_roam.o \
  607. $(SME_SRC_DIR)/csr/csr_api_scan.o \
  608. $(SME_SRC_DIR)/csr/csr_cmd_process.o \
  609. $(SME_SRC_DIR)/csr/csr_link_list.o \
  610. $(SME_SRC_DIR)/csr/csr_neighbor_roam.o \
  611. $(SME_SRC_DIR)/csr/csr_util.o \
  612. ifeq ($(CONFIG_QCACLD_WLAN_LFR2),y)
  613. SME_CSR_OBJS += $(SME_SRC_DIR)/csr/csr_roam_preauth.o \
  614. $(SME_SRC_DIR)/csr/csr_host_scan_roam.o
  615. endif
  616. SME_QOS_OBJS := $(SME_SRC_DIR)/qos/sme_qos.o
  617. SME_CMN_OBJS := $(SME_SRC_DIR)/common/sme_api.o \
  618. $(SME_SRC_DIR)/common/sme_ft_api.o \
  619. $(SME_SRC_DIR)/common/sme_power_save.o \
  620. $(SME_SRC_DIR)/common/sme_trace.o
  621. SME_RRM_OBJS := $(SME_SRC_DIR)/rrm/sme_rrm.o
  622. ifeq ($(CONFIG_QCACLD_FEATURE_NAN),y)
  623. SME_NAN_OBJS = $(SME_SRC_DIR)/nan/nan_api.o
  624. endif
  625. ifeq ($(CONFIG_WLAN_FEATURE_NAN_DATAPATH), y)
  626. SME_NDP_OBJS += $(SME_SRC_DIR)/nan/nan_datapath_api.o
  627. endif
  628. SME_OBJS := $(SME_CMN_OBJS) \
  629. $(SME_CSR_OBJS) \
  630. $(SME_QOS_OBJS) \
  631. $(SME_RRM_OBJS) \
  632. $(SME_NAN_OBJS) \
  633. $(SME_NDP_OBJS)
  634. ############ NLINK ############
  635. NLINK_DIR := $(WLAN_COMMON_ROOT)/utils/nlink
  636. NLINK_INC_DIR := $(NLINK_DIR)/inc
  637. NLINK_SRC_DIR := $(NLINK_DIR)/src
  638. NLINK_INC := -I$(WLAN_ROOT)/$(NLINK_INC_DIR)
  639. NLINK_OBJS := $(NLINK_SRC_DIR)/wlan_nlink_srv.o
  640. ############ PTT ############
  641. PTT_DIR := $(WLAN_COMMON_ROOT)/utils/ptt
  642. PTT_INC_DIR := $(PTT_DIR)/inc
  643. PTT_SRC_DIR := $(PTT_DIR)/src
  644. PTT_INC := -I$(WLAN_ROOT)/$(PTT_INC_DIR)
  645. PTT_OBJS := $(PTT_SRC_DIR)/wlan_ptt_sock_svc.o
  646. ############ WLAN_LOGGING ############
  647. WLAN_LOGGING_DIR := $(WLAN_COMMON_ROOT)/utils/logging
  648. WLAN_LOGGING_INC_DIR := $(WLAN_LOGGING_DIR)/inc
  649. WLAN_LOGGING_SRC_DIR := $(WLAN_LOGGING_DIR)/src
  650. WLAN_LOGGING_INC := -I$(WLAN_ROOT)/$(WLAN_LOGGING_INC_DIR)
  651. WLAN_LOGGING_OBJS := $(WLAN_LOGGING_SRC_DIR)/wlan_logging_sock_svc.o \
  652. $(WLAN_LOGGING_SRC_DIR)/wlan_roam_debug.o
  653. ############ SYS ############
  654. SYS_DIR := core/mac/src/sys
  655. SYS_INC := -I$(WLAN_ROOT)/$(SYS_DIR)/common/inc \
  656. -I$(WLAN_ROOT)/$(SYS_DIR)/legacy/src/platform/inc \
  657. -I$(WLAN_ROOT)/$(SYS_DIR)/legacy/src/system/inc \
  658. -I$(WLAN_ROOT)/$(SYS_DIR)/legacy/src/utils/inc
  659. SYS_COMMON_SRC_DIR := $(SYS_DIR)/common/src
  660. SYS_LEGACY_SRC_DIR := $(SYS_DIR)/legacy/src
  661. SYS_OBJS := $(SYS_COMMON_SRC_DIR)/wlan_qct_sys.o \
  662. $(SYS_LEGACY_SRC_DIR)/platform/src/sys_wrapper.o \
  663. $(SYS_LEGACY_SRC_DIR)/system/src/mac_init_api.o \
  664. $(SYS_LEGACY_SRC_DIR)/system/src/sys_entry_func.o \
  665. $(SYS_LEGACY_SRC_DIR)/utils/src/dot11f.o \
  666. $(SYS_LEGACY_SRC_DIR)/utils/src/mac_trace.o \
  667. $(SYS_LEGACY_SRC_DIR)/utils/src/parser_api.o \
  668. $(SYS_LEGACY_SRC_DIR)/utils/src/utils_parser.o
  669. ############ Qca-wifi-host-cmn ############
  670. QDF_OS_DIR := qdf
  671. QDF_OS_INC_DIR := $(QDF_OS_DIR)/inc
  672. QDF_OS_SRC_DIR := $(QDF_OS_DIR)/src
  673. QDF_OS_LINUX_SRC_DIR := $(QDF_OS_DIR)/linux/src
  674. QDF_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(QDF_OS_SRC_DIR)
  675. QDF_LINUX_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(QDF_OS_LINUX_SRC_DIR)
  676. QDF_INC := -I$(WLAN_COMMON_INC)/$(QDF_OS_INC_DIR) \
  677. -I$(WLAN_COMMON_INC)/$(QDF_OS_LINUX_SRC_DIR)
  678. QDF_OBJS := $(QDF_LINUX_OBJ_DIR)/qdf_defer.o \
  679. $(QDF_LINUX_OBJ_DIR)/qdf_event.o \
  680. $(QDF_LINUX_OBJ_DIR)/qdf_file.o \
  681. $(QDF_LINUX_OBJ_DIR)/qdf_list.o \
  682. $(QDF_LINUX_OBJ_DIR)/qdf_lock.o \
  683. $(QDF_LINUX_OBJ_DIR)/qdf_mc_timer.o \
  684. $(QDF_LINUX_OBJ_DIR)/qdf_mem.o \
  685. $(QDF_LINUX_OBJ_DIR)/qdf_nbuf.o \
  686. $(QDF_LINUX_OBJ_DIR)/qdf_threads.o \
  687. $(QDF_LINUX_OBJ_DIR)/qdf_crypto.o \
  688. $(QDF_LINUX_OBJ_DIR)/qdf_trace.o \
  689. $(QDF_OBJ_DIR)/qdf_parse.o \
  690. $(QDF_OBJ_DIR)/qdf_platform.o \
  691. $(QDF_OBJ_DIR)/qdf_str.o \
  692. $(QDF_OBJ_DIR)/qdf_types.o \
  693. ifeq ($(CONFIG_WLAN_DEBUGFS), y)
  694. QDF_OBJS += $(QDF_LINUX_OBJ_DIR)/qdf_debugfs.o
  695. endif
  696. ifeq ($(CONFIG_IPA_OFFLOAD), 1)
  697. QDF_OBJS += $(QDF_LINUX_OBJ_DIR)/qdf_ipa.o
  698. endif
  699. # enable CPU hotplug support if SMP is enabled
  700. ifeq ($(CONFIG_SMP),y)
  701. QDF_OBJS += $(QDF_OBJ_DIR)/qdf_cpuhp.o
  702. QDF_OBJS += $(QDF_LINUX_OBJ_DIR)/qdf_cpuhp.o
  703. endif
  704. ifdef CONFIG_LEAK_DETECTION
  705. QDF_OBJS += $(QDF_OBJ_DIR)/qdf_debug_domain.o
  706. endif
  707. ##########OS_IF #######
  708. OS_IF_DIR := $(WLAN_COMMON_ROOT)/os_if
  709. OS_IF_INC := -I$(WLAN_COMMON_INC)/os_if/linux \
  710. -I$(WLAN_COMMON_INC)/os_if/linux/scan/inc \
  711. -I$(WLAN_COMMON_INC)/os_if/linux/p2p/inc \
  712. -I$(WLAN_COMMON_INC)/os_if/linux/spectral/inc \
  713. -I$(WLAN_COMMON_INC)/os_if/linux/tdls/inc
  714. OS_IF_OBJ := $(OS_IF_DIR)/linux/p2p/src/wlan_cfg80211_p2p.o
  715. ############ UMAC_DISP ############
  716. UMAC_DISP_DIR := umac/global_umac_dispatcher/lmac_if
  717. UMAC_DISP_INC_DIR := $(UMAC_DISP_DIR)/inc
  718. UMAC_DISP_SRC_DIR := $(UMAC_DISP_DIR)/src
  719. UMAC_DISP_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_DISP_SRC_DIR)
  720. UMAC_DISP_INC := -I$(WLAN_COMMON_INC)/$(UMAC_DISP_INC_DIR)
  721. UMAC_DISP_OBJS := $(UMAC_DISP_OBJ_DIR)/wlan_lmac_if.o
  722. ############# UMAC_SCAN ############
  723. UMAC_SCAN_DIR := umac/scan
  724. UMAC_SCAN_DISP_INC_DIR := $(UMAC_SCAN_DIR)/dispatcher/inc
  725. UMAC_SCAN_CORE_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_SCAN_DIR)/core/src
  726. UMAC_SCAN_DISP_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_SCAN_DIR)/dispatcher/src
  727. UMAC_TARGET_SCAN_INC := -I$(WLAN_COMMON_INC)/target_if/scan/inc
  728. UMAC_SCAN_INC := -I$(WLAN_COMMON_INC)/$(UMAC_SCAN_DISP_INC_DIR)
  729. UMAC_SCAN_OBJS := $(UMAC_SCAN_CORE_DIR)/wlan_scan_cache_db.o \
  730. $(UMAC_SCAN_CORE_DIR)/wlan_scan_11d.o \
  731. $(UMAC_SCAN_CORE_DIR)/wlan_scan_bss_score.o \
  732. $(UMAC_SCAN_CORE_DIR)/wlan_scan_filter.o \
  733. $(UMAC_SCAN_CORE_DIR)/wlan_scan_main.o \
  734. $(UMAC_SCAN_CORE_DIR)/wlan_scan_manager.o \
  735. $(UMAC_SCAN_DISP_DIR)/wlan_scan_tgt_api.o \
  736. $(UMAC_SCAN_DISP_DIR)/wlan_scan_ucfg_api.o \
  737. $(UMAC_SCAN_DISP_DIR)/wlan_scan_utils_api.o \
  738. $(WLAN_COMMON_ROOT)/os_if/linux/scan/src/wlan_cfg80211_scan.o \
  739. $(WLAN_COMMON_ROOT)/os_if/linux/wlan_cfg80211.o \
  740. $(WLAN_COMMON_ROOT)/target_if/scan/src/target_if_scan.o
  741. ############# UMAC_SPECTRAL_SCAN ############
  742. UMAC_SPECTRAL_DIR := spectral
  743. UMAC_SPECTRAL_DISP_INC_DIR := $(UMAC_SPECTRAL_DIR)/dispatcher/inc
  744. UMAC_SPECTRAL_CORE_INC_DIR := $(UMAC_SPECTRAL_DIR)/core
  745. UMAC_SPECTRAL_CORE_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_SPECTRAL_DIR)/core
  746. UMAC_SPECTRAL_DISP_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_SPECTRAL_DIR)/dispatcher/src
  747. UMAC_TARGET_SPECTRAL_INC := -I$(WLAN_COMMON_INC)/target_if/spectral
  748. UMAC_SPECTRAL_INC := -I$(WLAN_COMMON_INC)/$(UMAC_SPECTRAL_DISP_INC_DIR) \
  749. -I$(WLAN_COMMON_INC)/$(UMAC_SPECTRAL_CORE_INC_DIR) \
  750. -I$(WLAN_COMMON_INC)/target_if/direct_buf_rx/inc
  751. UMAC_SPECTRAL_OBJS := $(UMAC_SPECTRAL_CORE_DIR)/spectral_offload.o \
  752. $(UMAC_SPECTRAL_CORE_DIR)/spectral_common.o \
  753. $(UMAC_SPECTRAL_DISP_DIR)/wlan_spectral_ucfg_api.o \
  754. $(UMAC_SPECTRAL_DISP_DIR)/wlan_spectral_utils_api.o \
  755. $(UMAC_SPECTRAL_DISP_DIR)/wlan_spectral_tgt_api.o \
  756. $(WLAN_COMMON_ROOT)/os_if/linux/spectral/src/wlan_cfg80211_spectral.o \
  757. $(WLAN_COMMON_ROOT)/os_if/linux/spectral/src/os_if_spectral_netlink.o \
  758. $(WLAN_COMMON_ROOT)/target_if/spectral/target_if_spectral_netlink.o \
  759. $(WLAN_COMMON_ROOT)/target_if/spectral/target_if_spectral_phyerr.o \
  760. $(WLAN_COMMON_ROOT)/target_if/spectral/target_if_spectral.o \
  761. $(WLAN_COMMON_ROOT)/target_if/spectral/target_if_spectral_sim.o
  762. ############# UMAC_GREEN_AP ############
  763. UMAC_GREEN_AP_DIR := umac/green_ap
  764. UMAC_GREEN_AP_DISP_INC_DIR := $(UMAC_GREEN_AP_DIR)/dispatcher/inc
  765. UMAC_GREEN_AP_CORE_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_GREEN_AP_DIR)/core/src
  766. UMAC_GREEN_AP_DISP_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_GREEN_AP_DIR)/dispatcher/src
  767. UMAC_TARGET_GREEN_AP_INC := -I$(WLAN_COMMON_INC)/target_if/green_ap/inc
  768. UMAC_GREEN_AP_INC := -I$(WLAN_COMMON_INC)/$(UMAC_GREEN_AP_DISP_INC_DIR)
  769. UMAC_GREEN_AP_OBJS := $(UMAC_GREEN_AP_CORE_DIR)/wlan_green_ap_main.o \
  770. $(UMAC_GREEN_AP_DISP_DIR)/wlan_green_ap_api.o \
  771. $(UMAC_GREEN_AP_DISP_DIR)/wlan_green_ap_ucfg_api.o \
  772. $(WLAN_COMMON_ROOT)/target_if/green_ap/src/target_if_green_ap.o
  773. ############# FTM CORE ############
  774. FTM_CORE_DIR := ftm
  775. TARGET_IF_FTM_DIR := target_if/ftm
  776. OS_IF_LINUX_FTM_DIR := os_if/linux/ftm
  777. FTM_CORE_SRC := $(WLAN_COMMON_ROOT)/$(FTM_CORE_DIR)/core/src
  778. FTM_DISP_SRC := $(WLAN_COMMON_ROOT)/$(FTM_CORE_DIR)/dispatcher/src
  779. TARGET_IF_FTM_SRC := $(WLAN_COMMON_ROOT)/$(TARGET_IF_FTM_DIR)/src
  780. OS_IF_FTM_SRC := $(WLAN_COMMON_ROOT)/$(OS_IF_LINUX_FTM_DIR)/src
  781. FTM_CORE_INC := $(WLAN_COMMON_INC)/$(FTM_CORE_DIR)/core/src
  782. FTM_DISP_INC := $(WLAN_COMMON_INC)/$(FTM_CORE_DIR)/dispatcher/inc
  783. TARGET_IF_FTM_INC := $(WLAN_COMMON_INC)/$(TARGET_IF_FTM_DIR)/inc
  784. OS_IF_FTM_INC := $(WLAN_COMMON_INC)/$(OS_IF_LINUX_FTM_DIR)/inc
  785. FTM_INC := -I$(FTM_DISP_INC) \
  786. -I$(FTM_CORE_INC) \
  787. -I$(OS_IF_FTM_INC) \
  788. -I$(TARGET_IF_FTM_INC)
  789. FTM_OBJS := $(FTM_DISP_SRC)/wlan_ftm_init_deinit.o \
  790. $(FTM_DISP_SRC)/wlan_ftm_ucfg_api.o \
  791. $(FTM_CORE_SRC)/wlan_ftm_svc.o \
  792. $(OS_IF_FTM_SRC)/wlan_cfg80211_ftm.o \
  793. $(TARGET_IF_FTM_SRC)/target_if_ftm.o
  794. ifeq ($(CONFIG_LINUX_QCMBR),y)
  795. FTM_OBJS += $(OS_IF_FTM_SRC)/wlan_ioctl_ftm.o
  796. endif
  797. ############# UMAC_CMN_SERVICES ############
  798. UMAC_COMMON_INC := -I$(WLAN_COMMON_INC)/umac/cmn_services/cmn_defs/inc \
  799. -I$(WLAN_COMMON_INC)/umac/cmn_services/utils/inc
  800. UMAC_COMMON_OBJS := $(WLAN_COMMON_ROOT)/umac/cmn_services/utils/src/wlan_utility.o
  801. ifeq ($(CONFIG_WLAN_LRO), y)
  802. QDF_OBJS += $(QDF_LINUX_OBJ_DIR)/qdf_lro.o
  803. endif
  804. ############ CDS (Connectivity driver services) ############
  805. CDS_DIR := core/cds
  806. CDS_INC_DIR := $(CDS_DIR)/inc
  807. CDS_SRC_DIR := $(CDS_DIR)/src
  808. CDS_INC := -I$(WLAN_ROOT)/$(CDS_INC_DIR) \
  809. -I$(WLAN_ROOT)/$(CDS_SRC_DIR)
  810. CDS_OBJS := $(CDS_SRC_DIR)/cds_api.o \
  811. $(CDS_SRC_DIR)/cds_reg_service.o \
  812. $(CDS_SRC_DIR)/cds_packet.o \
  813. $(CDS_SRC_DIR)/cds_regdomain.o \
  814. $(CDS_SRC_DIR)/cds_sched.o \
  815. $(CDS_SRC_DIR)/cds_utils.o
  816. ###### UMAC OBJMGR ########
  817. UMAC_OBJMGR_DIR := $(WLAN_COMMON_ROOT)/umac/cmn_services/obj_mgr
  818. UMAC_OBJMGR_INC := -I$(WLAN_COMMON_INC)/umac/cmn_services/obj_mgr/inc \
  819. -I$(WLAN_COMMON_INC)/umac/cmn_services/obj_mgr/src \
  820. -I$(WLAN_COMMON_INC)/umac/cmn_services/inc \
  821. -I$(WLAN_COMMON_INC)/umac/global_umac_dispatcher/lmac_if/inc
  822. UMAC_OBJMGR_OBJS := $(UMAC_OBJMGR_DIR)/src/wlan_objmgr_global_obj.o \
  823. $(UMAC_OBJMGR_DIR)/src/wlan_objmgr_pdev_obj.o \
  824. $(UMAC_OBJMGR_DIR)/src/wlan_objmgr_peer_obj.o \
  825. $(UMAC_OBJMGR_DIR)/src/wlan_objmgr_psoc_obj.o \
  826. $(UMAC_OBJMGR_DIR)/src/wlan_objmgr_vdev_obj.o
  827. ifeq ($(CONFIG_WLAN_OBJMGR_DEBUG), y)
  828. UMAC_OBJMGR_OBJS += $(UMAC_OBJMGR_DIR)/src/wlan_objmgr_debug.o
  829. endif
  830. ########### UMAC MGMT TXRX ##########
  831. UMAC_MGMT_TXRX_DIR := $(WLAN_COMMON_ROOT)/umac/cmn_services/mgmt_txrx
  832. UMAC_MGMT_TXRX_INC := -I$(WLAN_COMMON_INC)/umac/cmn_services/mgmt_txrx/dispatcher/inc \
  833. UMAC_MGMT_TXRX_OBJS := $(UMAC_MGMT_TXRX_DIR)/core/src/wlan_mgmt_txrx_main.o \
  834. $(UMAC_MGMT_TXRX_DIR)/dispatcher/src/wlan_mgmt_txrx_utils_api.o \
  835. $(UMAC_MGMT_TXRX_DIR)/dispatcher/src/wlan_mgmt_txrx_tgt_api.o
  836. ########## POWER MANAGEMENT OFFLOADS (PMO) ##########
  837. PMO_DIR := components/pmo
  838. PMO_INC := -I$(WLAN_ROOT)/$(PMO_DIR)/core/inc \
  839. -I$(WLAN_ROOT)/$(PMO_DIR)/core/src \
  840. -I$(WLAN_ROOT)/$(PMO_DIR)/dispatcher/inc \
  841. -I$(WLAN_ROOT)/$(PMO_DIR)/dispatcher/src \
  842. PMO_OBJS := $(PMO_DIR)/core/src/wlan_pmo_main.o \
  843. $(PMO_DIR)/core/src/wlan_pmo_apf.o \
  844. $(PMO_DIR)/core/src/wlan_pmo_arp.o \
  845. $(PMO_DIR)/core/src/wlan_pmo_ns.o \
  846. $(PMO_DIR)/core/src/wlan_pmo_gtk.o \
  847. $(PMO_DIR)/core/src/wlan_pmo_mc_addr_filtering.o \
  848. $(PMO_DIR)/core/src/wlan_pmo_static_config.o \
  849. $(PMO_DIR)/core/src/wlan_pmo_wow.o \
  850. $(PMO_DIR)/core/src/wlan_pmo_lphb.o \
  851. $(PMO_DIR)/core/src/wlan_pmo_suspend_resume.o \
  852. $(PMO_DIR)/core/src/wlan_pmo_hw_filter.o \
  853. $(PMO_DIR)/core/src/wlan_pmo_pkt_filter.o \
  854. $(PMO_DIR)/dispatcher/src/wlan_pmo_obj_mgmt_api.o \
  855. $(PMO_DIR)/dispatcher/src/wlan_pmo_ucfg_api.o \
  856. $(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_arp.o \
  857. $(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_ns.o \
  858. $(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_gtk.o \
  859. $(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_wow.o \
  860. $(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_static_config.o \
  861. $(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_mc_addr_filtering.o \
  862. $(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_lphb.o \
  863. $(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_suspend_resume.o \
  864. $(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_hw_filter.o \
  865. $(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_pkt_filter.o
  866. ########## DISA (ENCRYPTION TEST) ##########
  867. DISA_DIR := components/disa
  868. DISA_INC := -I$(WLAN_ROOT)/$(DISA_DIR)/core/inc \
  869. -I$(WLAN_ROOT)/$(DISA_DIR)/dispatcher/inc
  870. ifeq ($(CONFIG_WLAN_FEATURE_DISA), y)
  871. DISA_OBJS := $(DISA_DIR)/core/src/wlan_disa_main.o \
  872. $(DISA_DIR)/dispatcher/src/wlan_disa_obj_mgmt_api.o \
  873. $(DISA_DIR)/dispatcher/src/wlan_disa_tgt_api.o \
  874. $(DISA_DIR)/dispatcher/src/wlan_disa_ucfg_api.o
  875. endif
  876. ######## OCB ##############
  877. OCB_DIR := components/ocb
  878. OCB_INC := -I$(WLAN_ROOT)/$(OCB_DIR)/core/inc \
  879. -I$(WLAN_ROOT)/$(OCB_DIR)/dispatcher/inc
  880. ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
  881. OCB_OBJS := $(OCB_DIR)/dispatcher/src/wlan_ocb_ucfg_api.o \
  882. $(OCB_DIR)/dispatcher/src/wlan_ocb_tgt_api.o \
  883. $(OCB_DIR)/core/src/wlan_ocb_main.o
  884. endif
  885. ######## IPA ##############
  886. IPA_DIR := components/ipa
  887. IPA_INC := -I$(WLAN_ROOT)/$(IPA_DIR)/core/inc \
  888. -I$(WLAN_ROOT)/$(IPA_DIR)/dispatcher/inc
  889. ifeq ($(CONFIG_IPA_OFFLOAD), 1)
  890. IPA_OBJS := $(IPA_DIR)/dispatcher/src/wlan_ipa_ucfg_api.o \
  891. $(IPA_DIR)/dispatcher/src/wlan_ipa_obj_mgmt_api.o \
  892. $(IPA_DIR)/dispatcher/src/wlan_ipa_tgt_api.o \
  893. $(IPA_DIR)/core/src/wlan_ipa_main.o \
  894. $(IPA_DIR)/core/src/wlan_ipa_core.o \
  895. $(IPA_DIR)/core/src/wlan_ipa_stats.o \
  896. $(IPA_DIR)/core/src/wlan_ipa_rm.o
  897. endif
  898. ########## CLD TARGET_IF #######
  899. CLD_TARGET_IF_DIR := components/target_if
  900. CLD_TARGET_IF_INC := -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/pmo/inc \
  901. -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/pmo/src
  902. CLD_TARGET_IF_OBJ := $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_arp.o \
  903. $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_gtk.o \
  904. $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_hw_filter.o \
  905. $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_lphb.o \
  906. $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_main.o \
  907. $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_mc_addr_filtering.o \
  908. $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_ns.o \
  909. $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_pkt_filter.o \
  910. $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_static_config.o \
  911. $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_suspend_resume.o \
  912. $(CLD_TARGET_IF_DIR)/pmo/src/target_if_pmo_wow.o
  913. ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
  914. CLD_TARGET_IF_INC += -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/ocb/inc
  915. CLD_TARGET_IF_OBJ += $(CLD_TARGET_IF_DIR)/ocb/src/target_if_ocb.o
  916. endif
  917. ifeq ($(CONFIG_WLAN_FEATURE_DISA), y)
  918. CLD_TARGET_IF_INC += -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/disa/inc
  919. CLD_TARGET_IF_OBJ += $(CLD_TARGET_IF_DIR)/disa/src/target_if_disa.o
  920. endif
  921. ifeq ($(CONFIG_IPA_OFFLOAD), 1)
  922. CLD_TARGET_IF_INC += -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/ipa/inc
  923. CLD_TARGET_IF_OBJ += $(CLD_TARGET_IF_DIR)/ipa/src/target_if_ipa.o
  924. endif
  925. ############## UMAC P2P ###########
  926. P2P_DIR := umac/p2p
  927. P2P_CORE_DIR := $(P2P_DIR)/core
  928. P2P_CORE_SRC_DIR := $(P2P_CORE_DIR)/src
  929. P2P_CORE_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(P2P_CORE_SRC_DIR)
  930. P2P_DISPATCHER_DIR := $(P2P_DIR)/dispatcher
  931. P2P_DISPATCHER_INC_DIR := $(P2P_DISPATCHER_DIR)/inc
  932. P2P_DISPATCHER_SRC_DIR := $(P2P_DISPATCHER_DIR)/src
  933. P2P_DISPATCHER_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(P2P_DISPATCHER_SRC_DIR)
  934. UMAC_P2P_INC := -I$(WLAN_COMMON_INC)/$(P2P_DISPATCHER_INC_DIR) \
  935. -I$(WLAN_COMMON_INC)/umac/scan/dispatcher/inc
  936. UMAC_P2P_OBJS := $(P2P_DISPATCHER_OBJ_DIR)/wlan_p2p_ucfg_api.o \
  937. $(P2P_DISPATCHER_OBJ_DIR)/wlan_p2p_tgt_api.o \
  938. $(P2P_CORE_OBJ_DIR)/wlan_p2p_main.o \
  939. $(P2P_CORE_OBJ_DIR)/wlan_p2p_roc.o \
  940. $(P2P_CORE_OBJ_DIR)/wlan_p2p_off_chan_tx.o
  941. ###### UMAC POLICY MGR ########
  942. UMAC_POLICY_MGR_DIR := $(WLAN_COMMON_ROOT)/umac/cmn_services/policy_mgr
  943. UMAC_POLICY_MGR_INC := -I$(WLAN_COMMON_INC)/umac/cmn_services/policy_mgr/inc \
  944. -I$(WLAN_COMMON_INC)/umac/cmn_services/policy_mgr/src
  945. UMAC_POLICY_MGR_OBJS := $(UMAC_POLICY_MGR_DIR)/src/wlan_policy_mgr_action.o \
  946. $(UMAC_POLICY_MGR_DIR)/src/wlan_policy_mgr_core.o \
  947. $(UMAC_POLICY_MGR_DIR)/src/wlan_policy_mgr_get_set_utils.o \
  948. $(UMAC_POLICY_MGR_DIR)/src/wlan_policy_mgr_init_deinit.o \
  949. $(UMAC_POLICY_MGR_DIR)/src/wlan_policy_mgr_pcl.o \
  950. ###### UMAC TDLS ########
  951. UMAC_TDLS_DIR := $(WLAN_COMMON_ROOT)/umac/tdls
  952. UMAC_TDLS_INC := -I$(WLAN_COMMON_INC)/umac/tdls/dispatcher/inc
  953. UMAC_TDLS_OBJS := $(UMAC_TDLS_DIR)/core/src/wlan_tdls_main.o \
  954. $(UMAC_TDLS_DIR)/core/src/wlan_tdls_cmds_process.o \
  955. $(UMAC_TDLS_DIR)/core/src/wlan_tdls_peer.o \
  956. $(UMAC_TDLS_DIR)/core/src/wlan_tdls_mgmt.o \
  957. $(UMAC_TDLS_DIR)/core/src/wlan_tdls_ct.o \
  958. $(UMAC_TDLS_DIR)/dispatcher/src/wlan_tdls_tgt_api.o \
  959. $(UMAC_TDLS_DIR)/dispatcher/src/wlan_tdls_ucfg_api.o \
  960. $(UMAC_TDLS_DIR)/dispatcher/src/wlan_tdls_utils_api.o \
  961. $(WLAN_COMMON_ROOT)/os_if/linux/tdls/src/wlan_cfg80211_tdls.o
  962. ########### BMI ###########
  963. BMI_DIR := core/bmi
  964. BMI_INC := -I$(WLAN_ROOT)/$(BMI_DIR)/inc
  965. BMI_OBJS := $(BMI_DIR)/src/bmi.o \
  966. $(BMI_DIR)/src/ol_fw.o \
  967. $(BMI_DIR)/src/ol_fw_common.o
  968. BMI_OBJS += $(BMI_DIR)/src/bmi_1.o
  969. ########## TARGET_IF #######
  970. TARGET_IF_DIR := $(WLAN_COMMON_ROOT)/target_if
  971. TARGET_IF_INC := -I$(WLAN_COMMON_INC)/target_if/core/inc \
  972. -I$(WLAN_COMMON_INC)/target_if/core/src \
  973. -I$(WLAN_COMMON_INC)/target_if/init_deinit/inc \
  974. -I$(WLAN_COMMON_INC)/target_if/p2p/inc \
  975. -I$(WLAN_COMMON_INC)/target_if/regulatory/inc \
  976. -I$(WLAN_COMMON_INC)/target_if/tdls/inc
  977. TARGET_IF_OBJ := $(TARGET_IF_DIR)/core/src/target_if_main.o \
  978. $(TARGET_IF_DIR)/p2p/src/target_if_p2p.o \
  979. $(TARGET_IF_DIR)/regulatory/src/target_if_reg.o \
  980. $(TARGET_IF_DIR)/tdls/src/target_if_tdls.o \
  981. $(TARGET_IF_DIR)/init_deinit/src/init_cmd_api.o \
  982. $(TARGET_IF_DIR)/init_deinit/src/init_deinit_ucfg.o \
  983. $(TARGET_IF_DIR)/init_deinit/src/init_event_handler.o \
  984. $(TARGET_IF_DIR)/init_deinit/src/service_ready_util.o \
  985. ########### GLOBAL_LMAC_IF ##########
  986. GLOBAL_LMAC_IF_DIR := $(WLAN_COMMON_ROOT)/global_lmac_if
  987. GLOBAL_LMAC_IF_INC := -I$(WLAN_COMMON_INC)/global_lmac_if/inc \
  988. -I$(WLAN_COMMON_INC)/global_lmac_if/src
  989. GLOBAL_LMAC_IF_OBJ := $(GLOBAL_LMAC_IF_DIR)/src/wlan_global_lmac_if.o
  990. ########### WMI ###########
  991. WMI_ROOT_DIR := wmi
  992. WMI_SRC_DIR := $(WMI_ROOT_DIR)/src
  993. WMI_INC_DIR := $(WMI_ROOT_DIR)/inc
  994. WMI_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(WMI_SRC_DIR)
  995. WMI_INC := -I$(WLAN_COMMON_INC)/$(WMI_INC_DIR)
  996. WMI_OBJS := $(WMI_OBJ_DIR)/wmi_unified.o \
  997. $(WMI_OBJ_DIR)/wmi_tlv_helper.o \
  998. $(WMI_OBJ_DIR)/wmi_unified_tlv.o \
  999. $(WMI_OBJ_DIR)/wmi_unified_api.o \
  1000. $(WMI_OBJ_DIR)/wmi_unified_pmo_api.o \
  1001. $(WMI_OBJ_DIR)/wmi_unified_reg_api.o \
  1002. $(WMI_OBJ_DIR)/wmi_unified_dfs_api.o \
  1003. $(WMI_OBJ_DIR)/wmi_unified_non_tlv.o
  1004. ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
  1005. ifeq ($(CONFIG_OCB_UT_FRAMEWORK), y)
  1006. WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_ocb_ut.o
  1007. endif
  1008. endif
  1009. ########### FWLOG ###########
  1010. FWLOG_DIR := $(WLAN_COMMON_ROOT)/utils/fwlog
  1011. FWLOG_INC := -I$(WLAN_ROOT)/$(FWLOG_DIR)
  1012. FWLOG_OBJS := $(FWLOG_DIR)/dbglog_host.o
  1013. ############ TXRX ############
  1014. TXRX_DIR := core/dp/txrx
  1015. TXRX_INC := -I$(WLAN_ROOT)/$(TXRX_DIR)
  1016. TXRX_OBJS := $(TXRX_DIR)/ol_txrx.o \
  1017. $(TXRX_DIR)/ol_cfg.o \
  1018. $(TXRX_DIR)/ol_rx.o \
  1019. $(TXRX_DIR)/ol_rx_fwd.o \
  1020. $(TXRX_DIR)/ol_txrx.o \
  1021. $(TXRX_DIR)/ol_rx_defrag.o \
  1022. $(TXRX_DIR)/ol_tx_desc.o \
  1023. $(TXRX_DIR)/ol_tx.o \
  1024. $(TXRX_DIR)/ol_rx_reorder_timeout.o \
  1025. $(TXRX_DIR)/ol_rx_reorder.o \
  1026. $(TXRX_DIR)/ol_rx_pn.o \
  1027. $(TXRX_DIR)/ol_tx_queue.o \
  1028. $(TXRX_DIR)/ol_txrx_peer_find.o \
  1029. $(TXRX_DIR)/ol_txrx_event.o \
  1030. $(TXRX_DIR)/ol_txrx_encap.o \
  1031. $(TXRX_DIR)/ol_tx_send.o \
  1032. $(TXRX_DIR)/ol_tx_sched.o \
  1033. $(TXRX_DIR)/ol_tx_classify.o
  1034. ifeq ($(CONFIG_WLAN_TX_FLOW_CONTROL_V2), y)
  1035. TXRX_OBJS += $(TXRX_DIR)/ol_txrx_flow_control.o
  1036. endif
  1037. ifeq ($(CONFIG_IPA_OFFLOAD), 1)
  1038. TXRX_OBJS += $(TXRX_DIR)/ol_txrx_ipa.o
  1039. endif
  1040. ifeq ($(CONFIG_LITHIUM), y)
  1041. ############ DP 3.0 ############
  1042. DP_INC := -I$(WLAN_COMMON_ROOT)/dp/inc \
  1043. -I$(WLAN_COMMON_ROOT)/dp/wifi3.0
  1044. DP_SRC := $(WLAN_COMMON_ROOT)/dp/wifi3.0
  1045. DP_OBJS := $(DP_SRC)/dp_main.o \
  1046. $(DP_SRC)/dp_tx.o \
  1047. $(DP_SRC)/dp_tx_desc.o \
  1048. $(DP_SRC)/dp_rx.o \
  1049. $(DP_SRC)/dp_rx_err.o \
  1050. $(DP_SRC)/dp_htt.o \
  1051. $(DP_SRC)/dp_peer.o \
  1052. $(DP_SRC)/dp_rx_desc.o \
  1053. $(DP_SRC)/dp_reo.o \
  1054. $(DP_SRC)/dp_rx_mon_dest.o \
  1055. $(DP_SRC)/dp_rx_mon_status.o \
  1056. $(DP_SRC)/dp_rx_defrag.o \
  1057. $(DP_SRC)/dp_stats.o
  1058. ifeq ($(CONFIG_WLAN_TX_FLOW_CONTROL_V2), y)
  1059. DP_OBJS += $(DP_SRC)/dp_tx_flow_control.o
  1060. endif
  1061. endif
  1062. ifeq ($(CONFIG_IPA_OFFLOAD), 1)
  1063. DP_OBJS += $(DP_SRC)/dp_ipa.o
  1064. endif
  1065. ifeq ($(CONFIG_WDI_EVENT_ENABLE), 1)
  1066. DP_OBJS += $(DP_SRC)/dp_wdi_event.o
  1067. endif
  1068. ############ CFG ############
  1069. WCFG_DIR := wlan_cfg
  1070. WCFG_INC := -I$(WLAN_COMMON_INC)/$(WCFG_DIR)
  1071. WCFG_SRC := $(WLAN_COMMON_ROOT)/$(WCFG_DIR)
  1072. WCFG_OBJS := $(WCFG_SRC)/wlan_cfg.o
  1073. ############ OL ############
  1074. OL_DIR := core/dp/ol
  1075. OL_INC := -I$(WLAN_ROOT)/$(OL_DIR)/inc
  1076. ############ CDP ############
  1077. CDP_ROOT_DIR := dp
  1078. CDP_INC_DIR := $(CDP_ROOT_DIR)/inc
  1079. CDP_INC := -I$(WLAN_COMMON_INC)/$(CDP_INC_DIR)
  1080. ############ PKTLOG ############
  1081. PKTLOG_DIR := $(WLAN_COMMON_ROOT)/utils/pktlog
  1082. PKTLOG_INC := -I$(WLAN_ROOT)/$(PKTLOG_DIR)/include
  1083. PKTLOG_OBJS := $(PKTLOG_DIR)/pktlog_ac.o \
  1084. $(PKTLOG_DIR)/pktlog_internal.o \
  1085. $(PKTLOG_DIR)/linux_ac.o
  1086. ############ HTT ############
  1087. HTT_DIR := core/dp/htt
  1088. HTT_INC := -I$(WLAN_ROOT)/$(HTT_DIR)
  1089. HTT_OBJS := $(HTT_DIR)/htt_tx.o \
  1090. $(HTT_DIR)/htt.o \
  1091. $(HTT_DIR)/htt_t2h.o \
  1092. $(HTT_DIR)/htt_h2t.o \
  1093. $(HTT_DIR)/htt_fw_stats.o \
  1094. $(HTT_DIR)/htt_rx.o
  1095. ############## INIT-DEINIT ###########
  1096. INIT_DEINIT_DIR := init_deinit/dispatcher
  1097. INIT_DEINIT_INC_DIR := $(INIT_DEINIT_DIR)/inc
  1098. INIT_DEINIT_SRC_DIR := $(INIT_DEINIT_DIR)/src
  1099. INIT_DEINIT_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(INIT_DEINIT_SRC_DIR)
  1100. INIT_DEINIT_INC := -I$(WLAN_COMMON_INC)/$(INIT_DEINIT_INC_DIR)
  1101. INIT_DEINIT_OBJS := $(INIT_DEINIT_OBJ_DIR)/dispatcher_init_deinit.o
  1102. ############## REGULATORY ###########
  1103. REGULATORY_DIR := umac/regulatory
  1104. REGULATORY_CORE_INC_DIR := $(REGULATORY_DIR)/core/inc
  1105. REGULATORY_CORE_SRC_DIR := $(REGULATORY_DIR)/core/src
  1106. REG_DISPATCHER_INC_DIR := $(REGULATORY_DIR)/dispatcher/inc
  1107. REG_DISPATCHER_SRC_DIR := $(REGULATORY_DIR)/dispatcher/src
  1108. REG_CORE_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(REGULATORY_CORE_SRC_DIR)
  1109. REG_DISPATCHER_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(REG_DISPATCHER_SRC_DIR)
  1110. REGULATORY_INC := -I$(WLAN_COMMON_INC)/$(REGULATORY_CORE_INC_DIR)
  1111. REGULATORY_INC += -I$(WLAN_COMMON_INC)/$(REG_DISPATCHER_INC_DIR)
  1112. REGULATORY_OBJS := $(REG_CORE_OBJ_DIR)/reg_db.o \
  1113. $(REG_CORE_OBJ_DIR)/reg_services.o \
  1114. $(REG_CORE_OBJ_DIR)/reg_db_parser.o \
  1115. $(REG_DISPATCHER_OBJ_DIR)/wlan_reg_services_api.o \
  1116. $(REG_DISPATCHER_OBJ_DIR)/wlan_reg_tgt_api.o \
  1117. $(REG_DISPATCHER_OBJ_DIR)/wlan_reg_ucfg_api.o
  1118. ############## Control path common scheduler ##########
  1119. SCHEDULER_DIR := scheduler
  1120. SCHEDULER_INC_DIR := $(SCHEDULER_DIR)/inc
  1121. SCHEDULER_SRC_DIR := $(SCHEDULER_DIR)/src
  1122. SCHEDULER_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(SCHEDULER_SRC_DIR)
  1123. SCHEDULER_INC := -I$(WLAN_COMMON_INC)/$(SCHEDULER_INC_DIR)
  1124. SCHEDULER_OBJS := $(SCHEDULER_OBJ_DIR)/scheduler_api.o \
  1125. $(SCHEDULER_OBJ_DIR)/scheduler_core.o
  1126. ###### UMAC SERIALIZATION ########
  1127. UMAC_SER_DIR := umac/cmn_services/serialization
  1128. UMAC_SER_INC_DIR := $(UMAC_SER_DIR)/inc
  1129. UMAC_SER_SRC_DIR := $(UMAC_SER_DIR)/src
  1130. UMAC_SER_OBJ_DIR := $(WLAN_COMMON_ROOT)/$(UMAC_SER_SRC_DIR)
  1131. UMAC_SER_INC := -I$(WLAN_COMMON_INC)/$(UMAC_SER_INC_DIR)
  1132. UMAC_SER_OBJS := $(UMAC_SER_OBJ_DIR)/wlan_serialization_dequeue.o \
  1133. $(UMAC_SER_OBJ_DIR)/wlan_serialization_enqueue.o \
  1134. $(UMAC_SER_OBJ_DIR)/wlan_serialization_main.o \
  1135. $(UMAC_SER_OBJ_DIR)/wlan_serialization_api.o \
  1136. $(UMAC_SER_OBJ_DIR)/wlan_serialization_utils.o \
  1137. $(UMAC_SER_OBJ_DIR)/wlan_serialization_legacy_api.o \
  1138. $(UMAC_SER_OBJ_DIR)/wlan_serialization_rules.o
  1139. ###### WIFI POS ########
  1140. CONFIG_WIFI_POS_CONVERGED := y
  1141. WIFI_POS_OS_IF_DIR := $(WLAN_COMMON_ROOT)/os_if/linux/wifi_pos/src
  1142. WIFI_POS_OS_IF_INC := -I$(WLAN_COMMON_INC)/os_if/linux/wifi_pos/inc
  1143. WIFI_POS_TGT_DIR := $(WLAN_COMMON_ROOT)/target_if/wifi_pos/src
  1144. WIFI_POS_TGT_INC := -I$(WLAN_COMMON_INC)/target_if/wifi_pos/inc
  1145. WIFI_POS_CORE_DIR := $(WLAN_COMMON_ROOT)/umac/wifi_pos/src
  1146. WIFI_POS_API_INC := -I$(WLAN_COMMON_INC)/umac/wifi_pos/inc
  1147. ifeq ($(CONFIG_WIFI_POS_CONVERGED), y)
  1148. WIFI_POS_OBJS := $(WIFI_POS_CORE_DIR)/wifi_pos_api.o \
  1149. $(WIFI_POS_CORE_DIR)/wifi_pos_main.o \
  1150. $(WIFI_POS_CORE_DIR)/wifi_pos_ucfg.o \
  1151. $(WIFI_POS_CORE_DIR)/wifi_pos_utils.o \
  1152. $(WIFI_POS_OS_IF_DIR)/os_if_wifi_pos.o \
  1153. $(WIFI_POS_TGT_DIR)/target_if_wifi_pos.o
  1154. endif
  1155. ###### CP STATS ########
  1156. CONFIG_CP_STATS := y
  1157. CP_STATS_OS_IF_INC := -I$(WLAN_COMMON_INC)/os_if/linux/cp_stats/inc
  1158. CP_STATS_TGT_INC := -I$(WLAN_COMMON_INC)/target_if/cp_stats/inc
  1159. CP_STATS_DISPATCHER_INC := -I$(WLAN_COMMON_INC)/umac/cp_stats/dispatcher/inc
  1160. ######################### NAN #########################
  1161. NAN_CORE_DIR := $(WLAN_COMMON_ROOT)/umac/nan/core/src
  1162. NAN_CORE_INC := -I$(WLAN_COMMON_INC)/umac/nan/core/inc
  1163. NAN_UCFG_DIR := $(WLAN_COMMON_ROOT)/umac/nan/dispatcher/src
  1164. NAN_UCFG_INC := -I$(WLAN_COMMON_INC)/umac/nan/dispatcher/inc
  1165. NAN_TGT_DIR := $(WLAN_COMMON_ROOT)/target_if/nan/src
  1166. NAN_TGT_INC := -I$(WLAN_COMMON_INC)/target_if/nan/inc
  1167. NAN_OS_IF_DIR := $(WLAN_COMMON_ROOT)/os_if/linux/nan/src
  1168. NAN_OS_IF_INC := -I$(WLAN_COMMON_INC)/os_if/linux/nan/inc
  1169. ifeq ($(CONFIG_NAN_CONVERGENCE), y)
  1170. WLAN_NAN_OBJS := $(NAN_CORE_DIR)/nan_main.o \
  1171. $(NAN_CORE_DIR)/nan_api.o \
  1172. $(NAN_CORE_DIR)/nan_utils.o \
  1173. $(NAN_UCFG_DIR)/nan_ucfg_api.o \
  1174. $(NAN_TGT_DIR)/target_if_nan.o \
  1175. $(NAN_OS_IF_DIR)/os_if_nan.o
  1176. endif
  1177. #######################################################
  1178. ############## HTC ##########
  1179. HTC_DIR := htc
  1180. HTC_INC := -I$(WLAN_COMMON_INC)/$(HTC_DIR)
  1181. HTC_OBJS := $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc.o \
  1182. $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc_send.o \
  1183. $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc_recv.o \
  1184. $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc_services.o
  1185. ifeq ($(CONFIG_FEATURE_HTC_CREDIT_HISTORY), 1)
  1186. HTC_OBJS += $(WLAN_COMMON_ROOT)/$(HTC_DIR)/htc_credit_history.o
  1187. endif
  1188. ########### HIF ###########
  1189. HIF_DIR := hif
  1190. HIF_CE_DIR := $(HIF_DIR)/src/ce
  1191. HIF_DISPATCHER_DIR := $(HIF_DIR)/src/dispatcher
  1192. HIF_PCIE_DIR := $(HIF_DIR)/src/pcie
  1193. HIF_SNOC_DIR := $(HIF_DIR)/src/snoc
  1194. HIF_USB_DIR := $(HIF_DIR)/src/usb
  1195. HIF_SDIO_DIR := $(HIF_DIR)/src/sdio
  1196. HIF_SDIO_NATIVE_DIR := $(HIF_SDIO_DIR)/native_sdio
  1197. HIF_SDIO_NATIVE_INC_DIR := $(HIF_SDIO_NATIVE_DIR)/include
  1198. HIF_SDIO_NATIVE_SRC_DIR := $(HIF_SDIO_NATIVE_DIR)/src
  1199. HIF_INC := -I$(WLAN_COMMON_INC)/$(HIF_DIR)/inc \
  1200. -I$(WLAN_COMMON_INC)/$(HIF_DIR)/src
  1201. ifeq ($(CONFIG_HIF_PCI), 1)
  1202. HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_DISPATCHER_DIR)
  1203. HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_PCIE_DIR)
  1204. HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_CE_DIR)
  1205. endif
  1206. ifeq ($(CONFIG_HIF_SNOC), 1)
  1207. HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_DISPATCHER_DIR)
  1208. HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_SNOC_DIR)
  1209. HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_CE_DIR)
  1210. endif
  1211. ifeq ($(CONFIG_HIF_USB), 1)
  1212. HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_DISPATCHER_DIR)
  1213. HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_USB_DIR)
  1214. endif
  1215. ifeq ($(CONFIG_HIF_SDIO), 1)
  1216. HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_DISPATCHER_DIR)
  1217. HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_SDIO_DIR)
  1218. HIF_INC += -I$(WLAN_COMMON_INC)/$(HIF_SDIO_NATIVE_INC_DIR)
  1219. endif
  1220. HIF_COMMON_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/ath_procfs.o \
  1221. $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_main.o \
  1222. $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/mp_dev.o
  1223. ifeq ($(CONFIG_WLAN_NAPI), y)
  1224. HIF_COMMON_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_exec.o
  1225. HIF_COMMON_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_irq_affinity.o
  1226. endif
  1227. HIF_CE_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_bmi.o \
  1228. $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_diag.o \
  1229. $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_main.o \
  1230. $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_service.o \
  1231. $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_tasklet.o \
  1232. $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/regtable.o
  1233. ifeq ($(CONFIG_LITHIUM), y)
  1234. HIF_CE_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/qca6290def.o \
  1235. $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ce_service_srng.o
  1236. endif
  1237. HIF_USB_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_USB_DIR)/usbdrv.o \
  1238. $(WLAN_COMMON_ROOT)/$(HIF_USB_DIR)/hif_usb.o \
  1239. $(WLAN_COMMON_ROOT)/$(HIF_USB_DIR)/if_usb.o \
  1240. $(WLAN_COMMON_ROOT)/$(HIF_USB_DIR)/regtable_usb.o
  1241. HIF_SDIO_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_sdio_send.o \
  1242. $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_bmi_reg_access.o \
  1243. $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_diag_reg_access.o \
  1244. $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_sdio_dev.o \
  1245. $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_sdio.o \
  1246. $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/hif_sdio_recv.o \
  1247. $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/regtable_sdio.o
  1248. HIF_SDIO_NATIVE_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_SDIO_NATIVE_SRC_DIR)/hif.o \
  1249. $(WLAN_COMMON_ROOT)/$(HIF_SDIO_NATIVE_SRC_DIR)/hif_scatter.o
  1250. ifeq ($(CONFIG_WLAN_NAPI), y)
  1251. HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_napi.o
  1252. endif
  1253. ifeq ($(CONFIG_FEATURE_UNIT_TEST_SUSPEND), 1)
  1254. HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DIR)/src/hif_unit_test_suspend.o
  1255. endif
  1256. HIF_PCIE_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_PCIE_DIR)/if_pci.o
  1257. HIF_SNOC_OBJS := $(WLAN_COMMON_ROOT)/$(HIF_SNOC_DIR)/if_snoc.o
  1258. HIF_SDIO_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/if_sdio.o
  1259. HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus.o
  1260. HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/dummy.o
  1261. HIF_OBJS += $(HIF_COMMON_OBJS)
  1262. ifeq ($(CONFIG_HIF_PCI), 1)
  1263. HIF_OBJS += $(HIF_PCIE_OBJS)
  1264. HIF_OBJS += $(HIF_CE_OBJS)
  1265. HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus_pci.o
  1266. endif
  1267. ifeq ($(CONFIG_HIF_SNOC), 1)
  1268. HIF_OBJS += $(HIF_SNOC_OBJS)
  1269. HIF_OBJS += $(HIF_CE_OBJS)
  1270. HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus_snoc.o
  1271. endif
  1272. ifeq ($(CONFIG_HIF_SDIO), 1)
  1273. HIF_OBJS += $(HIF_SDIO_OBJS)
  1274. HIF_OBJS += $(HIF_SDIO_NATIVE_OBJS)
  1275. HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus_sdio.o
  1276. endif
  1277. ifeq ($(CONFIG_HIF_USB), 1)
  1278. HIF_OBJS += $(HIF_USB_OBJS)
  1279. HIF_OBJS += $(WLAN_COMMON_ROOT)/$(HIF_DISPATCHER_DIR)/multibus_usb.o
  1280. endif
  1281. ifeq ($(CONFIG_LITHIUM), y)
  1282. ############ HAL ############
  1283. HAL_DIR := hal
  1284. HAL_INC := -I$(WLAN_COMMON_INC)/$(HAL_DIR)/inc \
  1285. -I$(WLAN_COMMON_INC)/$(HAL_DIR)/wifi3.0
  1286. HAL_OBJS := $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/hal_srng.o \
  1287. $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/hal_rx.o \
  1288. $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/hal_wbm.o \
  1289. $(WLAN_COMMON_ROOT)/$(HAL_DIR)/wifi3.0/hal_reo.o
  1290. endif
  1291. ############ WMA ############
  1292. WMA_DIR := core/wma
  1293. WMA_INC_DIR := $(WMA_DIR)/inc
  1294. WMA_SRC_DIR := $(WMA_DIR)/src
  1295. WMA_INC := -I$(WLAN_ROOT)/$(WMA_INC_DIR) \
  1296. -I$(WLAN_ROOT)/$(WMA_SRC_DIR)
  1297. ifeq ($(CONFIG_WLAN_FEATURE_NAN_DATAPATH), y)
  1298. WMA_NDP_OBJS += $(WMA_SRC_DIR)/wma_nan_datapath.o
  1299. endif
  1300. WMA_OBJS := $(WMA_SRC_DIR)/wma_main.o \
  1301. $(WMA_SRC_DIR)/wma_scan_roam.o \
  1302. $(WMA_SRC_DIR)/wma_dev_if.o \
  1303. $(WMA_SRC_DIR)/wma_mgmt.o \
  1304. $(WMA_SRC_DIR)/wma_power.o \
  1305. $(WMA_SRC_DIR)/wma_data.o \
  1306. $(WMA_SRC_DIR)/wma_utils.o \
  1307. $(WMA_SRC_DIR)/wma_features.o \
  1308. $(WMA_SRC_DIR)/wlan_qct_wma_legacy.o\
  1309. $(WMA_NDP_OBJS)
  1310. ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
  1311. WMA_OBJS+= $(WMA_SRC_DIR)/wma_ocb.o
  1312. endif
  1313. ifeq ($(CONFIG_WLAN_FEATURE_FIPS), y)
  1314. WMA_OBJS+= $(WMA_SRC_DIR)/wma_fips_api.o
  1315. endif
  1316. ifeq ($(CONFIG_MPC_UT_FRAMEWORK),y)
  1317. WMA_OBJS += $(WMA_SRC_DIR)/wma_utils_ut.o
  1318. endif
  1319. ifeq ($(CONFIG_WLAN_FEATURE_11AX), y)
  1320. WMA_OBJS+= $(WMA_SRC_DIR)/wma_he.o
  1321. endif
  1322. ############## PLD ##########
  1323. PLD_DIR := core/pld
  1324. PLD_INC_DIR := $(PLD_DIR)/inc
  1325. PLD_SRC_DIR := $(PLD_DIR)/src
  1326. PLD_INC := -I$(WLAN_ROOT)/$(PLD_INC_DIR) \
  1327. -I$(WLAN_ROOT)/$(PLD_SRC_DIR)
  1328. PLD_OBJS := $(PLD_SRC_DIR)/pld_common.o
  1329. ifeq ($(CONFIG_PCI), y)
  1330. PLD_OBJS += $(PLD_SRC_DIR)/pld_pcie.o
  1331. endif
  1332. ifeq ($(CONFIG_ICNSS),y)
  1333. PLD_OBJS += $(PLD_SRC_DIR)/pld_snoc.o
  1334. endif
  1335. ifeq ($(CONFIG_QCA_WIFI_SDIO), 1)
  1336. PLD_OBJS += $(PLD_SRC_DIR)/pld_sdio.o
  1337. endif
  1338. ifeq ($(CONFIG_PLD_USB_CNSS), y)
  1339. PLD_OBJS += $(PLD_SRC_DIR)/pld_usb.o
  1340. endif
  1341. ifeq ($(CONFIG_QCA6290_11AX), y)
  1342. TARGET_INC := -I$(WLAN_ROOT)/../fw-api/hw/qca6290/11ax/v1 \
  1343. -I$(WLAN_ROOT)/../fw-api/fw
  1344. else
  1345. TARGET_INC := -I$(WLAN_ROOT)/../fw-api/hw/qca6290/v2 \
  1346. -I$(WLAN_ROOT)/../fw-api/fw
  1347. endif
  1348. LINUX_INC := -Iinclude
  1349. INCS := $(HDD_INC) \
  1350. $(EPPING_INC) \
  1351. $(LINUX_INC) \
  1352. $(MAC_INC) \
  1353. $(SAP_INC) \
  1354. $(SME_INC) \
  1355. $(SYS_INC) \
  1356. $(QDF_INC) \
  1357. $(CDS_INC) \
  1358. $(DFS_INC) \
  1359. $(TARGET_IF_INC) \
  1360. $(CLD_TARGET_IF_INC) \
  1361. $(OS_IF_INC) \
  1362. $(GLOBAL_LMAC_IF_INC) \
  1363. $(FTM_INC)
  1364. INCS += $(WMA_INC) \
  1365. $(UAPI_INC) \
  1366. $(COMMON_INC) \
  1367. $(WMI_INC) \
  1368. $(FWLOG_INC) \
  1369. $(TXRX_INC) \
  1370. $(OL_INC) \
  1371. $(CDP_INC) \
  1372. $(PKTLOG_INC) \
  1373. $(HTT_INC) \
  1374. $(INIT_DEINIT_INC) \
  1375. $(SCHEDULER_INC) \
  1376. $(REGULATORY_INC) \
  1377. $(HTC_INC) \
  1378. $(DFS_INC) \
  1379. $(WCFG_INC)
  1380. INCS += $(HIF_INC) \
  1381. $(BMI_INC)
  1382. ifeq ($(CONFIG_LITHIUM), y)
  1383. INCS += $(HAL_INC) \
  1384. $(DP_INC)
  1385. endif
  1386. ################ WIFI POS ################
  1387. INCS += $(WIFI_POS_API_INC)
  1388. INCS += $(WIFI_POS_TGT_INC)
  1389. INCS += $(WIFI_POS_OS_IF_INC)
  1390. ################ CP STATS ################
  1391. INCS += $(CP_STATS_OS_IF_INC)
  1392. INCS += $(CP_STATS_TGT_INC)
  1393. INCS += $(CP_STATS_DISPATCHER_INC)
  1394. ################ NAN POS ################
  1395. INCS += $(NAN_CORE_INC)
  1396. INCS += $(NAN_UCFG_INC)
  1397. INCS += $(NAN_TGT_INC)
  1398. INCS += $(NAN_OS_IF_INC)
  1399. ##########################################
  1400. INCS += $(UMAC_OBJMGR_INC)
  1401. INCS += $(UMAC_MGMT_TXRX_INC)
  1402. INCS += $(PMO_INC)
  1403. INCS += $(UMAC_P2P_INC)
  1404. INCS += $(UMAC_POLICY_MGR_INC)
  1405. INCS += $(TARGET_INC)
  1406. INCS += $(UMAC_TDLS_INC)
  1407. INCS += $(UMAC_SER_INC)
  1408. INCS += $(NLINK_INC) \
  1409. $(PTT_INC) \
  1410. $(WLAN_LOGGING_INC)
  1411. INCS += $(PLD_INC)
  1412. INCS += $(OCB_INC)
  1413. INCS += $(IPA_INC)
  1414. ifeq ($(CONFIG_REMOVE_PKT_LOG), 0)
  1415. INCS += $(PKTLOG_INC)
  1416. endif
  1417. ifeq ($(BUILD_DIAG_VERSION), 1)
  1418. INCS += $(HOST_DIAG_LOG_INC)
  1419. endif
  1420. INCS += $(DISA_INC)
  1421. INCS += $(UMAC_DISP_INC)
  1422. INCS += $(UMAC_SCAN_INC)
  1423. INCS += $(UMAC_TARGET_SCAN_INC)
  1424. INCS += $(UMAC_GREEN_AP_INC)
  1425. INCS += $(UMAC_TARGET_GREEN_AP_INC)
  1426. INCS += $(UMAC_COMMON_INC)
  1427. INCS += $(UMAC_SPECTRAL_INC)
  1428. INCS += $(UMAC_TARGET_SPECTRAL_INC)
  1429. OBJS := $(HDD_OBJS) \
  1430. $(MAC_OBJS) \
  1431. $(SAP_OBJS) \
  1432. $(SME_OBJS) \
  1433. $(SYS_OBJS) \
  1434. $(QDF_OBJS) \
  1435. $(CDS_OBJS) \
  1436. $(DFS_OBJS) \
  1437. $(FTM_OBJS)
  1438. OBJS += $(WMA_OBJS) \
  1439. $(TXRX_OBJS) \
  1440. $(WMI_OBJS) \
  1441. $(FWLOG_OBJS) \
  1442. $(HTC_OBJS) \
  1443. $(INIT_DEINIT_OBJS) \
  1444. $(SCHEDULER_OBJS) \
  1445. $(REGULATORY_OBJS) \
  1446. $(DFS_OBJS)
  1447. OBJS += $(HIF_OBJS) \
  1448. $(BMI_OBJS) \
  1449. $(HTT_OBJS) \
  1450. $(OS_IF_OBJ) \
  1451. $(TARGET_IF_OBJ) \
  1452. $(CLD_TARGET_IF_OBJ) \
  1453. $(GLOBAL_LMAC_IF_OBJ)
  1454. ifeq ($(CONFIG_LITHIUM), y)
  1455. OBJS += $(HAL_OBJS)
  1456. endif
  1457. ifeq ($(CONFIG_FEATURE_EPPING), y)
  1458. OBJS += $(EPPING_OBJS)
  1459. endif
  1460. OBJS += $(UMAC_OBJMGR_OBJS)
  1461. OBJS += $(WIFI_POS_OBJS)
  1462. OBJS += $(WLAN_NAN_OBJS)
  1463. OBJS += $(UMAC_MGMT_TXRX_OBJS)
  1464. OBJS += $(UMAC_TDLS_OBJS)
  1465. OBJS += $(PMO_OBJS)
  1466. OBJS += $(UMAC_P2P_OBJS)
  1467. OBJS += $(UMAC_POLICY_MGR_OBJS)
  1468. OBJS += $(WLAN_LOGGING_OBJS)
  1469. OBJS += $(NLINK_OBJS)
  1470. OBJS += $(PTT_OBJS)
  1471. OBJS += $(UMAC_SER_OBJS)
  1472. OBJS += $(PLD_OBJS)
  1473. ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
  1474. OBJS += $(OCB_OBJS)
  1475. endif
  1476. ifeq ($(CONFIG_IPA_OFFLOAD), 1)
  1477. OBJS += $(IPA_OBJS)
  1478. endif
  1479. ifeq ($(CONFIG_REMOVE_PKT_LOG), 0)
  1480. OBJS += $(PKTLOG_OBJS)
  1481. endif
  1482. ifeq ($(BUILD_DIAG_VERSION), 1)
  1483. OBJS += $(HOST_DIAG_LOG_OBJS)
  1484. endif
  1485. ifeq ($(CONFIG_WLAN_FEATURE_DISA), y)
  1486. OBJS += $(DISA_OBJS)
  1487. endif
  1488. OBJS += $(UMAC_DISP_OBJS)
  1489. OBJS += $(UMAC_SCAN_OBJS)
  1490. OBJS += $(UMAC_COMMON_OBJS)
  1491. OBJS += $(WCFG_OBJS)
  1492. OBJS += $(UMAC_SPECTRAL_OBJS)
  1493. ifeq ($(CONFIG_QCACLD_FEATURE_GREEN_AP),y)
  1494. OBJS += $(UMAC_GREEN_AP_OBJS)
  1495. endif
  1496. ifeq ($(CONFIG_LITHIUM), y)
  1497. OBJS += $(DP_OBJS)
  1498. endif
  1499. EXTRA_CFLAGS += $(INCS)
  1500. CDEFINES := -DANI_LITTLE_BYTE_ENDIAN \
  1501. -DANI_LITTLE_BIT_ENDIAN \
  1502. -DDOT11F_LITTLE_ENDIAN_HOST \
  1503. -DANI_COMPILER_TYPE_GCC \
  1504. -DANI_OS_TYPE_ANDROID=6 \
  1505. -DPTT_SOCK_SVC_ENABLE \
  1506. -Wall\
  1507. -Werror\
  1508. -D__linux__ \
  1509. -DHAL_SELF_STA_PER_BSS=1 \
  1510. -DFEATURE_WLAN_WAPI \
  1511. -DSOFTAP_CHANNEL_RANGE \
  1512. -DWLAN_AP_STA_CONCURRENCY \
  1513. -DFEATURE_WLAN_SCAN_PNO \
  1514. -DWLAN_FEATURE_PACKET_FILTERING \
  1515. -DWLAN_ENABLE_AGEIE_ON_SCAN_RESULTS \
  1516. -DWLANTL_DEBUG\
  1517. -DWLAN_NS_OFFLOAD \
  1518. -DWLAN_SOFTAP_VSTA_FEATURE \
  1519. -DWLAN_FEATURE_GTK_OFFLOAD \
  1520. -DWLAN_WAKEUP_EVENTS \
  1521. -DFEATURE_WLAN_RA_FILTERING\
  1522. -DFEATURE_WLAN_LPHB \
  1523. -DQCA_SUPPORT_TX_THROTTLE \
  1524. -DWMI_INTERFACE_EVENT_LOGGING \
  1525. -DATH_SUPPORT_WAPI \
  1526. -DWLAN_FEATURE_LINK_LAYER_STATS \
  1527. -DFEATURE_WLAN_EXTSCAN \
  1528. -DWLAN_FEATURE_MBSSID \
  1529. -DCONFIG_160MHZ_SUPPORT \
  1530. -DCONFIG_MCL \
  1531. -DCONFIG_LEGACY_CHAN_ENUM \
  1532. -DNAPIER_SCAN \
  1533. -DWLAN_PMO_ENABLE \
  1534. -DCONVERGED_P2P_ENABLE \
  1535. -DWLAN_POLICY_MGR_ENABLE \
  1536. -DSUPPORT_11AX \
  1537. -DCONFIG_HDD_INIT_WITH_RTNL_LOCK \
  1538. -DCONVERGED_TDLS_ENABLE \
  1539. -DWLAN_CONV_SPECTRAL_ENABLE \
  1540. -DSPECTRAL_USE_NETLINK_SOCKETS \
  1541. -DWLAN_SPECTRAL_ENABLE \
  1542. -DWMI_CMD_STRINGS
  1543. ifeq ($(CONFIG_WLAN_DISABLE_EXPORT_SYMBOL), y)
  1544. CDEFINES += -DWLAN_DISABLE_EXPORT_SYMBOL
  1545. endif
  1546. ############ WIFI POS ##############
  1547. ifeq ($(CONFIG_WIFI_POS_CONVERGED), y)
  1548. CDEFINES += -DWIFI_POS_CONVERGED
  1549. else
  1550. CDEFINES += -DFEATURE_OEM_DATA_SUPPORT
  1551. endif
  1552. ####################################
  1553. ifeq ($(CONFIG_FEATURE_HTC_CREDIT_HISTORY), 1)
  1554. CDEFINES += -DFEATURE_HTC_CREDIT_HISTORY
  1555. endif
  1556. ifeq ($(CONFIG_WLAN_FEATURE_P2P_DEBUG), 1)
  1557. CDEFINES += -DWLAN_FEATURE_P2P_DEBUG
  1558. endif
  1559. ifneq ($(CONFIG_HIF_USB), 1)
  1560. CDEFINES += -DWLAN_LOGGING_SOCK_SVC_ENABLE
  1561. endif
  1562. ifeq ($(CONFIG_WLAN_FEATURE_FILS),y)
  1563. CDEFINES += -DWLAN_FEATURE_FILS_SK
  1564. endif
  1565. ifeq ($(CONFIG_CNSS), y)
  1566. ifeq ($(CONFIG_CNSS_SDIO), y)
  1567. CDEFINES += -DCONFIG_PLD_SDIO_CNSS
  1568. else
  1569. CDEFINES += -DCONFIG_PLD_PCIE_CNSS
  1570. endif
  1571. endif
  1572. ifeq ($(CONFIG_CNSS2), y)
  1573. CDEFINES += -DCONFIG_PLD_PCIE_CNSS
  1574. CDEFINES += -DCONFIG_PLD_PCIE_INIT
  1575. endif
  1576. #Enable NL80211 test mode
  1577. ifeq ($(CONFIG_NL80211_TESTMODE), y)
  1578. CDEFINES += -DWLAN_NL80211_TESTMODE
  1579. endif
  1580. # Flag to enable bus auto suspend
  1581. ifeq ($(CONFIG_ROME_IF),pci)
  1582. ifeq ($(CONFIG_BUS_AUTO_SUSPEND), y)
  1583. CDEFINES += -DFEATURE_RUNTIME_PM
  1584. endif
  1585. endif
  1586. ifeq ($(CONFIG_ICNSS), y)
  1587. CDEFINES += -DCONFIG_PLD_SNOC_ICNSS
  1588. endif
  1589. ifeq (y,$(filter y,$(CONFIG_CNSS_EOS) $(CONFIG_ICNSS)))
  1590. CDEFINES += -DQCA_WIFI_3_0
  1591. endif
  1592. ifeq (y,$(filter y,$(CONFIG_CNSS_ADRASTEA) $(CONFIG_ICNSS)))
  1593. CDEFINES += -DQCA_WIFI_3_0_ADRASTEA
  1594. ifeq ($(CONFIG_QMI_SUPPORT), 1)
  1595. CDEFINES += -DADRASTEA_SHADOW_REGISTERS
  1596. endif
  1597. CDEFINES += -DADRASTEA_RRI_ON_DDR
  1598. endif
  1599. ifeq ($(CONFIG_QMI_SUPPORT), 0)
  1600. CDEFINES += -DCONFIG_BYPASS_QMI
  1601. endif
  1602. ifeq ($(CONFIG_WLAN_FASTPATH), y)
  1603. CDEFINES += -DWLAN_FEATURE_FASTPATH
  1604. endif
  1605. ifeq ($(CONFIG_FEATURE_PKTLOG), y)
  1606. CDEFINES += -DFEATURE_PKTLOG
  1607. endif
  1608. CDEFINES += -DCONFIG_DP_TRACE
  1609. ifeq ($(CONFIG_WLAN_NAPI), y)
  1610. CDEFINES += -DFEATURE_NAPI
  1611. CDEFINES += -DHIF_IRQ_AFFINITY
  1612. ifeq ($(CONFIG_WLAN_NAPI_DEBUG), y)
  1613. CDEFINES += -DFEATURE_NAPI_DEBUG
  1614. endif
  1615. endif
  1616. ifeq (y,$(findstring y,$(CONFIG_ARCH_MSM) $(CONFIG_ARCH_QCOM)))
  1617. CDEFINES += -DMSM_PLATFORM
  1618. endif
  1619. CDEFINES += -DQCA_SUPPORT_TXRX_LOCAL_PEER_ID
  1620. ifeq ($(CONFIG_WLAN_TX_FLOW_CONTROL_V2), y)
  1621. CDEFINES += -DQCA_LL_TX_FLOW_CONTROL_V2
  1622. CDEFINES += -DQCA_LL_TX_FLOW_GLOBAL_MGMT_POOL
  1623. else
  1624. ifeq ($(CONFIG_ROME_IF),pci)
  1625. ifneq ($(CONFIG_LITHIUM),y)
  1626. CDEFINES += -DQCA_LL_LEGACY_TX_FLOW_CONTROL
  1627. endif
  1628. endif
  1629. endif
  1630. ifneq ($(CONFIG_QCA_CLD_WLAN),)
  1631. CDEFINES += -DWCN_PRONTO
  1632. CDEFINES += -DWCN_PRONTO_V1
  1633. endif
  1634. ifeq ($(BUILD_DEBUG_VERSION),1)
  1635. CDEFINES += -DWLAN_DEBUG \
  1636. -DPE_DEBUG_LOGW \
  1637. -DPE_DEBUG_LOGE
  1638. ifeq ($(CONFIG_TRACE_RECORD_FEATURE),1)
  1639. CDEFINES += -DTRACE_RECORD \
  1640. -DLIM_TRACE_RECORD \
  1641. -DSME_TRACE_RECORD \
  1642. -DHDD_TRACE_RECORD
  1643. endif
  1644. endif
  1645. ifeq ($(CONFIG_FEATURE_UNIT_TEST_SUSPEND), 1)
  1646. CDEFINES += -DWLAN_SUSPEND_RESUME_TEST
  1647. endif
  1648. ifeq ($(CONFIG_SLUB_DEBUG_ON),y)
  1649. CDEFINES += -DTIMER_MANAGER
  1650. CDEFINES += -DMEMORY_DEBUG
  1651. CDEFINES += -DCONFIG_HALT_KMEMLEAK
  1652. endif
  1653. ifdef CONFIG_LEAK_DETECTION
  1654. CDEFINES += -DCONFIG_LEAK_DETECTION
  1655. endif
  1656. ifeq ($(HAVE_CFG80211),1)
  1657. CDEFINES += -DWLAN_FEATURE_P2P
  1658. CDEFINES += -DWLAN_FEATURE_WFD
  1659. ifeq ($(CONFIG_QCOM_VOWIFI_11R),y)
  1660. CDEFINES += -DKERNEL_SUPPORT_11R_CFG80211
  1661. CDEFINES += -DUSE_80211_WMMTSPEC_FOR_RIC
  1662. endif
  1663. endif
  1664. ifeq ($(CONFIG_QCOM_ESE),y)
  1665. CDEFINES += -DFEATURE_WLAN_ESE
  1666. CDEFINES += -DQCA_COMPUTE_TX_DELAY
  1667. CDEFINES += -DQCA_COMPUTE_TX_DELAY_PER_TID
  1668. endif
  1669. #normally, TDLS negative behavior is not needed
  1670. ifeq ($(CONFIG_QCOM_TDLS),y)
  1671. CDEFINES += -DFEATURE_WLAN_TDLS
  1672. endif
  1673. ifeq ($(CONFIG_QCACLD_WLAN_LFR3),y)
  1674. CDEFINES += -DWLAN_FEATURE_ROAM_OFFLOAD
  1675. endif
  1676. ifeq ($(CONFIG_CNSS_GENL), y)
  1677. CDEFINES += -DCNSS_GENL
  1678. endif
  1679. ifeq ($(CONFIG_QCACLD_WLAN_LFR2),y)
  1680. CDEFINES += -DWLAN_FEATURE_HOST_ROAM
  1681. endif
  1682. ifeq ($(CONFIG_WLAN_POWER_DEBUGFS), y)
  1683. CDEFINES += -DWLAN_POWER_DEBUGFS
  1684. endif
  1685. # Enable object manager reference count debug infrastructure
  1686. ifeq ($(CONFIG_WLAN_OBJMGR_DEBUG), y)
  1687. CDEFINES += -DWLAN_OBJMGR_DEBUG
  1688. endif
  1689. ifeq ($(CONFIG_WLAN_FEATURE_SAE),y)
  1690. CDEFINES += -DWLAN_FEATURE_SAE
  1691. endif
  1692. ifeq ($(BUILD_DIAG_VERSION),1)
  1693. CDEFINES += -DFEATURE_WLAN_DIAG_SUPPORT
  1694. CDEFINES += -DFEATURE_WLAN_DIAG_SUPPORT_CSR
  1695. CDEFINES += -DFEATURE_WLAN_DIAG_SUPPORT_LIM
  1696. ifeq ($(CONFIG_HIF_PCI), 1)
  1697. CDEFINES += -DCONFIG_ATH_PROCFS_DIAG_SUPPORT
  1698. endif
  1699. endif
  1700. ifeq ($(CONFIG_HIF_USB), 1)
  1701. CDEFINES += -DCONFIG_ATH_PROCFS_DIAG_SUPPORT
  1702. CDEFINES += -DQCA_SUPPORT_OL_RX_REORDER_TIMEOUT
  1703. CDEFINES += -DCONFIG_ATH_PCIE_MAX_PERF=0 -DCONFIG_ATH_PCIE_AWAKE_WHILE_DRIVER_LOAD=0 -DCONFIG_DISABLE_CDC_MAX_PERF_WAR=0
  1704. endif
  1705. ifeq ($(CONFIG_WLAN_FEATURE_11W),y)
  1706. CDEFINES += -DWLAN_FEATURE_11W
  1707. endif
  1708. ifeq ($(CONFIG_QCA_TXDESC_SANITY_CHECKS), 1)
  1709. CDEFINES += -DQCA_SUPPORT_TXDESC_SANITY_CHECKS
  1710. endif
  1711. ifeq ($(CONFIG_QCOM_LTE_COEX),y)
  1712. CDEFINES += -DFEATURE_WLAN_CH_AVOID
  1713. endif
  1714. ifeq ($(CONFIG_WLAN_FEATURE_LPSS),y)
  1715. CDEFINES += -DWLAN_FEATURE_LPSS
  1716. endif
  1717. ifneq ($(TARGET_BUILD_VARIANT),user)
  1718. CDEFINES += -DDESC_DUP_DETECT_DEBUG
  1719. CDEFINES += -DDEBUG_RX_RING_BUFFER
  1720. endif
  1721. ifeq ($(PANIC_ON_BUG),1)
  1722. CDEFINES += -DPANIC_ON_BUG
  1723. endif
  1724. ifeq ($(WLAN_WARN_ON_ASSERT), 1)
  1725. CDEFINES += -DWLAN_WARN_ON_ASSERT
  1726. endif
  1727. ifeq ($(CONFIG_WLAN_LOG_FATAL), y)
  1728. CDEFINES += -DWLAN_LOG_FATAL
  1729. endif
  1730. ifeq ($(CONFIG_WLAN_LOG_ERROR), y)
  1731. CDEFINES += -DWLAN_LOG_ERROR
  1732. endif
  1733. ifeq ($(CONFIG_WLAN_LOG_WARN), y)
  1734. CDEFINES += -DWLAN_LOG_WARN
  1735. endif
  1736. ifeq ($(CONFIG_WLAN_LOG_INFO), y)
  1737. CDEFINES += -DWLAN_LOG_INFO
  1738. endif
  1739. ifeq ($(CONFIG_WLAN_LOG_DEBUG), y)
  1740. CDEFINES += -DWLAN_LOG_DEBUG
  1741. endif
  1742. ifeq ($(WLAN_OPEN_SOURCE), 1)
  1743. CDEFINES += -DWLAN_OPEN_SOURCE
  1744. endif
  1745. ifeq ($(CONFIG_FEATURE_STATS_EXT), 1)
  1746. CDEFINES += -DWLAN_FEATURE_STATS_EXT
  1747. endif
  1748. ifeq ($(CONFIG_QCACLD_FEATURE_NAN),y)
  1749. CDEFINES += -DWLAN_FEATURE_NAN
  1750. endif
  1751. ifeq ($(CONFIG_QCA_IBSS_SUPPORT), 1)
  1752. CDEFINES += -DQCA_IBSS_SUPPORT
  1753. endif
  1754. #Enable OL debug and wmi unified functions
  1755. ifeq ($(CONFIG_ATH_PERF_PWR_OFFLOAD), 1)
  1756. CDEFINES += -DATH_PERF_PWR_OFFLOAD
  1757. endif
  1758. #Disable packet log
  1759. ifeq ($(CONFIG_REMOVE_PKT_LOG), 1)
  1760. CDEFINES += -DREMOVE_PKT_LOG
  1761. endif
  1762. #Enable 11AC TX
  1763. ifeq ($(CONFIG_ATH_11AC_TXCOMPACT), 1)
  1764. CDEFINES += -DATH_11AC_TXCOMPACT
  1765. endif
  1766. #Enable OS specific IRQ abstraction
  1767. ifeq ($(CONFIG_ATH_SUPPORT_SHARED_IRQ), 1)
  1768. CDEFINES += -DATH_SUPPORT_SHARED_IRQ
  1769. endif
  1770. #Enable message based HIF instead of RAW access in BMI
  1771. ifeq ($(CONFIG_HIF_MESSAGE_BASED), 1)
  1772. CDEFINES += -DHIF_MESSAGE_BASED
  1773. endif
  1774. #Enable PCI specific APIS (dma, etc)
  1775. ifeq ($(CONFIG_HIF_PCI), 1)
  1776. CDEFINES += -DHIF_PCI
  1777. endif
  1778. ifeq ($(CONFIG_HIF_SNOC), 1)
  1779. CDEFINES += -DHIF_SNOC
  1780. endif
  1781. #Enable High Latency related Flags
  1782. ifeq ($(CONFIG_QCA_WIFI_SDIO), 1)
  1783. CDEFINES += -DCONFIG_HL_SUPPORT \
  1784. -DCONFIG_AR6320_SUPPORT \
  1785. -DSDIO_3_0 \
  1786. -DHIF_SDIO \
  1787. -DCONFIG_DISABLE_CDC_MAX_PERF_WAR=0 \
  1788. -DCONFIG_ATH_PROCFS_DIAG_SUPPORT \
  1789. -DFEATURE_HL_GROUP_CREDIT_FLOW_CONTROL \
  1790. -DHIF_MBOX_SLEEP_WAR \
  1791. -DDEBUG_HL_LOGGING \
  1792. -DQCA_BAD_PEER_TX_FLOW_CL \
  1793. -DCONFIG_TX_DESC_HI_PRIO_RESERVE \
  1794. -DCONFIG_PER_VDEV_TX_DESC_POOL \
  1795. -DCONFIG_SDIO \
  1796. -DFEATURE_WLAN_FORCE_SAP_SCC
  1797. endif
  1798. ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
  1799. CDEFINES += -DWLAN_FEATURE_DSRC
  1800. ifeq ($(CONFIG_OCB_UT_FRAMEWORK), y)
  1801. CDEFINES += -DWLAN_OCB_UT
  1802. endif
  1803. endif
  1804. ifeq ($(CONFIG_ARCH_SDX20), y)
  1805. ifeq ($(CONFIG_QCA_WIFI_SDIO), 1)
  1806. ifeq ($(CONFIG_WCNSS_SKB_PRE_ALLOC), y)
  1807. CDEFINES += -DFEATURE_SKB_PRE_ALLOC
  1808. endif
  1809. endif
  1810. endif
  1811. #Enable USB specific APIS
  1812. ifeq ($(CONFIG_HIF_USB), 1)
  1813. CDEFINES += -DHIF_USB \
  1814. -DCONFIG_PLD_USB_CNSS \
  1815. -DDEBUG_HL_LOGGING \
  1816. -DCONFIG_HL_SUPPORT
  1817. endif
  1818. #Enable FW logs through ini
  1819. CDEFINES += -DCONFIG_FW_LOGS_BASED_ON_INI
  1820. #Enable pci read/write config functions
  1821. ifeq ($(CONFIG_ATH_PCI), 1)
  1822. CDEFINES += -DATH_PCI
  1823. endif
  1824. #Enable power management suspend/resume functionality
  1825. ifeq ($(CONFIG_ATH_BUS_PM), 1)
  1826. CDEFINES += -DATH_BUS_PM
  1827. endif
  1828. #Enable FLOWMAC module support
  1829. ifeq ($(CONFIG_ATH_SUPPORT_FLOWMAC_MODULE), 1)
  1830. CDEFINES += -DATH_SUPPORT_FLOWMAC_MODULE
  1831. endif
  1832. #Enable spectral support
  1833. ifeq ($(CONFIG_ATH_SUPPORT_SPECTRAL), 1)
  1834. CDEFINES += -DATH_SUPPORT_SPECTRAL
  1835. endif
  1836. #Enable WDI Event support
  1837. ifeq ($(CONFIG_WDI_EVENT_ENABLE), 1)
  1838. CDEFINES += -DWDI_EVENT_ENABLE
  1839. endif
  1840. #Endianess selection
  1841. ifeq ($(CONFIG_LITTLE_ENDIAN), 1)
  1842. AH_LITTLE_ENDIAN=1234
  1843. CDEFINES += -DAH_BYTE_ORDER=$(AH_LITTLE_ENDIAN)
  1844. else
  1845. AH_BIG_ENDIAN=4321
  1846. CDEFINES += -DAH_BYTE_ORDER=$(AH_BIG_ENDIAN)
  1847. CDEFINES += -DBIG_ENDIAN_HOST
  1848. endif
  1849. #Enable TX reclaim support
  1850. ifeq ($(CONFIG_TX_CREDIT_RECLAIM_SUPPORT), 1)
  1851. CDEFINES += -DTX_CREDIT_RECLAIM_SUPPORT
  1852. endif
  1853. #Enable FTM support
  1854. ifeq ($(CONFIG_QCA_WIFI_FTM), 1)
  1855. CDEFINES += -DQCA_WIFI_FTM
  1856. endif
  1857. #Enable Checksum Offload support
  1858. ifeq ($(CONFIG_CHECKSUM_OFFLOAD), 1)
  1859. CDEFINES += -DCHECKSUM_OFFLOAD
  1860. endif
  1861. #Enable Checksum Offload support
  1862. ifeq ($(CONFIG_IPA_OFFLOAD), 1)
  1863. CDEFINES += -DIPA_OFFLOAD
  1864. endif
  1865. ifeq ($(CONFIG_ARCH_SDX20), y)
  1866. CDEFINES += -DSYNC_IPA_READY
  1867. endif
  1868. #Enable GTK Offload
  1869. ifeq ($(CONFIG_GTK_OFFLOAD), 1)
  1870. CDEFINES += -DWLAN_FEATURE_GTK_OFFLOAD
  1871. CDEFINES += -DIGTK_OFFLOAD
  1872. endif
  1873. #Enable GTK Offload
  1874. ifeq ($(CONFIG_EXT_WOW), 1)
  1875. CDEFINES += -DWLAN_FEATURE_EXTWOW_SUPPORT
  1876. endif
  1877. #Mark it as SMP Kernel
  1878. ifeq ($(CONFIG_SMP),y)
  1879. CDEFINES += -DQCA_CONFIG_SMP
  1880. endif
  1881. #Enable Channel Matrix restriction for all Rome only targets
  1882. ifneq (y,$(filter y,$(CONFIG_CNSS_EOS) $(CONFIG_ICNSS)))
  1883. CDEFINES += -DWLAN_ENABLE_CHNL_MATRIX_RESTRICTION
  1884. endif
  1885. #Enable ICMP packet disable powersave feature
  1886. ifeq ($(CONFIG_ICMP_DISABLE_PS),y)
  1887. CDEFINES += -DWLAN_ICMP_DISABLE_PS
  1888. endif
  1889. #Enable OBSS feature
  1890. CDEFINES += -DQCA_HT_2040_COEX
  1891. #features specific to mobile router use case
  1892. ifeq ($(CONFIG_MOBILE_ROUTER), y)
  1893. #enable MCC TO SCC switch
  1894. CDEFINES += -DFEATURE_WLAN_MCC_TO_SCC_SWITCH
  1895. #enable wlan auto shutdown feature
  1896. CDEFINES += -DFEATURE_WLAN_AUTO_SHUTDOWN
  1897. #enable for MBSSID
  1898. CDEFINES += -DWLAN_FEATURE_MBSSID
  1899. #enable AP-AP ACS Optimization
  1900. CDEFINES += -DFEATURE_WLAN_AP_AP_ACS_OPTIMIZE
  1901. #Enable 4address scheme
  1902. CDEFINES += -DFEATURE_WLAN_STA_4ADDR_SCHEME
  1903. #enable MDM/SDX special config
  1904. CDEFINES += -DMDM_PLATFORM
  1905. #Disable STA-AP Mode DFS support
  1906. CDEFINES += -DFEATURE_WLAN_STA_AP_MODE_DFS_DISABLE
  1907. else #CONFIG_MOBILE_ROUTER
  1908. #Open P2P device interface only for non-Mobile router use cases
  1909. CDEFINES += -DWLAN_OPEN_P2P_INTERFACE
  1910. #Enable 2.4 GHz social channels in 5 GHz only mode for p2p usage
  1911. CDEFINES += -DWLAN_ENABLE_SOCIAL_CHANNELS_5G_ONLY
  1912. endif #CONFIG_MOBILE_ROUTER
  1913. #Green AP feature
  1914. ifeq ($(CONFIG_QCACLD_FEATURE_GREEN_AP),y)
  1915. CDEFINES += -DWLAN_SUPPORT_GREEN_AP
  1916. endif
  1917. #Stats & Quota Metering feature
  1918. ifeq ($(CONFIG_IPA_OFFLOAD),1)
  1919. ifeq ($(CONFIG_QCACLD_FEATURE_METERING),y)
  1920. CDEFINES += -DFEATURE_METERING
  1921. endif
  1922. endif
  1923. #Enable RX Full re-order OL feature only "LL and NON-MDM9630 platform"
  1924. ifneq ($(CONFIG_ARCH_MDM9630), y)
  1925. ifeq ($(CONFIG_HIF_PCI), 1)
  1926. CDEFINES += -DWLAN_FEATURE_RX_FULL_REORDER_OL
  1927. endif
  1928. endif
  1929. ifeq ($(CONFIG_ARCH_MDM9607), y)
  1930. CDEFINES += -DCONFIG_TUFELLO_DUAL_FW_SUPPORT
  1931. endif
  1932. ifeq ($(CONFIG_ARCH_MSM8996), y)
  1933. CDEFINES += -DCHANNEL_HOPPING_ALL_BANDS
  1934. endif
  1935. #Enable Signed firmware support for split binary format
  1936. ifeq ($(CONFIG_QCA_SIGNED_SPLIT_BINARY_SUPPORT), 1)
  1937. CDEFINES += -DQCA_SIGNED_SPLIT_BINARY_SUPPORT
  1938. endif
  1939. #Enable single firmware binary format
  1940. ifeq ($(CONFIG_QCA_SINGLE_BINARY_SUPPORT), 1)
  1941. CDEFINES += -DQCA_SINGLE_BINARY_SUPPORT
  1942. endif
  1943. #Enable collecting target RAM dump after kernel panic
  1944. ifeq ($(CONFIG_TARGET_RAMDUMP_AFTER_KERNEL_PANIC), 1)
  1945. CDEFINES += -DTARGET_RAMDUMP_AFTER_KERNEL_PANIC
  1946. endif
  1947. #Enable/disable secure firmware feature
  1948. ifeq ($(CONFIG_FEATURE_SECURE_FIRMWARE), 1)
  1949. CDEFINES += -DFEATURE_SECURE_FIRMWARE
  1950. endif
  1951. ifeq ($(CONFIG_ATH_PCIE_ACCESS_DEBUG), 1)
  1952. CDEFINES += -DCONFIG_ATH_PCIE_ACCESS_DEBUG
  1953. endif
  1954. # Enable feature support fo Linux version QCMBR
  1955. ifeq ($(CONFIG_LINUX_QCMBR),y)
  1956. CDEFINES += -DLINUX_QCMBR
  1957. endif
  1958. # Enable featue sync tsf between multi devices
  1959. ifeq ($(CONFIG_WLAN_SYNC_TSF), y)
  1960. CDEFINES += -DWLAN_FEATURE_TSF
  1961. endif
  1962. ifeq ($(CONFIG_WLAN_SYNC_TSF_PLUS), y)
  1963. CDEFINES += -DWLAN_FEATURE_TSF_PLUS
  1964. endif
  1965. # Enable full rx re-order offload for adrastea
  1966. ifeq (y, $(filter y, $(CONFIG_CNSS_ADRASTEA) $(CONFIG_ICNSS)))
  1967. CDEFINES += -DWLAN_FEATURE_RX_FULL_REORDER_OL
  1968. endif
  1969. # Enable athdiag procfs debug support for adrastea
  1970. ifeq (y, $(filter y, $(CONFIG_CNSS_ADRASTEA) $(CONFIG_ICNSS)))
  1971. CDEFINES += -DCONFIG_ATH_PROCFS_DIAG_SUPPORT
  1972. endif
  1973. # Enable 11AC TX compact feature for adrastea
  1974. ifeq (y, $(filter y, $(CONFIG_CNSS_ADRASTEA) $(CONFIG_ICNSS)))
  1975. CDEFINES += -DATH_11AC_TXCOMPACT
  1976. endif
  1977. # NOTE: CONFIG_64BIT_PADDR requires CONFIG_HELIUMPLUS
  1978. ifeq (y,$(filter y,$(CONFIG_CNSS_EOS) $(CONFIG_ICNSS)))
  1979. CONFIG_HELIUMPLUS := y
  1980. CONFIG_64BIT_PADDR := y
  1981. CONFIG_FEATURE_TSO := y
  1982. CONFIG_FEATURE_TSO_DEBUG := y
  1983. ifneq ($(CONFIG_FORCE_ALLOC_FROM_DMA_ZONE), y)
  1984. CONFIG_ENABLE_DEBUG_ADDRESS_MARKING := y
  1985. endif
  1986. ifeq ($(CONFIG_HELIUMPLUS),y)
  1987. CDEFINES += -DHELIUMPLUS
  1988. CDEFINES += -DAR900B
  1989. ifeq ($(CONFIG_64BIT_PADDR),y)
  1990. CDEFINES += -DHTT_PADDR64
  1991. endif
  1992. ifeq ($(CONFIG_SLUB_DEBUG_ON),y)
  1993. CDEFINES += -DOL_RX_INDICATION_RECORD
  1994. CDEFINES += -DTSOSEG_DEBUG
  1995. endif
  1996. endif
  1997. endif
  1998. ifeq ($(CONFIG_ENABLE_DEBUG_ADDRESS_MARKING),y)
  1999. CDEFINES += -DENABLE_DEBUG_ADDRESS_MARKING
  2000. endif
  2001. ifeq ($(CONFIG_FEATURE_TSO),y)
  2002. CDEFINES += -DFEATURE_TSO
  2003. endif
  2004. ifeq ($(CONFIG_FEATURE_TSO_DEBUG),y)
  2005. CDEFINES += -DFEATURE_TSO_DEBUG
  2006. endif
  2007. ifeq ($(CONFIG_WLAN_LRO), y)
  2008. CDEFINES += -DFEATURE_LRO
  2009. endif
  2010. ifeq ($(CONFIG_MOBILE_ROUTER), y)
  2011. CDEFINES += -DFEATURE_AP_MCC_CH_AVOIDANCE
  2012. endif
  2013. ifeq ($(CONFIG_MPC_UT_FRAMEWORK), y)
  2014. CDEFINES += -DMPC_UT_FRAMEWORK
  2015. endif
  2016. ifeq ($(CONFIG_FEATURE_EPPING), y)
  2017. CDEFINES += -DWLAN_FEATURE_EPPING
  2018. endif
  2019. ifeq ($(CONFIG_WLAN_OFFLOAD_PACKETS),y)
  2020. CDEFINES += -DWLAN_FEATURE_OFFLOAD_PACKETS
  2021. endif
  2022. ifeq ($(CONFIG_WLAN_FEATURE_DISA), y)
  2023. CDEFINES += -DWLAN_FEATURE_DISA
  2024. endif
  2025. ifeq ($(CONFIG_WLAN_FEATURE_FIPS),y)
  2026. CDEFINES += -DWLAN_FEATURE_FIPS
  2027. endif
  2028. ifeq ($(CONFIG_LFR_SUBNET_DETECTION), y)
  2029. CDEFINES += -DFEATURE_LFR_SUBNET_DETECTION
  2030. endif
  2031. ifeq ($(CONFIG_MCC_TO_SCC_SWITCH), y)
  2032. CDEFINES += -DFEATURE_WLAN_MCC_TO_SCC_SWITCH
  2033. endif
  2034. ifeq ($(CONFIG_WLAN_FEATURE_NAN_DATAPATH), y)
  2035. CDEFINES += -DWLAN_FEATURE_NAN_DATAPATH
  2036. endif
  2037. ifeq ($(CONFIG_NAN_CONVERGENCE), y)
  2038. CDEFINES += -DWLAN_FEATURE_NAN_CONVERGENCE
  2039. endif
  2040. #Flag to enable/disable WLAN D0-WOW
  2041. ifeq ($(CONFIG_PCI_MSM), y)
  2042. ifeq ($(CONFIG_ROME_IF),pci)
  2043. CDEFINES += -DFEATURE_WLAN_D0WOW
  2044. endif
  2045. endif
  2046. ifeq ($(CONFIG_LITHIUM),y)
  2047. CDEFINES += -DCONFIG_SHADOW_V2
  2048. CDEFINES += -DQCA6290_HEADERS_DEF
  2049. CDEFINES += -DQCA_WIFI_QCA6290
  2050. CDEFINES += -DQCA_WIFI_QCA8074
  2051. CDEFINES += -DQCA_WIFI_QCA8074_VP
  2052. CDEFINES += -DDP_INTR_POLL_BASED
  2053. CDEFINES += -DTX_PER_PDEV_DESC_POOL
  2054. ifneq ($(CONFIG_IPA_OFFLOAD), 1)
  2055. CDEFINES += -DWLAN_RX_HASH
  2056. endif
  2057. CDEFINES += -DCONFIG_DP_TRACE
  2058. CDEFINES += -DFEATURE_TSO
  2059. CDEFINES += -DTSO_DEBUG_LOG_ENABLE
  2060. CDEFINES += -DDP_LFR
  2061. CDEFINES += -DHTT_PADDR64
  2062. endif
  2063. ifeq ($(CONFIG_QCA6290_11AX), y)
  2064. CDEFINES += -DQCA_WIFI_QCA6290_11AX
  2065. endif
  2066. ifeq ($(CONFIG_WLAN_FEATURE_11AX),y)
  2067. CDEFINES += -DWLAN_FEATURE_11AX
  2068. CDEFINES += -DWLAN_FEATURE_11AX_BSS_COLOR
  2069. endif
  2070. # Dummy flag for WIN/MCL converged data path compilation
  2071. CDEFINES += -DDP_PRINT_ENABLE=0
  2072. CDEFINES += -DATH_SUPPORT_WRAP=0
  2073. CDEFINES += -DQCA_HOST2FW_RXBUF_RING
  2074. #endof dummy flags
  2075. # DFS component
  2076. CDEFINES += -DQCA_MCL_DFS_SUPPORT
  2077. ifeq ($(CONFIG_WLAN_FEATURE_DFS_OFFLOAD),y)
  2078. CDEFINES += -DWLAN_DFS_FULL_OFFLOAD
  2079. else
  2080. CDEFINES += -DWLAN_DFS_PARTIAL_OFFLOAD
  2081. endif
  2082. CDEFINES += -DDFS_COMPONENT_ENABLE
  2083. CDEFINES += -DQCA_DFS_USE_POLICY_MANAGER
  2084. CDEFINES += -DQCA_DFS_NOL_PLATFORM_DRV_SUPPORT
  2085. ifeq ($(CONFIG_WLAN_DEBUGFS), y)
  2086. CDEFINES += -DWLAN_DEBUGFS
  2087. endif
  2088. ifeq ($(CONFIG_DYNAMIC_DEBUG),y)
  2089. CDEFINES += -DFEATURE_MULTICAST_HOST_FW_MSGS
  2090. endif
  2091. #Flag to enable SMMU S1 support
  2092. ifeq ($(CONFIG_ARCH_SDM845), y)
  2093. ifeq ($(CONFIG_IPA_OFFLOAD), 1)
  2094. CDEFINES += -DENABLE_SMMU_S1_TRANSLATION
  2095. endif
  2096. endif
  2097. #Flag to enable NUD tracking
  2098. ifeq ($(CONFIG_WLAN_NUD_TRACKING), 1)
  2099. CDEFINES += -DWLAN_NUD_TRACKING
  2100. endif
  2101. KBUILD_CPPFLAGS += $(CDEFINES)
  2102. # Currently, for versions of gcc which support it, the kernel Makefile
  2103. # is disabling the maybe-uninitialized warning. Re-enable it for the
  2104. # WLAN driver. Note that we must use EXTRA_CFLAGS here so that it
  2105. # will override the kernel settings.
  2106. ifeq ($(call cc-option-yn, -Wmaybe-uninitialized),y)
  2107. EXTRA_CFLAGS += -Wmaybe-uninitialized
  2108. ifneq (y,$(CONFIG_ARCH_MSM))
  2109. EXTRA_CFLAGS += -Wframe-larger-than=4096
  2110. endif
  2111. endif
  2112. EXTRA_CFLAGS += -Wmissing-prototypes
  2113. ifeq ($(call cc-option-yn, -Wheader-guard),y)
  2114. EXTRA_CFLAGS += -Wheader-guard
  2115. endif
  2116. # If the module name is not "wlan", then the define MULTI_IF_NAME to be the
  2117. # same a the QCA CHIP name. The host driver will then append MULTI_IF_NAME to
  2118. # any string that must be unique for all instances of the driver on the system.
  2119. # This allows multiple instances of the driver with different module names.
  2120. # If the module name is wlan, leave MULTI_IF_NAME undefined and the code will
  2121. # treat the driver as the primary driver.
  2122. ifneq ($(MODNAME), wlan)
  2123. CHIP_NAME ?= $(MODNAME)
  2124. CDEFINES += -DMULTI_IF_NAME=\"$(CHIP_NAME)\"
  2125. endif
  2126. # WLAN_HDD_ADAPTER_MAGIC must be unique for all instances of the driver on the
  2127. # system. If it is not defined, then the host driver will use the first 4
  2128. # characters (including NULL) of MULTI_IF_NAME to construct
  2129. # WLAN_HDD_ADAPTER_MAGIC.
  2130. ifdef WLAN_HDD_ADAPTER_MAGIC
  2131. CDEFINES += -DWLAN_HDD_ADAPTER_MAGIC=$(WLAN_HDD_ADAPTER_MAGIC)
  2132. endif
  2133. # Determine if we are building against an arm architecture host
  2134. ifeq ($(findstring arm, $(ARCH)),)
  2135. CDEFINES += -DWLAN_HOST_ARCH_ARM=0
  2136. else
  2137. CDEFINES += -DWLAN_HOST_ARCH_ARM=1
  2138. endif
  2139. # inject some build related information
  2140. ifeq ($(CONFIG_BUILD_TAG), y)
  2141. CLD_CHECKOUT = $(shell cd "$(WLAN_ROOT)" && \
  2142. git reflog | grep -vm1 cherry-pick | grep -oE ^[0-f]+)
  2143. CLD_IDS = $(shell cd "$(WLAN_ROOT)" && \
  2144. git log $(CLD_CHECKOUT)~..HEAD | \
  2145. sed -nE 's/^\s*Change-Id: (I[0-f]{10})[0-f]{30}\s*$$/\1/p' | \
  2146. paste -sd "," -)
  2147. CMN_CHECKOUT = $(shell cd "$(WLAN_COMMON_INC)" && \
  2148. git reflog | grep -vm1 cherry-pick | grep -oE ^[0-f]+)
  2149. CMN_IDS = $(shell cd "$(WLAN_COMMON_INC)" && \
  2150. git log $(CMN_CHECKOUT)~..HEAD | \
  2151. sed -nE 's/^\s*Change-Id: (I[0-f]{10})[0-f]{30}\s*$$/\1/p' | \
  2152. paste -sd "," -)
  2153. TIMESTAMP = $(shell date -u +'%Y-%m-%dT%H:%M:%SZ')
  2154. BUILD_TAG = "$(TIMESTAMP); cld:$(CLD_IDS); cmn:$(CMN_IDS);"
  2155. # It's assumed that BUILD_TAG is used only in wlan_hdd_main.c
  2156. CFLAGS_wlan_hdd_main.o += -DBUILD_TAG=\"$(BUILD_TAG)\"
  2157. endif
  2158. # Module information used by KBuild framework
  2159. obj-$(CONFIG_QCA_CLD_WLAN) += $(MODNAME).o
  2160. $(MODNAME)-y := $(OBJS)
  2161. OBJS_DIRS := $(dir $(OBJS)) \
  2162. $(WLAN_COMMON_ROOT)/$(HIF_CE_DIR)/ \
  2163. $(QDF_OBJ_DIR)/ \
  2164. $(WLAN_COMMON_ROOT)/$(HIF_PCIE_DIR)/ \
  2165. $(WLAN_COMMON_ROOT)/$(HIF_SNOC_DIR)/ \
  2166. $(WLAN_COMMON_ROOT)/$(HIF_SDIO_DIR)/
  2167. CLEAN_DIRS := $(addsuffix *.o,$(sort $(OBJS_DIRS))) \
  2168. $(addsuffix .*.o.cmd,$(sort $(OBJS_DIRS)))
  2169. clean-files := $(CLEAN_DIRS)