wlan_mlme_api.h 127 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795
  1. /*
  2. * Copyright (c) 2018-2021 The Linux Foundation. All rights reserved.
  3. * Copyright (c) 2021-2023 Qualcomm Innovation Center, Inc. All rights reserved.
  4. *
  5. * Permission to use, copy, modify, and/or distribute this software for
  6. * any purpose with or without fee is hereby granted, provided that the
  7. * above copyright notice and this permission notice appear in all
  8. * copies.
  9. *
  10. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
  11. * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
  12. * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
  13. * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
  14. * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
  15. * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
  16. * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
  17. * PERFORMANCE OF THIS SOFTWARE.
  18. */
  19. /**
  20. * DOC: declare public APIs exposed by the mlme component
  21. */
  22. #ifndef _WLAN_MLME_API_H_
  23. #define _WLAN_MLME_API_H_
  24. #include <wlan_mlme_public_struct.h>
  25. #include <wlan_objmgr_psoc_obj.h>
  26. #include <wlan_cmn.h>
  27. #include "sme_api.h"
  28. #define ASSEMBLE_RATECODE_V1(_pream, _nss, _rate) \
  29. (((1) << 28) | ((_pream) << 8) | ((_nss) << 5) | (_rate))
  30. /* This macro is used to extract the rate from the rate_code as first four bits
  31. * in rate_code represents the rate, next 3 bits represents the nss and
  32. * next 2 bits represents preamble.
  33. */
  34. #define RATECODE_V1_RIX_MASK 0xf
  35. /* This macro is used to extract preamble from the rate_code as first 4 bits
  36. * in rate_code represents the rate, next 3 bits represents the nss and
  37. * next 2 bits represents preamble.
  38. */
  39. #define RATECODE_V1_PREAMBLE_OFFSET (4 + 3)
  40. /* This macro is used to extract NSS from the rate_code as first 4 bits
  41. * in rate_code represents the rate, next 3 bits represents the NSS and
  42. * next 2 bits represents preamble.
  43. */
  44. #define RATECODE_V1_NSS_OFFSET 0x4
  45. #define RATECODE_V1_NSS_MASK 0x7
  46. #ifdef FEATURE_SET
  47. /**
  48. * wlan_mlme_get_feature_info() - Get mlme features
  49. * @psoc: psoc context
  50. * @mlme_feature_set: MLME feature set info structure
  51. *
  52. * Return: None
  53. */
  54. void wlan_mlme_get_feature_info(
  55. struct wlan_objmgr_psoc *psoc,
  56. struct wlan_mlme_features *mlme_feature_set);
  57. #endif
  58. /**
  59. * wlan_mlme_get_cfg_str() - Copy the uint8_t array for a particular CFG
  60. * @dst: pointer to the destination buffer.
  61. * @cfg_str: pointer to the cfg string structure
  62. * @len: length to be copied
  63. *
  64. * Return: QDF_STATUS_SUCCESS or QDF_STATUS_E_FAILURE
  65. */
  66. QDF_STATUS wlan_mlme_get_cfg_str(uint8_t *dst, struct mlme_cfg_str *cfg_str,
  67. qdf_size_t *len);
  68. /**
  69. * wlan_mlme_set_cfg_str() - Set values for a particular CFG
  70. * @src: pointer to the source buffer.
  71. * @dst_cfg_str: pointer to the cfg string structure to be modified
  72. * @len: length to be written
  73. *
  74. * Return: QDF_STATUS_SUCCESS or QDF_STATUS_E_FAILURE
  75. */
  76. QDF_STATUS wlan_mlme_set_cfg_str(uint8_t *src, struct mlme_cfg_str *dst_cfg_str,
  77. qdf_size_t len);
  78. /**
  79. * wlan_mlme_get_edca_params() - get the EDCA parameters corresponding to the
  80. * edca profile access category
  81. * @edca_params: pointer to mlme edca parameters structure
  82. * @data: data to which the parameter is to be copied
  83. * @edca_ac: edca ac type enum passed to get the cfg value
  84. *
  85. * Return QDF_STATUS_SUCCESS or QDF_STATUS_E_FAILURE
  86. *
  87. */
  88. QDF_STATUS wlan_mlme_get_edca_params(struct wlan_mlme_edca_params *edca_params,
  89. uint8_t *data, enum e_edca_type edca_ac);
  90. /**
  91. * wlan_mlme_update_cfg_with_tgt_caps() - Update mlme cfg with tgt caps
  92. * @psoc: pointer to psoc object
  93. * @tgt_caps: Pointer to the mlme related capability structure
  94. *
  95. * Return: None
  96. */
  97. void
  98. wlan_mlme_update_cfg_with_tgt_caps(struct wlan_objmgr_psoc *psoc,
  99. struct mlme_tgt_caps *tgt_caps);
  100. /**
  101. * wlan_mlme_update_aux_dev_caps() - Update mlme aux capability
  102. * @psoc: pointer to psoc object
  103. * @wlan_mlme_aux_dev_caps: array for aux dev capability
  104. *
  105. * Return: None
  106. */
  107. void
  108. wlan_mlme_update_aux_dev_caps(struct wlan_objmgr_psoc *psoc,
  109. struct wlan_mlme_aux_dev_caps
  110. wlan_mlme_aux_dev_caps[]);
  111. /*
  112. * mlme_get_wep_key() - get the wep key to process during auth frame
  113. * @vdev: VDEV object for which the wep key is being requested
  114. * @wep_params: cfg wep parameters structure
  115. * @wep_key_id: default key number
  116. * @default_key: default key to be copied
  117. * @key_len: length of the key to copy
  118. *
  119. * Return QDF_STATUS
  120. */
  121. QDF_STATUS mlme_get_wep_key(struct wlan_objmgr_vdev *vdev,
  122. struct wlan_mlme_wep_cfg *wep_params,
  123. enum wep_key_id wep_keyid, uint8_t *default_key,
  124. qdf_size_t *key_len);
  125. /**
  126. * wlan_mlme_get_tx_power() - Get the max tx power in particular band
  127. * @psoc: pointer to psoc object
  128. * @band: 2ghz/5ghz band
  129. *
  130. * Return: value of tx power in the respective band
  131. */
  132. uint8_t wlan_mlme_get_tx_power(struct wlan_objmgr_psoc *psoc,
  133. enum band_info band);
  134. /**
  135. * wlan_mlme_get_power_usage() - Get the power usage info
  136. * @psoc: pointer to psoc object
  137. *
  138. * Return: pointer to character array of power usage
  139. */
  140. char *wlan_mlme_get_power_usage(struct wlan_objmgr_psoc *psoc);
  141. /**
  142. * wlan_mlme_get_enable_deauth_to_disassoc_map() - Get the deauth to disassoc
  143. * map
  144. * @psoc: pointer to psoc object
  145. * @value: pointer to the value which will be filled for the caller
  146. *
  147. * Return: QDF Status
  148. */
  149. QDF_STATUS
  150. wlan_mlme_get_enable_deauth_to_disassoc_map(struct wlan_objmgr_psoc *psoc,
  151. bool *value);
  152. /**
  153. * wlan_mlme_get_ht_cap_info() - Get the HT cap info config
  154. * @psoc: pointer to psoc object
  155. * @ht_cap_info: pointer to the value which will be filled for the caller
  156. *
  157. * Return: QDF Status
  158. */
  159. QDF_STATUS wlan_mlme_get_ht_cap_info(struct wlan_objmgr_psoc *psoc,
  160. struct mlme_ht_capabilities_info
  161. *ht_cap_info);
  162. /**
  163. * wlan_mlme_get_manufacturer_name() - get manufacturer name
  164. * @psoc: pointer to psoc object
  165. * @pbuf: pointer of the buff which will be filled for the caller
  166. * @plen: pointer of max buffer length
  167. * actual length will be returned at this address
  168. * This function gets manufacturer name
  169. *
  170. * Return: QDF_STATUS_SUCCESS - in case of success
  171. */
  172. QDF_STATUS
  173. wlan_mlme_get_manufacturer_name(struct wlan_objmgr_psoc *psoc,
  174. uint8_t *pbuf, uint32_t *plen);
  175. /**
  176. * wlan_mlme_get_model_number() - get model number
  177. * @psoc: pointer to psoc object
  178. * @pbuf: pointer of the buff which will be filled for the caller
  179. * @plen: pointer of max buffer length
  180. * actual length will be returned at this address
  181. * This function gets model number
  182. *
  183. * Return: QDF_STATUS_SUCCESS - in case of success
  184. */
  185. QDF_STATUS
  186. wlan_mlme_get_model_number(struct wlan_objmgr_psoc *psoc,
  187. uint8_t *pbuf, uint32_t *plen);
  188. /**
  189. * wlan_mlme_get_model_name() - get model name
  190. * @psoc: pointer to psoc object
  191. * @pbuf: pointer of the buff which will be filled for the caller
  192. * @plen: pointer of max buffer length
  193. * actual length will be returned at this address
  194. * This function gets model name
  195. *
  196. * Return: QDF_STATUS_SUCCESS - in case of success
  197. */
  198. QDF_STATUS
  199. wlan_mlme_get_model_name(struct wlan_objmgr_psoc *psoc,
  200. uint8_t *pbuf, uint32_t *plen);
  201. /**
  202. * wlan_mlme_get_manufacture_product_name() - get manufacture product name
  203. * @psoc: pointer to psoc object
  204. * @pbuf: pointer of the buff which will be filled for the caller
  205. * @plen: pointer of max buffer length
  206. * actual length will be returned at this address
  207. * This function gets manufacture product name
  208. *
  209. * Return: QDF_STATUS_SUCCESS - in case of success
  210. */
  211. QDF_STATUS
  212. wlan_mlme_get_manufacture_product_name(struct wlan_objmgr_psoc *psoc,
  213. uint8_t *pbuf, uint32_t *plen);
  214. /**
  215. * wlan_mlme_get_manufacture_product_version() - get manufacture product version
  216. * @psoc: pointer to psoc object
  217. * @pbuf: pointer of the buff which will be filled for the caller
  218. * @plen: pointer of max buffer length
  219. * actual length will be returned at this address
  220. * This function gets manufacture product version
  221. *
  222. * Return: QDF_STATUS_SUCCESS - in case of success
  223. */
  224. QDF_STATUS
  225. wlan_mlme_get_manufacture_product_version(struct wlan_objmgr_psoc *psoc,
  226. uint8_t *pbuf, uint32_t *plen);
  227. /**
  228. * wlan_mlme_set_ht_cap_info() - Set the HT cap info config
  229. * @psoc: pointer to psoc object
  230. * @ht_cap_info: Value that needs to be set from the caller
  231. *
  232. * Return: QDF Status
  233. */
  234. QDF_STATUS wlan_mlme_set_ht_cap_info(struct wlan_objmgr_psoc *psoc,
  235. struct mlme_ht_capabilities_info
  236. ht_cap_info);
  237. /**
  238. * wlan_mlme_get_max_amsdu_num() - get the max amsdu num
  239. * @psoc: pointer to psoc object
  240. * @value: pointer to the value where the max_amsdu num is to be filled
  241. *
  242. * Return: QDF_STATUS
  243. */
  244. QDF_STATUS wlan_mlme_get_max_amsdu_num(struct wlan_objmgr_psoc *psoc,
  245. uint8_t *value);
  246. /**
  247. * wlan_mlme_set_max_amsdu_num() - set the max amsdu num
  248. * @psoc: pointer to psoc object
  249. * @value: value to be set for max_amsdu_num
  250. *
  251. * Return: QDF_STATUS
  252. */
  253. QDF_STATUS wlan_mlme_set_max_amsdu_num(struct wlan_objmgr_psoc *psoc,
  254. uint8_t value);
  255. /**
  256. * wlan_mlme_get_ht_mpdu_density() - get the ht mpdu density
  257. * @psoc: pointer to psoc object
  258. * @value: pointer to the value where the ht mpdu density is to be filled
  259. *
  260. * Return: QDF_STATUS
  261. */
  262. QDF_STATUS wlan_mlme_get_ht_mpdu_density(struct wlan_objmgr_psoc *psoc,
  263. uint8_t *value);
  264. /**
  265. * wlan_mlme_set_ht_mpdu_density() - set the ht mpdu density
  266. * @psoc: pointer to psoc object
  267. * @value: value to be set for ht mpdu density
  268. *
  269. * Return: QDF_STATUS
  270. */
  271. QDF_STATUS wlan_mlme_set_ht_mpdu_density(struct wlan_objmgr_psoc *psoc,
  272. uint8_t value);
  273. /**
  274. * wlan_mlme_get_band_capability() - Get the Band capability config
  275. * @psoc: pointer to psoc object
  276. * @band_capability: Pointer to the variable from caller
  277. *
  278. * Return: QDF Status
  279. */
  280. QDF_STATUS wlan_mlme_get_band_capability(struct wlan_objmgr_psoc *psoc,
  281. uint32_t *band_capability);
  282. #ifdef QCA_MULTIPASS_SUPPORT
  283. /**
  284. * wlan_mlme_peer_config_vlan() - send vlan id to FW for RX path
  285. * @vdev: vdev pointer
  286. * @mac_addr: mac address of the peer
  287. *
  288. * Return: QDF_STATUS
  289. */
  290. QDF_STATUS
  291. wlan_mlme_peer_config_vlan(struct wlan_objmgr_vdev *vdev,
  292. uint8_t *mac_addr);
  293. #else
  294. static inline QDF_STATUS
  295. wlan_mlme_peer_config_vlan(struct wlan_objmgr_vdev *vdev,
  296. uint8_t *mac_addr)
  297. {
  298. return QDF_STATUS_SUCCESS;
  299. }
  300. #endif
  301. #ifdef MULTI_CLIENT_LL_SUPPORT
  302. /**
  303. * wlan_mlme_get_wlm_multi_client_ll_caps() - Get the wlm multi client latency
  304. * level capability flag
  305. * @psoc: pointer to psoc object
  306. *
  307. * Return: True is multi client ll cap present
  308. */
  309. bool wlan_mlme_get_wlm_multi_client_ll_caps(struct wlan_objmgr_psoc *psoc);
  310. #else
  311. static inline bool
  312. wlan_mlme_get_wlm_multi_client_ll_caps(struct wlan_objmgr_psoc *psoc)
  313. {
  314. return false;
  315. }
  316. #endif
  317. #ifdef FEATURE_WLAN_CH_AVOID_EXT
  318. /**
  319. * wlan_mlme_get_coex_unsafe_chan_nb_user_prefer() - get coex unsafe nb
  320. * support
  321. * @psoc: pointer to psoc object
  322. *
  323. * Return: coex_unsafe_chan_nb_user_prefer
  324. */
  325. bool wlan_mlme_get_coex_unsafe_chan_nb_user_prefer(
  326. struct wlan_objmgr_psoc *psoc);
  327. #else
  328. static inline
  329. bool wlan_mlme_get_coex_unsafe_chan_nb_user_prefer(
  330. struct wlan_objmgr_psoc *psoc)
  331. {
  332. return false;
  333. }
  334. #endif
  335. /**
  336. * wlan_mlme_set_band_capability() - Set the Band capability config
  337. * @psoc: pointer to psoc object
  338. * @band_capability: Value to be set from the caller
  339. *
  340. * Return: QDF Status
  341. */
  342. QDF_STATUS wlan_mlme_set_band_capability(struct wlan_objmgr_psoc *psoc,
  343. uint32_t band_capability);
  344. #ifdef WLAN_VENDOR_HANDOFF_CONTROL
  345. /**
  346. * wlan_mlme_get_vendor_handoff_control_caps() - Get the vendor handoff control
  347. * capability flag
  348. * @psoc: pointer to psoc object
  349. *
  350. * Return: True if vendor handoff control caps present
  351. */
  352. bool wlan_mlme_get_vendor_handoff_control_caps(struct wlan_objmgr_psoc *psoc);
  353. #else
  354. static inline bool
  355. wlan_mlme_get_vendor_handoff_control_caps(struct wlan_objmgr_psoc *psoc)
  356. {
  357. return false;
  358. }
  359. #endif
  360. /**
  361. * wlan_mlme_set_dual_sta_policy() - Set the dual sta config
  362. * @psoc: pointer to psoc object
  363. * @dual_sta_config: Value to be set from the caller
  364. *
  365. * Return: QDF Status
  366. */
  367. QDF_STATUS wlan_mlme_set_dual_sta_policy(struct wlan_objmgr_psoc *psoc,
  368. uint8_t dual_sta_config);
  369. /**
  370. * wlan_mlme_get_dual_sta_policy() - Get the dual sta policy
  371. * @psoc: pointer to psoc object
  372. * @dual_sta_config: Value to be set from the caller
  373. *
  374. * Return: QDF Status
  375. */
  376. QDF_STATUS wlan_mlme_get_dual_sta_policy(struct wlan_objmgr_psoc *psoc,
  377. uint8_t *dual_sta_config);
  378. /**
  379. * wlan_mlme_convert_ap_policy_config() - Convert vendor attr ap policy
  380. * config to host enum
  381. * @ap_config: Value to convert
  382. *
  383. * Return: enum host_concurrent_ap_policy
  384. */
  385. enum host_concurrent_ap_policy
  386. wlan_mlme_convert_ap_policy_config(
  387. enum qca_wlan_concurrent_ap_policy_config ap_config);
  388. /**
  389. * wlan_mlme_set_ap_policy() - Set ap config policy value
  390. * @vdev: pointer to vdev object
  391. * @ap_cfg_policy: Value to be set from the caller
  392. *
  393. * Return: QDF Status
  394. */
  395. QDF_STATUS
  396. wlan_mlme_set_ap_policy(struct wlan_objmgr_vdev *vdev,
  397. enum host_concurrent_ap_policy ap_cfg_policy);
  398. /**
  399. * wlan_mlme_get_ap_policy() - Get ap config policy value
  400. * @vdev: pointer to vdev object
  401. *
  402. * Return: enum host_concurrent_ap_policy
  403. */
  404. enum host_concurrent_ap_policy
  405. wlan_mlme_get_ap_policy(struct wlan_objmgr_vdev *vdev);
  406. /**
  407. * wlan_mlme_ll_lt_sap_send_oce_flags_fw() - Send the oce flags to FW for
  408. * ll_lt_sap
  409. * @vdev: pointer to vdev object
  410. *
  411. * Return: void
  412. */
  413. void wlan_mlme_ll_lt_sap_send_oce_flags_fw(struct wlan_objmgr_vdev *vdev);
  414. /**
  415. * wlan_mlme_get_prevent_link_down() - Get the prevent link down config
  416. * @psoc: pointer to psoc object
  417. * @prevent_link_down: Pointer to the variable from caller
  418. *
  419. * Return: QDF Status
  420. */
  421. QDF_STATUS wlan_mlme_get_prevent_link_down(struct wlan_objmgr_psoc *psoc,
  422. bool *prevent_link_down);
  423. /**
  424. * wlan_mlme_get_select_5ghz_margin() - Get the select 5Ghz margin config
  425. * @psoc: pointer to psoc object
  426. * @select_5ghz_margin: Pointer to the variable from caller
  427. *
  428. * Return: QDF Status
  429. */
  430. QDF_STATUS wlan_mlme_get_select_5ghz_margin(struct wlan_objmgr_psoc *psoc,
  431. uint8_t *select_5ghz_margin);
  432. /**
  433. * wlan_mlme_get_rtt_mac_randomization() - Get the RTT MAC randomization config
  434. * @psoc: pointer to psoc object
  435. * @rtt_mac_randomization: Pointer to the variable from caller
  436. *
  437. * Return: QDF Status
  438. */
  439. QDF_STATUS wlan_mlme_get_rtt_mac_randomization(struct wlan_objmgr_psoc *psoc,
  440. bool *rtt_mac_randomization);
  441. /**
  442. * wlan_mlme_get_crash_inject() - Get the crash inject config
  443. * @psoc: pointer to psoc object
  444. * @crash_inject: Pointer to the variable from caller
  445. *
  446. * Return: QDF Status
  447. */
  448. QDF_STATUS wlan_mlme_get_crash_inject(struct wlan_objmgr_psoc *psoc,
  449. bool *crash_inject);
  450. /**
  451. * wlan_mlme_get_lpass_support() - Get the LPASS Support config
  452. * @psoc: pointer to psoc object
  453. * @lpass_support: Pointer to the variable from caller
  454. *
  455. * Return: QDF Status
  456. */
  457. QDF_STATUS wlan_mlme_get_lpass_support(struct wlan_objmgr_psoc *psoc,
  458. bool *lpass_support);
  459. /**
  460. * wlan_mlme_get_wls_6ghz_cap() - Get the wifi location service(WLS)
  461. * 6ghz capability
  462. * @psoc: pointer to psoc object
  463. * @wls_6ghz_capable: Pointer to the variable from caller
  464. *
  465. * Return: void
  466. */
  467. void wlan_mlme_get_wls_6ghz_cap(struct wlan_objmgr_psoc *psoc,
  468. bool *wls_6ghz_capable);
  469. /**
  470. * wlan_mlme_get_self_recovery() - Get the self recovery config
  471. * @psoc: pointer to psoc object
  472. * @self_recovery: Pointer to the variable from caller
  473. *
  474. * Return: QDF Status
  475. */
  476. QDF_STATUS wlan_mlme_get_self_recovery(struct wlan_objmgr_psoc *psoc,
  477. bool *self_recovery);
  478. /**
  479. * wlan_mlme_get_sub_20_chan_width() - Get the sub 20 chan width config
  480. * @psoc: pointer to psoc object
  481. * @sub_20_chan_width: Pointer to the variable from caller
  482. *
  483. * Return: QDF Status
  484. */
  485. QDF_STATUS wlan_mlme_get_sub_20_chan_width(struct wlan_objmgr_psoc *psoc,
  486. uint8_t *sub_20_chan_width);
  487. /**
  488. * wlan_mlme_get_fw_timeout_crash() - Get the fw timeout crash config
  489. * @psoc: pointer to psoc object
  490. * @fw_timeout_crash: Pointer to the variable from caller
  491. *
  492. * Return: QDF Status
  493. */
  494. QDF_STATUS wlan_mlme_get_fw_timeout_crash(struct wlan_objmgr_psoc *psoc,
  495. bool *fw_timeout_crash);
  496. /**
  497. * wlan_mlme_get_ito_repeat_count() - Get the fw timeout crash config
  498. * @psoc: pointer to psoc object
  499. * @ito_repeat_count: Pointer to the variable from caller
  500. *
  501. * Return: QDF Status
  502. */
  503. QDF_STATUS wlan_mlme_get_ito_repeat_count(struct wlan_objmgr_psoc *psoc,
  504. uint8_t *ito_repeat_count);
  505. /**
  506. * wlan_mlme_get_acs_with_more_param() - Get the acs_with_more_param flag
  507. * @psoc: pointer to psoc object
  508. * @value: Value that needs to be set from the caller
  509. *
  510. * Return: QDF Status
  511. */
  512. QDF_STATUS wlan_mlme_get_acs_with_more_param(struct wlan_objmgr_psoc *psoc,
  513. bool *value);
  514. /**
  515. * wlan_mlme_get_auto_channel_weight() - Get the auto channel weight
  516. * @psoc: pointer to psoc object
  517. * @value: Value that needs to be set from the caller
  518. *
  519. * Return: QDF Status
  520. */
  521. QDF_STATUS wlan_mlme_get_auto_channel_weight(struct wlan_objmgr_psoc *psoc,
  522. uint32_t *value);
  523. /**
  524. * wlan_mlme_get_vendor_acs_support() - Get the vendor based channel selece
  525. * @psoc: pointer to psoc object
  526. * @value: Value that needs to be set from the caller
  527. *
  528. * Return: QDF Status
  529. */
  530. QDF_STATUS wlan_mlme_get_vendor_acs_support(struct wlan_objmgr_psoc *psoc,
  531. bool *value);
  532. /**
  533. * wlan_mlme_get_acs_support_for_dfs_ltecoex() - Get the flag for
  534. * acs support for dfs ltecoex
  535. * @psoc: pointer to psoc object
  536. * @value: Value that needs to be set from the caller
  537. *
  538. * Return: QDF Status
  539. */
  540. QDF_STATUS
  541. wlan_mlme_get_acs_support_for_dfs_ltecoex(struct wlan_objmgr_psoc *psoc,
  542. bool *value);
  543. /**
  544. * wlan_mlme_get_external_acs_policy() - Get the flag for external acs policy
  545. * @psoc: pointer to psoc object
  546. * @value: Value that needs to be set from the caller
  547. *
  548. * Return: QDF Status
  549. */
  550. QDF_STATUS
  551. wlan_mlme_get_external_acs_policy(struct wlan_objmgr_psoc *psoc,
  552. bool *value);
  553. /**
  554. * wlan_mlme_get_sap_inactivity_override() - Check if sap max inactivity
  555. * override flag is set.
  556. * @psoc: pointer to psoc object
  557. * @value: Value that needs to be set from the caller
  558. *
  559. * Return: QDF Status
  560. */
  561. void wlan_mlme_get_sap_inactivity_override(struct wlan_objmgr_psoc *psoc,
  562. bool *value);
  563. /**
  564. * wlan_mlme_get_ignore_peer_ht_mode() - Get the ignore peer ht opmode flag
  565. * @psoc: pointer to psoc object
  566. * @value: Value that needs to be set from the caller
  567. *
  568. * Return: QDF Status
  569. */
  570. QDF_STATUS wlan_mlme_get_ignore_peer_ht_mode(struct wlan_objmgr_psoc *psoc,
  571. bool *value);
  572. /**
  573. * wlan_mlme_get_tx_chainmask_cck() - Get the tx_chainmask_cfg value
  574. * @psoc: pointer to psoc object
  575. * @value: Value that needs to be set from the caller
  576. *
  577. * Return: QDF_STATUS_FAILURE or QDF_STATUS_SUCCESS
  578. */
  579. QDF_STATUS wlan_mlme_get_tx_chainmask_cck(struct wlan_objmgr_psoc *psoc,
  580. bool *value);
  581. /**
  582. * wlan_mlme_get_tx_chainmask_1ss() - Get the tx_chainmask_1ss value
  583. * @psoc: pointer to psoc object
  584. * @value: Value that caller needs to get
  585. *
  586. * Return: QDF_STATUS_FAILURE or QDF_STATUS_SUCCESS
  587. */
  588. QDF_STATUS wlan_mlme_get_tx_chainmask_1ss(struct wlan_objmgr_psoc *psoc,
  589. uint8_t *value);
  590. /**
  591. * wlan_mlme_get_num_11b_tx_chains() - Get the number of 11b only tx chains
  592. * @psoc: pointer to psoc object
  593. * @value: Value that needs to be set from the caller
  594. *
  595. * Return: QDF_STATUS_FAILURE or QDF_STATUS_SUCCESS
  596. */
  597. QDF_STATUS wlan_mlme_get_num_11b_tx_chains(struct wlan_objmgr_psoc *psoc,
  598. uint16_t *value);
  599. /**
  600. * wlan_mlme_get_num_11ag_tx_chains() - get the total number of 11a/g tx chains
  601. * @psoc: pointer to psoc object
  602. * @value: Value that caller needs to get
  603. *
  604. * Return: QDF_STATUS_FAILURE or QDF_STATUS_SUCCESS
  605. */
  606. QDF_STATUS wlan_mlme_get_num_11ag_tx_chains(struct wlan_objmgr_psoc *psoc,
  607. uint16_t *value);
  608. /**
  609. * wlan_mlme_get_bt_chain_separation_flag() - get the enable_bt_chain_separation
  610. * flag
  611. * @psoc: pointer to psoc object
  612. * @value: Value that needs to be set from the caller
  613. *
  614. * Return: QDF_STATUS_FAILURE or QDF_STATUS_SUCCESS
  615. */
  616. QDF_STATUS wlan_mlme_get_bt_chain_separation_flag(struct wlan_objmgr_psoc *psoc,
  617. bool *value);
  618. /**
  619. * wlan_mlme_configure_chain_mask() - configure chainmask parameters
  620. * @psoc: pointer to psoc object
  621. * @session_id: vdev_id
  622. *
  623. * Return: QDF_STATUS_FAILURE or QDF_STATUS_SUCCESS
  624. */
  625. QDF_STATUS wlan_mlme_configure_chain_mask(struct wlan_objmgr_psoc *psoc,
  626. uint8_t session_id);
  627. /**
  628. * wlan_mlme_is_chain_mask_supported() - check if configure chainmask can
  629. * be supported
  630. * @psoc: pointer to psoc object
  631. *
  632. * Return: true if supported else false
  633. */
  634. bool wlan_mlme_is_chain_mask_supported(struct wlan_objmgr_psoc *psoc);
  635. /**
  636. * wlan_mlme_get_listen_interval() - Get listen interval
  637. * @psoc: pointer to psoc object
  638. * @value: Pointer to value that needs to be filled by MLME
  639. *
  640. * Return: QDF Status
  641. */
  642. QDF_STATUS wlan_mlme_get_listen_interval(struct wlan_objmgr_psoc *psoc,
  643. int *value);
  644. /**
  645. * wlan_mlme_set_sap_listen_interval() - Set the sap listen interval
  646. * @psoc: pointer to psoc object
  647. * @value: Value that needs to be set from the caller
  648. *
  649. * Return: QDF Status
  650. */
  651. QDF_STATUS wlan_mlme_set_sap_listen_interval(struct wlan_objmgr_psoc *psoc,
  652. int value);
  653. /**
  654. * wlan_mlme_set_assoc_sta_limit() - Set the assoc sta limit
  655. * @psoc: pointer to psoc object
  656. * @value: Value that needs to be set from the caller
  657. *
  658. * Return: QDF Status
  659. */
  660. QDF_STATUS wlan_mlme_set_assoc_sta_limit(struct wlan_objmgr_psoc *psoc,
  661. int value);
  662. /**
  663. * wlan_mlme_get_assoc_sta_limit() - Get the assoc sta limit
  664. * @psoc: pointer to psoc object
  665. * @value: Pointer to value that needs to be filled by MLME
  666. *
  667. * Return: QDF Status
  668. */
  669. QDF_STATUS wlan_mlme_get_assoc_sta_limit(struct wlan_objmgr_psoc *psoc,
  670. int *value);
  671. /**
  672. * wlan_mlme_get_sap_get_peer_info() - get the sap get peer info
  673. * @psoc: pointer to psoc object
  674. * @value: Value that needs to be set from the caller
  675. *
  676. * Return: QDF Status
  677. */
  678. QDF_STATUS wlan_mlme_get_sap_get_peer_info(struct wlan_objmgr_psoc *psoc,
  679. bool *value);
  680. /**
  681. * wlan_mlme_set_sap_get_peer_info() - set the sap get peer info
  682. * @psoc: pointer to psoc object
  683. * @value: value to overwrite the sap get peer info
  684. *
  685. * Return: QDF Status
  686. */
  687. QDF_STATUS wlan_mlme_set_sap_get_peer_info(struct wlan_objmgr_psoc *psoc,
  688. bool value);
  689. /**
  690. * wlan_mlme_get_sap_bcast_deauth_enabled() - get the enable/disable value
  691. * for broadcast deauth in sap
  692. * @psoc: pointer to psoc object
  693. * @value: Value that needs to get from the caller
  694. *
  695. * Return: QDF Status
  696. */
  697. QDF_STATUS
  698. wlan_mlme_get_sap_bcast_deauth_enabled(struct wlan_objmgr_psoc *psoc,
  699. bool *value);
  700. /**
  701. * wlan_mlme_get_sap_allow_all_channels() - get the value of sap allow all
  702. * channels
  703. * @psoc: pointer to psoc object
  704. * @value: Value that needs to be set from the caller
  705. *
  706. * Return: QDF Status
  707. */
  708. QDF_STATUS wlan_mlme_get_sap_allow_all_channels(struct wlan_objmgr_psoc *psoc,
  709. bool *value);
  710. /**
  711. * wlan_mlme_is_6g_sap_fd_enabled() - get the enable/disable value
  712. * for 6g sap fils discovery
  713. * @psoc: pointer to psoc object
  714. * @value: Value that needs to get from the caller
  715. *
  716. * Return: QDF Status
  717. */
  718. QDF_STATUS
  719. wlan_mlme_is_6g_sap_fd_enabled(struct wlan_objmgr_psoc *psoc,
  720. bool *value);
  721. /**
  722. * wlan_mlme_get_sap_max_peers() - get the value sap max peers
  723. * @psoc: pointer to psoc object
  724. * @value: Value that needs to be set from the caller
  725. *
  726. * Return: QDF Status
  727. */
  728. QDF_STATUS wlan_mlme_get_sap_max_peers(struct wlan_objmgr_psoc *psoc,
  729. int *value);
  730. /**
  731. * wlan_mlme_set_sap_max_peers() - set the value sap max peers
  732. * @psoc: pointer to psoc object
  733. * @value: Value that needs to be set from the caller
  734. *
  735. * Return: QDF Status
  736. */
  737. QDF_STATUS wlan_mlme_set_sap_max_peers(struct wlan_objmgr_psoc *psoc,
  738. int value);
  739. /**
  740. * wlan_mlme_get_sap_max_offload_peers() - get the value sap max offload peers
  741. * @psoc: pointer to psoc object
  742. * @value: Value that needs to be set from the caller
  743. *
  744. * Return: QDF Status
  745. */
  746. QDF_STATUS wlan_mlme_get_sap_max_offload_peers(struct wlan_objmgr_psoc *psoc,
  747. int *value);
  748. /**
  749. * wlan_mlme_get_sap_max_offload_reorder_buffs() - get the value sap max offload
  750. * reorder buffs.
  751. * @psoc: pointer to psoc object
  752. * @value: Value that needs to be set from the caller
  753. *
  754. * Return: QDF Status
  755. */
  756. QDF_STATUS wlan_mlme_get_sap_max_offload_reorder_buffs(struct wlan_objmgr_psoc
  757. *psoc, int *value);
  758. /**
  759. * wlan_mlme_get_sap_chn_switch_bcn_count() - get the value sap max channel
  760. * switch beacon count
  761. * @psoc: pointer to psoc object
  762. * @value: Value that needs to be set from the caller
  763. *
  764. * Return: QDF Status
  765. */
  766. QDF_STATUS wlan_mlme_get_sap_chn_switch_bcn_count(struct wlan_objmgr_psoc *psoc,
  767. int *value);
  768. /**
  769. * wlan_mlme_get_sap_chn_switch_mode() - get the sap channel
  770. * switch mode
  771. * @psoc: pointer to psoc object
  772. * @value: Value that needs to be set from the caller
  773. *
  774. * Return: QDF Status
  775. */
  776. QDF_STATUS wlan_mlme_get_sap_chn_switch_mode(struct wlan_objmgr_psoc *psoc,
  777. bool *value);
  778. /**
  779. * wlan_mlme_get_sap_internal_restart() - get the sap internal
  780. * restart
  781. * @psoc: pointer to psoc object
  782. * @value: Value that needs to be set from the caller
  783. *
  784. * Return: QDF Status
  785. */
  786. QDF_STATUS wlan_mlme_get_sap_internal_restart(struct wlan_objmgr_psoc *psoc,
  787. bool *value);
  788. /**
  789. * wlan_mlme_get_sap_max_modulated_dtim() - get the max modulated dtim
  790. * restart
  791. * @psoc: pointer to psoc object
  792. * @value: Value that needs to be set from the caller
  793. *
  794. * Return: QDF Status
  795. */
  796. QDF_STATUS wlan_mlme_get_sap_max_modulated_dtim(struct wlan_objmgr_psoc *psoc,
  797. uint8_t *value);
  798. /**
  799. * wlan_mlme_get_sap_chan_pref_location() - get the sap chan pref location
  800. * restart
  801. * @psoc: pointer to psoc object
  802. * @value: Value that needs to be set from the caller
  803. *
  804. * Return: QDF Status
  805. */
  806. QDF_STATUS wlan_mlme_get_sap_chan_pref_location(struct wlan_objmgr_psoc *psoc,
  807. uint8_t *value);
  808. /**
  809. * wlan_mlme_get_sap_country_priority() - get the sap country code priority
  810. * restart
  811. * @psoc: pointer to psoc object
  812. * @value: Value that needs to be set from the caller
  813. *
  814. * Return: QDF Status
  815. */
  816. QDF_STATUS wlan_mlme_get_sap_country_priority(struct wlan_objmgr_psoc *psoc,
  817. bool *value);
  818. /**
  819. * wlan_mlme_get_sap_reduced_beacon_interval() - get the sap reduced
  820. * beacon interval
  821. * @psoc: pointer to psoc object
  822. * @value: Value that needs to be set from the caller
  823. *
  824. * Return: QDF Status
  825. */
  826. QDF_STATUS wlan_mlme_get_sap_reduced_beacon_interval(struct wlan_objmgr_psoc
  827. *psoc, int *value);
  828. /**
  829. * wlan_mlme_get_sap_chan_switch_rate_enabled() - get the sap rate hostapd
  830. * enabled beacon interval
  831. * @psoc: pointer to psoc object
  832. * @value: Value that needs to be set from the caller
  833. *
  834. * Return: QDF Status
  835. */
  836. QDF_STATUS wlan_mlme_get_sap_chan_switch_rate_enabled(struct wlan_objmgr_psoc
  837. *psoc, bool *value);
  838. /**
  839. * wlan_mlme_get_sap_force_11n_for_11ac() - get the sap 11n for 11ac
  840. * @psoc: pointer to psoc object
  841. * @value: Value that needs to be set from the caller
  842. *
  843. * Return: QDF Status
  844. */
  845. QDF_STATUS wlan_mlme_get_sap_force_11n_for_11ac(struct wlan_objmgr_psoc
  846. *psoc, bool *value);
  847. /**
  848. * wlan_mlme_get_go_force_11n_for_11ac() - get the go 11n for 11ac
  849. * @psoc: pointer to psoc object
  850. * @value: Value that needs to be set from the caller
  851. *
  852. * Return: QDF Status
  853. */
  854. QDF_STATUS wlan_mlme_get_go_force_11n_for_11ac(struct wlan_objmgr_psoc
  855. *psoc, bool *value);
  856. /**
  857. * wlan_mlme_is_go_11ac_override() - Override 11ac bandwdith for P2P GO
  858. * @psoc: pointer to psoc object
  859. * @value: pointer to the value which will be filled for the caller
  860. *
  861. * Return: QDF Status
  862. */
  863. QDF_STATUS wlan_mlme_is_go_11ac_override(struct wlan_objmgr_psoc *psoc,
  864. bool *value);
  865. /**
  866. * wlan_mlme_is_sap_11ac_override() - Override 11ac bandwdith for SAP
  867. * @psoc: pointer to psoc object
  868. * @value: pointer to the value which will be filled for the caller
  869. *
  870. * Return: QDF Status
  871. */
  872. QDF_STATUS wlan_mlme_is_sap_11ac_override(struct wlan_objmgr_psoc *psoc,
  873. bool *value);
  874. /**
  875. * wlan_mlme_set_go_11ac_override() - set override 11ac bandwdith for P2P GO
  876. * @psoc: pointer to psoc object
  877. * @value: pointer to the value which will be filled for the caller
  878. *
  879. * Return: QDF Status
  880. */
  881. QDF_STATUS wlan_mlme_set_go_11ac_override(struct wlan_objmgr_psoc *psoc,
  882. bool value);
  883. /**
  884. * wlan_mlme_set_sap_11ac_override() - set override 11ac bandwdith for SAP
  885. * @psoc: pointer to psoc object
  886. * @value: pointer to the value which will be filled for the caller
  887. *
  888. * Return: QDF Status
  889. */
  890. QDF_STATUS wlan_mlme_set_sap_11ac_override(struct wlan_objmgr_psoc *psoc,
  891. bool value);
  892. /**
  893. * wlan_mlme_get_oce_sta_enabled_info() - Get the OCE feature enable
  894. * info for STA
  895. * @psoc: pointer to psoc object
  896. * @value: pointer to the value which will be filled for the caller
  897. *
  898. * Return: QDF Status
  899. */
  900. QDF_STATUS wlan_mlme_get_oce_sta_enabled_info(struct wlan_objmgr_psoc *psoc,
  901. bool *value);
  902. /**
  903. * wlan_mlme_get_bigtk_support() - Get the BIGTK support
  904. * @psoc: pointer to psoc object
  905. * @value: pointer to the value which will be filled for the caller
  906. *
  907. * Return: QDF Status
  908. */
  909. QDF_STATUS wlan_mlme_get_bigtk_support(struct wlan_objmgr_psoc *psoc,
  910. bool *value);
  911. /**
  912. * wlan_mlme_get_ocv_support() - Get the OCV support
  913. * @psoc: pointer to psoc object
  914. * @value: pointer to the value which will be filled for the caller
  915. *
  916. * Return: QDF Status
  917. */
  918. QDF_STATUS wlan_mlme_get_ocv_support(struct wlan_objmgr_psoc *psoc,
  919. bool *value);
  920. /**
  921. * wlan_mlme_get_host_scan_abort_support() - Get support for stop all host
  922. * scans service capability.
  923. * @psoc: PSOC object pointer
  924. *
  925. * Return: True if capability is supported, else False
  926. */
  927. bool wlan_mlme_get_host_scan_abort_support(struct wlan_objmgr_psoc *psoc);
  928. /**
  929. * wlan_mlme_get_dual_sta_roam_support - Get support for dual sta roaming
  930. * feature
  931. * @psoc: PSOC object pointer
  932. *
  933. * Return: True if capability is supported, else False
  934. */
  935. bool wlan_mlme_get_dual_sta_roam_support(struct wlan_objmgr_psoc *psoc);
  936. /**
  937. * wlan_mlme_get_oce_sap_enabled_info() - Get the OCE feature enable
  938. * info for SAP
  939. * @psoc: pointer to psoc object
  940. * @value: pointer to the value which will be filled for the caller
  941. *
  942. * Return: QDF Status
  943. */
  944. QDF_STATUS wlan_mlme_get_oce_sap_enabled_info(struct wlan_objmgr_psoc *psoc,
  945. bool *value);
  946. /**
  947. * wlan_mlme_update_oce_flags() - Update the oce flags to FW
  948. * @pdev: pointer to pdev object
  949. *
  950. * Return: void
  951. */
  952. void wlan_mlme_update_oce_flags(struct wlan_objmgr_pdev *pdev);
  953. /**
  954. * wlan_mlme_cfg_get_aux_supported_modes() - get supported mode of aux.
  955. * definition of bitmap refer WMI_AUX_DEV_CAPS_SUPPORTED_MODE.
  956. *
  957. * @psoc: pointer to psoc object
  958. * @aux_index: aux index, current only support aux0.
  959. * @hw_mode_id: hw mode id
  960. * @supported_modes_bitmap: output for value
  961. *
  962. * Return: true for getting value. false for failure check.
  963. */
  964. bool wlan_mlme_cfg_get_aux_supported_modes(
  965. struct wlan_objmgr_psoc *psoc,
  966. uint32_t aux_index,
  967. enum wlan_mlme_hw_mode_config_type hw_mode_id,
  968. uint32_t *supported_modes_bitmap);
  969. #ifdef WLAN_FEATURE_11AX
  970. /**
  971. * wlan_mlme_cfg_get_he_ul_mumimo() - Get the HE Ul Mumio
  972. * @psoc: pointer to psoc object
  973. * @value: Value that needs to be set from the caller
  974. *
  975. * Return: QDF Status
  976. */
  977. QDF_STATUS wlan_mlme_cfg_get_he_ul_mumimo(struct wlan_objmgr_psoc *psoc,
  978. uint32_t *value);
  979. /**
  980. * wlan_mlme_cfg_set_he_ul_mumimo() - Set the HE Ul Mumio
  981. * @psoc: pointer to psoc object
  982. * @value: Value that needs to be set from the caller
  983. *
  984. * Return: QDF Status
  985. */
  986. QDF_STATUS wlan_mlme_cfg_set_he_ul_mumimo(struct wlan_objmgr_psoc *psoc,
  987. uint32_t value);
  988. /**
  989. * mlme_cfg_get_he_caps() - Get the HE capability info
  990. * @psoc: pointer to psoc object
  991. * @he_cap: Caps that needs to be filled.
  992. *
  993. * Return: QDF Status
  994. */
  995. QDF_STATUS mlme_cfg_get_he_caps(struct wlan_objmgr_psoc *psoc,
  996. tDot11fIEhe_cap *he_cap);
  997. /**
  998. * wlan_mlme_cfg_get_enable_ul_mimo() - Get the HE Ul mimo
  999. * @psoc: pointer to psoc object
  1000. * @value: Value that needs to be set from the caller
  1001. *
  1002. * Return: QDF Status
  1003. */
  1004. QDF_STATUS wlan_mlme_cfg_get_enable_ul_mimo(struct wlan_objmgr_psoc *psoc,
  1005. uint8_t *value);
  1006. /**
  1007. * wlan_mlme_cfg_get_enable_ul_ofdm() - Get enable ul ofdm
  1008. * @psoc: pointer to psoc object
  1009. * @value: Value that needs to be set from the caller
  1010. *
  1011. * Return: QDF Status
  1012. */
  1013. QDF_STATUS wlan_mlme_cfg_get_enable_ul_ofdm(struct wlan_objmgr_psoc *psoc,
  1014. uint8_t *value);
  1015. /**
  1016. * mlme_update_tgt_he_caps_in_cfg() - Update tgt he cap in mlme component
  1017. * @psoc: pointer to psoc object
  1018. * @cfg: pointer to config params from target
  1019. *
  1020. * This api to be used by callers to update
  1021. * he caps in mlme.
  1022. *
  1023. * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
  1024. */
  1025. QDF_STATUS mlme_update_tgt_he_caps_in_cfg(struct wlan_objmgr_psoc *psoc,
  1026. struct wma_tgt_cfg *cfg);
  1027. #endif
  1028. /**
  1029. * wlan_mlme_convert_vht_op_bw_to_phy_ch_width() - convert channel width in VHT
  1030. * operation IE to phy_ch_width
  1031. * @channel_width: channel width in VHT operation IE.
  1032. * @chan_id: channel id
  1033. * @ccfs0: channel center frequency segment 0
  1034. * @ccfs1: channel center frequency segment 1
  1035. *
  1036. * Return: phy_ch_width
  1037. */
  1038. enum phy_ch_width
  1039. wlan_mlme_convert_vht_op_bw_to_phy_ch_width(uint8_t channel_width,
  1040. uint8_t chan_id,
  1041. uint8_t ccfs0,
  1042. uint8_t ccfs1);
  1043. /**
  1044. * wlan_mlme_convert_he_6ghz_op_bw_to_phy_ch_width() - convert channel width in
  1045. * he 6ghz peration IE to phy_ch_width
  1046. * @channel_width: channel width in HE operation IE.
  1047. * @chan_id: channel id
  1048. * @ccfs0: channel center frequency segment 0
  1049. * @ccfs1: channel center frequency segment 1
  1050. *
  1051. * Return: phy_ch_width
  1052. */
  1053. enum phy_ch_width
  1054. wlan_mlme_convert_he_6ghz_op_bw_to_phy_ch_width(uint8_t channel_width,
  1055. uint8_t chan_id,
  1056. uint8_t ccfs0,
  1057. uint8_t ccfs1);
  1058. /**
  1059. * wlan_mlme_chan_stats_scan_event_cb() - process connected channel stats
  1060. * scan event
  1061. * @vdev: pointer to vdev object
  1062. * @event: scan event definition
  1063. * @arg: scan argument
  1064. *
  1065. * Return: none
  1066. */
  1067. void wlan_mlme_chan_stats_scan_event_cb(struct wlan_objmgr_vdev *vdev,
  1068. struct scan_event *event, void *arg);
  1069. /**
  1070. * wlan_mlme_send_ch_width_update_with_notify() - update connected VDEV
  1071. * channel bandwidth
  1072. * @psoc: pointer to psoc object
  1073. * @vdev: pointer to vdev object
  1074. * @vdev_id: vdev id
  1075. * @ch_width: channel width to update
  1076. *
  1077. * Return: none
  1078. */
  1079. QDF_STATUS
  1080. wlan_mlme_send_ch_width_update_with_notify(struct wlan_objmgr_psoc *psoc,
  1081. struct wlan_objmgr_vdev *vdev,
  1082. uint8_t vdev_id,
  1083. enum phy_ch_width ch_width);
  1084. /**
  1085. * wlan_mlme_update_bss_rate_flags() - update bss rate flag as per new channel
  1086. * width
  1087. * @psoc: pointer to psoc object
  1088. * @vdev_id: Vdev id
  1089. * @cw: channel width to update
  1090. * @eht_present: connected bss is eht capable or not
  1091. * @he_present: connected bss is he capable or not
  1092. * @vht_present: connected bss is vht capable or not
  1093. * @ht_present: connected bss is ht capable or not
  1094. *
  1095. * Return: QDF_STATUS
  1096. */
  1097. QDF_STATUS wlan_mlme_update_bss_rate_flags(struct wlan_objmgr_psoc *psoc,
  1098. uint8_t vdev_id,
  1099. enum phy_ch_width cw,
  1100. uint8_t eht_present,
  1101. uint8_t he_present,
  1102. uint8_t vht_present,
  1103. uint8_t ht_present);
  1104. #ifdef WLAN_FEATURE_11BE
  1105. /**
  1106. * mlme_update_tgt_eht_caps_in_cfg() - Update tgt eht cap in mlme component
  1107. * @psoc: pointer to psoc object
  1108. * @cfg: pointer to config params from target
  1109. *
  1110. * This api to be used by callers to update EHT caps in mlme.
  1111. *
  1112. * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
  1113. */
  1114. QDF_STATUS mlme_update_tgt_eht_caps_in_cfg(struct wlan_objmgr_psoc *psoc,
  1115. struct wma_tgt_cfg *cfg);
  1116. /**
  1117. * mlme_update_tgt_mlo_caps_in_cfg() - Update tgt MLO cap in mlme component
  1118. * @psoc: pointer to psoc object
  1119. *
  1120. * This api to be used by callers to update MLO caps in mlme.
  1121. *
  1122. * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
  1123. */
  1124. QDF_STATUS mlme_update_tgt_mlo_caps_in_cfg(struct wlan_objmgr_psoc *psoc);
  1125. /**
  1126. * wlan_mlme_convert_eht_op_bw_to_phy_ch_width() - convert channel width in eht
  1127. * operation IE to phy_ch_width
  1128. * @channel_width: channel width in eht operation IE
  1129. *
  1130. * Return: phy_ch_width
  1131. */
  1132. enum phy_ch_width wlan_mlme_convert_eht_op_bw_to_phy_ch_width(
  1133. uint8_t channel_width);
  1134. /**
  1135. * wlan_mlme_convert_phy_ch_width_to_eht_op_bw() - convert channel width to eht
  1136. * operation IE format
  1137. * @ch_width: phy_ch_width
  1138. *
  1139. * Return: channel width in eht operation IE
  1140. */
  1141. uint8_t wlan_mlme_convert_phy_ch_width_to_eht_op_bw(enum phy_ch_width ch_width);
  1142. /**
  1143. * wlan_mlme_get_epcs_capability() - Get mlme epcs capability flag
  1144. * @psoc: psoc object
  1145. *
  1146. * Return: true if epcs capability enabled
  1147. */
  1148. bool wlan_mlme_get_epcs_capability(struct wlan_objmgr_psoc *psoc);
  1149. /**
  1150. * wlan_mlme_set_epcs_capability() - Set mlme epcs capability flag
  1151. * @psoc: psoc object
  1152. * @flag: epcs capability flag
  1153. *
  1154. * Return: void
  1155. */
  1156. void wlan_mlme_set_epcs_capability(struct wlan_objmgr_psoc *psoc, bool flag);
  1157. /**
  1158. * wlan_mlme_get_usr_disable_sta_eht() - Get user disable sta eht flag
  1159. * @psoc: psoc object
  1160. *
  1161. * Return: true if user has disabled eht in connect request
  1162. */
  1163. bool wlan_mlme_get_usr_disable_sta_eht(struct wlan_objmgr_psoc *psoc);
  1164. /**
  1165. * wlan_mlme_set_usr_disable_sta_eht() - Set user disable sta eht flag
  1166. * @psoc: psoc object
  1167. * @disable: eht disable flag
  1168. *
  1169. * Return: void
  1170. */
  1171. void wlan_mlme_set_usr_disable_sta_eht(struct wlan_objmgr_psoc *psoc,
  1172. bool disable);
  1173. #else
  1174. static inline
  1175. bool wlan_mlme_get_epcs_capability(struct wlan_objmgr_psoc *psoc)
  1176. {
  1177. return false;
  1178. }
  1179. static inline
  1180. void wlan_mlme_set_epcs_capability(struct wlan_objmgr_psoc *psoc, bool flag)
  1181. {
  1182. }
  1183. static inline
  1184. bool wlan_mlme_get_usr_disable_sta_eht(struct wlan_objmgr_psoc *psoc)
  1185. {
  1186. return true;
  1187. }
  1188. static inline
  1189. void wlan_mlme_set_usr_disable_sta_eht(struct wlan_objmgr_psoc *psoc,
  1190. bool disable)
  1191. {
  1192. }
  1193. #endif
  1194. /**
  1195. * wlan_mlme_is_ap_prot_enabled() - check if sap protection is enabled
  1196. * @psoc: pointer to psoc object
  1197. *
  1198. * Return: is_ap_prot_enabled flag
  1199. */
  1200. bool wlan_mlme_is_ap_prot_enabled(struct wlan_objmgr_psoc *psoc);
  1201. /**
  1202. * wlan_mlme_get_ap_protection_mode() - Get ap_protection_mode value
  1203. * @psoc: pointer to psoc object
  1204. * @value: pointer to the value which needs to be filled for the caller
  1205. *
  1206. * Return: QDF Status
  1207. */
  1208. QDF_STATUS wlan_mlme_get_ap_protection_mode(struct wlan_objmgr_psoc *psoc,
  1209. uint16_t *value);
  1210. /**
  1211. * wlan_mlme_is_ap_obss_prot_enabled() - Get ap_obss_protection is
  1212. * enabled/disabled
  1213. * @psoc: pointer to psoc object
  1214. * @value: pointer to the value which needs to be filled for the caller
  1215. *
  1216. * Return: QDF Status
  1217. */
  1218. QDF_STATUS wlan_mlme_is_ap_obss_prot_enabled(struct wlan_objmgr_psoc *psoc,
  1219. bool *value);
  1220. /**
  1221. * wlan_mlme_get_rts_threshold() - Get the RTS threshold config
  1222. * @psoc: pointer to psoc object
  1223. * @value: pointer to the value which will be filled for the caller
  1224. *
  1225. * Return: QDF Status
  1226. */
  1227. QDF_STATUS wlan_mlme_get_rts_threshold(struct wlan_objmgr_psoc *psoc,
  1228. uint32_t *value);
  1229. /**
  1230. * wlan_mlme_set_rts_threshold() - Set the RTS threshold config
  1231. * @psoc: pointer to psoc object
  1232. * @value: Value that needs to be set from the caller
  1233. *
  1234. * Return: QDF Status
  1235. */
  1236. QDF_STATUS wlan_mlme_set_rts_threshold(struct wlan_objmgr_psoc *psoc,
  1237. uint32_t value);
  1238. /**
  1239. * wlan_mlme_get_frag_threshold() - Get the Fragmentation threshold
  1240. * config
  1241. * @psoc: pointer to psoc object
  1242. * @value: pointer to the value which will be filled for the caller
  1243. *
  1244. * Return: QDF Status
  1245. */
  1246. QDF_STATUS wlan_mlme_get_frag_threshold(struct wlan_objmgr_psoc *psoc,
  1247. uint32_t *value);
  1248. /**
  1249. * wlan_mlme_set_frag_threshold() - Set the Fragmentation threshold
  1250. * config
  1251. * @psoc: pointer to psoc object
  1252. * @value: Value that needs to be set from the caller
  1253. *
  1254. * Return: QDF Status
  1255. */
  1256. QDF_STATUS wlan_mlme_set_frag_threshold(struct wlan_objmgr_psoc *psoc,
  1257. uint32_t value);
  1258. /**
  1259. * wlan_mlme_get_fils_enabled_info() - Get the fils enable info for driver
  1260. * @psoc: pointer to psoc object
  1261. * @value: pointer to the value which will be filled for the caller
  1262. *
  1263. * Return: QDF Status
  1264. */
  1265. QDF_STATUS wlan_mlme_get_fils_enabled_info(struct wlan_objmgr_psoc *psoc,
  1266. bool *value);
  1267. /**
  1268. * wlan_mlme_set_fils_enabled_info() - Set the fils enable info for driver
  1269. * @psoc: pointer to psoc object
  1270. * @value: value that needs to be set from the caller
  1271. *
  1272. * Return: QDF Status
  1273. */
  1274. QDF_STATUS wlan_mlme_set_fils_enabled_info(struct wlan_objmgr_psoc *psoc,
  1275. bool value);
  1276. /**
  1277. * wlan_mlme_set_primary_interface() - Set the primary iface id for driver
  1278. * @psoc: pointer to psoc object
  1279. * @value: value that needs to be set from the caller
  1280. *
  1281. * When a vdev is set as primary then based on the dual sta policy
  1282. * "qca_wlan_concurrent_sta_policy_config" mcc preference and roaming has
  1283. * to be enabled on the primary vdev
  1284. *
  1285. * Return: QDF Status
  1286. */
  1287. QDF_STATUS wlan_mlme_set_primary_interface(struct wlan_objmgr_psoc *psoc,
  1288. uint8_t value);
  1289. /**
  1290. * wlan_mlme_set_default_primary_iface() - Set the default primary iface id
  1291. * for driver
  1292. * @psoc: pointer to psoc object
  1293. *
  1294. * Return: QDF Status
  1295. */
  1296. QDF_STATUS wlan_mlme_set_default_primary_iface(struct wlan_objmgr_psoc *psoc);
  1297. /**
  1298. * wlan_mlme_is_primary_interface_configured() - Check if primary iface is set
  1299. * @psoc: pointer to psoc object
  1300. *
  1301. * Check if primary iface is configured from userspace through vendor command.
  1302. * Return true if it's configured. If it's not configured, default value would
  1303. * be 0xFF and return false then.
  1304. *
  1305. * Return: True or False
  1306. */
  1307. bool wlan_mlme_is_primary_interface_configured(struct wlan_objmgr_psoc *psoc);
  1308. /**
  1309. * wlan_mlme_peer_get_assoc_rsp_ies() - Get the assoc response IEs of peer
  1310. * @peer: WLAN peer objmgr
  1311. * @ie_buf: Pointer to IE buffer
  1312. * @ie_len: Length of the IE buffer
  1313. *
  1314. * Get the pointer to assoc response IEs of the peer from MLME
  1315. * and length of the IE buffer.
  1316. *
  1317. * Return: QDF_STATUS
  1318. */
  1319. QDF_STATUS wlan_mlme_peer_get_assoc_rsp_ies(struct wlan_objmgr_peer *peer,
  1320. const uint8_t **ie_buf,
  1321. size_t *ie_len);
  1322. /**
  1323. * wlan_mlme_get_mcc_duty_cycle_percentage() - Get primary STA iface duty
  1324. * cycle percentage
  1325. * @pdev: pointer to pdev object
  1326. *
  1327. * API to get the MCC duty cycle for primary and secondary STA's
  1328. *
  1329. * Return: primary iface quota on success
  1330. */
  1331. int wlan_mlme_get_mcc_duty_cycle_percentage(struct wlan_objmgr_pdev *pdev);
  1332. /**
  1333. * wlan_mlme_get_tl_delayed_trgr_frm_int() - Get delay interval(in ms)
  1334. * of UAPSD auto trigger
  1335. * @psoc: pointer to psoc object
  1336. * @value: Value that needs to be set from the caller
  1337. *
  1338. * Return: None
  1339. */
  1340. void wlan_mlme_get_tl_delayed_trgr_frm_int(struct wlan_objmgr_psoc *psoc,
  1341. uint32_t *value);
  1342. /**
  1343. * wlan_mlme_get_wmm_dir_ac_vi() - Get TSPEC direction
  1344. * for VI
  1345. * @psoc: pointer to psoc object
  1346. * @value: Value that needs to be set from the caller
  1347. *
  1348. * Return: QDF Status
  1349. */
  1350. QDF_STATUS
  1351. wlan_mlme_get_wmm_dir_ac_vi(struct wlan_objmgr_psoc *psoc, uint8_t *value);
  1352. /**
  1353. * wlan_mlme_get_wmm_nom_msdu_size_ac_vi() - Get normal
  1354. * MSDU size for VI
  1355. * @psoc: pointer to psoc object
  1356. * @value: Value that needs to be set from the caller
  1357. *
  1358. * Return: QDF Status
  1359. */
  1360. QDF_STATUS wlan_mlme_get_wmm_nom_msdu_size_ac_vi(struct wlan_objmgr_psoc *psoc,
  1361. uint16_t *value);
  1362. /**
  1363. * wlan_mlme_get_wmm_mean_data_rate_ac_vi() - mean data
  1364. * rate for VI
  1365. * @psoc: pointer to psoc object
  1366. * @value: Value that needs to be set from the caller
  1367. *
  1368. * Return: QDF Status
  1369. */
  1370. QDF_STATUS
  1371. wlan_mlme_get_wmm_mean_data_rate_ac_vi(struct wlan_objmgr_psoc *psoc,
  1372. uint32_t *value);
  1373. /**
  1374. * wlan_mlme_get_wmm_min_phy_rate_ac_vi() - min PHY
  1375. * rate for VI
  1376. * @psoc: pointer to psoc object
  1377. * @value: Value that needs to be set from the caller
  1378. *
  1379. * Return: QDF Status
  1380. */
  1381. QDF_STATUS wlan_mlme_get_wmm_min_phy_rate_ac_vi(struct wlan_objmgr_psoc *psoc,
  1382. uint32_t *value);
  1383. /**
  1384. * wlan_mlme_get_wmm_sba_ac_vi() - surplus bandwidth
  1385. * allowance for VI
  1386. * @psoc: pointer to psoc object
  1387. * @value: Value that needs to be set from the caller
  1388. *
  1389. * Return: QDF Status
  1390. */
  1391. QDF_STATUS
  1392. wlan_mlme_get_wmm_sba_ac_vi(struct wlan_objmgr_psoc *psoc, uint16_t *value);
  1393. /**
  1394. * wlan_mlme_get_wmm_uapsd_vi_srv_intv() - Get Uapsd service
  1395. * interval for video
  1396. * @psoc: pointer to psoc object
  1397. * @value: pointer to the value which will be filled for the caller
  1398. *
  1399. * Return: QDF Status
  1400. */
  1401. QDF_STATUS
  1402. wlan_mlme_get_wmm_uapsd_vi_srv_intv(struct wlan_objmgr_psoc *psoc,
  1403. uint32_t *value);
  1404. /**
  1405. * wlan_mlme_get_wmm_uapsd_vi_sus_intv() - Get Uapsd suspension
  1406. * interval for video
  1407. * @psoc: pointer to psoc object
  1408. * @value: pointer to the value which will be filled for the caller
  1409. *
  1410. * Return: QDF Status
  1411. */
  1412. QDF_STATUS
  1413. wlan_mlme_get_wmm_uapsd_vi_sus_intv(struct wlan_objmgr_psoc *psoc,
  1414. uint32_t *value);
  1415. /**
  1416. * wlan_mlme_get_wmm_dir_ac_be() - Get TSPEC direction
  1417. * for BE
  1418. * @psoc: pointer to psoc object
  1419. * @value: Value that needs to be set from the caller
  1420. *
  1421. * Return: QDF Status
  1422. */
  1423. QDF_STATUS
  1424. wlan_mlme_get_wmm_dir_ac_be(struct wlan_objmgr_psoc *psoc,
  1425. uint8_t *value);
  1426. /**
  1427. * wlan_mlme_get_wmm_nom_msdu_size_ac_be() - Get normal
  1428. * MSDU size for BE
  1429. * @psoc: pointer to psoc object
  1430. * @value: Value that needs to be set from the caller
  1431. *
  1432. * Return: QDF Status
  1433. */
  1434. QDF_STATUS wlan_mlme_get_wmm_nom_msdu_size_ac_be(struct wlan_objmgr_psoc *psoc,
  1435. uint16_t *value);
  1436. /**
  1437. * wlan_mlme_get_wmm_mean_data_rate_ac_be() - mean data
  1438. * rate for BE
  1439. * @psoc: pointer to psoc object
  1440. * @value: Value that needs to be set from the caller
  1441. *
  1442. * Return: QDF Status
  1443. */
  1444. QDF_STATUS wlan_mlme_get_wmm_mean_data_rate_ac_be(struct wlan_objmgr_psoc *psoc,
  1445. uint32_t *value);
  1446. /**
  1447. * wlan_mlme_get_wmm_min_phy_rate_ac_be() - min PHY
  1448. * rate for BE
  1449. * @psoc: pointer to psoc object
  1450. * @value: Value that needs to be set from the caller
  1451. *
  1452. * Return: QDF Status
  1453. */
  1454. QDF_STATUS wlan_mlme_get_wmm_min_phy_rate_ac_be(struct wlan_objmgr_psoc *psoc,
  1455. uint32_t *value);
  1456. /**
  1457. * wlan_mlme_get_wmm_sba_ac_be() - surplus bandwidth
  1458. * allowance for BE
  1459. * @psoc: pointer to psoc object
  1460. * @value: Value that needs to be set from the caller
  1461. *
  1462. * Return: QDF Status
  1463. */
  1464. QDF_STATUS
  1465. wlan_mlme_get_wmm_sba_ac_be(struct wlan_objmgr_psoc *psoc, uint16_t *value);
  1466. /**
  1467. * wlan_mlme_get_wmm_uapsd_be_srv_intv() - Get Uapsd service
  1468. * interval for BE
  1469. * @psoc: pointer to psoc object
  1470. * @value: pointer to the value which will be filled for the caller
  1471. *
  1472. * Return: QDF Status
  1473. */
  1474. QDF_STATUS
  1475. wlan_mlme_get_wmm_uapsd_be_srv_intv(struct wlan_objmgr_psoc *psoc,
  1476. uint32_t *value);
  1477. /**
  1478. * wlan_mlme_get_wmm_uapsd_be_sus_intv() - Get Uapsd suspension
  1479. * interval for BE
  1480. * @psoc: pointer to psoc object
  1481. * @value: pointer to the value which will be filled for the caller
  1482. *
  1483. * Return: QDF Status
  1484. */
  1485. QDF_STATUS
  1486. wlan_mlme_get_wmm_uapsd_be_sus_intv(struct wlan_objmgr_psoc *psoc,
  1487. uint32_t *value);
  1488. /**
  1489. * wlan_mlme_get_wmm_dir_ac_bk() - Get TSPEC direction
  1490. * for BK
  1491. * @psoc: pointer to psoc object
  1492. * @value: Value that needs to be set from the caller
  1493. *
  1494. * Return: QDF Status
  1495. */
  1496. QDF_STATUS
  1497. wlan_mlme_get_wmm_dir_ac_bk(struct wlan_objmgr_psoc *psoc, uint8_t *value);
  1498. /**
  1499. * wlan_mlme_get_wmm_nom_msdu_size_ac_bk() - Get normal
  1500. * MSDU size for BK
  1501. * @psoc: pointer to psoc object
  1502. * @value: Value that needs to be set from the caller
  1503. *
  1504. * Return: QDF Status
  1505. */
  1506. QDF_STATUS wlan_mlme_get_wmm_nom_msdu_size_ac_bk(struct wlan_objmgr_psoc *psoc,
  1507. uint16_t *value);
  1508. /**
  1509. * wlan_mlme_get_wmm_mean_data_rate_ac_bk() - mean data
  1510. * rate for BK
  1511. * @psoc: pointer to psoc object
  1512. * @value: Value that needs to be set from the caller
  1513. *
  1514. * Return: QDF Status
  1515. */
  1516. QDF_STATUS wlan_mlme_get_wmm_mean_data_rate_ac_bk(struct wlan_objmgr_psoc *psoc,
  1517. uint32_t *value);
  1518. /**
  1519. * wlan_mlme_get_wmm_min_phy_rate_ac_bk() - min PHY
  1520. * rate for BK
  1521. * @psoc: pointer to psoc object
  1522. * @value: Value that needs to be set from the caller
  1523. *
  1524. * Return: QDF Status
  1525. */
  1526. QDF_STATUS wlan_mlme_get_wmm_min_phy_rate_ac_bk(struct wlan_objmgr_psoc *psoc,
  1527. uint32_t *value);
  1528. /**
  1529. * wlan_mlme_get_wmm_sba_ac_bk() - surplus bandwidth
  1530. * allowance for BE
  1531. * @psoc: pointer to psoc object
  1532. * @value: Value that needs to be set from the caller
  1533. *
  1534. * Return: QDF Status
  1535. */
  1536. QDF_STATUS
  1537. wlan_mlme_get_wmm_sba_ac_bk(struct wlan_objmgr_psoc *psoc, uint16_t *value);
  1538. /**
  1539. * wlan_mlme_get_wmm_uapsd_bk_srv_intv() - Get Uapsd service
  1540. * interval for BK
  1541. * @psoc: pointer to psoc object
  1542. * @value: pointer to the value which will be filled for the caller
  1543. *
  1544. * Return: QDF Status
  1545. */
  1546. QDF_STATUS
  1547. wlan_mlme_get_wmm_uapsd_bk_srv_intv(struct wlan_objmgr_psoc *psoc,
  1548. uint32_t *value);
  1549. /**
  1550. * wlan_mlme_get_wmm_uapsd_bk_sus_intv() - Get Uapsd suspension
  1551. * interval for BK
  1552. * @psoc: pointer to psoc object
  1553. * @value: pointer to the value which will be filled for the caller
  1554. *
  1555. * Return: QDF Status
  1556. */
  1557. QDF_STATUS
  1558. wlan_mlme_get_wmm_uapsd_bk_sus_intv(struct wlan_objmgr_psoc *psoc,
  1559. uint32_t *value);
  1560. /**
  1561. * wlan_mlme_get_wmm_mode() - Enable WMM feature
  1562. * @psoc: pointer to psoc object
  1563. * @value: pointer to the value which will be filled for the caller
  1564. *
  1565. * Return: QDF Status
  1566. */
  1567. QDF_STATUS
  1568. wlan_mlme_get_wmm_mode(struct wlan_objmgr_psoc *psoc, uint8_t *value);
  1569. /**
  1570. * wlan_mlme_get_80211e_is_enabled() - Enable 802.11e feature
  1571. * @psoc: pointer to psoc object
  1572. * @value: pointer to the value which will be filled for the caller
  1573. *
  1574. * Return: QDF Status
  1575. */
  1576. QDF_STATUS
  1577. wlan_mlme_get_80211e_is_enabled(struct wlan_objmgr_psoc *psoc, bool *value);
  1578. /**
  1579. * wlan_mlme_get_wmm_uapsd_mask() - setup U-APSD mask for ACs
  1580. * @psoc: pointer to psoc object
  1581. * @value: pointer to the value which will be filled for the caller
  1582. *
  1583. * Return: QDF Status
  1584. */
  1585. QDF_STATUS
  1586. wlan_mlme_get_wmm_uapsd_mask(struct wlan_objmgr_psoc *psoc, uint8_t *value);
  1587. #ifdef FEATURE_WLAN_ESE
  1588. /**
  1589. * wlan_mlme_get_inactivity_interval() - Infra Inactivity Interval
  1590. * @psoc: pointer to psoc object
  1591. * @value: pointer to the value which will be filled for the caller
  1592. *
  1593. * Return: None
  1594. */
  1595. void
  1596. wlan_mlme_get_inactivity_interval(struct wlan_objmgr_psoc *psoc,
  1597. uint32_t *value);
  1598. #endif
  1599. /**
  1600. * wlan_mlme_get_is_ts_burst_size_enable() - Get TS burst size flag
  1601. * @psoc: pointer to psoc object
  1602. * @value: pointer to the value which will be filled for the caller
  1603. *
  1604. * Return: None
  1605. */
  1606. void wlan_mlme_get_is_ts_burst_size_enable(struct wlan_objmgr_psoc *psoc,
  1607. bool *value);
  1608. /**
  1609. * wlan_mlme_get_ts_info_ack_policy() - Get TS ack policy
  1610. * @psoc: pointer to psoc object
  1611. * @value: pointer to the value which will be filled for the caller
  1612. *
  1613. * Return: None
  1614. */
  1615. void wlan_mlme_get_ts_info_ack_policy(struct wlan_objmgr_psoc *psoc,
  1616. enum mlme_ts_info_ack_policy *value);
  1617. /**
  1618. * wlan_mlme_get_ts_acm_value_for_ac() - Get ACM value for AC
  1619. * @psoc: pointer to psoc object
  1620. * @value: pointer to the value which will be filled for the caller
  1621. *
  1622. * Return: QDF Status
  1623. */
  1624. QDF_STATUS
  1625. wlan_mlme_get_ts_acm_value_for_ac(struct wlan_objmgr_psoc *psoc, bool *value);
  1626. /**
  1627. * wlan_mlme_get_wmm_dir_ac_vo() - Get TSPEC direction
  1628. * for VO
  1629. * @psoc: pointer to psoc object
  1630. * @value: Value that needs to be set from the caller
  1631. *
  1632. * Return: QDF Status
  1633. */
  1634. QDF_STATUS
  1635. wlan_mlme_get_wmm_dir_ac_vo(struct wlan_objmgr_psoc *psoc, uint8_t *value);
  1636. /**
  1637. * wlan_mlme_get_wmm_nom_msdu_size_ac_vo() - Get normal
  1638. * MSDU size for VO
  1639. * @psoc: pointer to psoc object
  1640. * @value: Value that needs to be set from the caller
  1641. *
  1642. * Return: QDF Status
  1643. */
  1644. QDF_STATUS wlan_mlme_get_wmm_nom_msdu_size_ac_vo(struct wlan_objmgr_psoc *psoc,
  1645. uint16_t *value);
  1646. /**
  1647. * wlan_mlme_get_wmm_mean_data_rate_ac_vo() - mean data rate for VO
  1648. * @psoc: pointer to psoc object
  1649. * @value: Value that needs to be set from the caller
  1650. *
  1651. * Return: QDF Status
  1652. */
  1653. QDF_STATUS wlan_mlme_get_wmm_mean_data_rate_ac_vo(struct wlan_objmgr_psoc *psoc,
  1654. uint32_t *value);
  1655. /**
  1656. * wlan_mlme_get_wmm_min_phy_rate_ac_vo() - min PHY
  1657. * rate for VO
  1658. * @psoc: pointer to psoc object
  1659. * @value: Value that needs to be set from the caller
  1660. *
  1661. * Return: QDF Status
  1662. */
  1663. QDF_STATUS wlan_mlme_get_wmm_min_phy_rate_ac_vo(struct wlan_objmgr_psoc *psoc,
  1664. uint32_t *value);
  1665. /**
  1666. * wlan_mlme_get_wmm_sba_ac_vo() - surplus bandwidth allowance for VO
  1667. * @psoc: pointer to psoc object
  1668. * @value: Value that needs to be set from the caller
  1669. *
  1670. * Return: QDF Status
  1671. */
  1672. QDF_STATUS
  1673. wlan_mlme_get_wmm_sba_ac_vo(struct wlan_objmgr_psoc *psoc, uint16_t *value);
  1674. /**
  1675. * wlan_mlme_set_enable_bcast_probe_rsp() - Set enable bcast probe resp info
  1676. * @psoc: pointer to psoc object
  1677. * @value: value that needs to be set from the caller
  1678. *
  1679. * Return: QDF Status
  1680. */
  1681. QDF_STATUS wlan_mlme_set_enable_bcast_probe_rsp(struct wlan_objmgr_psoc *psoc,
  1682. bool value);
  1683. /**
  1684. * wlan_mlme_get_wmm_uapsd_vo_srv_intv() - Get Uapsd service
  1685. * interval for voice
  1686. * @psoc: pointer to psoc object
  1687. * @value: pointer to the value which will be filled for the caller
  1688. *
  1689. * Return: QDF Status
  1690. */
  1691. QDF_STATUS
  1692. wlan_mlme_get_wmm_uapsd_vo_srv_intv(struct wlan_objmgr_psoc *psoc,
  1693. uint32_t *value);
  1694. /**
  1695. * wlan_mlme_get_wmm_uapsd_vo_sus_intv() - Get Uapsd suspension
  1696. * interval for voice
  1697. * @psoc: pointer to psoc object
  1698. * @value: pointer to the value which will be filled for the caller
  1699. *
  1700. * Return: QDF Status
  1701. */
  1702. QDF_STATUS
  1703. wlan_mlme_get_wmm_uapsd_vo_sus_intv(struct wlan_objmgr_psoc *psoc,
  1704. uint32_t *value);
  1705. /**
  1706. * wlan_mlme_cfg_get_vht_max_mpdu_len() - gets vht max mpdu length from cfg item
  1707. * @psoc: psoc context
  1708. * @value: pointer to get required data
  1709. *
  1710. * Return: QDF_STATUS
  1711. */
  1712. QDF_STATUS
  1713. wlan_mlme_cfg_get_vht_max_mpdu_len(struct wlan_objmgr_psoc *psoc,
  1714. uint8_t *value);
  1715. /**
  1716. * wlan_mlme_cfg_set_vht_max_mpdu_len() - sets vht max mpdu length into cfg item
  1717. * @psoc: psoc context
  1718. * @value: data to be set
  1719. *
  1720. * Return: QDF_STATUS
  1721. */
  1722. QDF_STATUS
  1723. wlan_mlme_cfg_set_vht_max_mpdu_len(struct wlan_objmgr_psoc *psoc,
  1724. uint8_t value);
  1725. /**
  1726. * wlan_mlme_cfg_get_ht_smps() - gets HT SM Power Save mode from cfg item
  1727. * @psoc: psoc context
  1728. * @value: data to be set
  1729. *
  1730. * Return: QDF_STATUS
  1731. */
  1732. QDF_STATUS wlan_mlme_cfg_get_ht_smps(struct wlan_objmgr_psoc *psoc,
  1733. uint8_t *value);
  1734. /**
  1735. * wlan_mlme_cfg_get_vht_chan_width() - gets vht supported channel width from
  1736. * cfg item
  1737. * @psoc: psoc context
  1738. * @value: pointer to get required data
  1739. *
  1740. * Return: QDF_STATUS
  1741. */
  1742. QDF_STATUS wlan_mlme_cfg_get_vht_chan_width(struct wlan_objmgr_psoc *psoc,
  1743. uint8_t *value);
  1744. /**
  1745. * wlan_mlme_cfg_set_vht_chan_width() - sets vht supported channel width into
  1746. * cfg item
  1747. * @psoc: psoc context
  1748. * @value: data to be set
  1749. *
  1750. * Return: QDF_STATUS
  1751. */
  1752. QDF_STATUS wlan_mlme_cfg_set_vht_chan_width(struct wlan_objmgr_psoc *psoc,
  1753. uint8_t value);
  1754. /**
  1755. * wlan_mlme_cfg_get_vht_chan_width() - sets vht supported channel width into
  1756. * cfg item
  1757. * @psoc: psoc context
  1758. * @value: data to be set
  1759. *
  1760. * Return: QDF_STATUS
  1761. */
  1762. QDF_STATUS wlan_mlme_cfg_get_vht_chan_width(struct wlan_objmgr_psoc *psoc,
  1763. uint8_t *value);
  1764. /**
  1765. * wlan_mlme_cfg_get_vht_ldpc_coding_cap() - gets vht ldpc coding cap from
  1766. * cfg item
  1767. * @psoc: psoc context
  1768. * @value: pointer to get required data
  1769. *
  1770. * Return: QDF_STATUS
  1771. */
  1772. QDF_STATUS wlan_mlme_cfg_get_vht_ldpc_coding_cap(struct wlan_objmgr_psoc *psoc,
  1773. bool *value);
  1774. /**
  1775. * wlan_mlme_cfg_set_vht_ldpc_coding_cap() - sets vht ldpc coding cap into
  1776. * cfg item
  1777. * @psoc: psoc context
  1778. * @value: data to be set
  1779. *
  1780. * Return: QDF_STATUS
  1781. */
  1782. QDF_STATUS wlan_mlme_cfg_set_vht_ldpc_coding_cap(struct wlan_objmgr_psoc *psoc,
  1783. bool value);
  1784. /**
  1785. * wlan_mlme_cfg_get_vht_short_gi_80mhz() - gets vht short gi 80MHz from
  1786. * cfg item
  1787. * @psoc: psoc context
  1788. * @value: pointer to get required data
  1789. *
  1790. * Return: QDF_STATUS
  1791. */
  1792. QDF_STATUS wlan_mlme_cfg_get_vht_short_gi_80mhz(struct wlan_objmgr_psoc *psoc,
  1793. bool *value);
  1794. /**
  1795. * wlan_mlme_cfg_set_vht_short_gi_80mhz() - sets vht short gi 80MHz into
  1796. * cfg item
  1797. * @psoc: psoc context
  1798. * @value: data to be set
  1799. *
  1800. * Return: QDF_STATUS
  1801. */
  1802. QDF_STATUS wlan_mlme_cfg_set_vht_short_gi_80mhz(struct wlan_objmgr_psoc *psoc,
  1803. bool value);
  1804. /**
  1805. * wlan_mlme_cfg_get_short_gi_160_mhz() - gets vht short gi 160MHz from
  1806. * cfg item
  1807. * @psoc: psoc context
  1808. * @value: pointer to get required data
  1809. *
  1810. * Return: QDF_STATUS
  1811. */
  1812. QDF_STATUS
  1813. wlan_mlme_cfg_get_short_gi_160_mhz(struct wlan_objmgr_psoc *psoc, bool *value);
  1814. /**
  1815. * wlan_mlme_cfg_set_short_gi_160_mhz() - sets vht short gi 160MHz into
  1816. * cfg item
  1817. * @psoc: psoc context
  1818. * @value: data to be set
  1819. *
  1820. * Return: QDF_STATUS
  1821. */
  1822. QDF_STATUS
  1823. wlan_mlme_cfg_set_short_gi_160_mhz(struct wlan_objmgr_psoc *psoc, bool value);
  1824. /**
  1825. * wlan_mlme_cfg_get_vht_tx_stbc() - gets vht tx stbc from
  1826. * cfg item
  1827. * @psoc: psoc context
  1828. * @value: pointer to get required data
  1829. *
  1830. * Return: QDF_STATUS
  1831. */
  1832. QDF_STATUS
  1833. wlan_mlme_cfg_get_vht_tx_stbc(struct wlan_objmgr_psoc *psoc, bool *value);
  1834. /**
  1835. * wlan_mlme_cfg_get_vht_rx_stbc() - gets vht rx stbc from
  1836. * cfg item
  1837. * @psoc: psoc context
  1838. * @value: pointer to get required data
  1839. *
  1840. * Return: QDF_STATUS
  1841. */
  1842. QDF_STATUS
  1843. wlan_mlme_cfg_get_vht_rx_stbc(struct wlan_objmgr_psoc *psoc, bool *value);
  1844. /**
  1845. * wlan_mlme_cfg_set_vht_tx_stbc() - sets vht tx stbc into
  1846. * cfg item
  1847. * @psoc: psoc context
  1848. * @value: data to be set
  1849. *
  1850. * Return: QDF_STATUS
  1851. */
  1852. QDF_STATUS
  1853. wlan_mlme_cfg_set_vht_tx_stbc(struct wlan_objmgr_psoc *psoc, bool value);
  1854. /**
  1855. * wlan_mlme_cfg_get_vht_rx_stbc() - gets vht rx stbc from
  1856. * cfg item
  1857. * @psoc: psoc context
  1858. * @value: pointer to get required data
  1859. *
  1860. * Return: QDF_STATUS
  1861. */
  1862. QDF_STATUS
  1863. wlan_mlme_cfg_get_vht_rx_stbc(struct wlan_objmgr_psoc *psoc, bool *value);
  1864. /**
  1865. * wlan_mlme_cfg_set_vht_rx_stbc() - sets vht rx stbc into
  1866. * cfg item
  1867. * @psoc: psoc context
  1868. * @value: data to be set
  1869. *
  1870. * Return: QDF_STATUS
  1871. */
  1872. QDF_STATUS
  1873. wlan_mlme_cfg_set_vht_rx_stbc(struct wlan_objmgr_psoc *psoc, bool value);
  1874. /**
  1875. * wlan_mlme_cfg_get_vht_su_bformer() - gets vht su beam former cap from
  1876. * cfg item
  1877. * @psoc: psoc context
  1878. * @value: pointer to get required data
  1879. *
  1880. * Return: QDF_STATUS
  1881. */
  1882. QDF_STATUS
  1883. wlan_mlme_cfg_get_vht_su_bformer(struct wlan_objmgr_psoc *psoc, bool *value);
  1884. /**
  1885. * wlan_mlme_cfg_set_vht_su_bformer() - sets vht su beam former cap into
  1886. * cfg item
  1887. * @psoc: psoc context
  1888. * @value: data to be set
  1889. *
  1890. * Return: QDF_STATUS
  1891. */
  1892. QDF_STATUS
  1893. wlan_mlme_cfg_set_vht_su_bformer(struct wlan_objmgr_psoc *psoc, bool value);
  1894. /**
  1895. * wlan_mlme_cfg_set_vht_su_bformee() - sets vht su beam formee cap into
  1896. * cfg item
  1897. * @psoc: psoc context
  1898. * @value: data to be set
  1899. *
  1900. * Return: QDF_STATUS
  1901. */
  1902. QDF_STATUS
  1903. wlan_mlme_cfg_set_vht_su_bformee(struct wlan_objmgr_psoc *psoc, bool value);
  1904. /**
  1905. * wlan_mlme_cfg_set_vht_tx_bfee_ant_supp() - sets vht Beamformee antenna
  1906. * support cap
  1907. * into cfg item
  1908. * @psoc: psoc context
  1909. * @value: data to be set
  1910. *
  1911. * Return: QDF_STATUS
  1912. */
  1913. QDF_STATUS wlan_mlme_cfg_set_vht_tx_bfee_ant_supp(struct wlan_objmgr_psoc *psoc,
  1914. uint8_t value);
  1915. /**
  1916. * wlan_mlme_cfg_get_vht_tx_bfee_ant_supp() - Gets vht Beamformee antenna
  1917. * support cap into cfg item
  1918. *
  1919. * @psoc: psoc context
  1920. * @value: data to be set
  1921. *
  1922. * Return: QDF_STATUS
  1923. */
  1924. QDF_STATUS wlan_mlme_cfg_get_vht_tx_bfee_ant_supp(struct wlan_objmgr_psoc *psoc,
  1925. uint8_t *value);
  1926. /**
  1927. * wlan_mlme_cfg_set_vht_num_sounding_dim() - sets vht no of sounding dimensions
  1928. * into cfg item
  1929. * @psoc: psoc context
  1930. * @value: data to be set
  1931. *
  1932. * Return: QDF_STATUS
  1933. */
  1934. QDF_STATUS wlan_mlme_cfg_set_vht_num_sounding_dim(struct wlan_objmgr_psoc *psoc,
  1935. uint8_t value);
  1936. /**
  1937. * wlan_mlme_cfg_get_vht_mu_bformer() - gets vht mu beam former cap from
  1938. * cfg item
  1939. * @psoc: psoc context
  1940. * @value: pointer to get required data
  1941. *
  1942. * Return: QDF_STATUS
  1943. */
  1944. QDF_STATUS
  1945. wlan_mlme_cfg_get_vht_mu_bformer(struct wlan_objmgr_psoc *psoc, bool *value);
  1946. /**
  1947. * wlan_mlme_cfg_set_vht_mu_bformer() - sets vht mu beam former cap into
  1948. * cfg item
  1949. * @psoc: psoc context
  1950. * @value: data to be set
  1951. *
  1952. * Return: QDF_STATUS
  1953. */
  1954. QDF_STATUS
  1955. wlan_mlme_cfg_set_vht_mu_bformer(struct wlan_objmgr_psoc *psoc, bool value);
  1956. /**
  1957. * wlan_mlme_cfg_get_vht_mu_bformee() - gets vht mu beam formee cap from
  1958. * cfg item
  1959. * @psoc: psoc context
  1960. * @value: pointer to get required data
  1961. *
  1962. * Return: QDF_STATUS
  1963. */
  1964. QDF_STATUS
  1965. wlan_mlme_cfg_get_vht_mu_bformee(struct wlan_objmgr_psoc *psoc, bool *value);
  1966. /**
  1967. * wlan_mlme_cfg_set_vht_mu_bformee() - sets vht mu beam formee cap into
  1968. * cfg item
  1969. * @psoc: psoc context
  1970. * @value: data to be set
  1971. *
  1972. * Return: QDF_STATUS
  1973. */
  1974. QDF_STATUS
  1975. wlan_mlme_cfg_set_vht_mu_bformee(struct wlan_objmgr_psoc *psoc, bool value);
  1976. /**
  1977. * wlan_mlme_cfg_get_vht_txop_ps() - gets vht tx ops ps cap from
  1978. * cfg item
  1979. * @psoc: psoc context
  1980. * @value: pointer to get required data
  1981. *
  1982. * Return: QDF_STATUS
  1983. */
  1984. QDF_STATUS
  1985. wlan_mlme_cfg_get_vht_txop_ps(struct wlan_objmgr_psoc *psoc, bool *value);
  1986. /**
  1987. * wlan_mlme_cfg_set_vht_txop_ps() - sets vht tx ops ps cap into
  1988. * cfg item
  1989. * @psoc: psoc context
  1990. * @value: data to be set
  1991. *
  1992. * Return: QDF_STATUS
  1993. */
  1994. QDF_STATUS
  1995. wlan_mlme_cfg_set_vht_txop_ps(struct wlan_objmgr_psoc *psoc, bool value);
  1996. /**
  1997. * wlan_mlme_cfg_get_vht_ampdu_len_exp() - gets vht max AMPDU length exponent from
  1998. * cfg item
  1999. * @psoc: psoc context
  2000. * @value: pointer to get required data
  2001. *
  2002. * Return: QDF_STATUS
  2003. */
  2004. QDF_STATUS
  2005. wlan_mlme_cfg_get_vht_ampdu_len_exp(struct wlan_objmgr_psoc *psoc,
  2006. uint8_t *value);
  2007. /**
  2008. * wlan_mlme_cfg_set_vht_ampdu_len_exp() - sets vht max AMPDU length exponent into
  2009. * cfg item
  2010. * @psoc: psoc context
  2011. * @value: data to be set
  2012. *
  2013. * Return: QDF_STATUS
  2014. */
  2015. QDF_STATUS
  2016. wlan_mlme_cfg_set_vht_ampdu_len_exp(struct wlan_objmgr_psoc *psoc,
  2017. uint8_t value);
  2018. /**
  2019. * wlan_mlme_cfg_get_vht_rx_mcs_map() - gets vht rx mcs map from
  2020. * cfg item
  2021. * @psoc: psoc context
  2022. * @value: pointer to get required data
  2023. *
  2024. * Return: QDF_STATUS
  2025. */
  2026. QDF_STATUS wlan_mlme_cfg_get_vht_rx_mcs_map(struct wlan_objmgr_psoc *psoc,
  2027. uint32_t *value);
  2028. /**
  2029. * wlan_mlme_cfg_set_vht_rx_mcs_map() - sets rx mcs map into
  2030. * cfg item
  2031. * @psoc: psoc context
  2032. * @value: data to be set
  2033. *
  2034. * Return: QDF_STATUS
  2035. */
  2036. QDF_STATUS
  2037. wlan_mlme_cfg_set_vht_rx_mcs_map(struct wlan_objmgr_psoc *psoc, uint32_t value);
  2038. /**
  2039. * wlan_mlme_cfg_get_vht_tx_mcs_map() - gets vht tx mcs map from
  2040. * cfg item
  2041. * @psoc: psoc context
  2042. * @value: pointer to get required data
  2043. *
  2044. * Return: QDF_STATUS
  2045. */
  2046. QDF_STATUS wlan_mlme_cfg_get_vht_tx_mcs_map(struct wlan_objmgr_psoc *psoc,
  2047. uint32_t *value);
  2048. /**
  2049. * wlan_mlme_cfg_set_vht_tx_mcs_map() - sets tx mcs map into
  2050. * cfg item
  2051. * @psoc: psoc context
  2052. * @value: data to be set
  2053. *
  2054. * Return: QDF_STATUS
  2055. */
  2056. QDF_STATUS wlan_mlme_cfg_set_vht_tx_mcs_map(struct wlan_objmgr_psoc *psoc,
  2057. uint32_t value);
  2058. /**
  2059. * wlan_mlme_cfg_set_vht_rx_supp_data_rate() - sets rx supported data rate into
  2060. * cfg item
  2061. * @psoc: psoc context
  2062. * @value: data to be set
  2063. *
  2064. * Return: QDF_STATUS
  2065. */
  2066. QDF_STATUS
  2067. wlan_mlme_cfg_set_vht_rx_supp_data_rate(struct wlan_objmgr_psoc *psoc,
  2068. uint32_t value);
  2069. /**
  2070. * wlan_mlme_cfg_set_vht_tx_supp_data_rate() - sets tx supported data rate into
  2071. * cfg item
  2072. * @psoc: psoc context
  2073. * @value: data to be set
  2074. *
  2075. * Return: QDF_STATUS
  2076. */
  2077. QDF_STATUS
  2078. wlan_mlme_cfg_set_vht_tx_supp_data_rate(struct wlan_objmgr_psoc *psoc,
  2079. uint32_t value);
  2080. /**
  2081. * wlan_mlme_cfg_get_vht_basic_mcs_set() - gets basic mcs set from
  2082. * cfg item
  2083. * @psoc: psoc context
  2084. * @value: data to be set
  2085. *
  2086. * Return: QDF_STATUS
  2087. */
  2088. QDF_STATUS
  2089. wlan_mlme_cfg_get_vht_basic_mcs_set(struct wlan_objmgr_psoc *psoc,
  2090. uint32_t *value);
  2091. /**
  2092. * wlan_mlme_cfg_set_vht_basic_mcs_set() - sets basic mcs set into
  2093. * cfg item
  2094. * @psoc: psoc context
  2095. * @value: data to be set
  2096. *
  2097. * Return: QDF_STATUS
  2098. */
  2099. QDF_STATUS
  2100. wlan_mlme_cfg_set_vht_basic_mcs_set(struct wlan_objmgr_psoc *psoc,
  2101. uint32_t value);
  2102. /**
  2103. * wlan_mlme_get_vht_enable_tx_bf() - Get vht enable tx bf
  2104. * @psoc: psoc context
  2105. * @value: data to be set
  2106. *
  2107. * Return: QDF_STATUS
  2108. */
  2109. QDF_STATUS
  2110. wlan_mlme_get_vht_enable_tx_bf(struct wlan_objmgr_psoc *psoc, bool *value);
  2111. /**
  2112. * wlan_mlme_get_vht_tx_su_beamformer() - VHT enable tx su beamformer
  2113. * @psoc: psoc context
  2114. * @value: data to be set
  2115. *
  2116. * Return: QDF_STATUS
  2117. */
  2118. QDF_STATUS
  2119. wlan_mlme_get_vht_tx_su_beamformer(struct wlan_objmgr_psoc *psoc, bool *value);
  2120. /**
  2121. * wlan_mlme_get_vht_channel_width() - gets Channel width capability
  2122. * for 11ac
  2123. * @psoc: psoc context
  2124. * @value: data to be set
  2125. *
  2126. * Return: QDF_STATUS
  2127. */
  2128. QDF_STATUS wlan_mlme_get_vht_channel_width(struct wlan_objmgr_psoc *psoc,
  2129. uint8_t *value);
  2130. /**
  2131. * wlan_mlme_get_vht_rx_mcs_8_9() - VHT Rx MCS capability for 1x1 mode
  2132. * @psoc: psoc context
  2133. * @value: data to be set
  2134. *
  2135. * Return: QDF_STATUS
  2136. */
  2137. QDF_STATUS wlan_mlme_get_vht_rx_mcs_8_9(struct wlan_objmgr_psoc *psoc,
  2138. uint8_t *value);
  2139. /**
  2140. * wlan_mlme_get_vht_tx_mcs_8_9() - VHT Tx MCS capability for 1x1 mode
  2141. * @psoc: psoc context
  2142. * @value: data to be set
  2143. *
  2144. * Return: QDF_STATUS
  2145. */
  2146. QDF_STATUS
  2147. wlan_mlme_get_vht_tx_mcs_8_9(struct wlan_objmgr_psoc *psoc, uint8_t *value);
  2148. /**
  2149. * wlan_mlme_get_vht_rx_mcs_2x2() - VHT Rx MCS capability for 2x2 mode
  2150. * @psoc: psoc context
  2151. * @value: data to be set
  2152. *
  2153. * Return: QDF_STATUS
  2154. */
  2155. QDF_STATUS wlan_mlme_get_vht_rx_mcs_2x2(struct wlan_objmgr_psoc *psoc,
  2156. uint8_t *value);
  2157. /**
  2158. * wlan_mlme_get_vht_tx_mcs_2x2() - VHT Tx MCS capability for 2x2 mode
  2159. * @psoc: psoc context
  2160. * @value: data to be set
  2161. *
  2162. * Return: QDF_STATUS
  2163. */
  2164. QDF_STATUS wlan_mlme_get_vht_tx_mcs_2x2(struct wlan_objmgr_psoc *psoc,
  2165. uint8_t *value);
  2166. /**
  2167. * wlan_mlme_get_vht20_mcs9() - Enables VHT MCS9 in 20M BW operation
  2168. * @psoc: psoc context
  2169. * @value: data to be set
  2170. *
  2171. * Return: QDF_STATUS
  2172. */
  2173. QDF_STATUS
  2174. wlan_mlme_get_vht20_mcs9(struct wlan_objmgr_psoc *psoc, bool *value);
  2175. /**
  2176. * wlan_mlme_get_srd_master_mode_for_vdev - Get SRD master mode for vdev
  2177. * @psoc: pointer to psoc object
  2178. * @vdev_opmode: vdev operating mode
  2179. * @value: pointer to the value which will be filled for the caller
  2180. *
  2181. * Return: QDF Status
  2182. */
  2183. QDF_STATUS
  2184. wlan_mlme_get_srd_master_mode_for_vdev(struct wlan_objmgr_psoc *psoc,
  2185. enum QDF_OPMODE vdev_opmode,
  2186. bool *value);
  2187. /**
  2188. * wlan_mlme_get_indoor_support_for_nan - Get indoor channel support for NAN
  2189. * @psoc: pointer to psoc object
  2190. * @value: pointer to the value which will be filled for the caller
  2191. *
  2192. * Return: QDF Status
  2193. */
  2194. QDF_STATUS
  2195. wlan_mlme_get_indoor_support_for_nan(struct wlan_objmgr_psoc *psoc,
  2196. bool *value);
  2197. /**
  2198. * wlan_mlme_get_force_sap_enabled() - Get the value of force SAP enabled
  2199. * @psoc: psoc context
  2200. * @value: data to get
  2201. *
  2202. * Get the value of force SAP enabled
  2203. *
  2204. * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
  2205. */
  2206. QDF_STATUS
  2207. wlan_mlme_get_force_sap_enabled(struct wlan_objmgr_psoc *psoc, bool *value);
  2208. /**
  2209. * wlan_mlme_get_enable_dynamic_nss_chains_cfg() - API to get whether dynamic
  2210. * nss and chain config is enabled or not
  2211. * @psoc: psoc context
  2212. * @value: data to be set
  2213. *
  2214. * API to get whether dynamic nss and chain config is enabled or not
  2215. *
  2216. * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
  2217. */
  2218. QDF_STATUS
  2219. wlan_mlme_get_enable_dynamic_nss_chains_cfg(struct wlan_objmgr_psoc *psoc,
  2220. bool *value);
  2221. /**
  2222. * wlan_mlme_get_restart_sap_on_dynamic_nss_chains_cfg() - API to get whether
  2223. * SAP needs to be restarted or not on dynamic nss chain config
  2224. * @psoc: psoc context
  2225. * @value: data to be set
  2226. *
  2227. * API to get whether SAP needs to be restarted or not on dynamic nss chain
  2228. * config
  2229. *
  2230. * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
  2231. */
  2232. QDF_STATUS
  2233. wlan_mlme_get_restart_sap_on_dynamic_nss_chains_cfg(
  2234. struct wlan_objmgr_psoc *psoc,
  2235. bool *value);
  2236. /**
  2237. * wlan_mlme_cfg_set_dynamic_nss_chains_support() - API to update
  2238. * dynamic_nss_chains_support
  2239. *
  2240. * @psoc: psoc context
  2241. * @value: data to be set
  2242. *
  2243. * API to update dynamic_nss_chains_support in wlan_mlme_cfg object to
  2244. * maintain this value in mlme context
  2245. *
  2246. * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
  2247. */
  2248. QDF_STATUS
  2249. wlan_mlme_cfg_set_dynamic_nss_chains_support(struct wlan_objmgr_psoc *psoc,
  2250. bool value);
  2251. /**
  2252. * wlan_mlme_cfg_get_dynamic_nss_chains_support() - API to get current value of
  2253. * dynamic_nss_chains_support
  2254. *
  2255. * @psoc: psoc context
  2256. * @value: data to be set
  2257. *
  2258. * API to get current value of dynamic_nss_chains_support
  2259. *
  2260. * Return: QDF_STATUS_SUCCESS or QDF_STATUS_FAILURE
  2261. */
  2262. QDF_STATUS
  2263. wlan_mlme_cfg_get_dynamic_nss_chains_support(struct wlan_objmgr_psoc *psoc,
  2264. bool *value);
  2265. /**
  2266. * wlan_mlme_get_vht_enable2x2() - Enables/disables VHT Tx/Rx MCS values for 2x2
  2267. * @psoc: psoc context
  2268. * @value: data to be set
  2269. *
  2270. * Return: QDF_STATUS
  2271. */
  2272. QDF_STATUS
  2273. wlan_mlme_get_vht_enable2x2(struct wlan_objmgr_psoc *psoc, bool *value);
  2274. /**
  2275. * wlan_mlme_set_vht_enable2x2() - Enables/disables VHT Tx/Rx MCS values for 2x2
  2276. * @psoc: psoc context
  2277. * @value: data to be set
  2278. *
  2279. * Return: QDF_STATUS
  2280. */
  2281. QDF_STATUS
  2282. wlan_mlme_set_vht_enable2x2(struct wlan_objmgr_psoc *psoc, bool value);
  2283. /**
  2284. * wlan_mlme_get_vht_enable_paid() - Enables/disables paid feature
  2285. * @psoc: psoc context
  2286. * @value: data to be set
  2287. *
  2288. * Return: QDF_STATUS
  2289. */
  2290. QDF_STATUS
  2291. wlan_mlme_get_vht_enable_paid(struct wlan_objmgr_psoc *psoc, bool *value);
  2292. /**
  2293. * wlan_mlme_get_vht_enable_gid() - Enables/disables VHT GID feature
  2294. * @psoc: psoc context
  2295. * @value: data to be set
  2296. *
  2297. * Return: QDF_STATUS
  2298. */
  2299. QDF_STATUS
  2300. wlan_mlme_get_vht_enable_gid(struct wlan_objmgr_psoc *psoc, bool *value);
  2301. /**
  2302. * wlan_mlme_get_vht_for_24ghz() - Enables/disables VHT for 24 ghz
  2303. * @psoc: psoc context
  2304. * @value: data to be set
  2305. *
  2306. * Return: QDF_STATUS
  2307. */
  2308. QDF_STATUS
  2309. wlan_mlme_get_vht_for_24ghz(struct wlan_objmgr_psoc *psoc, bool *value);
  2310. /**
  2311. * wlan_mlme_set_vht_for_24ghz() - Enables/disables VHT for 24 ghz
  2312. * @psoc: psoc context
  2313. * @value: data to be set
  2314. *
  2315. * Return: QDF_STATUS
  2316. */
  2317. QDF_STATUS
  2318. wlan_mlme_set_vht_for_24ghz(struct wlan_objmgr_psoc *psoc, bool value);
  2319. /**
  2320. * wlan_mlme_get_vendor_vht_for_24ghz() - nables/disables vendor VHT for 24 ghz
  2321. * @psoc: psoc context
  2322. * @value: data to be set
  2323. *
  2324. * Return: QDF_STATUS
  2325. */
  2326. QDF_STATUS
  2327. wlan_mlme_get_vendor_vht_for_24ghz(struct wlan_objmgr_psoc *psoc, bool *value);
  2328. /**
  2329. * mlme_update_vht_cap() - update vht capabilities
  2330. * @psoc: psoc context
  2331. * @cfg: data to be set
  2332. *
  2333. * Return: QDF_STATUS
  2334. */
  2335. QDF_STATUS
  2336. mlme_update_vht_cap(struct wlan_objmgr_psoc *psoc, struct wma_tgt_vht_cap *cfg);
  2337. /**
  2338. * mlme_update_nss_vht_cap() - Update the number of spatial
  2339. * streams supported for vht
  2340. * @psoc: psoc context
  2341. *
  2342. * Return: QDF_STATUS
  2343. */
  2344. QDF_STATUS mlme_update_nss_vht_cap(struct wlan_objmgr_psoc *psoc);
  2345. #ifdef WLAN_FEATURE_11BE
  2346. /**
  2347. * mlme_get_bss_11be_allowed() - Check BSS allowed in 11be mode
  2348. * @psoc: psoc context
  2349. * @bssid: bssid
  2350. * @ie_data: ie data
  2351. * @ie_length: ie data length
  2352. *
  2353. * Return: true if AP in 11be oui allow list
  2354. */
  2355. bool mlme_get_bss_11be_allowed(struct wlan_objmgr_psoc *psoc,
  2356. struct qdf_mac_addr *bssid,
  2357. uint8_t *ie_data,
  2358. uint32_t ie_length);
  2359. #else
  2360. static inline
  2361. bool mlme_get_bss_11be_allowed(struct wlan_objmgr_psoc *psoc,
  2362. struct qdf_mac_addr *bssid,
  2363. uint8_t *ie_data,
  2364. uint32_t ie_length)
  2365. {
  2366. return false;
  2367. }
  2368. #endif
  2369. /**
  2370. * wlan_mlme_is_sap_uapsd_enabled() - Get if SAP UAPSD is enabled/disabled
  2371. * @psoc: psoc context
  2372. * @value: value to be filled for caller
  2373. *
  2374. * Return: QDF_STATUS
  2375. */
  2376. QDF_STATUS wlan_mlme_is_sap_uapsd_enabled(struct wlan_objmgr_psoc *psoc,
  2377. bool *value);
  2378. /**
  2379. * wlan_mlme_set_sap_uapsd_flag() - Enable/Disable SAP UAPSD
  2380. * @psoc: psoc context
  2381. * @value: Enable/Disable control value for sap_uapsd_enabled field
  2382. *
  2383. * Return: QDF_STATUS
  2384. */
  2385. QDF_STATUS wlan_mlme_set_sap_uapsd_flag(struct wlan_objmgr_psoc *psoc,
  2386. bool value);
  2387. /**
  2388. * wlan_mlme_is_11h_enabled() - Get the 11h flag
  2389. * @psoc: psoc context
  2390. * @value: Enable/Disable value ptr.
  2391. *
  2392. * Return: QDF_STATUS
  2393. */
  2394. QDF_STATUS
  2395. wlan_mlme_is_11h_enabled(struct wlan_objmgr_psoc *psoc, bool *value);
  2396. /**
  2397. * wlan_mlme_set_11h_enabled() - Set the 11h flag
  2398. * @psoc: psoc context
  2399. * @value: Enable/Disable value
  2400. *
  2401. * Return: QDF_STATUS
  2402. */
  2403. QDF_STATUS
  2404. wlan_mlme_set_11h_enabled(struct wlan_objmgr_psoc *psoc, bool value);
  2405. /**
  2406. * wlan_mlme_is_11d_enabled() - Get the 11d flag
  2407. * @psoc: psoc context
  2408. * @value: Enable/Disable value ptr.
  2409. *
  2410. * Return: QDF_STATUS
  2411. */
  2412. QDF_STATUS
  2413. wlan_mlme_is_11d_enabled(struct wlan_objmgr_psoc *psoc, bool *value);
  2414. /**
  2415. * wlan_mlme_set_11d_enabled() - Set the 11h flag
  2416. * @psoc: psoc context
  2417. * @value: Enable/Disable value
  2418. *
  2419. * Return: QDF_STATUS
  2420. */
  2421. QDF_STATUS
  2422. wlan_mlme_set_11d_enabled(struct wlan_objmgr_psoc *psoc, bool value);
  2423. /**
  2424. * wlan_mlme_is_rf_test_mode_enabled() - Get the rf test mode flag
  2425. * @psoc: psoc context
  2426. * @value: Enable/Disable value ptr.
  2427. *
  2428. * Return: QDF_STATUS
  2429. */
  2430. QDF_STATUS
  2431. wlan_mlme_is_rf_test_mode_enabled(struct wlan_objmgr_psoc *psoc, bool *value);
  2432. /**
  2433. * wlan_mlme_set_rf_test_mode_enabled() - Set the rf test mode flag
  2434. * @psoc: psoc context
  2435. * @value: Enable/Disable value.
  2436. *
  2437. * Return: QDF_STATUS
  2438. */
  2439. QDF_STATUS
  2440. wlan_mlme_set_rf_test_mode_enabled(struct wlan_objmgr_psoc *psoc, bool value);
  2441. #ifdef CONFIG_BAND_6GHZ
  2442. /**
  2443. * wlan_mlme_is_disable_vlp_sta_conn_to_sp_ap_enabled() - Get the disable vlp
  2444. * STA conn to SP AP flag
  2445. * @psoc: psoc context
  2446. * @value: Enable/Disable value ptr.
  2447. *
  2448. * Return: QDF_STATUS
  2449. */
  2450. QDF_STATUS
  2451. wlan_mlme_is_disable_vlp_sta_conn_to_sp_ap_enabled(
  2452. struct wlan_objmgr_psoc *psoc,
  2453. bool *value);
  2454. /**
  2455. * wlan_mlme_is_standard_6ghz_conn_policy_enabled() - Get the 6 GHz standard
  2456. * connection policy flag
  2457. * @psoc: psoc context
  2458. * @value: Enable/Disable value ptr.
  2459. *
  2460. * Return: QDF_STATUS
  2461. */
  2462. QDF_STATUS
  2463. wlan_mlme_is_standard_6ghz_conn_policy_enabled(struct wlan_objmgr_psoc *psoc,
  2464. bool *value);
  2465. #else
  2466. static inline QDF_STATUS
  2467. wlan_mlme_is_disable_vlp_sta_conn_to_sp_ap_enabled(
  2468. struct wlan_objmgr_psoc *psoc,
  2469. bool *value)
  2470. {
  2471. *value = false;
  2472. return QDF_STATUS_SUCCESS;
  2473. }
  2474. static inline QDF_STATUS
  2475. wlan_mlme_is_standard_6ghz_conn_policy_enabled(struct wlan_objmgr_psoc *psoc,
  2476. bool *value)
  2477. {
  2478. *value = false;
  2479. return QDF_STATUS_SUCCESS;
  2480. }
  2481. #endif
  2482. #ifdef WLAN_FEATURE_11BE_MLO
  2483. /**
  2484. * wlan_mlme_get_eht_mode() - Get the EHT mode of operations
  2485. * @psoc: psoc context
  2486. * @value: EHT mode value ptr
  2487. *
  2488. * Return: QDF_STATUS
  2489. */
  2490. QDF_STATUS
  2491. wlan_mlme_get_eht_mode(struct wlan_objmgr_psoc *psoc,
  2492. enum wlan_eht_mode *value);
  2493. /**
  2494. * wlan_mlme_set_eht_mode() - Set the EHT mode of operation
  2495. * @psoc: psoc context
  2496. * @value: EHT mode value
  2497. *
  2498. * Return: QDF_STATUS
  2499. */
  2500. QDF_STATUS
  2501. wlan_mlme_set_eht_mode(struct wlan_objmgr_psoc *psoc, enum wlan_eht_mode value);
  2502. /**
  2503. * wlan_mlme_get_emlsr_mode_enabled() - Get the eMLSR mode flag
  2504. * @psoc: psoc context
  2505. * @value: Enable/Disable value ptr.
  2506. *
  2507. * Return: QDF_STATUS
  2508. */
  2509. QDF_STATUS
  2510. wlan_mlme_get_emlsr_mode_enabled(struct wlan_objmgr_psoc *psoc, bool *value);
  2511. /**
  2512. * wlan_mlme_set_emlsr_mode_enabled() - Set the eMLSR mode flag
  2513. * @psoc: psoc context
  2514. * @value: Enable/Disable value.
  2515. *
  2516. * Return: QDF_STATUS
  2517. */
  2518. QDF_STATUS
  2519. wlan_mlme_set_emlsr_mode_enabled(struct wlan_objmgr_psoc *psoc, bool value);
  2520. /**
  2521. * wlan_mlme_set_eml_params() - Set EML subfields in psoc mlme obj that
  2522. * are received from FW
  2523. * @psoc: psoc context
  2524. * @cap: psoc mac/phy capability ptr
  2525. *
  2526. * Return: none
  2527. */
  2528. void
  2529. wlan_mlme_set_eml_params(struct wlan_objmgr_psoc *psoc,
  2530. struct wlan_psoc_host_mac_phy_caps_ext2 *cap);
  2531. /**
  2532. * wlan_mlme_get_eml_params() - Get EML subfields from psoc mlme obj
  2533. * @psoc: psoc context
  2534. * @cap: EML capability subfield ptr
  2535. *
  2536. * Return: none
  2537. */
  2538. void
  2539. wlan_mlme_get_eml_params(struct wlan_objmgr_psoc *psoc,
  2540. struct wlan_mlo_eml_cap *cap);
  2541. /**
  2542. * wlan_mlme_cfg_set_emlsr_pad_delay() - Configure EMLSR padding delay subfield
  2543. * @psoc: psoc context
  2544. * @val: EMLSR padding delay subfield value
  2545. *
  2546. * API to configure EMLSR padding delay subfield in psoc mlme obj with user
  2547. * requested value if it greater than the value configured by FW during boot-up.
  2548. *
  2549. * Return: none
  2550. */
  2551. void
  2552. wlan_mlme_cfg_set_emlsr_pad_delay(struct wlan_objmgr_psoc *psoc, uint8_t val);
  2553. /**
  2554. * wlan_mlme_get_t2lm_negotiation_supported() - Get the T2LM
  2555. * negotiation supported value
  2556. * @psoc: psoc context
  2557. *
  2558. * Return: t2lm negotiation supported value
  2559. */
  2560. enum t2lm_negotiation_support
  2561. wlan_mlme_get_t2lm_negotiation_supported(struct wlan_objmgr_psoc *psoc);
  2562. /**
  2563. * wlan_mlme_set_t2lm_negotiation_supported() - Set the T2LM
  2564. * negotiation supported value
  2565. * @psoc: psoc context
  2566. * @value: t2lm negotiation supported value
  2567. *
  2568. * Return: qdf status
  2569. */
  2570. QDF_STATUS
  2571. wlan_mlme_set_t2lm_negotiation_supported(struct wlan_objmgr_psoc *psoc,
  2572. uint8_t value);
  2573. /**
  2574. * wlan_mlme_get_eht_mld_id() - Get the MLD ID of the requested BSS
  2575. * @psoc: psoc context
  2576. *
  2577. * Return: MLD ID of the requested BSS
  2578. */
  2579. uint8_t
  2580. wlan_mlme_get_eht_mld_id(struct wlan_objmgr_psoc *psoc);
  2581. /**
  2582. * wlan_mlme_set_eht_mld_id() - Set MLD ID of the requested BSS information
  2583. * within the ML probe request.
  2584. * @psoc: psoc context
  2585. * @value: MLD ID
  2586. *
  2587. * Return: qdf status
  2588. */
  2589. QDF_STATUS
  2590. wlan_mlme_set_eht_mld_id(struct wlan_objmgr_psoc *psoc, uint8_t value);
  2591. /*
  2592. * wlan_mlme_get_mlo_prefer_percentage() - get MLO preference percentage
  2593. * @psoc: pointer to psoc object
  2594. *
  2595. * Return: void
  2596. */
  2597. void
  2598. wlan_mlme_get_mlo_prefer_percentage(
  2599. struct wlan_objmgr_psoc *psoc,
  2600. int8_t *mlo_prefer_percentage);
  2601. #else
  2602. static inline QDF_STATUS
  2603. wlan_mlme_get_eht_mode(struct wlan_objmgr_psoc *psoc, enum wlan_eht_mode *value)
  2604. {
  2605. *value = WLAN_EHT_MODE_DISABLED;
  2606. return QDF_STATUS_SUCCESS;
  2607. }
  2608. static inline QDF_STATUS
  2609. wlan_mlme_set_eht_mode(struct wlan_objmgr_psoc *psoc, enum wlan_eht_mode value)
  2610. {
  2611. return QDF_STATUS_SUCCESS;
  2612. }
  2613. static inline QDF_STATUS
  2614. wlan_mlme_get_emlsr_mode_enabled(struct wlan_objmgr_psoc *psoc, bool *value)
  2615. {
  2616. *value = false;
  2617. return QDF_STATUS_SUCCESS;
  2618. }
  2619. static inline QDF_STATUS
  2620. wlan_mlme_set_emlsr_mode_enabled(struct wlan_objmgr_psoc *psoc, bool value)
  2621. {
  2622. return QDF_STATUS_SUCCESS;
  2623. }
  2624. static inline void
  2625. wlan_mlme_set_eml_params(struct wlan_objmgr_psoc *psoc,
  2626. struct wlan_psoc_host_mac_phy_caps_ext2 *cap)
  2627. {
  2628. }
  2629. static inline void
  2630. wlan_mlme_get_eml_params(struct wlan_objmgr_psoc *psoc,
  2631. struct wlan_mlo_eml_cap *cap)
  2632. {
  2633. }
  2634. static inline void
  2635. wlan_mlme_cfg_set_emlsr_pad_delay(struct wlan_objmgr_psoc *psoc, uint8_t val)
  2636. {
  2637. }
  2638. static inline enum t2lm_negotiation_support
  2639. wlan_mlme_get_t2lm_negotiation_supported(struct wlan_objmgr_psoc *psoc)
  2640. {
  2641. return T2LM_NEGOTIATION_DISABLED;
  2642. }
  2643. static inline QDF_STATUS
  2644. wlan_mlme_set_t2lm_negotiation_supported(struct wlan_objmgr_psoc *psoc,
  2645. uint8_t value)
  2646. {
  2647. return QDF_STATUS_E_NOSUPPORT;
  2648. }
  2649. static inline uint8_t
  2650. wlan_mlme_get_eht_mld_id(struct wlan_objmgr_psoc *psoc)
  2651. {
  2652. return 0;
  2653. }
  2654. static inline QDF_STATUS
  2655. wlan_mlme_set_eht_mld_id(struct wlan_objmgr_psoc *psoc, uint8_t value)
  2656. {
  2657. return QDF_STATUS_E_NOSUPPORT;
  2658. }
  2659. static inline void
  2660. wlan_mlme_get_mlo_prefer_percentage(
  2661. struct wlan_objmgr_psoc *psoc,
  2662. int8_t *mlo_prefer_percentage)
  2663. {}
  2664. #endif
  2665. /**
  2666. * wlan_mlme_set_btm_abridge_flag() - Set BTM abridge flag
  2667. * @psoc: psoc context
  2668. * @value: abridge flag
  2669. *
  2670. * Return: qdf status
  2671. *
  2672. * BTM abridge flag indicates whether to select candidates
  2673. * for BTM roam based on score.
  2674. */
  2675. QDF_STATUS
  2676. wlan_mlme_set_btm_abridge_flag(struct wlan_objmgr_psoc *psoc, bool value);
  2677. /**
  2678. * wlan_mlme_get_btm_abridge_flag() - Get BTM abridge flag
  2679. * @psoc: psoc context
  2680. *
  2681. * Return: abridge flag
  2682. *
  2683. * BTM abridge flag indicates whether to select candidates
  2684. * for BTM roam based on score.
  2685. */
  2686. bool
  2687. wlan_mlme_get_btm_abridge_flag(struct wlan_objmgr_psoc *psoc);
  2688. /**
  2689. * wlan_mlme_get_sta_miracast_mcc_rest_time() - Get STA/MIRACAST MCC rest time
  2690. * @psoc: pointer to psoc object
  2691. * @value: value which needs to filled by API
  2692. *
  2693. * This API gives rest time to be used when STA and MIRACAST MCC conc happens
  2694. *
  2695. * Return: QDF_STATUS
  2696. */
  2697. QDF_STATUS
  2698. wlan_mlme_get_sta_miracast_mcc_rest_time(struct wlan_objmgr_psoc *psoc,
  2699. uint32_t *value);
  2700. /**
  2701. * wlan_mlme_get_max_modulated_dtim_ms() - get the max modulated dtim in ms
  2702. * restart
  2703. * @psoc: pointer to psoc object
  2704. * @value: Value that needs to be set from the caller
  2705. *
  2706. * Return: QDF Status
  2707. */
  2708. QDF_STATUS
  2709. wlan_mlme_get_max_modulated_dtim_ms(struct wlan_objmgr_psoc *psoc,
  2710. uint16_t *value);
  2711. /**
  2712. * wlan_mlme_get_scan_probe_unicast_ra() - Get scan probe unicast RA cfg
  2713. * @psoc: pointer to psoc object
  2714. * @value: value which needs to filled by API
  2715. *
  2716. * This API gives scan probe request with unicast RA user config
  2717. *
  2718. * Return: QDF_STATUS
  2719. */
  2720. QDF_STATUS
  2721. wlan_mlme_get_scan_probe_unicast_ra(struct wlan_objmgr_psoc *psoc,
  2722. bool *value);
  2723. /**
  2724. * wlan_mlme_set_scan_probe_unicast_ra() - Set scan probe unicast RA cfg
  2725. * @psoc: pointer to psoc object
  2726. * @value: set value
  2727. *
  2728. * This API sets scan probe request with unicast RA user config
  2729. *
  2730. * Return: QDF_STATUS
  2731. */
  2732. QDF_STATUS
  2733. wlan_mlme_set_scan_probe_unicast_ra(struct wlan_objmgr_psoc *psoc,
  2734. bool value);
  2735. /**
  2736. * wlan_mlme_get_sap_mcc_chnl_avoid() - Check if SAP MCC needs to be avoided
  2737. * @psoc: pointer to psoc object
  2738. * @value: value which needs to filled by API
  2739. *
  2740. * This API fetches the user setting to determine if SAP MCC with other persona
  2741. * to be avoided.
  2742. *
  2743. * Return: QDF_STATUS
  2744. */
  2745. QDF_STATUS
  2746. wlan_mlme_get_sap_mcc_chnl_avoid(struct wlan_objmgr_psoc *psoc,
  2747. uint8_t *value);
  2748. /**
  2749. * wlan_mlme_get_mcc_bcast_prob_resp() - Get broadcast probe rsp in MCC
  2750. * @psoc: pointer to psoc object
  2751. * @value: value which needs to filled by API
  2752. *
  2753. * To get INI value which helps to determe whether to enable/disable use of
  2754. * broadcast probe response to increase the detectability of SAP in MCC mode.
  2755. *
  2756. *
  2757. * Return: QDF_STATUS
  2758. */
  2759. QDF_STATUS
  2760. wlan_mlme_get_mcc_bcast_prob_resp(struct wlan_objmgr_psoc *psoc,
  2761. uint8_t *value);
  2762. /**
  2763. * wlan_mlme_get_mcc_rts_cts_prot() - To get RTS-CTS protection in MCC.
  2764. * @psoc: pointer to psoc object
  2765. * @value: value which needs to filled by API
  2766. *
  2767. * To get INI value which helps to determine whether to enable/disable
  2768. * use of long duration RTS-CTS protection when SAP goes off
  2769. * channel in MCC mode.
  2770. *
  2771. * Return: QDF_STATUS
  2772. */
  2773. QDF_STATUS
  2774. wlan_mlme_get_mcc_rts_cts_prot(struct wlan_objmgr_psoc *psoc,
  2775. uint8_t *value);
  2776. /**
  2777. * wlan_mlme_get_mcc_feature() - To find out to enable/disable MCC feature
  2778. * @psoc: pointer to psoc object
  2779. * @value: value which needs to filled by API
  2780. *
  2781. * To get INI value which helps to determine whether to enable MCC feature
  2782. *
  2783. * Return: QDF_STATUS
  2784. */
  2785. QDF_STATUS
  2786. wlan_mlme_get_mcc_feature(struct wlan_objmgr_psoc *psoc,
  2787. uint8_t *value);
  2788. /**
  2789. * wlan_mlme_get_rrm_enabled() - Get the RRM enabled ini
  2790. * @psoc: pointer to psoc object
  2791. * @value: pointer to the value which will be filled for the caller
  2792. *
  2793. * Return: QDF Status
  2794. */
  2795. QDF_STATUS wlan_mlme_get_rrm_enabled(struct wlan_objmgr_psoc *psoc,
  2796. bool *value);
  2797. /**
  2798. * wlan_mlme_get_dtim_selection_diversity() - get dtim selection diversity
  2799. * bitmap
  2800. * @psoc: pointer to psoc object
  2801. * @dtim_selection_div: value that is requested by the caller
  2802. * This function gets the dtim selection diversity bitmap to be
  2803. * sent to the firmware
  2804. *
  2805. * Return: QDF_STATUS_SUCCESS - in case of success
  2806. */
  2807. QDF_STATUS wlan_mlme_get_dtim_selection_diversity(struct wlan_objmgr_psoc *psoc,
  2808. uint32_t *dtim_selection_div);
  2809. /**
  2810. * wlan_mlme_get_bmps_min_listen_interval() - get beacon mode powersave
  2811. * minimum listen interval value
  2812. * @psoc: pointer to psoc object
  2813. * @value: value that is requested by the caller
  2814. *
  2815. * Return: QDF_STATUS_SUCCESS - in case of success
  2816. */
  2817. QDF_STATUS wlan_mlme_get_bmps_min_listen_interval(struct wlan_objmgr_psoc *psoc,
  2818. uint32_t *value);
  2819. /**
  2820. * wlan_mlme_get_bmps_max_listen_interval() - get beacon mode powersave
  2821. * maximum listen interval value
  2822. * @psoc: pointer to psoc object
  2823. * @value: value that is requested by the caller
  2824. *
  2825. * Return: QDF_STATUS_SUCCESS - in case of success
  2826. */
  2827. QDF_STATUS wlan_mlme_get_bmps_max_listen_interval(struct wlan_objmgr_psoc *psoc,
  2828. uint32_t *value);
  2829. /**
  2830. * wlan_mlme_get_auto_bmps_timer_value() - get bmps timer value
  2831. * @psoc: pointer to psoc object
  2832. * @value: value that is requested by the caller
  2833. *
  2834. * Return: QDF_STATUS_SUCCESS - in case of success
  2835. */
  2836. QDF_STATUS wlan_mlme_get_auto_bmps_timer_value(struct wlan_objmgr_psoc *psoc,
  2837. uint32_t *value);
  2838. /**
  2839. * wlan_mlme_is_bmps_enabled() - check if beacon mode powersave is
  2840. * enabled/disabled
  2841. * @psoc: pointer to psoc object
  2842. * @value: value that is requested by the caller
  2843. *
  2844. * Return: QDF_STATUS_SUCCESS - in case of success
  2845. */
  2846. QDF_STATUS wlan_mlme_is_bmps_enabled(struct wlan_objmgr_psoc *psoc,
  2847. bool *value);
  2848. /**
  2849. * wlan_mlme_override_bmps_imps() - disable imps/bmps
  2850. * @psoc: pointer to psoc object
  2851. *
  2852. * Return: QDF_STATUS_SUCCESS - in case of success
  2853. */
  2854. QDF_STATUS wlan_mlme_override_bmps_imps(struct wlan_objmgr_psoc *psoc);
  2855. /**
  2856. * wlan_mlme_is_imps_enabled() - check if idle mode powersave is
  2857. * enabled/disabled
  2858. * @psoc: pointer to psoc object
  2859. * @value: value that is requested by the caller
  2860. *
  2861. * Return: QDF_STATUS_SUCCESS - in case of success
  2862. */
  2863. QDF_STATUS wlan_mlme_is_imps_enabled(struct wlan_objmgr_psoc *psoc,
  2864. bool *value);
  2865. /**
  2866. * wlan_mlme_get_wps_uuid() - get the wps uuid string
  2867. * @wps_params: pointer to mlme wps parameters structure
  2868. * @data: data to which the parameter is to be copied
  2869. *
  2870. * Return None
  2871. *
  2872. */
  2873. void
  2874. wlan_mlme_get_wps_uuid(struct wlan_mlme_wps_params *wps_params, uint8_t *data);
  2875. /**
  2876. * wlan_mlme_get_self_gen_frm_pwr() - get self gen frm pwr
  2877. * @psoc: pointer to psoc object
  2878. * @value: Pointer to the value which will be filled for the caller
  2879. *
  2880. * Return: QDF Status
  2881. */
  2882. QDF_STATUS
  2883. wlan_mlme_get_self_gen_frm_pwr(struct wlan_objmgr_psoc *psoc,
  2884. uint32_t *value);
  2885. /**
  2886. * wlan_mlme_get_4way_hs_offload() - get 4-way hs offload to fw cfg
  2887. * @psoc: pointer to psoc object
  2888. * @value: Pointer to the value which will be filled for the caller
  2889. *
  2890. * Return: QDF Status
  2891. */
  2892. QDF_STATUS
  2893. wlan_mlme_get_4way_hs_offload(struct wlan_objmgr_psoc *psoc, uint32_t *value);
  2894. /**
  2895. * wlan_mlme_get_bmiss_skip_full_scan_value() - To get value of
  2896. * bmiss_skip_full_scan ini
  2897. * @psoc: pointer to psoc object
  2898. * @value: Pointer to the value which will be filled for the caller
  2899. *
  2900. * Return: QDF Status
  2901. */
  2902. QDF_STATUS
  2903. wlan_mlme_get_bmiss_skip_full_scan_value(struct wlan_objmgr_psoc *psoc,
  2904. bool *value);
  2905. /**
  2906. * mlme_get_peer_phymode() - get phymode of peer
  2907. * @psoc: pointer to psoc object
  2908. * @mac: Pointer to the mac addr of the peer
  2909. * @peer_phymode: phymode
  2910. *
  2911. * Return: QDF Status
  2912. */
  2913. QDF_STATUS
  2914. mlme_get_peer_phymode(struct wlan_objmgr_psoc *psoc, uint8_t *mac,
  2915. enum wlan_phymode *peer_phymode);
  2916. /**
  2917. * mlme_set_tgt_wpa3_roam_cap() - Set the target WPA3 roam support
  2918. * to mlme
  2919. * @psoc: pointer to PSOC object
  2920. * @akm_bitmap: Bitmap of akm suites supported for roaming by the firmware
  2921. *
  2922. * Return: QDF Status
  2923. */
  2924. QDF_STATUS mlme_set_tgt_wpa3_roam_cap(struct wlan_objmgr_psoc *psoc,
  2925. uint32_t akm_bitmap);
  2926. /**
  2927. * wlan_mlme_get_ignore_fw_reg_offload_ind() - Get the
  2928. * ignore_fw_reg_offload_ind ini
  2929. * @psoc: pointer to psoc object
  2930. * @disabled: output pointer to hold user config
  2931. *
  2932. * Return: QDF Status
  2933. */
  2934. QDF_STATUS
  2935. wlan_mlme_get_ignore_fw_reg_offload_ind(struct wlan_objmgr_psoc *psoc,
  2936. bool *disabled);
  2937. /**
  2938. * mlme_get_roam_trigger_str() - Get the string for enum
  2939. * WMI_ROAM_TRIGGER_REASON_ID reason.
  2940. * @roam_scan_trigger: roam scan trigger ID
  2941. *
  2942. * Return: Meaningful string from enum WMI_ROAM_TRIGGER_REASON_ID
  2943. */
  2944. char *mlme_get_roam_trigger_str(uint32_t roam_scan_trigger);
  2945. /**
  2946. * mlme_get_roam_status_str() - Get the string for roam status
  2947. * @roam_status: roam status coming from fw via
  2948. * wmi_roam_scan_info tlv
  2949. *
  2950. * Return: Meaningful string for roam status
  2951. */
  2952. char *mlme_get_roam_status_str(uint32_t roam_status);
  2953. /**
  2954. * mlme_get_converted_timestamp() - Return time of the day
  2955. * from timestamp
  2956. * @timestamp: Timestamp value in milliseconds
  2957. * @time: Output buffer to fill time into
  2958. *
  2959. * Return: Time of the day in [HH:MM:SS.uS]
  2960. */
  2961. void mlme_get_converted_timestamp(uint32_t timestamp, char *time);
  2962. #if defined(WLAN_SAE_SINGLE_PMK) && defined(WLAN_FEATURE_ROAM_OFFLOAD)
  2963. /**
  2964. * wlan_mlme_set_sae_single_pmk_bss_cap - API to set WPA3 single pmk AP IE
  2965. * @psoc: Pointer to psoc object
  2966. * @vdev_id: vdev id
  2967. * @val: value to be set
  2968. *
  2969. * Return : None
  2970. */
  2971. void wlan_mlme_set_sae_single_pmk_bss_cap(struct wlan_objmgr_psoc *psoc,
  2972. uint8_t vdev_id, bool val);
  2973. /**
  2974. * wlan_mlme_update_sae_single_pmk - API to update mlme_pmkid_info
  2975. * @vdev: vdev object
  2976. * @sae_single_pmk: pointer to sae_single_pmk_info struct
  2977. *
  2978. * Return : None
  2979. */
  2980. void
  2981. wlan_mlme_update_sae_single_pmk(struct wlan_objmgr_vdev *vdev,
  2982. struct mlme_pmk_info *sae_single_pmk);
  2983. /**
  2984. * wlan_mlme_get_sae_single_pmk_info - API to get mlme_pmkid_info
  2985. * @vdev: vdev object
  2986. * @pmksa: pointer to PMKSA struct
  2987. *
  2988. * Return : None
  2989. */
  2990. void
  2991. wlan_mlme_get_sae_single_pmk_info(struct wlan_objmgr_vdev *vdev,
  2992. struct wlan_mlme_sae_single_pmk *pmksa);
  2993. /**
  2994. * wlan_mlme_is_sae_single_pmk_enabled() - Get is SAE single pmk feature enabled
  2995. * @psoc: Pointer to Global psoc
  2996. *
  2997. * Return: True if SAE single PMK is enabled
  2998. */
  2999. bool wlan_mlme_is_sae_single_pmk_enabled(struct wlan_objmgr_psoc *psoc);
  3000. /**
  3001. * wlan_mlme_clear_sae_single_pmk_info - API to clear mlme_pmkid_info ap caps
  3002. * @vdev: vdev object
  3003. * @pmk : pmk info to clear
  3004. *
  3005. * Return : None
  3006. */
  3007. void wlan_mlme_clear_sae_single_pmk_info(struct wlan_objmgr_vdev *vdev,
  3008. struct mlme_pmk_info *pmk);
  3009. #else
  3010. static inline void
  3011. wlan_mlme_set_sae_single_pmk_bss_cap(struct wlan_objmgr_psoc *psoc,
  3012. uint8_t vdev_id, bool val)
  3013. {
  3014. }
  3015. static inline
  3016. bool wlan_mlme_is_sae_single_pmk_enabled(struct wlan_objmgr_psoc *psoc)
  3017. {
  3018. return false;
  3019. }
  3020. static inline void
  3021. wlan_mlme_update_sae_single_pmk(struct wlan_objmgr_vdev *vdev,
  3022. struct mlme_pmk_info *sae_single_pmk)
  3023. {
  3024. }
  3025. static inline void
  3026. wlan_mlme_get_sae_single_pmk_info(struct wlan_objmgr_vdev *vdev,
  3027. struct wlan_mlme_sae_single_pmk *pmksa)
  3028. {
  3029. }
  3030. static inline
  3031. void wlan_mlme_clear_sae_single_pmk_info(struct wlan_objmgr_vdev *vdev,
  3032. struct mlme_pmk_info *pmk)
  3033. {
  3034. }
  3035. #endif
  3036. /**
  3037. * mlme_get_roam_fail_reason_str() - Get fail string from enum
  3038. * WMI_ROAM_FAIL_REASON_ID
  3039. * @result: Roam fail reason
  3040. *
  3041. * Return: Meaningful string from enum
  3042. */
  3043. char *mlme_get_roam_fail_reason_str(uint32_t result);
  3044. /**
  3045. * mlme_get_sub_reason_str() - Get roam trigger sub reason from enum
  3046. * WMI_ROAM_TRIGGER_SUB_REASON_ID
  3047. * @sub_reason: Sub reason value
  3048. *
  3049. * Return: Meaningful string from enum WMI_ROAM_TRIGGER_SUB_REASON_ID
  3050. */
  3051. char *mlme_get_sub_reason_str(uint32_t sub_reason);
  3052. /**
  3053. * wlan_mlme_get_mgmt_max_retry() - Get the
  3054. * max mgmt retry
  3055. * @psoc: pointer to psoc object
  3056. * @max_retry: output pointer to hold user config
  3057. *
  3058. * Return: QDF Status
  3059. */
  3060. QDF_STATUS
  3061. wlan_mlme_get_mgmt_max_retry(struct wlan_objmgr_psoc *psoc,
  3062. uint8_t *max_retry);
  3063. /**
  3064. * wlan_mlme_get_mgmt_6ghz_rate_support() - Get status of HE rates for
  3065. * 6GHz mgmt frames
  3066. * @psoc: pointer to psoc object
  3067. * @enable_he_mcs0_for_6ghz_mgmt: pointer to check for HE rates support
  3068. *
  3069. * Return: QDF Status
  3070. */
  3071. QDF_STATUS
  3072. wlan_mlme_get_mgmt_6ghz_rate_support(struct wlan_objmgr_psoc *psoc,
  3073. bool *enable_he_mcs0_for_6ghz_mgmt);
  3074. /**
  3075. * wlan_mlme_get_status_ring_buffer() - Get the
  3076. * status of ring buffer
  3077. * @psoc: pointer to psoc object
  3078. * @enable_ring_buffer: output pointer to point the configured value of
  3079. * ring buffer
  3080. *
  3081. * Return: QDF_STATUS
  3082. */
  3083. QDF_STATUS
  3084. wlan_mlme_get_status_ring_buffer(struct wlan_objmgr_psoc *psoc,
  3085. bool *enable_ring_buffer);
  3086. /**
  3087. * wlan_mlme_get_peer_unmap_conf() - Indicate if peer unmap confirmation
  3088. * support is enabled or disabled
  3089. * @psoc: pointer to psoc object
  3090. *
  3091. * Return: true if peer unmap confirmation support is enabled, else false
  3092. */
  3093. bool wlan_mlme_get_peer_unmap_conf(struct wlan_objmgr_psoc *psoc);
  3094. #ifdef WLAN_FEATURE_ROAM_OFFLOAD
  3095. /**
  3096. * wlan_mlme_get_roam_reason_vsie_status() - Indicate if roam reason
  3097. * vsie is enabled or disabled
  3098. * @psoc: pointer to psoc object
  3099. * @roam_reason_vsie_enabled: pointer to hold value of roam reason
  3100. * vsie
  3101. *
  3102. * Return: QDF_STATUS
  3103. */
  3104. QDF_STATUS
  3105. wlan_mlme_get_roam_reason_vsie_status(struct wlan_objmgr_psoc *psoc,
  3106. uint8_t *roam_reason_vsie_enabled);
  3107. /**
  3108. * wlan_mlme_set_roam_reason_vsie_status() - Update roam reason vsie status
  3109. * @psoc: pointer to psoc object
  3110. * @roam_reason_vsie_enabled: value of roam reason vsie
  3111. *
  3112. * Return: QDF_STATUS
  3113. */
  3114. QDF_STATUS
  3115. wlan_mlme_set_roam_reason_vsie_status(struct wlan_objmgr_psoc *psoc,
  3116. uint8_t roam_reason_vsie_enabled);
  3117. /**
  3118. * wlan_mlme_get_roaming_triggers - Get the roaming triggers bitmap
  3119. * @psoc: Pointer to PSOC object
  3120. *
  3121. * Return: Roaming triggers value
  3122. */
  3123. uint32_t wlan_mlme_get_roaming_triggers(struct wlan_objmgr_psoc *psoc);
  3124. /**
  3125. * wlan_mlme_set_roaming_triggers() - Set the roaming triggers bitmap
  3126. * @psoc: Pointer to PSOC object
  3127. * @trigger_bitmap: Roaming triggers bitmap to set
  3128. *
  3129. * Return: void
  3130. */
  3131. void wlan_mlme_set_roaming_triggers(struct wlan_objmgr_psoc *psoc,
  3132. uint32_t trigger_bitmap);
  3133. /**
  3134. * wlan_mlme_get_roaming_offload() - Get roaming offload setting
  3135. * @psoc: pointer to psoc object
  3136. * @val: Pointer to enable/disable roaming offload
  3137. *
  3138. * Return: QDF Status
  3139. */
  3140. QDF_STATUS
  3141. wlan_mlme_get_roaming_offload(struct wlan_objmgr_psoc *psoc,
  3142. bool *val);
  3143. /**
  3144. * wlan_mlme_get_enable_disconnect_roam_offload() - Get emergency roaming
  3145. * Enable/Disable status during deauth/disassoc
  3146. * @psoc: pointer to psoc object
  3147. * @val: Pointer to emergency roaming Enable/Disable status
  3148. * during deauth/disassoc
  3149. *
  3150. * Return: QDF Status
  3151. */
  3152. QDF_STATUS
  3153. wlan_mlme_get_enable_disconnect_roam_offload(struct wlan_objmgr_psoc *psoc,
  3154. bool *val);
  3155. /**
  3156. * wlan_mlme_get_enable_idle_roam() - Get Enable/Disable idle roaming status
  3157. * @psoc: pointer to psoc object
  3158. * @val: Pointer to Enable/Disable idle roaming status
  3159. *
  3160. * Return: QDF Status
  3161. */
  3162. QDF_STATUS
  3163. wlan_mlme_get_enable_idle_roam(struct wlan_objmgr_psoc *psoc, bool *val);
  3164. /**
  3165. * wlan_mlme_get_idle_roam_rssi_delta() - Get idle roam rssi delta
  3166. * @psoc: pointer to psoc object
  3167. * @val: Pointer to idle roam rssi delta
  3168. *
  3169. * Return: QDF Status
  3170. */
  3171. QDF_STATUS
  3172. wlan_mlme_get_idle_roam_rssi_delta(struct wlan_objmgr_psoc *psoc,
  3173. uint32_t *val);
  3174. /**
  3175. * wlan_mlme_get_roam_info_stats_num() - Get roam information statistics number
  3176. * @psoc: pointer to psoc object
  3177. * @val: Pointer to roam_info_stats_num
  3178. *
  3179. * Return: QDF Status
  3180. */
  3181. QDF_STATUS
  3182. wlan_mlme_get_roam_info_stats_num(struct wlan_objmgr_psoc *psoc, uint32_t *val);
  3183. /**
  3184. * wlan_mlme_get_idle_roam_inactive_time() - Get idle roam inactive time
  3185. * @psoc: pointer to psoc object
  3186. * @val: Pointer to idle roam inactive time
  3187. *
  3188. * Return: QDF Status
  3189. */
  3190. QDF_STATUS
  3191. wlan_mlme_get_idle_roam_inactive_time(struct wlan_objmgr_psoc *psoc,
  3192. uint32_t *val);
  3193. /**
  3194. * wlan_mlme_get_idle_data_packet_count() - Get idle data packet count
  3195. * @psoc: pointer to psoc object
  3196. * @val: Pointer to idle data packet count
  3197. *
  3198. * Return: QDF Status
  3199. */
  3200. QDF_STATUS
  3201. wlan_mlme_get_idle_data_packet_count(struct wlan_objmgr_psoc *psoc,
  3202. uint32_t *val);
  3203. /**
  3204. * wlan_mlme_get_idle_roam_min_rssi() - Get idle roam min rssi
  3205. * @psoc: pointer to psoc object
  3206. * @val: Pointer to idle roam min rssi
  3207. *
  3208. * Return: QDF Status
  3209. */
  3210. QDF_STATUS
  3211. wlan_mlme_get_idle_roam_min_rssi(struct wlan_objmgr_psoc *psoc, uint32_t *val);
  3212. /**
  3213. * wlan_mlme_get_idle_roam_band() - Get idle roam band
  3214. * @psoc: pointer to psoc object
  3215. * @val: Pointer to idle roam band
  3216. *
  3217. * Return: QDF Status
  3218. */
  3219. QDF_STATUS
  3220. wlan_mlme_get_idle_roam_band(struct wlan_objmgr_psoc *psoc, uint32_t *val);
  3221. /**
  3222. * wlan_mlme_get_self_bss_roam() - Get self bss roam enable status
  3223. * @psoc: pointer to psoc object
  3224. * @enable_self_bss_roam: Pointer to self bss roam enable status
  3225. *
  3226. * Return: QDF Status
  3227. */
  3228. QDF_STATUS
  3229. wlan_mlme_get_self_bss_roam(struct wlan_objmgr_psoc *psoc,
  3230. uint8_t *enable_self_bss_roam);
  3231. #else
  3232. static inline QDF_STATUS
  3233. wlan_mlme_get_roam_reason_vsie_status(struct wlan_objmgr_psoc *psoc,
  3234. uint8_t *roam_reason_vsie_enable)
  3235. {
  3236. return QDF_STATUS_E_FAILURE;
  3237. }
  3238. static inline QDF_STATUS
  3239. wlan_mlme_set_roam_reason_vsie_status(struct wlan_objmgr_psoc *psoc,
  3240. uint8_t roam_reason_vsie_enable)
  3241. {
  3242. return QDF_STATUS_E_FAILURE;
  3243. }
  3244. static inline
  3245. uint32_t wlan_mlme_get_roaming_triggers(struct wlan_objmgr_psoc *psoc)
  3246. {
  3247. return 0xFFFF;
  3248. }
  3249. static inline
  3250. void wlan_mlme_set_roaming_triggers(struct wlan_objmgr_psoc *psoc,
  3251. uint32_t trigger_bitmap)
  3252. {
  3253. }
  3254. static inline QDF_STATUS
  3255. wlan_mlme_get_roaming_offload(struct wlan_objmgr_psoc *psoc,
  3256. bool *val)
  3257. {
  3258. *val = false;
  3259. return QDF_STATUS_SUCCESS;
  3260. }
  3261. #endif
  3262. /**
  3263. * wlan_mlme_set_peer_indicated_ch_width() - Set peer indicated channel width
  3264. * @psoc: pointer to psoc object
  3265. * @data: Pointer to peer operating mode change event status
  3266. *
  3267. * Return: QDF Status
  3268. */
  3269. QDF_STATUS
  3270. wlan_mlme_set_peer_indicated_ch_width(struct wlan_objmgr_psoc *psoc,
  3271. struct peer_oper_mode_event *data);
  3272. /**
  3273. * wlan_mlme_get_peer_indicated_ch_width() - Get peer indicated channel width
  3274. * @psoc: pointer to psoc object
  3275. * @data: Pointer to peer operating mode change event status
  3276. *
  3277. * Return: QDF Status
  3278. */
  3279. QDF_STATUS
  3280. wlan_mlme_get_peer_indicated_ch_width(struct wlan_objmgr_psoc *psoc,
  3281. struct peer_oper_mode_event *data);
  3282. /**
  3283. * wlan_mlme_set_ft_over_ds() - Update ft_over_ds
  3284. * @psoc: pointer to psoc object
  3285. * @ft_over_ds_enable: value of ft_over_ds
  3286. *
  3287. * Return: QDF_STATUS
  3288. */
  3289. QDF_STATUS wlan_mlme_set_ft_over_ds(struct wlan_objmgr_psoc *psoc,
  3290. uint8_t ft_over_ds_enable);
  3291. /**
  3292. * wlan_mlme_get_dfs_chan_ageout_time() - Get the DFS Channel ageout time
  3293. * @psoc: pointer to psoc object
  3294. * @dfs_chan_ageout_time: output pointer to hold configured value of DFS
  3295. * Channel ageout time
  3296. *
  3297. * Return: QDF Status
  3298. */
  3299. QDF_STATUS
  3300. wlan_mlme_get_dfs_chan_ageout_time(struct wlan_objmgr_psoc *psoc,
  3301. uint8_t *dfs_chan_ageout_time);
  3302. #ifdef WLAN_FEATURE_SAE
  3303. /**
  3304. * wlan_mlme_get_sae_assoc_retry_count() - Get the sae assoc retry count
  3305. * @psoc: pointer to psoc object
  3306. * @retry_count: assoc retry count
  3307. *
  3308. * Return: QDF Status
  3309. */
  3310. QDF_STATUS
  3311. wlan_mlme_get_sae_assoc_retry_count(struct wlan_objmgr_psoc *psoc,
  3312. uint8_t *retry_count);
  3313. /**
  3314. * wlan_mlme_get_sae_auth_retry_count() - Get the sae auth retry count
  3315. * @psoc: pointer to psoc object
  3316. * @retry_count: auth retry count
  3317. *
  3318. * Return: QDF Status
  3319. */
  3320. QDF_STATUS
  3321. wlan_mlme_get_sae_auth_retry_count(struct wlan_objmgr_psoc *psoc,
  3322. uint8_t *retry_count);
  3323. /**
  3324. * wlan_mlme_get_sae_roam_auth_retry_count() - Get the sae roam auth retry count
  3325. * @psoc: pointer to psoc object
  3326. * @retry_count: auth retry count
  3327. *
  3328. * Return: QDF Status
  3329. */
  3330. QDF_STATUS
  3331. wlan_mlme_get_sae_roam_auth_retry_count(struct wlan_objmgr_psoc *psoc,
  3332. uint8_t *retry_count);
  3333. #else
  3334. static inline QDF_STATUS
  3335. wlan_mlme_get_sae_assoc_retry_count(struct wlan_objmgr_psoc *psoc,
  3336. uint8_t *retry_count)
  3337. {
  3338. *retry_count = 0;
  3339. return QDF_STATUS_SUCCESS;
  3340. }
  3341. static inline QDF_STATUS
  3342. wlan_mlme_get_sae_auth_retry_count(struct wlan_objmgr_psoc *psoc,
  3343. uint8_t *retry_count)
  3344. {
  3345. *retry_count = 0;
  3346. return QDF_STATUS_SUCCESS;
  3347. }
  3348. static inline QDF_STATUS
  3349. wlan_mlme_get_sae_roam_auth_retry_count(struct wlan_objmgr_psoc *psoc,
  3350. uint8_t *retry_count)
  3351. {
  3352. *retry_count = 0;
  3353. return QDF_STATUS_SUCCESS;
  3354. }
  3355. #endif
  3356. #ifdef WLAN_FEATURE_ROAM_OFFLOAD
  3357. /**
  3358. * wlan_mlme_get_dual_sta_roaming_enabled - API to get if the dual sta
  3359. * roaming support is enabled.
  3360. * @psoc: Pointer to global psoc object
  3361. *
  3362. * Return: True if dual sta roaming feature is enabled else return false
  3363. */
  3364. bool
  3365. wlan_mlme_get_dual_sta_roaming_enabled(struct wlan_objmgr_psoc *psoc);
  3366. #else
  3367. static inline bool
  3368. wlan_mlme_get_dual_sta_roaming_enabled(struct wlan_objmgr_psoc *psoc)
  3369. {
  3370. return false;
  3371. }
  3372. #endif
  3373. /**
  3374. * mlme_store_fw_scan_channels - Update the valid channel list to mlme.
  3375. * @psoc: Pointer to global psoc object
  3376. * @chan_list: Source channel list pointer
  3377. *
  3378. * Currently the channel list is saved to wma_handle to be updated in the
  3379. * PCL command. This cannot be accessed at target_if while sending vdev
  3380. * set pcl command. So save the channel list to mlme.
  3381. *
  3382. * Return: QDF_STATUS
  3383. */
  3384. QDF_STATUS
  3385. mlme_store_fw_scan_channels(struct wlan_objmgr_psoc *psoc,
  3386. tSirUpdateChanList *chan_list);
  3387. /**
  3388. * mlme_get_fw_scan_channels - Copy the saved valid channel
  3389. * list to the provided buffer
  3390. * @psoc: Pointer to global psoc object
  3391. * @freq_list: Pointer to the frequency list buffer to be filled
  3392. * @saved_num_chan: Number of channels filled
  3393. *
  3394. * Return: QDF_STATUS
  3395. */
  3396. QDF_STATUS mlme_get_fw_scan_channels(struct wlan_objmgr_psoc *psoc,
  3397. uint32_t *freq_list,
  3398. uint8_t *saved_num_chan);
  3399. /**
  3400. * wlan_mlme_get_roam_scan_offload_enabled() - Roam scan offload enable or not
  3401. * @psoc: pointer to psoc object
  3402. * @val: Pointer to the value which will be filled for the caller
  3403. *
  3404. * Return: QDF Status
  3405. */
  3406. QDF_STATUS
  3407. wlan_mlme_get_roam_scan_offload_enabled(struct wlan_objmgr_psoc *psoc,
  3408. bool *val);
  3409. /**
  3410. * wlan_mlme_get_roam_bmiss_final_bcnt() - Get roam bmiss final count
  3411. * @psoc: pointer to psoc object
  3412. * @val: Pointer to the value which will be filled for the caller
  3413. *
  3414. * Return: QDF Status
  3415. */
  3416. QDF_STATUS
  3417. wlan_mlme_get_roam_bmiss_final_bcnt(struct wlan_objmgr_psoc *psoc,
  3418. uint8_t *val);
  3419. /**
  3420. * wlan_mlme_get_roam_bmiss_first_bcnt() - Get roam bmiss first count
  3421. * @psoc: pointer to psoc object
  3422. * @val: Pointer to the value which will be filled for the caller
  3423. *
  3424. * Return: QDF Status
  3425. */
  3426. QDF_STATUS
  3427. wlan_mlme_get_roam_bmiss_first_bcnt(struct wlan_objmgr_psoc *psoc,
  3428. uint8_t *val);
  3429. /**
  3430. * wlan_mlme_get_bmiss_timeout_on_wakeup() - Get bmiss timeout
  3431. * @psoc: pointer to psoc object
  3432. * @val: Pointer to the value which will be filled for the caller
  3433. *
  3434. * Return: QDF Status
  3435. */
  3436. QDF_STATUS
  3437. wlan_mlme_get_bmiss_timeout_on_wakeup(struct wlan_objmgr_psoc *psoc,
  3438. uint8_t *val);
  3439. /**
  3440. * wlan_mlme_get_bmiss_timeout_on_sleep() - Get roam conbmiss timeout
  3441. * @psoc: pointer to psoc object
  3442. * @val: Pointer to the value which will be filled for the caller
  3443. *
  3444. * Return: QDF Status
  3445. */
  3446. QDF_STATUS
  3447. wlan_mlme_get_bmiss_timeout_on_sleep(struct wlan_objmgr_psoc *psoc,
  3448. uint8_t *val);
  3449. /**
  3450. * wlan_mlme_adaptive_11r_enabled() - check if adaptive 11r feature is enaled
  3451. * or not
  3452. * @psoc: pointer to psoc object
  3453. *
  3454. * Return: bool
  3455. */
  3456. #ifdef WLAN_ADAPTIVE_11R
  3457. bool wlan_mlme_adaptive_11r_enabled(struct wlan_objmgr_psoc *psoc);
  3458. #else
  3459. static inline bool wlan_mlme_adaptive_11r_enabled(struct wlan_objmgr_psoc *psoc)
  3460. {
  3461. return false;
  3462. }
  3463. #endif
  3464. /**
  3465. * wlan_mlme_get_mawc_enabled() - Get mawc enabled status
  3466. * @psoc: pointer to psoc object
  3467. * @val: Pointer to the value which will be filled for the caller
  3468. *
  3469. * Return: QDF Status
  3470. */
  3471. QDF_STATUS
  3472. wlan_mlme_get_mawc_enabled(struct wlan_objmgr_psoc *psoc, bool *val);
  3473. /**
  3474. * wlan_mlme_get_mawc_roam_enabled() - Get mawc roam enabled status
  3475. * @psoc: pointer to psoc object
  3476. * @val: Pointer to the value which will be filled for the caller
  3477. *
  3478. * Return: QDF Status
  3479. */
  3480. QDF_STATUS
  3481. wlan_mlme_get_mawc_roam_enabled(struct wlan_objmgr_psoc *psoc, bool *val);
  3482. /**
  3483. * wlan_mlme_get_mawc_roam_traffic_threshold() - Get mawc traffic threshold
  3484. * @psoc: pointer to psoc object
  3485. * @val: Pointer to the value which will be filled for the caller
  3486. *
  3487. * Return: QDF Status
  3488. */
  3489. QDF_STATUS
  3490. wlan_mlme_get_mawc_roam_traffic_threshold(struct wlan_objmgr_psoc *psoc,
  3491. uint32_t *val);
  3492. /**
  3493. * wlan_mlme_get_mawc_roam_ap_rssi_threshold() - Get AP RSSI threshold for
  3494. * MAWC roaming
  3495. * @psoc: pointer to psoc object
  3496. * @val: Pointer to the value which will be filled for the caller
  3497. *
  3498. * Return: QDF Status
  3499. */
  3500. QDF_STATUS
  3501. wlan_mlme_get_mawc_roam_ap_rssi_threshold(struct wlan_objmgr_psoc *psoc,
  3502. uint32_t *val);
  3503. /**
  3504. * wlan_mlme_get_mawc_roam_rssi_high_adjust() - Get high adjustment value
  3505. * for suppressing scan
  3506. * @psoc: pointer to psoc object
  3507. * @val: Pointer to the value which will be filled for the caller
  3508. *
  3509. * Return: QDF Status
  3510. */
  3511. QDF_STATUS
  3512. wlan_mlme_get_mawc_roam_rssi_high_adjust(struct wlan_objmgr_psoc *psoc,
  3513. uint8_t *val);
  3514. /**
  3515. * wlan_mlme_get_mawc_roam_rssi_low_adjust() - Get low adjustment value
  3516. * for suppressing scan
  3517. * @psoc: pointer to psoc object
  3518. * @val: Pointer to the value which will be filled for the caller
  3519. *
  3520. * Return: QDF Status
  3521. */
  3522. QDF_STATUS
  3523. wlan_mlme_get_mawc_roam_rssi_low_adjust(struct wlan_objmgr_psoc *psoc,
  3524. uint8_t *val);
  3525. /**
  3526. * wlan_mlme_get_bss_load_enabled() - Get bss load based roam trigger
  3527. * enabled status
  3528. * @psoc: pointer to psoc object
  3529. * @val: Pointer to the value which will be filled for the caller
  3530. *
  3531. * Return: QDF Status
  3532. */
  3533. QDF_STATUS
  3534. wlan_mlme_get_bss_load_enabled(struct wlan_objmgr_psoc *psoc, bool *val);
  3535. /**
  3536. * wlan_mlme_get_bss_load_threshold() - Get bss load threshold
  3537. * @psoc: pointer to psoc object
  3538. * @val: Pointer to the value which will be filled for the caller
  3539. *
  3540. * Return: QDF Status
  3541. */
  3542. QDF_STATUS
  3543. wlan_mlme_get_bss_load_threshold(struct wlan_objmgr_psoc *psoc, uint32_t *val);
  3544. /**
  3545. * wlan_mlme_get_bss_load_sample_time() - Get bss load sample time
  3546. * @psoc: pointer to psoc object
  3547. * @val: Pointer to the value which will be filled for the caller
  3548. *
  3549. * Return: QDF Status
  3550. */
  3551. QDF_STATUS
  3552. wlan_mlme_get_bss_load_sample_time(struct wlan_objmgr_psoc *psoc,
  3553. uint32_t *val);
  3554. /**
  3555. * wlan_mlme_get_bss_load_rssi_threshold_6ghz() - Get bss load RSSI
  3556. * threshold on 6G
  3557. * @psoc: pointer to psoc object
  3558. * @val: Pointer to the value which will be filled for the caller
  3559. *
  3560. * Return: QDF Status
  3561. */
  3562. QDF_STATUS
  3563. wlan_mlme_get_bss_load_rssi_threshold_6ghz(struct wlan_objmgr_psoc *psoc,
  3564. int32_t *val);
  3565. /**
  3566. * wlan_mlme_get_bss_load_rssi_threshold_5ghz() - Get bss load RSSI
  3567. * threshold on 5G
  3568. * @psoc: pointer to psoc object
  3569. * @val: Pointer to the value which will be filled for the caller
  3570. *
  3571. * Return: QDF Status
  3572. */
  3573. QDF_STATUS
  3574. wlan_mlme_get_bss_load_rssi_threshold_5ghz(struct wlan_objmgr_psoc *psoc,
  3575. int32_t *val);
  3576. /**
  3577. * wlan_mlme_get_bss_load_rssi_threshold_24ghz() - Get bss load RSSI
  3578. * threshold on 2.4G
  3579. * @psoc: pointer to psoc object
  3580. * @val: Pointer to the value which will be filled for the caller
  3581. *
  3582. * Return: QDF Status
  3583. */
  3584. QDF_STATUS
  3585. wlan_mlme_get_bss_load_rssi_threshold_24ghz(struct wlan_objmgr_psoc *psoc,
  3586. int32_t *val);
  3587. /**
  3588. * wlan_mlme_check_chan_param_has_dfs() - Get dfs flag based on
  3589. * channel & channel parameters
  3590. * @pdev: pdev object
  3591. * @ch_params: channel parameters
  3592. * @chan_freq: channel frequency in MHz
  3593. *
  3594. * Return: True for dfs
  3595. */
  3596. bool
  3597. wlan_mlme_check_chan_param_has_dfs(struct wlan_objmgr_pdev *pdev,
  3598. struct ch_params *ch_params,
  3599. uint32_t chan_freq);
  3600. /**
  3601. * wlan_mlme_set_usr_disabled_roaming() - Set user config for roaming disable
  3602. * @psoc: pointer to psoc object
  3603. * @val: user config for roaming disable
  3604. *
  3605. * Return: QDF_STATUS
  3606. */
  3607. QDF_STATUS
  3608. wlan_mlme_set_usr_disabled_roaming(struct wlan_objmgr_psoc *psoc, bool val);
  3609. /**
  3610. * wlan_mlme_get_usr_disabled_roaming() - Get user config for roaming disable
  3611. * @psoc: pointer to psoc object
  3612. * @val: user config for roaming disable
  3613. *
  3614. * Return: QDF_STATUS
  3615. */
  3616. QDF_STATUS
  3617. wlan_mlme_get_usr_disabled_roaming(struct wlan_objmgr_psoc *psoc, bool *val);
  3618. /**
  3619. * mlme_get_opr_rate() - get operational rate
  3620. * @vdev: vdev pointer
  3621. * @dst: buffer to get rates set
  3622. * @len: length of the buffer
  3623. *
  3624. * Return: length of the rates set
  3625. */
  3626. qdf_size_t mlme_get_opr_rate(struct wlan_objmgr_vdev *vdev, uint8_t *dst,
  3627. qdf_size_t len);
  3628. /**
  3629. * mlme_set_opr_rate() - set operational rate
  3630. * @vdev: vdev pointer
  3631. * @src: pointer to set operational rate
  3632. * @len: length of operational rate
  3633. *
  3634. * Return: QDF_SUCCESS if success
  3635. */
  3636. QDF_STATUS mlme_set_opr_rate(struct wlan_objmgr_vdev *vdev, uint8_t *src,
  3637. qdf_size_t len);
  3638. /**
  3639. * mlme_get_ext_opr_rate() - get extended operational rate
  3640. * @vdev: vdev pointer
  3641. * @dst: buffer to get rates set
  3642. * @len: length of the buffer
  3643. *
  3644. * Return: length of the rates set
  3645. */
  3646. qdf_size_t mlme_get_ext_opr_rate(struct wlan_objmgr_vdev *vdev, uint8_t *dst,
  3647. qdf_size_t len);
  3648. /**
  3649. * mlme_set_ext_opr_rate() - set extended operational rate
  3650. * @vdev: vdev pointer
  3651. * @src: pointer to set extended operational rate
  3652. * @len: length of extended operational rate
  3653. *
  3654. * Return: QDF_SUCCESS if success
  3655. */
  3656. QDF_STATUS mlme_set_ext_opr_rate(struct wlan_objmgr_vdev *vdev, uint8_t *src,
  3657. qdf_size_t len);
  3658. /**
  3659. * mlme_clear_ext_opr_rate() - clear extended operational rate
  3660. * @vdev: vdev pointer
  3661. *
  3662. * Return: QDF_SUCCESS if success
  3663. */
  3664. QDF_STATUS mlme_clear_ext_opr_rate(struct wlan_objmgr_vdev *vdev);
  3665. /**
  3666. * mlme_get_mcs_rate() - get MCS based rate
  3667. * @vdev: vdev pointer
  3668. * @dst: buffer to get rates set
  3669. * @len: length of the buffer
  3670. *
  3671. * Return: length of the rates set
  3672. */
  3673. qdf_size_t mlme_get_mcs_rate(struct wlan_objmgr_vdev *vdev, uint8_t *dst,
  3674. qdf_size_t len);
  3675. /**
  3676. * mlme_set_mcs_rate() - set MCS based rate
  3677. * @vdev: vdev pointer
  3678. * @src: pointer to set MCS based rate
  3679. * @len: length of MCS based rate
  3680. *
  3681. * Return: QDF_SUCCESS if success
  3682. */
  3683. QDF_STATUS mlme_set_mcs_rate(struct wlan_objmgr_vdev *vdev, uint8_t *src,
  3684. qdf_size_t len);
  3685. /**
  3686. * mlme_clear_mcs_rate() - clear MCS based rate
  3687. * @vdev: vdev pointer
  3688. *
  3689. * Return: QDF_SUCCESS if success
  3690. */
  3691. QDF_STATUS mlme_clear_mcs_rate(struct wlan_objmgr_vdev *vdev);
  3692. /**
  3693. * wlan_mlme_is_sta_mon_conc_supported() - Check if STA + Monitor mode
  3694. * concurrency is supported
  3695. * @psoc: pointer to psoc object
  3696. *
  3697. * Return: True if supported
  3698. */
  3699. bool wlan_mlme_is_sta_mon_conc_supported(struct wlan_objmgr_psoc *psoc);
  3700. /**
  3701. * wlan_mlme_get_phy_max_freq_range() - Get phy supported max channel
  3702. * frequency range
  3703. * @psoc: psoc for country information
  3704. * @low_2ghz_chan: 2.4 GHz low channel frequency
  3705. * @high_2ghz_chan: 2.4 GHz high channel frequency
  3706. * @low_5ghz_chan: 5 GHz low channel frequency
  3707. * @high_5ghz_chan: 5 GHz high channel frequency
  3708. *
  3709. * Return: QDF status
  3710. */
  3711. QDF_STATUS wlan_mlme_get_phy_max_freq_range(struct wlan_objmgr_psoc *psoc,
  3712. uint32_t *low_2ghz_chan,
  3713. uint32_t *high_2ghz_chan,
  3714. uint32_t *low_5ghz_chan,
  3715. uint32_t *high_5ghz_chan);
  3716. /**
  3717. * wlan_mlme_is_multipass_sap() -Get multipass sap support
  3718. * @psoc: psoc pointer
  3719. *
  3720. * Return: True, if FW support multipass support.
  3721. */
  3722. bool wlan_mlme_is_multipass_sap(struct wlan_objmgr_psoc *psoc);
  3723. #ifdef FEATURE_WDS
  3724. /**
  3725. * wlan_mlme_get_wds_mode() - Check wds mode supported
  3726. * @psoc: pointer to psoc object
  3727. *
  3728. * Return: supported wds mode
  3729. */
  3730. enum wlan_wds_mode
  3731. wlan_mlme_get_wds_mode(struct wlan_objmgr_psoc *psoc);
  3732. /**
  3733. * wlan_mlme_set_wds_mode() - Set wds mode
  3734. * @psoc: pointer to psoc object
  3735. * @mode: wds mode to set
  3736. *
  3737. * Return: void
  3738. */
  3739. void wlan_mlme_set_wds_mode(struct wlan_objmgr_psoc *psoc,
  3740. enum wlan_wds_mode mode);
  3741. #else
  3742. static inline enum wlan_wds_mode
  3743. wlan_mlme_get_wds_mode(struct wlan_objmgr_psoc *psoc)
  3744. {
  3745. return WLAN_WDS_MODE_DISABLED;
  3746. }
  3747. static inline void wlan_mlme_set_wds_mode(struct wlan_objmgr_psoc *psoc,
  3748. enum wlan_wds_mode mode)
  3749. {
  3750. }
  3751. #endif
  3752. #ifdef WLAN_SUPPORT_TWT
  3753. /**
  3754. * mlme_is_twt_enabled() - Get if TWT is enabled via ini.
  3755. * @psoc: pointer to psoc object
  3756. *
  3757. * Return: True if TWT is enabled else false.
  3758. */
  3759. bool
  3760. mlme_is_twt_enabled(struct wlan_objmgr_psoc *psoc);
  3761. #else
  3762. static inline bool
  3763. mlme_is_twt_enabled(struct wlan_objmgr_psoc *psoc)
  3764. {
  3765. return false;
  3766. }
  3767. #endif /* WLAN_SUPPORT_TWT */
  3768. /**
  3769. * wlan_mlme_skip_tpe() - Get preference to not consider TPE in 2G/5G case
  3770. *
  3771. * @psoc: pointer to psoc object
  3772. *
  3773. * Return: True if host should not consider TPE IE in TX power calculation when
  3774. * operating in 2G/5G bands, false if host should always consider TPE IE values
  3775. */
  3776. bool wlan_mlme_skip_tpe(struct wlan_objmgr_psoc *psoc);
  3777. /**
  3778. * wlan_mlme_is_data_stall_recovery_fw_supported() - Check if data stall
  3779. * recovery is supported by fw
  3780. * @psoc: pointer to psoc object
  3781. *
  3782. * Return: True if supported
  3783. */
  3784. bool
  3785. wlan_mlme_is_data_stall_recovery_fw_supported(struct wlan_objmgr_psoc *psoc);
  3786. /**
  3787. * mlme_cfg_get_eht_caps() - Get the EHT capability info
  3788. * @psoc: pointer to psoc object
  3789. * @eht_cap: Caps that needs to be filled.
  3790. *
  3791. * Return: QDF Status
  3792. */
  3793. QDF_STATUS mlme_cfg_get_eht_caps(struct wlan_objmgr_psoc *psoc,
  3794. tDot11fIEeht_cap *eht_cap);
  3795. /**
  3796. * wlan_mlme_set_bt_profile_con() - Set bluetooth connection profile
  3797. * @psoc: pointer to psoc object
  3798. * @bt_profile_con: Bluetooth connection profile bit
  3799. *
  3800. * Return: None
  3801. */
  3802. void
  3803. wlan_mlme_set_bt_profile_con(struct wlan_objmgr_psoc *psoc,
  3804. bool bt_profile_con);
  3805. /**
  3806. * wlan_mlme_get_bt_profile_con() - Get Bluetooth connection profile
  3807. * @psoc: pointer to psoc object
  3808. *
  3809. * Return: Bluetooth connection profile
  3810. */
  3811. bool
  3812. wlan_mlme_get_bt_profile_con(struct wlan_objmgr_psoc *psoc);
  3813. #ifdef WLAN_FEATURE_11BE_MLO
  3814. /**
  3815. * wlan_mlme_get_sta_mlo_conn_max_num() - get max number of links that sta mlo
  3816. * connection can support
  3817. * @psoc: pointer to psoc object
  3818. *
  3819. * Return: max number of links that sta mlo connection can support
  3820. */
  3821. uint8_t wlan_mlme_get_sta_mlo_conn_max_num(struct wlan_objmgr_psoc *psoc);
  3822. /**
  3823. * wlan_mlme_set_sta_mlo_conn_max_num() - set max number of links that sta mlo
  3824. * connection can support
  3825. * @psoc: pointer to psoc object
  3826. * @value: value to set
  3827. *
  3828. * Return: QDF Status
  3829. */
  3830. QDF_STATUS wlan_mlme_set_sta_mlo_conn_max_num(struct wlan_objmgr_psoc *psoc,
  3831. uint8_t value);
  3832. /**
  3833. * wlan_mlme_set_user_set_link_num() - set number of links that config by user
  3834. * @psoc: pointer to psoc object
  3835. * @value: value to set
  3836. *
  3837. * Return: QDF Status
  3838. */
  3839. QDF_STATUS wlan_mlme_set_user_set_link_num(struct wlan_objmgr_psoc *psoc,
  3840. uint8_t value);
  3841. /**
  3842. * wlan_mlme_set_ml_link_control_mode() - set ml_link_control_mode
  3843. * @psoc: pointer to psoc object
  3844. * @vdev_id: vdev id
  3845. * @value: value to set
  3846. *
  3847. * API get call when host receives vendor command
  3848. * QCA_NL80211_VENDOR_SUBCMD_MLO_LINK_STATE to configure link control mode.
  3849. *
  3850. * Return: none
  3851. */
  3852. void wlan_mlme_set_ml_link_control_mode(struct wlan_objmgr_psoc *psoc,
  3853. uint8_t vdev_id, uint8_t value);
  3854. /**
  3855. * wlan_mlme_get_ml_link_control_mode() - get ml_link_control_mode
  3856. * @psoc: pointer to psoc object
  3857. * @vdev_id: vdev id
  3858. *
  3859. * Return: value of ml_link_control_mode in success
  3860. */
  3861. uint8_t wlan_mlme_get_ml_link_control_mode(struct wlan_objmgr_psoc *psoc,
  3862. uint8_t vdev_id);
  3863. /**
  3864. * wlan_mlme_restore_user_set_link_num() - restore link num when SSR happens
  3865. * @psoc: pointer to psoc object
  3866. *
  3867. * Return: void
  3868. */
  3869. void wlan_mlme_restore_user_set_link_num(struct wlan_objmgr_psoc *psoc);
  3870. /**
  3871. * wlan_mlme_clear_user_set_link_num() - clear user set link num
  3872. * @psoc: pointer to psoc object
  3873. *
  3874. * Return: void
  3875. */
  3876. void wlan_mlme_clear_user_set_link_num(struct wlan_objmgr_psoc *psoc);
  3877. /**
  3878. * wlan_mlme_get_sta_mlo_conn_band_bmp() - get band bitmap that sta mlo
  3879. * connection can support
  3880. * @psoc: pointer to psoc object
  3881. *
  3882. * Return: band bitmap that sta mlo connection can support
  3883. */
  3884. uint8_t wlan_mlme_get_sta_mlo_conn_band_bmp(struct wlan_objmgr_psoc *psoc);
  3885. /**
  3886. * wlan_mlme_set_sta_mlo_simultaneous_links() - set mlo simultaneous links
  3887. * @psoc: pointer to psoc object
  3888. * @value: value to set
  3889. *
  3890. * Return: QDF Status
  3891. */
  3892. QDF_STATUS
  3893. wlan_mlme_set_sta_mlo_simultaneous_links(struct wlan_objmgr_psoc *psoc,
  3894. uint8_t value);
  3895. /**
  3896. * wlan_mlme_get_sta_mlo_simultaneous_links() - get mlo simultaneous links
  3897. * @psoc: pointer to psoc object
  3898. *
  3899. * Return: number of links
  3900. */
  3901. uint8_t wlan_mlme_get_sta_mlo_simultaneous_links(struct wlan_objmgr_psoc *psoc);
  3902. /**
  3903. * wlan_mlme_set_sta_mlo_conn_band_bmp() - set band bitmap that sta mlo
  3904. * connection can support
  3905. * @psoc: pointer to psoc object
  3906. * @value: value to set
  3907. *
  3908. * Return: QDF Status
  3909. */
  3910. QDF_STATUS wlan_mlme_set_sta_mlo_conn_band_bmp(struct wlan_objmgr_psoc *psoc,
  3911. uint8_t value);
  3912. /**
  3913. * wlan_mlme_get_sta_same_link_mld_addr() - check if mld/link use same address
  3914. * @psoc: pointer to psoc object
  3915. *
  3916. * Return: bool to check if the mld/link use same mac address
  3917. */
  3918. bool wlan_mlme_get_sta_same_link_mld_addr(struct wlan_objmgr_psoc *psoc);
  3919. #else
  3920. static inline
  3921. void wlan_mlme_set_ml_link_control_mode(struct wlan_objmgr_psoc *psoc,
  3922. uint8_t vdev_id, uint8_t value)
  3923. {
  3924. }
  3925. static inline
  3926. uint8_t wlan_mlme_get_ml_link_control_mode(struct wlan_objmgr_psoc *psoc,
  3927. uint8_t vdev_id)
  3928. {
  3929. return 0;
  3930. }
  3931. static inline QDF_STATUS
  3932. wlan_mlme_set_user_set_link_num(struct wlan_objmgr_psoc *psoc,
  3933. uint8_t value)
  3934. {
  3935. return QDF_STATUS_SUCCESS;
  3936. }
  3937. static inline
  3938. void wlan_mlme_restore_user_set_link_num(struct wlan_objmgr_psoc *psoc)
  3939. {
  3940. }
  3941. static inline
  3942. void wlan_mlme_clear_user_set_link_num(struct wlan_objmgr_psoc *psoc)
  3943. {
  3944. }
  3945. static inline QDF_STATUS
  3946. wlan_mlme_set_sta_mlo_conn_max_num(struct wlan_objmgr_psoc *psoc,
  3947. uint8_t value)
  3948. {
  3949. return QDF_STATUS_SUCCESS;
  3950. }
  3951. static inline uint8_t
  3952. wlan_mlme_get_sta_mlo_conn_max_num(struct wlan_objmgr_psoc *psoc)
  3953. {
  3954. return 0;
  3955. }
  3956. static inline QDF_STATUS
  3957. wlan_mlme_set_sta_mlo_simultaneous_links(struct wlan_objmgr_psoc *psoc,
  3958. uint8_t value)
  3959. {
  3960. return QDF_STATUS_SUCCESS;
  3961. }
  3962. static inline QDF_STATUS
  3963. wlan_mlme_set_sta_mlo_conn_band_bmp(struct wlan_objmgr_psoc *psoc,
  3964. uint8_t value)
  3965. {
  3966. return QDF_STATUS_SUCCESS;
  3967. }
  3968. #endif
  3969. /**
  3970. * wlan_mlme_set_ba_2k_jump_iot_ap() - Set a flag if ba 2k jump IOT AP is found
  3971. * @vdev: vdev pointer
  3972. * @found: Carries the value true if ba 2k jump IOT AP is found
  3973. *
  3974. * Return: QDF Status
  3975. */
  3976. QDF_STATUS
  3977. wlan_mlme_set_ba_2k_jump_iot_ap(struct wlan_objmgr_vdev *vdev, bool found);
  3978. /**
  3979. * wlan_mlme_is_ba_2k_jump_iot_ap() - Check if ba 2k jump IOT AP is found
  3980. * @vdev: vdev pointer
  3981. *
  3982. * Return: true if ba 2k jump IOT AP is found
  3983. */
  3984. bool
  3985. wlan_mlme_is_ba_2k_jump_iot_ap(struct wlan_objmgr_vdev *vdev);
  3986. /**
  3987. * wlan_mlme_set_last_delba_sent_time() - Cache the last delba sent ts
  3988. * @vdev: vdev pointer
  3989. * @delba_sent_time: Last delba sent timestamp
  3990. *
  3991. * Return: QDF Status
  3992. */
  3993. QDF_STATUS
  3994. wlan_mlme_set_last_delba_sent_time(struct wlan_objmgr_vdev *vdev,
  3995. qdf_time_t delba_sent_time);
  3996. /**
  3997. * wlan_mlme_get_last_delba_sent_time() - Get the last delba sent ts
  3998. * @vdev: vdev pointer
  3999. *
  4000. * Return: Last delba timestamp if cached, 0 otherwise
  4001. */
  4002. qdf_time_t
  4003. wlan_mlme_get_last_delba_sent_time(struct wlan_objmgr_vdev *vdev);
  4004. /**
  4005. * mlme_set_user_ps() - Set the PS user config
  4006. * @psoc: Pointer to psoc object
  4007. * @vdev_id: vdev id
  4008. * @ps_enable: User PS enable
  4009. *
  4010. * Return: QDF_STATUS
  4011. */
  4012. QDF_STATUS mlme_set_user_ps(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
  4013. bool ps_enable);
  4014. /**
  4015. * mlme_get_user_ps() - Set the user ps flag
  4016. * @psoc: Pointer to psoc object
  4017. * @vdev_id: vdev id
  4018. *
  4019. * Return: True if user_ps flag is set
  4020. */
  4021. bool mlme_get_user_ps(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id);
  4022. #ifdef WLAN_FEATURE_P2P_P2P_STA
  4023. /**
  4024. * wlan_mlme_get_p2p_p2p_conc_support() - Get p2p+p2p conc support
  4025. * @psoc: pointer to psoc object
  4026. *
  4027. * Return: Success/failure
  4028. */
  4029. bool
  4030. wlan_mlme_get_p2p_p2p_conc_support(struct wlan_objmgr_psoc *psoc);
  4031. #else
  4032. static inline bool
  4033. wlan_mlme_get_p2p_p2p_conc_support(struct wlan_objmgr_psoc *psoc)
  4034. {
  4035. return false;
  4036. }
  4037. #endif
  4038. /**
  4039. * mlme_get_vht_ch_width() - get vht channel width of fw capability
  4040. *
  4041. * Return: vht channel width
  4042. */
  4043. enum phy_ch_width mlme_get_vht_ch_width(void);
  4044. /**
  4045. * wlan_mlme_get_mgmt_hw_tx_retry_count() - Get mgmt frame hw tx retry count
  4046. * @psoc: pointer to psoc object
  4047. * @frm_type: frame type of the query
  4048. *
  4049. * Return: hw tx retry count
  4050. */
  4051. uint8_t
  4052. wlan_mlme_get_mgmt_hw_tx_retry_count(struct wlan_objmgr_psoc *psoc,
  4053. enum mlme_cfg_frame_type frm_type);
  4054. /**
  4055. * wlan_mlme_get_tx_retry_multiplier() - Get the tx retry multiplier percentage
  4056. * @psoc: pointer to psoc object
  4057. * @tx_retry_multiplier: pointer to hold user config value of
  4058. * tx_retry_multiplier
  4059. *
  4060. * Return: QDF Status
  4061. */
  4062. QDF_STATUS
  4063. wlan_mlme_get_tx_retry_multiplier(struct wlan_objmgr_psoc *psoc,
  4064. uint32_t *tx_retry_multiplier);
  4065. /**
  4066. * wlan_mlme_get_channel_bonding_5ghz - Get the channel bonding
  4067. * val for 5ghz freq
  4068. * @psoc: pointer to psoc object
  4069. * @value: pointer to the value which will be filled for the caller
  4070. *
  4071. * Return: QDF Status
  4072. */
  4073. QDF_STATUS
  4074. wlan_mlme_get_channel_bonding_5ghz(struct wlan_objmgr_psoc *psoc,
  4075. uint32_t *value);
  4076. /**
  4077. * wlan_mlme_update_ratemask_params() - Update ratemask params
  4078. *
  4079. * @vdev: pointer to vdev object
  4080. * @num_ratemask: number of rate masks
  4081. * @rate_params: pointer to ratemask structure
  4082. *
  4083. * Return: QDF Status
  4084. */
  4085. QDF_STATUS
  4086. wlan_mlme_update_ratemask_params(struct wlan_objmgr_vdev *vdev,
  4087. uint8_t num_ratemask,
  4088. struct config_ratemask_params *rate_params);
  4089. /**
  4090. * wlan_mlme_is_channel_valid() - validate channel frequency
  4091. * @psoc: psoc object manager
  4092. * @chan_freq: channel frequency
  4093. *
  4094. * This function validates channel frequency present in valid channel
  4095. * list or not.
  4096. *
  4097. * Return: true or false
  4098. */
  4099. bool wlan_mlme_is_channel_valid(struct wlan_objmgr_psoc *psoc,
  4100. uint32_t chan_freq);
  4101. #ifdef WLAN_FEATURE_MCC_QUOTA
  4102. /**
  4103. * wlan_mlme_set_user_mcc_quota() - set the user mcc quota in mlme
  4104. * @psoc: pointer to psoc object
  4105. * @quota: pointer to user set mcc quota object
  4106. *
  4107. * Return: QDF Status
  4108. */
  4109. QDF_STATUS wlan_mlme_set_user_mcc_quota(struct wlan_objmgr_psoc *psoc,
  4110. struct wlan_user_mcc_quota *quota);
  4111. /**
  4112. * wlan_mlme_get_user_mcc_quota() - Get the user mcc quota from mlme
  4113. * @psoc: pointer to psoc object
  4114. * @quota: pointer to user set mcc quota object
  4115. *
  4116. * Return: QDF Status
  4117. */
  4118. QDF_STATUS wlan_mlme_get_user_mcc_quota(struct wlan_objmgr_psoc *psoc,
  4119. struct wlan_user_mcc_quota *quota);
  4120. /**
  4121. * wlan_mlme_get_user_mcc_duty_cycle_percentage() - Get user mcc duty cycle
  4122. * @psoc: pointer to psoc object
  4123. *
  4124. * Return: MCC duty cycle if MCC exists for the user MCC quota, else 0
  4125. */
  4126. uint32_t
  4127. wlan_mlme_get_user_mcc_duty_cycle_percentage(struct wlan_objmgr_psoc *psoc);
  4128. #else
  4129. static inline QDF_STATUS
  4130. wlan_mlme_set_user_mcc_quota(struct wlan_objmgr_psoc *psoc,
  4131. struct wlan_user_mcc_quota *quota)
  4132. {
  4133. return QDF_STATUS_SUCCESS;
  4134. }
  4135. static inline QDF_STATUS
  4136. wlan_mlme_get_user_mcc_quota(struct wlan_objmgr_psoc *psoc,
  4137. struct wlan_user_mcc_quota *quota)
  4138. {
  4139. return QDF_STATUS_E_NOSUPPORT;
  4140. }
  4141. static inline uint32_t
  4142. wlan_mlme_get_user_mcc_duty_cycle_percentage(struct wlan_objmgr_psoc *psoc)
  4143. {
  4144. return 0;
  4145. }
  4146. #endif /* WLAN_FEATURE_MCC_QUOTA */
  4147. /**
  4148. * mlme_get_max_he_mcs_idx() - get max mcs index from he cap information
  4149. * @mcs_ch_width: channel width
  4150. * @hecap_rxmcsnssmap: rx mcs map from he cap
  4151. * @hecap_txmcsnssmap: tx mcs map from he cap
  4152. *
  4153. * Return: the maximum MCS supported
  4154. */
  4155. uint8_t mlme_get_max_he_mcs_idx(enum phy_ch_width mcs_ch_width,
  4156. u_int16_t *hecap_rxmcsnssmap,
  4157. u_int16_t *hecap_txmcsnssmap);
  4158. /**
  4159. * mlme_get_max_vht_mcs_idx() - get max mcs index from vht cap information
  4160. * @rx_vht_mcs_map: rx mcs map from vht cap
  4161. * @tx_vht_mcs_map: tx mcs map from vht cap
  4162. *
  4163. * Return: the maximum MCS supported
  4164. */
  4165. uint8_t mlme_get_max_vht_mcs_idx(u_int16_t rx_vht_mcs_map,
  4166. u_int16_t tx_vht_mcs_map);
  4167. #ifdef WLAN_FEATURE_SON
  4168. /**
  4169. * mlme_save_vdev_max_mcs_idx() - Save max mcs index of vdev
  4170. * @vdev: pointer to vdev object
  4171. * @max_mcs_idx: max_mcs_idx to save
  4172. *
  4173. * Return: QDF Status
  4174. */
  4175. QDF_STATUS mlme_save_vdev_max_mcs_idx(struct wlan_objmgr_vdev *vdev,
  4176. uint8_t max_mcs_idx);
  4177. /**
  4178. * mlme_get_vdev_max_mcs_idx() - Get max mcs index of vdev
  4179. * @vdev: pointer to vdev object
  4180. *
  4181. * Return max mcs index of vdev
  4182. */
  4183. uint8_t mlme_get_vdev_max_mcs_idx(struct wlan_objmgr_vdev *vdev);
  4184. #endif /* WLAN_FEATURE_SON */
  4185. /**
  4186. * wlan_mlme_set_safe_mode_enable() - set safe_mode_enable flag
  4187. * based on value set by user space.
  4188. *
  4189. * @psoc: psoc context
  4190. * @safe_mode_enable: safe mode enabled or not
  4191. *
  4192. * Return: none
  4193. */
  4194. void wlan_mlme_set_safe_mode_enable(struct wlan_objmgr_psoc *psoc,
  4195. bool safe_mode_enable);
  4196. /**
  4197. * wlan_mlme_get_safe_mode_enable() - get safe_mode_enable set by user
  4198. * space
  4199. *
  4200. * @psoc: psoc context
  4201. * @safe_mode_enable: safe mode enabled or not
  4202. *
  4203. * Return: none
  4204. */
  4205. void wlan_mlme_get_safe_mode_enable(struct wlan_objmgr_psoc *psoc,
  4206. bool *safe_mode_enable);
  4207. /**
  4208. * wlan_mlme_get_6g_ap_power_type() - get the power type of the
  4209. * vdev operating on 6GHz.
  4210. *
  4211. * @vdev: vdev context
  4212. *
  4213. * Return: 6g_power_type
  4214. */
  4215. uint32_t wlan_mlme_get_6g_ap_power_type(struct wlan_objmgr_vdev *vdev);
  4216. QDF_STATUS wlan_connect_hw_mode_change_resp(struct wlan_objmgr_pdev *pdev,
  4217. uint8_t vdev_id,
  4218. wlan_cm_id cm_id,
  4219. QDF_STATUS status);
  4220. /**
  4221. * wlan_mlme_get_ch_width_from_phymode() - Convert phymode to ch_width
  4222. * @phy_mode: Phy mode
  4223. *
  4224. * Return: enum phy_ch_width
  4225. */
  4226. enum phy_ch_width
  4227. wlan_mlme_get_ch_width_from_phymode(enum wlan_phymode phy_mode);
  4228. /**
  4229. * wlan_mlme_get_peer_ch_width() - get ch_width of the given peer
  4230. * @psoc: psoc context
  4231. * @mac: peer mac
  4232. *
  4233. * Return: enum phy_ch_width
  4234. */
  4235. enum phy_ch_width
  4236. wlan_mlme_get_peer_ch_width(struct wlan_objmgr_psoc *psoc, uint8_t *mac);
  4237. #if defined(WLAN_FEATURE_SR)
  4238. /**
  4239. * wlan_mlme_get_sr_enable_modes() - get mode for which SR is enabled
  4240. *
  4241. * @psoc: psoc context
  4242. * @val: pointer to hold the value of SR(Spatial Reuse) enable modes
  4243. *
  4244. * Return: void
  4245. */
  4246. void
  4247. wlan_mlme_get_sr_enable_modes(struct wlan_objmgr_psoc *psoc, uint8_t *val);
  4248. #endif
  4249. /**
  4250. * wlan_mlme_set_edca_pifs_param() - set edca/pifs param for ll sap
  4251. * @ep: pointer to wlan_edca_pifs_param_ie
  4252. * @type: edca_param_type
  4253. *
  4254. * Return: None
  4255. */
  4256. void
  4257. wlan_mlme_set_edca_pifs_param(struct wlan_edca_pifs_param_ie *ep,
  4258. enum host_edca_param_type type);
  4259. /**
  4260. * wlan_mlme_stats_get_periodic_display_time() - get display time
  4261. * @psoc: pointer to psoc object
  4262. * @periodic_display_time: buffer to hold value
  4263. *
  4264. * Return: QDF Status
  4265. */
  4266. QDF_STATUS
  4267. wlan_mlme_stats_get_periodic_display_time(struct wlan_objmgr_psoc *psoc,
  4268. uint32_t *periodic_display_time);
  4269. /**
  4270. * wlan_mlme_is_bcn_prot_disabled_for_sap() - Is beacon protection config
  4271. * disabled for SAP interface
  4272. *
  4273. * @psoc: pointer to psoc object
  4274. *
  4275. * Return: is beacon protection disabled
  4276. */
  4277. bool
  4278. wlan_mlme_is_bcn_prot_disabled_for_sap(struct wlan_objmgr_psoc *psoc);
  4279. /**
  4280. * wlan_mlme_get_src_addr_from_frame() - Get source address of the frame
  4281. * @frame: frame ptr
  4282. *
  4283. * Extract source mac address of the frame
  4284. *
  4285. * Return: Ptr for extracted src mac address
  4286. *
  4287. */
  4288. uint8_t *
  4289. wlan_mlme_get_src_addr_from_frame(struct element_info *frame);
  4290. /*
  4291. * wlan_mlme_get_sap_ps_with_twt() - power save with twt config enabled/disabled
  4292. * for SAP interface
  4293. *
  4294. * @psoc: pointer to psoc object
  4295. *
  4296. * Return: power save enabled/disabled
  4297. */
  4298. bool
  4299. wlan_mlme_get_sap_ps_with_twt(struct wlan_objmgr_psoc *psoc);
  4300. /**
  4301. * wlan_mlme_get_max_bw() - Get max supported bandwidth
  4302. *
  4303. * Extract max supported bandwidth
  4304. *
  4305. * Return: enum phy_ch_width
  4306. *
  4307. */
  4308. enum phy_ch_width wlan_mlme_get_max_bw(void);
  4309. /**
  4310. * wlan_mlme_get_sta_ch_width() - Get current operating
  4311. * channel width for STA / P2P-CLI mode
  4312. *
  4313. * @vdev: STA / P2P-CLI vdev
  4314. * @ch_width: Returned channel width
  4315. *
  4316. * Return: QDF_STATUS_SUCCESS for success otherwise QDF_STATUS_E_INVAL
  4317. *
  4318. */
  4319. QDF_STATUS wlan_mlme_get_sta_ch_width(struct wlan_objmgr_vdev *vdev,
  4320. enum phy_ch_width *ch_width);
  4321. /**
  4322. * wlan_mlme_set_ul_mu_config() - set ul mu config
  4323. *
  4324. * @psoc: pointer to psoc object
  4325. * @vdev_id : vdev_id
  4326. * @ulmu_disable : ulmu_disable value
  4327. *
  4328. * Return: QDF Status
  4329. */
  4330. QDF_STATUS
  4331. wlan_mlme_set_ul_mu_config(struct wlan_objmgr_psoc *psoc, uint8_t vdev_id,
  4332. uint8_t ulmu_disable);
  4333. /**
  4334. * wlan_mlme_assemble_rate_code() - assemble rate code to be sent to FW
  4335. *
  4336. * @preamble: rate preamble
  4337. * @nss: number of spatial streams
  4338. * @rate: rate index
  4339. *
  4340. * Rate code assembling is different for targets which are 11ax capable.
  4341. * Check for the target support and assemble the rate code accordingly.
  4342. *
  4343. * Return: assembled rate code
  4344. */
  4345. uint32_t
  4346. wlan_mlme_assemble_rate_code(uint8_t preamble, uint8_t nss, uint8_t rate);
  4347. /**
  4348. * wlan_mlme_set_ap_oper_ch_width() - set SAP current operating ch_width
  4349. *
  4350. * @vdev: SAP VDEV object
  4351. * @ch_width: ch_width to be cached
  4352. *
  4353. * Return: QDF Status
  4354. */
  4355. QDF_STATUS
  4356. wlan_mlme_set_ap_oper_ch_width(struct wlan_objmgr_vdev *vdev,
  4357. enum phy_ch_width ch_width);
  4358. /**
  4359. * wlan_mlme_get_ap_oper_ch_width() - get SAP current operating ch_width
  4360. *
  4361. * @vdev: SAP VDEV object
  4362. *
  4363. * Return: Current SAP operating ch_width
  4364. */
  4365. enum phy_ch_width
  4366. wlan_mlme_get_ap_oper_ch_width(struct wlan_objmgr_vdev *vdev);
  4367. #endif /* _WLAN_MLME_API_H_ */