Commit Graph

41 Commits

Author SHA1 Message Date
Jayachandran Sreekumaran
68c952c716 qcacld-3.0: Add acs config parameter acs_policy
A new external acs configuration parameter acs_policy.
This parameter indicates the external ACS module whether
its mandatory or preferrable to select a channel
from the preferred channel list provided by the
driver

Change-Id: I80925109349c68c95f25ba27d87bd68964c4eb04
CRs-Fixed: 2037034
2017-05-11 01:26:07 -07:00
Rachit Kankane
2487f8f7e9 qcacld-3.0: HDD, SAP changes to Disable/Enable NOA
P2P-GO whenever goes offchannel, issues NOA. With this behavior, we
have issue whenever legacy STA connects to P2P-GO as legacy STA
does not understand NOA. To handle this case, changes are done in HDD
and SAP component and the revised behavior will be:
 1. By default no change in NOA.
 2. Whenever first legacy STA connects to GO, SAP informs HDD with
    new parameter station type. HDD will communicate the same to
    p2p protocol component. Once the connected station is authorized
    p2p protocol component will disable NOA (i.e. P2P-GO will start
    issuing Self-CTS whenever it goes off-channel).
 3. Whenever last legacy STA disconnects from GO, p2p protocol
    component enables NOA (i.e. P2P-GO will start issuing NOA whenever
    it goes off-channel).

Change-Id: Iadab47c9a2aeb434371d4c262623d7196f3b1ab4
CRs-Fixed: 2035609
2017-04-28 04:42:04 -07:00
Arif Hussain
cd1516322d qcacld-3.0: Use dfs component support
Remove legacy dfs api’s and use dfs component.

Change-Id: Ia0fa016b174ef4b50e2cc339e4e476ec65642dbf
CRs-Fixed: 2021357
2017-04-25 01:08:44 -07:00
Kiran Kumar Lokere
a3de226328 qcacld-3.0: Replace regulatory apis with reg component apis
Replace the legacy regulatory apis with regulatory component
public service apis

Change-Id: Ifd8c93fc8f57116cfc432b853248b35fd7ed1b94
CRs-Fixed: 2008013
2017-04-20 17:10:19 -07:00
Amar Singhal
5cccafec64 qcacld-3.0: Wiphy initialization for regulatory offload
For regulatory offload, send the regulatory config settings to regulatory
component to compute the current channel list. Query channel list for
each band. Populate the channel list in wiphy. Also do not register
regulatory notifier with the kernel anymore.

CRs-Fixed: 2008013
Change-Id: Ia4995c7498d97fe1e37717e65daa9dcacb2f21b3
2017-04-16 15:58:42 -07:00
Arif Hussain
759a023602 qcacld-3.0: Add cac and phyerr processing offload support
In case of dfs offload, do not run cac timer, as cac will also be
offloaded in that case. Decide the same based of service bit info.

Change-Id: If4dd62628270ff0ba8632a9cd644a9d7ed6f31a4
CRs-Fixed: 2021357
2017-04-03 18:41:24 -07:00
Dustin Brown
d28772bde9 qcacld-3.0: Change sme_open_session to take a session Id
Currently, vdev_id and session_id are assumed to be the same, but are
generated in two separate code paths. Unsurprisingly, this leads to a
whole host of desync issues. Instead, modify sme_open_session to take
a session_id, which will be populated with an objmgr vdev_id. This means
vdev_id and session_id can no longer desync, as there is only a single
source for both.

Change-Id: I104aba29beb3c19d0ef2ff23380e3d005e01ced0
CRs-Fixed: 2022136
2017-03-28 12:49:04 -07:00
Kapil Gupta
8878ad9517 qcacld-3.0: Add support for external auto channel selection
Add changes to enabled driver to use external auto selection
logic instead of current driver based implementation.
In case external application is not present, driver will fall
back to current solution.

Change-Id: Ib7474e82bc7f5878af46c91ea09711775a7c046a
CRs-Fixed: 1110061
2017-02-13 23:01:23 -08:00
Kapil Gupta
94ca6f67f6 qcacld-3.0: Add APIs to validate vendor ACS channel
If channel set is coming from external application, it could be
possible that it doesn't fall into valid channel criteria.

Add APIs to validate the channel.

