Commit Graph

60 Commits

Author SHA1 Message Date
Rahul Gusain
995b7ffc4a qcacld-3.0: Add INI to enable/disable NAN EHT cap
As per new requirement, add INI parameter to enable/disable NAN
EHT capability.
Host driver checks this INI value to decide whether it need to
send EHT IE capabilities for NAN and NDI VDEV or not.

Change-Id: I056c174cbc9a7ed2cf6318e43ed431e6c6e5ed30
CRs-Fixed: 3657226
2023-11-12 15:21:48 -08:00
Rahul Gusain
bb7e163983 Revert "qcacld-3.0: Block NDP_END_ALL req till last NDP_END is received"
This reverts commit 54c2fe240a.

Change-Id: Ic0028674e4728b951215bf7b4d9a7535b8b49efe
CRs-Fixed: 3523826
2023-06-08 20:46:22 -07:00
Rahul Gusain
54c2fe240a qcacld-3.0: Block NDP_END_ALL req till last NDP_END is received
Firmware sends NDP_HOST_UPDATE event as an immediate response to this
request and starts cleaning peers one by one. Once an NDP session is
ended (indicating NDP_END to peer + internal cleanup), firmware sends
NDP_END_IND to host.
Currently, host driver stops the wait timer and change state from NDP
end to disconnected upon receiving the NDP_HOST_UPDATE. But firmware
might still be in the process of NDP cleanup. As the NDP_END_ALL
context is unblocked, driver may send NAN disable request to firmware.
This may cause inconsistency in firmware state machine and firmware may
drop the ongoing NDP_END request. So, peer doesn't get the NDP_END frame
in such cases.

Unblock the NDP_END_ALL-wait call only upon last NDP_END indication to
avoid such issues. This change moves the major functionality of
NDP_HOST_UPDATE processing to last NDP_END indication. Cleanup/remove
the processing of NDP_HOST_UPDATE as it's not needed anymore.

Change-Id: I19d3e40700c1c0501b9c809820262472bf9bdba4
CRs-Fixed: 3512847
2023-06-02 16:47:31 -07:00
Jyoti Kumari
4ea4347be1 qcacld-3.0: Pass vdev_id as an argument in policy_mgr_get_pcl()
Pass vdev_id as an argument in policy_mgr_get_pcl()

Change-Id: If016b2ad1e47d1d8364037e44bd984e5b95c8d6f
CRs-Fixed: 3412927
2023-03-22 00:40:19 -07:00
Pragaspathi Thilagaraj
fbf0ea73d5 qcacld-3.0: Don't allow TDLS on MLO vdev
TDLS is not supported on ML STA but it gets enabled
currently when connected with ML AP and TDLS discovery request
is sent to peer devices.

So don't allow TDLS on MLO vdev.

Change-Id: I5bb9e03a0be3f3249aa7af664666a53a67ee812d
CRs-Fixed: 3416206
2023-03-09 23:26:11 -08:00
Rahul Gusain
6e78070bc6 qcacld-3.0: extract NAN vdev_id from mgmt BSSID
Currently, driver finds PASN peer from BSSID in mgmt auth frame
and with help of this peer, it extracts the vdev_id. It uses this
vdev_id to retrieve the adapter in hdd.
But for NAN iface, there is no PASN peer and driver drops the
auth mgmt frame as no valid vdev_id available.

The NAN Cluster ID is a MAC address that takes a value from
50-6F-9A-01-00-00 to 50-6F-9A-01-FF-FF and is carried in the A3
field of some of the NAN frames.
So, to fix this, compare the first four bytes BSSID with
"50-6F-9A-01" and extract the vdev from vdev_list for NAN opmode.

Change-Id: Ie4f15549e3bd8378e362538da4d7ec49e84ad138
CRs-Fixed: 3382962
2023-01-24 09:39:23 -08:00
Roopavathi Lingampalli
38bf757799 qcacld-3.0: Add Component APIs for required ucfg APIs in DP component
When component dependent functions calling from higher
modules or any other components, it uses ucfg APIs pattern.
Calling ucfg dependent APIs is acceptable for higher modules
like HDD, OSIF but for another components like DP to avoid
using ucfg APIs here, implementing component APIs for existing
ucfg APIs to other components like NAN, vdev_mgr in DP
component module.