Change-Id: I1aa855b64c7702418471111d59c92ebaebe8be49
CRs-Fixed: 1110061
2017-02-13 23:01:21 -08:00
Kapil Gupta
086c6206de qcacld-3.0: Add changes to collect channel info from regulatory
Vendor ACS requires regulatory channel info for each channel.

Add changes to collect channel information of each channel
and save it in sap config.

Change-Id: Ib96c3f7ddfc8476306e9a13127472be9dd0a9488
CRs-Fixed: 1110061
2017-02-13 23:01:19 -08:00
bings
394afddedf qcacld-3.0: Do not set ACS flag if no ACS to be done
qcacld-2.0 to qcacld-3.0 propagation

wlan_hdd_cfg80211_change_iface will abort if ACS_IN_PROGRESS
is set, which causes iface type mismatch between hostapd and
driver.

When force SCC if same band is enabled, driver will not do ACS
for the second AP. So do not set ACS_IN_PROGRESS if no ACS to
be done.

Change-Id: I2c975c89dc1cf0d11980ad11c8d0d256c680594d
CRs-Fixed: 1105386
2017-01-25 17:14:46 -08:00
Wu Gao
3671743bd5 qcacld-3.0: Stop SAP and indicate event more earlier after SSR
propagation from qcacld-2.0 to qcacld-3.0

DUT is SAP + STA SBSC mode, it takes very long time to recover after
SSR. There are two problems:

1. It clear STA session and create new after SSR, but just clear SAP
session. With sessionId in SAP context, it wrongly use new STA session
to close SAP when terminate hostapd. This is the reason why host wait
stop_bss_event for 10 seconds in cfg80211 stop ap. Set sessionId to
invalid if adapter is SAP mode.

2. In dual-wifi mode, it will start second WLAN if SSR and
WLAN_SVC_FW_CRASHED_IND late. Send this event more earlier.

Change-Id: I10a3f300ac5621463fcce4d0a5e18b2cf1cb8491
CRs-Fixed: 1054612
2017-01-09 11:21:28 -08:00
Yingying Tang
b4832f7faf qcacld-3.0: Add SAP TX leakage threshold into ini file
Propagate from qcacld-2.0 to qcacld-3.0

Current value of SAP TX leakage threshold is a fixed value 310,
since different product may need different threshold, add it
into ini file now.

Change-Id: I0df8ac14f5e9e812a8ec5e5127df21eff0a8502b
CRs-Fixed: 955258
2016-12-14 14:07:25 -08:00
Liangwei Dong
aef84347a8 qcacld-3.0: On demand OBSS scan of SAP
qcacld-2.0 to qcacld-3.0 propagation

To shorten the SAP starting time, the OBSS scan
can be skipped if the ACS scan is performed
and the ACS scan channels cover the OBSS scan
channel list.
This change caches the ACS channel list and
skip the OBSS scan if necessary.

Change-Id: Iae54115051ae037c83b8dd2b639754f941c1d0f5
CRs-Fixed: 1073053
2016-11-08 17:48:18 -08:00
Tushnim Bhattacharyya
0105770430 qcacld-3.0: Fix buffer overflow issue in cds_update_with_safe_channel_list
Fix the size of pcl_channels & pcl_weight array to be QDF_MAX_NUM_CHAN in
cds_get_nondfs_preferred_channel. Also make sure all the callers of
cds_get_channel_list uses QDF_MAX_NUM_CHAN as channel array size.

Change-Id: I256421f54180d1d8f9f6abd549d417e74d62add5
CRs-Fixed: 1082596
2016-11-03 17:54:03 -07:00
Kai Liu
bdd5fcb83f qcacld-3.0: Add interface to get channel width in sap mode
qcacld-2.0 to qcacld-3.0 propagation

Add iwpriv interface to get channel width when working in sap mode.

Change-Id: I9900655861032636af1b4147ec6322e5aa76e614
CRs-Fixed: 1009861
2016-10-19 17:42:26 -07:00
Agrawal Ashish
06e76d2909 qcacld-3.0: Populate correct supported rates from hostapd.conf file
qcacld-2.0 to qcacld-3.0 propagation

Currently driver populates default supported and extended supported
rates in beacons even if hostapd.conf file wants to change
supported and extended supported rates.
Fix this by parsing beacon head and tail to get supported
and extended rates and populate them in sap config.
If Driver force acs is enabled, driver acs will get priority.
In case of driver based acs, driver should
ignore basic and extended rates from hostapd.conf and should
populate default rates.

Change-Id: I3226438b908a96f1b1bd3c2968a0c20eef81a799
CRs-Fixed: 1035768
2016-10-06 04:08:57 -07:00
Agrawal Ashish
6563461fa7 qcacld-3.0: Implement vendor command for ACS policy
qcacld-2.0 to qcacld-3.0 propagation

Add support for vendor command which informs the driver about the
ACS policy.
QCA_NL80211_VENDOR_SUBCMD_ACS_POLICY is used to inform driver about
ACS policies.
QCA_WLAN_VENDOR_ATTR_ACS_DFS_MODE attribute tells if DFS channel
should be enabled or disabled in ACS.
QCA_WLAN_VENDOR_ATTR_ACS_CHANNEL attribute provides channel number to SAP
module to skip ACS and use this channel as operating channel.

Change-Id: I1ba69ed8fdf1c56a90e857054c725b830293d6bf
CRs-Fixed: 997433
2016-09-28 10:14:15 -07:00
Deepthi Gowri
b3bfefd6e1 qcacld-3.0: Pass the correct reason code to disassoc
qcacld-2.0 to qcacld-3.0 propagation

use the same reason code in the disassoc, which the upper
layer has passed to the driver

Change-Id: I6302a5c8318a8e3c1221b9272637455da4e7f150
CRs-Fixed: 852387
2016-09-16 21:06:35 +05:30
Selvaraj, Sridhar
4577a9b955 qcacld-3.0: Send p2p ack indication directly to HDD from PE
qcacld-2.0 to qcacld-3.0 propagation

During P2P functionality, Host will send GO NEG REQ and
receives ACK completion from firmware which will be queued
to indicate HDD. Meanwhile if host receives GO-NEG RESP it
will be sent directly to HDD via function callback. In HDD as
we got  GO NEG RESP before ACK completion for GO-NEG REQ, HDD
will generate pkt completion for GO NEG Request.
Now GO NEG CONFORMATION frame will be sent and driver will be
expecting completion for this. The GO NEG REQ ACK completion
which got buffered in PE will be delivered to Supplicant and
Supplicant assumes that this is the ACK for GO NEG CONF frame.
This causes early termination of remain on channel due to which
firmware may drop the GO NEG CONF frame and may not retry as ROC
is terminated.
Fix this by making ACK Completion indication to HDD via function
callback.

Git-commit: 32ddf4196f423b8eaea7ec6c0816e2961aa7fc45
Change-Id: I0dd3acb236b270839649d2becfdc007e7aae9fdd
CRs-Fixed: 1012547
(cherry picked from commit a3996d421de7f55d5a6f7da19d7ff4b568ce7c50)
(cherry picked from commit 42405db3bd3f4b10800cde8cdcd14f521461a5a7)
2016-09-11 17:12:10 -07:00
Kondabattini, Ganesh
b72e25cb7f qcacld-3.0: Define data structures for new AP requirements
qcacld-2.0 to qcacld-3.0 propagation

Defining data structures for below new requirements.
        - beacon_tx_rate
        - vendor_ie
        - vendor_ie_len
        - vendor_ie_assoc_policy
        - sta_inactivity_timeout
        - tx_pkt_fail_cnt_threshold
        - short_retry_limit
        - long_retry_limit
        - ampdu_size
        - supp_rate_set
        - extended_rate_set

Change-Id: I9d05cd7b8e051c4e9e4912cf866206ae32ec293d
CRs-Fixed: 1020078
(cherry picked from commit 8f57eee853baff54397c68c8cd71aeb50610a56a)
2016-09-10 19:06:29 -07:00
Manishekar Chandrasekaran
9e8c7be23d qcacld-3.0: Support for pre CAC on SAP for user requested channel
Add support for pre CAC on SAP for the user requested channel.
The reason for the requirement is to have SAP operations without
interruptions due to CAC. After starting SAP on the 2.4GHz
channel, the driver will start a pre CAC on the 5GHz DFS channel
requested. If no radar is detected, SAP is expected to switch
from the 2.4GHz channel to the DFS channel mentioned in the pre
CAC request. If radar is detected SAP will continue to operate on
the 2.4GHz channel. To provide the pre CAC channel to the driver,
vendor commands/attributes are used .