Change-Id: Ia5431c7de7fc944aacf5c8a328072a8ec31e8f3f
CRs-Fixed: 3351496
2023-01-17 21:04:25 -08:00
Divyajyothi Goparaju
adfb3a43d6 qcacld-3.0: Optimize pdev/vdev set param command
Currently host sends many pdev/vdev set param
commands separately to firmware from hdd.

Combine multiple pdev/vdev set params and
send to WMI to reduce number of transactions.
Also replace target wmi pdev/vdev params with host wmi
pdev/vdev params to fix existing broken layering
violation.

Change-Id: Ib76f5bd5f582a2c67486f6773ff6fd486b3d84cf
CRs-Fixed: 3333732
2022-12-30 00:06:07 -08:00
Jeff Johnson
116c817bb8 qcacld-3.0: Fix NAN Documentation
The kernel-doc script identified a multitude of documentation issues
in components/nan, so fix them.

Change-Id: Ibec4c381da3088f704264d04f756d82d20613c46
CRs-Fixed: 3359549
2022-12-27 19:09:33 -08:00
Jeff Johnson
56e9a4a4ef qcacld-3.0: components: nan: Fix misspellings
Fix misspellings in components/nan/...

Change-Id: I674974e300e440205676f822d0068e90ae1cc0c8
CRs-Fixed: 3303640
2022-10-07 03:49:24 -07:00
Srinivas Dasari
d2a4401675 Revert "qcacld-3.0: Make default value of ndi_max_support as 2"
Enabling ndi_max_support=2 is consuming 4 vdevs + 11 peers
in firmware when STA and NAN(+2 NDIs) are active. Max peers
allowed in firmware are 11 only and this ini configuration is
consuming all of them.
There is no provision/memory for new peer allocation even for
simple use cases like roaming(roaming needs a temporary peer).

Revert this change and set the ini ndi_max_support=2 in target
specific ini files if required to avoid the peer exhaust issue.

This reverts change: Id45147541dba057c2f3420adee43c7a56e3ee72b.

Change-Id: If655b63071b07e96b4e343b8e1bb65acd33be625
CRs-Fixed: 3120555
2022-02-09 13:08:38 -08:00
Jyoti Kumari
e5b79679ef qcacld-3.0: Add MLO STA + NAN + NDI service cap support
Add MLO STA + NAN + NDI service cap support

Change-Id: I736a68552502f5fc1fb498cfd8db6bad99a75b5e
CRs-Fixed: 3120620
2022-02-02 17:11:06 -08:00
Srinivas Dasari
69b074e9f9 qcacld-3.0: Make default value of ndi_max_support as 2
Currently, the ini param "ndi_max_support" is set to 1 in the
ini definition though DUT can support maximum 2 NDIs.
Customers need to set the ini param to 2 in ini file
in order to support two NDIs. This ini param value needs
to be maintained across chipsets and android versions,
which is difficult.
Change the default value to 2 to avoid these. If any customer
needs the value to be 1, the same can be set in customer/target
specific ini files.

Change-Id: Id45147541dba057c2f3420adee43c7a56e3ee72b
CRs-Fixed: 3097045
2021-12-28 05:19:17 -08:00
Bapiraju Alla
6058846058 qcacld-3.0: Fix mem leak with NDP peer multicast address list
Currently, NDP peer multicast address is derived from peer MAC address
and cached in the host. While removing the NDP peer, peer MAC address
is used to search the cached multicast address list. Because of this,
peer multicast address list is not getting freed.

To resolve this, derive peer multicast address from the peer MAC address
while clearing the cached multicast address list.

Since MAX NDP sessions are 8, allocate memory for peer multicast address
list during the NAN vdev private object allocation. This avoids the
special handling for peer multicast list in multiple error scenarios.

Change-Id: Ifbf890a4b9c8be54d84a5b57ed8f6c237ecd51ca
CRs-Fixed: 3085069
2021-12-01 04:22:56 -08:00
Bapiraju Alla
5cf970b5c7 qcacld-3.0: Derive NDP peer multicast address from peer MAC address
Currently, driver is depending on NS frame to be received to configure
peer multicast address for an NDP session. If there is a delay in NS
frame reception, peer multicast address list will be configured to the
FW without actual peer multicast address. Because of this, FW will drop
the NS frame from NDP peer.

To address this, derive peer multicast address from peer MAC address
and include it in multicast address list that is configured to the FW.