Change-Id: I4cf4bb5a861eea05f37fafb3bf35d327f5377aab
CRs-Fixed: 1045242
2016-08-13 14:07:02 -07:00
Manishekar Chandrasekaran
f7a1dad7e0 qcacld-3.0: Validate SAP context before access in callback
Ensure that the SAP context is validated before access in
its callback. The global SAP context is now an array of
contexts rather than a single global context to help
validate the session. Increasing the SAP open session
timeout helps to configure all the commands to the FW and
helps to further avoid any crashes.

Change-Id: I6f722dcc4ab671fef010c816a7c7d38fc1bdebe4
CRs-Fixed: 1031855
2016-06-24 14:30:50 -07:00
Manishekar Chandrasekaran
ec26759fc8 qcacld-3.0: Correct channel parameters during channel switch notification
Correct the channel parameters that are calculated and used to indicate
the channel switch notification sent to user space. The channel bonding
values should not be used to get the channel width information since
they can be used only in STA mode to enable or disable the channel
bonding. Fix the same by getting the updated channel switch information
from the session entries.

Change-Id: Ia51779cddb2b9c3108b211822f104c45f88e53fd
CRs-Fixed: 1021380
2016-06-09 22:09:51 -07:00
Kiran Kumar Lokere
13644679a2 qcacld-3.0: Move the channel width enum to cds
Currently channel width has different enum values in
different modules. Move the channel width enum definition
to CDS to maintain single channel width enum value in
the driver

Change-Id: I6a46d0c02546263080a15a3ec7c52486fc51e98e
CRs-Fixed: 983914
2016-04-17 18:06:59 -07:00
Peng Xu
66162de29e qcacld-3.0: Fix firmware assertion caused by vdev delete
Currently the SME session is deleted during interface change API and
a new session is not opened until SAP is ready to start. This will
cause crash when scan API is invoked. This fix opens the SME session
after interface type is changed, so that it can be used to scan and
SAP later.

Change-Id: I3c4f8da14dbc70a3102fb1892bb101eb1a90a00d
CRs-fixed: 968572
2016-04-13 21:51:26 -07:00
Amar Singhal
b8d4f1575c qcacld-3.0: Change channel nomenclature
Change channel nomenclature to more appropriate names.

Change-Id: If7fcd832a35563896534bab425ca05b528e1de93
CRs-Fixed: 856727
2016-04-13 21:51:25 -07:00
Amar Singhal
e4f28eedfd qcacld-3.0: Re-arrange regulatory code.
Re-arrange core regulatory code between HDD and CDS
layers. Move the OS dependent code to HDD.

Change-Id: I8ac26a48d0e8d613b2f6c23fd764e5cf94365c39
CRs-Fixed: 856727
2016-04-13 21:51:25 -07:00
Anurag Chouhan
f04e84f24a qcacld-3.0: Add qdf references in place of cdf
Replace CDF references with QDF references.

Change-Id: Ifb4571174719b5fce61dd305545d05628265f317
CRs-Fixed: 981188
2016-03-24 11:58:26 -07:00
Anurag Chouhan
210db07644 qcacld-3.0: Add QDF MC timer API's
Replace CDF MC timer API's with QDF MC timer API's

Change-Id: If18069e9cb8dbd24c5cdc8bd8def6932f55c0168
CRs-Fixed: 981188
2016-03-24 11:58:08 -07:00
Anurag Chouhan
6d760664ee qcacld-3.0: Add QDF types
Replace CDF types with QDF types

Change-Id: Idd6e65b148efb54f22d6951572957f1c6166465b
CRs-Fixed: 981188
2016-03-24 11:57:54 -07:00
Anurag Chouhan
fb54ab0eac qcacld-3.0: Add QDF status
Replace CDF status with QDF status

Change-Id: I7170c8ae4c5bd97a8f0f383af637bb2ec312f082
CRs-Fixed: 981188
2016-03-24 11:57:39 -07:00
Liangwei Dong
d7be7778d9 qcacld-3.0: correct phy_mode in hdd_chan_change_notify
qcacld-2.0 to qcacld-3.0 propagation

The sap Context related phyMode should be used
instead of the phyMode in hal. Otherwise, the incorrect
channel width will be reported to supplicant.

Change-Id: Ic0ce7861a786de5aef8b43c6aa0fde9f600b08b2
CRs-Fixed: 909668
2016-02-08 15:50:44 -08:00
Amar Singhal
7a1726aefe qcacld-3.0: Change regulatory data structures style
Change regulatory data structures and APIs to linux style.
Change the references to the data structures accordingly.
Leave data structures that would be deleted in subsequent
iterations as is.

Change-Id: I68dcd3485d3fb3d98f648b5844508356c3f3c29d
CRs-Fixed: 856727
2016-02-08 15:50:42 -08:00
Ryan Hsu
4252a2fc6f qcacld-3.0: clean up the WLAN_FEATURE_MBSSID flag (phase 1)
WLAN_FEATURE_MBSSID flag is originally added to support MBSSID,
specifically for the MOBILE ROUTER build, and is now enabled for all
builds, there is no longer needed to have a separate feature flag,
so that removing it.

This commit cleans up the following modules - cds/mac/sap/sme.

Change-Id: I79ad9767b7945af0c567b6294ac07e7697898e9e
CRs-fixed: 958154
2016-02-08 15:50:40 -08:00
Chandrasekaran, Manishekar
a74bb024b1 qcacld-3.0: Accommodate channel bandwidth as input during channel switch
Add support to include channel bandwidth as one of the inputs to
decide the channel switch parameters. Currently only the target channel
is used as the input to decide the channel switch parameters. With this
fix, user specified channel bandwidth is also taken into consideration.

Change-Id: Ic49b24edde6cabc52aa2b38110763da82da6790d
CRs-Fixed: 955368
2016-02-08 15:50:40 -08:00
Kiran Kumar Lokere
999e58c920 qcacld-3.0: Remove the cb_mode usage in channel bonding
Remove the CB mode usage in channel bonding since the center
center frequency is calculated using channel width and channel
number.

Change-Id: Ie9685a833750bf3b69cce40c5d9587fb9b232047
CRs-Fixed: 962174
2016-02-08 15:50:40 -08:00
Abhishek Singh
7996eb7a8e qcacld-3.0: Send management frame indication directly to HDD from PE
qcacld-2.0 to qcacld-3.0 propagation.

If MC thread stall while waiting on any event, In case of WPS,
probe requests may get accumulated in PE message queue.

Now every time MC thread process a probe request,
eWNI_SME_MGMT_FRM_IND msg is posted in SME message queue. But
unless PE queue is fully processed SME queue won't be processed.
This will gradually use all vos message wrapper.

To avoid this register a callback to send management frame
indication directly to HDD from PE which avoids posting message to
SME queue.

Change-Id: Ib83700825112cc52dade594909bfa8993909ac29
CRs-Fixed: 944961
2016-02-08 15:50:39 -08:00
Peng Xu
f5d60c8524 qcacld-3.0: Clean up usage of con_mode
Separate con_mode from adapter mode definition and clean up usage of
con_mode.

CRs-fixed: 917959
Change-Id: Ia058826cdb873558ab8703fcd4f80d37d3f782df
2016-02-08 15:50:37 -08:00
Abhishek Singh
518323d9c0 qcacld-3.0: Implement ECSA Action Frame
qcacld-2.0 to qcacld-3.0 propagation.

Implement:
1. Send & receive logic of ECSA action frame from P2P-CLI/GO
2. Trigger channel change on P2P GO side once ECSA action frame
   is received by,
  i) Adding CSA & ESCA IE in beacon template and updating
     FW to send it out
  ii) Notifying supplicant of channel change for P2P GO.

This change include UMAC changes.

CRs-fixed: 895240
Change-Id: Ie6c9154fb44ec75c699e37aaba660c637869c099
2015-11-25 17:26:45 -08:00
Prakash Dhavali
7090c5fd8d qcacld-3.0: Initial snapshot of ihelium wlan driver
qcacld-3.0: Initial snapshot of ihelium wlan driver
to match code-scanned SU Release 5.0.0.139. This is
open-source version of wlan for next Android release.

Change-Id: Icf598ca97da74f84bea607e4e902d1889806f507
2015-11-17 17:52:53 -08:00