Change-Id: I92a575352d592b4001dc4f061e31eb7f592f8445
CRs-Fixed: 3066990
2021-11-24 02:43:52 -08:00
Lincoln Tran
369c4ae107 qcacld-3.0: Store NDI beamform service bit
Store the NAN NDI beamform service bit in the NAN capability struct and
add API to access that value.

Change-Id: I429fc870b5287bd40855b9277d14b19574974a46
CRs-fixed: 2876730
2021-02-18 05:34:58 -08:00
Bapiraju Alla
20da92c02f qcacld-3.0: Add INI parameter to configure NAN in 6GHz
Currently, there is no INI parameter to control NAN feature in 6GHz
frequency band. Because of this, there is no provision to disable the
NAN in 6GHz when there is no requirement.

To address this, add INI parameter to configure NAN feature in 6GHz.

Change-Id: I6b4faa8e8aa1a3df72539fed1d7ff3cc8287debd
CRs-Fixed: 2817920
2020-11-24 15:03:04 -08:00
Bapiraju Alla
dc1fe5a7f4 qcacld-3.0: Reduce NDP keep alive time value to 14ms
NDP connection will be active for keep alive period even after receiving
NDP end request. The default value for this keep alive period if 20ms.
update the default value as 14ms to reduce the wait time for connection
termination.

Change-Id: I3d09ce764846d7e535a7369d32a730907b621735
CRs-Fixed: 2802723
2020-10-23 03:52:47 -07:00
Abdul Muqtadeer Ahmed
36d112aeab qcacld-3.0: Change the default value of ini param nan_feature_config
Set nan_feature_config default as 0 from 1 in INI to have DW interval for
NMNS mode when device goes to suspend mode.

Change-Id: Ib0044ca36cba570f51edcc0006f8e54c55d673d3
CRs-Fixed: 2776238
2020-10-09 04:18:52 -07:00
Srinivas Dasari
fb7989e27a qcacld-3.0: Send nan enabled/disabled flag of SRD channels to fw
Check if NAN SRD operation is enabled in the ini
"etsi13_srd_chan_in_master_mode" and send the same to firmware
for all SRD channels.

Change-Id: I2aa8fd34c67b2061963b62a34d29c73740af3a76
CRs-Fixed: 2748455
2020-08-27 18:36:59 -07:00
Srinivas Dasari
7586ee3a5e qcacld-3.0: Send NAN disable indication to userspace upon SSR
Currently, host driver sends NAN disable request to firmware and
firmware sends NAN disable indication as a response. Host driver
forwards this indication to framework. But when SSR happens,
driver needs to send this NAN disable indication to framework
as firmware lost the NAN context. This allows framework to
initiate NAN again. Send the NAN disable indication with success
status code to framework after recovery.

Change-Id: Ic2139e159f0c1d9c1fb5c39597ce18e0787e809b
CRs-Fixed: 2735047
2020-07-22 11:55:24 -07:00
Gururaj Pandurangi
7792f58388 qcacld-3.0: Enable NAN and NAN datapath by default
The NAN configs gEnableNanSupport and genable_nan_datapath
are being removed from ini config file. So, enable them by
default in .h file.

Change-Id: Ibc1e91e6d010994b5e1419b2241f846e0fde8969
CRs-Fixed: 2710133
2020-07-20 21:54:09 -07:00
Srinivas Dasari
440a823073 qcacld-3.0: Update policy mgr table if nan_conc control is supported
Currently, policy mgr table entries correspond to NAN/NDI are
updated only if nan_dbs is supported. Update/access the
policy mgr table even when nan_conc_control is supported by host.
This allows the host to take care of NAN cuncurrencies through
policy mgr on the non-DBS platforms.
Process NAN enable request in host if nan_conc_control is
supported, which updates the NAN entry to policy mgr table.

Change-Id: Id6e58a9bfde6ceb66a8a0b33136880f75e36090f
CRs-Fixed: 2729995
2020-07-12 07:31:19 -07:00
Srinivas Dasari
8e493f081d qcacld-3.0: Handle SAP+NAN concurrency when NAN_DBS isn't supported
When nan_sap and nan_disable are supported but nan_dbs is not
supported,
1. Allow SAP+NAN concurrency if force SCC is supported
2. Disable NAN if SAP comes up on a different band and force SCC is
   not supported
3. Reject NAN enable if SAP is already on a different band and force SCC is
   not supported

Change-Id: Ic53eedcda2e5b314f9be2a4bd913d5e63f6613a2
CRs-Fixed: 2729986
2020-07-11 22:39:29 -07:00
Srinivas Dasari
d296457502 qcacld-3.0: Rename nan_disable_support to nan_conc_controlled_by_host
nan_disable_support is the firmware capability to allow host to
disable NAN. So that host can disable NAN in any unsupported
concurrencies. This was actually introduced to handle
NAN concurrencies. Rename the capability flag and corresponding
APIs across host driver to resemble the functionality.

Change-Id: I24805194fdb855040bcc518acc96459ee7cb5128
CRs-Fixed: 2729984
2020-07-11 20:32:22 -07:00
Srinivas Dasari
c2b4e154f3 qcacld-3.0: Ini bitmap to enable/disable a particular NAN feature
NAN protocol runs in firmware and controlled by framework.
Framework configures multiple NAN discovery params while enabling
NAN. Framework configurations would be based on the framework
constraints or realtime scenarios like resource(memory/power/..)
consumption. But some of these params might need to be controlled
explicitly based on the usage.
NAN DW is one such parameter, which is configured as 4 seconds
when the device is in sync role and the screen is off. But
for some usecases, this param might have to be 512ms always
irrespective of screen off/on for some targets. Add an ini param
"nan_feature_config" to set a bit to indicate firmware whether to
honor framework configured DW value or the firmware default value.
Send the vdev param on NAN supported vdev by setting the "bit 0"
to indicate firmware to allow framework configured DW value.
If this bit is not set, firmware shall consider its default value.

Change-Id: I0476bca2bbe676beccfff207f5b4ea31e89031e2
CRs-Fixed: 2721970
2020-07-08 18:55:48 -07:00
Srinivas Dasari
2586d8f598 qcacld-3.0: cleanup NAN state upon NAN enable/disable timeout
Currently, driver sends NAN enable/disable request to firmware
and waits for the response. NAN state is cleaned up when NAN
disable indication is received. But if firmware doesn't respond to
NAN enable or disable request, a timeout happens and NAN state is
not cleaned up.
Cleanup the NAN state upon timeout for NAN enable/disable request.

Change-Id: Iadfff2b4d010407f04b529ff81b1ce1f11064695
CRs-Fixed: 2723094
2020-07-02 18:23:16 -07:00
Abhishek Ambure
9e3400ac77 qcacld-3.0: Add support to configure max ndi host supports
Introduce INI "ndi_max_support" to configure max number of ndi
interfaces host supports. Host configures max number of ndi
interfaces support in firmware using WMI_INIT_CMD.

Change-Id: I287b9f96b98103e67cf35d0c02488a28af731044
CRs-Fixed: 2701557
2020-06-10 07:25:54 -07:00
Abhishek Ambure
a6afc073d0 qcacld-3.0: Add ini support to configure max ndp sessions in fw
Introduce INI "ndp_max_sessions" to configure max number of ndp
sessions host supports. Firmware advertises max number of ndp
sessions supported in wmi_service_ready_ext2 event. If the firmware
advertises non-zero value of max ndp sessions then host configures
max ndp sessions support in firmware using WMI_INIT_CMD.

Host uses a minimum of "ndp_max_sessions" value and firmware
advertised max ndp session value to configure max number of ndp
sessions in firmware.

Change-Id: I613815f384f9b0a61711324c85ecfa095d133360
CRs-Fixed: 2673120
2020-06-08 16:00:50 -07:00
Srinivas Dasari
632c058365 qcacld-3.0: Send NDI del rsp in NAN_DATA_DISCONNECTED_STATE state
NDI delete response is sent to userspace only when NDI is in
NAN_DATA_NDI_DELETING_STATE state. But NDI could be in
NAN_DATA_DISCONNECTED_STATE state if cleanup happens through
NDP_END_ALL path. Driver doesn't send response to userspace in
this case.
Send the response to userspace in NAN_DATA_DISCONNECTED_STATE also
as the application might be waiting for NDI delete status.
Also, use set/get APIs and avoid accessing NDI state directly.

Change-Id: I81a6b19a77144c76dde145f126c45b2ca67ff093
CRs-Fixed: 2679581
2020-05-09 00:56:50 -07:00
Srinivas Dasari
9a0ed3383c qcacld-3.0: Delete all NDP peers when NDI is removed
When NDI is removed from framework, driver deletes all NDPs
as part of eWNI_SME_STOP_BSS_REQ. Driver posts WMA_DELETE_STA_RSP
to lim from wma just after sending PEER_DELETE request to
firmware for NDP and ignores the DEL_STA response from firmware.
If there are multiple peers, all peer delete requests are sent
back to back to firmware. NDI peer delete and NDI VDEV delete
request also follow these immediately. All these commands
can go back to back to firmware as driver doesn't wait for
any of these responses.
But firmware needs some time to send NDP end frame to
the NDP peer after receiving NDP peer delete. Firmware might hold
the NDP peer delete request till it successfully sends the frame
to the peer.
Driver must wait till the NDP peer delete response is received to
proceed further with NDI cleanup/NDI vdev delete.
So, send NDP_END_ALL to firmware to let the firmware
initiate cleanup for all NDP peers. Use ucfg_nan_disable_ndi to
do the same which takes care of waiting for response from firmware
indicating cleanup has started. Then wait for all NDP END
indications and unblock the wait upon receiving last NDP END
indication.

Change-Id: I250883b3e9759ad903c3ce17f8c2c0b74a81f496
CRs-Fixed: 2619757
2020-04-27 19:51:08 -07:00
Srinivas Dasari
11c907f867 qcacld-3.0: Consider host and firmware capa for NAN separate vdev
Firmware advertises the NAN separate vdev capability through
the service capability wmi_service_nan_vdev and host advertises
through the ini param nan_separate_iface_support. Both of the
capabilities must be checked to support the NAN separate vdev
support. Define an API to check both the capabilities and made
the individual capability APIs static. So that individual APIs
are not accessed outside this common API. Use this API to
know the support. This is to avoid any possible misses in
checking the support.
For example, NAN vdev id is fetched from the NAN enable
response message received from firmware only based on
firmware capability in nan_handle_enable_rsp. If firmware
supports the feature and ini is set to 0, then vdev id might
be invalid as it's fetched from the NAN enable response
without considering host capability. If either firmware or
host doesn't support NAN separate vdev feature, firmware
creates vdev and it may not fill the vdev id in NAN enable
response. Host shall use NAN_PSEUDO_VDEV_ID then.
So, consider NAN separate vdev feature as supported only if
both host and firmware support.
Also fetch the firmware capability to support NAN separate vdev
when wma_rx_service_ready_ext_event is received and update to NAN
psoc priv object.

Change-Id: I50e76fbe17befb28a5262fc26f5675b67f4d21f2
CRs-Fixed: 2650354
2020-04-17 17:24:13 -07:00
gaurank kathpalia
82511bc630 qcacld-3.0: Add support for STA+NAN+NDI+NDI
Add support for four port concurrency for
STA+NAN discovery + NDI + NDI.

Change-Id: I7d6d3f482a61bef7f3d0a31eee3fdfe5e5e9d879
CRs-Fixed: 2633982
2020-04-01 10:46:22 -07:00
Abhishek Ambure
48b790c62d qcacld-3.0: Add INI support to disable STA roaming
Use INI "sta_disable_roam" to disable roaming on STA interface if
connection on other interfaces ex. p2p, ndp comes up. Each bit of
the INI "sta_disable_roam" represents an interface.
ex. LFR3_STA_ROAM_DISABLE_BY_P2P BIT(0)
    LFR3_STA_ROAM_DISABLE_BY_NAN BIT(1)

As INI "sta_disable_roam" is generic for all the interfaces, cleanup
for INI "p2p_disable_roam" done.

Change-Id: Icd05a97c640ca07978d9960a33de036ed6fe38df
CRs-Fixed: 2637555
2020-03-13 19:22:14 -07:00
Ashish Kumar Dhanotiya
b3ae646bf2 qcacld-3.0: Add support for the NAN config items
Currently there is no inis for NAN component:
1. To configure the keep alive period for the
NDI interface.
2. To enable/disable discovery of NAN cluster with
Master Preference (MP) as 0 when a new device is
enabling NAN.

Add ini support to configure above mentioned values.

Change-Id: I47b67eb89fb8849960a9f492d2909e45b96308f3
CRs-Fixed: 2617839
2020-02-10 11:58:46 -08:00
Abhinav Kumar
36b42d3545 qcacld-3.0: Make nan_separate_iface_support enable by default
Make nan_separate_iface_support feature enable by default

Change-Id: I0651a47ce68421b0108ab65295a0341cbb22393e
CRs-Fixed: 2613584
2020-02-03 06:04:40 -08:00
Abhinav Kumar
dafd2a637b qcacld-3.0: Add an ini for separate iface support for NAN
Add a new INI parameter "nan_separate_iface_support" to
indicate firmware that the host driver supports separate
interface for NAN Discovery.

Change-Id: I6fb313b02c5f3a05638e85494051fb003b2dd867
CRs-Fixed: 2612006
2020-01-31 00:57:02 -08:00
Srinivas Dasari
ee454da9db qcacld-3.0: Disable NAN in stop_adapter
Framework might not disable NAN discovery explicitly in some
cases like driver unload. So disable NAN from stop_adapter to
terminate NDPs and NAN discovery properly.
Cleanup the API os_if_process_nan_disable_req() by using the
new API ucfg_disable_nan_discovery().

Change-Id: Ic2c834db44c42a44db902c93f67a887de1b6c2fb
CRs-Fixed: 2594318
2020-01-01 18:24:15 -08:00
Srinivas Dasari
4c50119c27 qcacld-3.0: Get the firmware capability NAN_VDEV_SUPPORT
Firmware advertises service capability bit NAN_VDEV_SUPPORT for
separate NAN vdev creation. This capability can be used to create
separate interface for NAN discovery and process corresponding
commands from userspace.

Change-Id: I45573c94ee2d966afc1e207c9eefc146ff43320f
CRs-Fixed: 2592019
2020-01-01 15:42:33 -08:00
Srinivas Dasari
4a32ec5220 qcacld-3.0: Allow/Disallow NDP creation in different concurrencies
Currently in case of STA+NDI+NDI concurrency, the below scenario
can occur,
1) If NDI(NDP) + NDI(NDP) exists and sta tries to connect,
   then all NDPs on 1st NDI is tear down.
2) If STA+NDI(NDPs) exist and then another NDI tries to establish
   the NDP, then it is allowed in the current driver.

Fix is to reject the 2nd NDI(NDP) if STA+NDI(NDPs) concurrency
already exist.

Change-Id: Iadf6c9e10b9cdd59ca7beaace578a52b5e5dbb0f
CRs-Fixed: 2568552
2019-12-11 17:44:33 -08:00
Srinivas Dasari
b24bdd3f73 qcacld-3.0: Consider NAN enabling also as connection in progress
There is a race condition while handling the below scenario,
1. NAN enable request is received from framework.
2. Policy mgr opportunistic timer expired and set hw mode
   initiated to Single MAC mode in scheduler thread at
   the same time

As the opportunistic timer handler doesn't have any info if
NAN enable initiated in DBS mode, it's configuring the hw
mode to Single Mac Mode just before NAN enable request is sent
to firmware. So the NAN enable request is sent to firmware in
Single Mac Mode which is not allowed by firmware.

NAN enable/disable is also similar to connection in progress
status in case of STA. So provide NAN enable/disable status
through hdd_is_connection_in_progress() to the opportunistic
timer handler. Opportunistic timer handler restarts the timer as
connection(NAN enable/disable) is in progress.

Also set hw_mode_change_in_progress before checking the
connection progress status. This is to avoid a possible race in
the below scenario,
1. NAN-enable sets the state but scheduler thread had read the
   state just before that
2. NAN-enable read the hw_mode_change_in_progress just
   before it gets set by scheduler thread.

Change-Id: I1a184c84520deb3f6ad1ec010a0fdefda96a5364
CRs-Fixed: 2566841
2019-12-01 17:39:45 -08:00
Manikandan Mohan
dbcd073e6d qcacld-3.0: Update NAN component to use frequency values
Due to channel number ambiguity with introduction of 6GHZ support
update NAN component APIs and data structures to use frequency
values instead of channel number.

Change-Id: I982fe8da0320c878f9473a62c86b80b220e2892e
CRs-fixed: 2551927
2019-10-24 21:41:47 -07:00
Sourav Mohapatra
4c9b82aaf6 qcacld-3.0: Fix compilation error in case NAN is disabled
Currently the function ucfg_nan_get_ndi_state is not defined for the
case WLAN_FEATURE_NAN is not defined. As this is a public function
defined in dispatcher/inc/ and can be used externally, there would be a
compilation failure on such cases.

Resolve the failure by declaring ucfg_nan_get_ndi_state as static in the
case WLAN_FEATURE_NAN is not enabled.

Change-Id: I30297e8a3781f9a529c40a1423a9d2613c286f4e
CRs-Fixed: 2548223
2019-10-19 06:48:58 -07:00
Manikandan Mohan
cf5048294b qcacld-3.0: Disallow TDLS when NAN is active
Since NAN has higher priority over TDLS, disallow TDLS link
when NAN is active.

Change-Id: I7de34dbb2f808c36358ac5266c26e2729b901941
CRs-fixed: 2537158
2019-10-14 05:47:03 -07:00
Sourav Mohapatra
3f02b6a70d qcacld-3.0: Add ini support for NDP inactivity timeout
Add an ini configuration that configures the inactivity timeout for NDP
peer. The value is sent to the firmware via the VDEV param
WMI_VDEV_PARAM_NDP_INACTIVITY_TIMEOUT.

Change-Id: Ifffe6bb40df94761d739463cf7e54a0be7e2a375
CRs-Fixed: 2531756
2019-09-20 23:36:09 -07:00
Manikandan Mohan
a440567c76 qcacld-3.0: Disable NDPs on SAP startup
NAN_NDP+SAP concurrency is not supported. Disable all NAN_NDP
sessions on SAP startup.

Change-Id: I73284ef4f820dd15df808b9c44da5f09c6b5db26
CRs-fixed: 2524112
2019-09-18 04:18:33 -07:00
Rajeev Kumar Sirasanagandla
c64548c8a8 qcacld-3.0: Remove policy mgr entry after NDI delete
In the host driver, after receiving NDP END INDICATIONs for all NDP
connections then policy manager deletes NDI mode from
pm_conc_connection_list.

From user-space application, if NDP END REQUEST and NDI DELETE request
are issued back to back without waiting for NDP END indication, then
firmware could process NDI DELETE command firstly and avoid NDP END
indication due to peer delete as a part of NDI delete.

If vendor command NDI delete request is issued without receiving
NDP_END_INDICATIONs for all active NDP peers then pm_conc_connection_list
contains stale entry of PM_NDI_MODE associated with deleted NDI.

Stale NDI entry in pm_conc_connection_list is the cause for failure of
get_second_connection_pcl_table_index() for PM_NAN_DISC_MODE, therefore
further NAN enable requests are rejected.

To address this issue, cleanup PM_NDI_MODE from pm_conc_connection_list
as a part of NDI delete.

Change-Id: Ic1535420b60224cc426b24e22fe7486781fd2fa6
CRs-Fixed: 2519625
2019-09-13 21:44:07 -07:00
Manikandan Mohan
4e66c9a73a qcacld-3.0: Move NAN cfg params init to PSOC open
NAN config param initialization from CFG component is done
during PSOC object created notification. But as per component
design it must be done at psoc open to avoid CFG component
not initialized case. Thus update nan component to reorganize
NAN cfg params init.

Change-Id: I9636b527b796202e55a57c28d604795a705de026
CRs-fixed: 2489286
2019-07-29 20:10:58 -07:00
Manikandan Mohan
a1f29a9bfe qcacld-3.0: NAN component updates for SAP concurrency
Add NAN+SAP concurrency related changes to NAN component. This
handles NAN discovery and SAP SCC design constraint.

Change-Id: Ief0d6735d9f011eb3bac22d813b2d2ef41f3fe7c
CRs-fixed: 2431539
2019-04-11 01:13:13 -07:00
Nachiket Kukade
9ea5f13a28 qcacld-3.0: Add support for disabling an NDI concurrency
NAN Datapath implementation allows more than one concurrent
NDI's to be active at the same time. But this isn't supported
if there is a higher priority incoming connection such as
STA. Add modules that check for unsupported NDI concurrency
and initiates termination of all NDP's on it.

Add modules that check and disable unsupported NDI concurrency.

Change-Id: I6ad9afbfc41beda1d1c8f31bf58a8ea70027f5ca
CRs-Fixed: 2407215
2019-03-12 13:58:08 -07:00