Commit Graph

372 Commits

Author SHA1 Message Date
Mukul Sharma
0c1c379514 qcacld-3.0: Add wow user pattern support in PMO
Add wow user pattern support in PMO.

Change-Id: I186e650e3a165ea0aeaada4bba880005c5be8b5f
CRs-Fixed: 2135644
2017-11-08 03:01:19 -08:00
Krunal Soni
8afae9b62d qcacld-3.0: Fix to propagate key-receiver-sequence-counter to WMA
SME module propagates KeyRSC to MAC/PE module but MAC/PE doesn't
pass this counter to WMA and due to which WMA is not able pass to
next module.

Add a fix to propagate KeyRSC field from MAC to WMA module and further
down in stack.

CRs-Fixed: 2130761
Change-Id: I157a44610e184b5e10d838fbc5d6b810e3efd6db
2017-11-07 22:56:29 -08:00
lifeng
7c607dd603 qcacld-3.0: Add a timer to reduce and resume beacon interval
qcacld-2.0 to qcacld-3.0 propagation

Reduce the beacon interval just before the channel switch.
This would help in reducing the downtime on the STA side which
is waiting for beacons from the AP to resume back transmission.

Switch back the beacon_interval to its original value after
the channel switch based on the timeout. This would ensure
there are atleast some beacons sent with increased frequency.

Change-Id: I37db52713d9e2c78abbb97a7cd0274d9da35bfd2
CRs-Fixed: 1094958
2017-11-07 01:13:18 -08:00
Tushnim Bhattacharyya
8629489f02 qcacld-3.0: Stop the opportunistic timer when hdd stop happens
Stop the opportunistic timer & take action if needed when hdd stop
happens. Also, take action when set_hw_mode request to FW times out.

Change-Id: I32f1e38e93a5805e0d85b800cc4e070cd6f79669
CRs-Fixed: 2133388
2017-11-04 06:59:44 -07:00
Rajeev Kumar Sirasanagandla
996e529f9d qcacld-3.0: Add support to query RCPI info
RCPI is measure of received RF power in the selected channel for a
received frame and is measured at the antenna connector and shall be
measured over an entire frame. It is a monotonically increasing,
logarithmic function of received power level.

Wlan firmware computes RCPI.

Add host support to query firmware for RCPI information of peer
mac address in sta, p2p client, softap and p2p go modes.

Change-Id: I43a061ad4ed0fceb66dbd82b1c35b7678ee2259c
CRs-Fixed: 1092612
2017-11-01 13:56:47 -07:00
Varun Reddy Yeturu
62c3265af2 qcacld-3.0: Check firmware MAWC capability
Check for the target capability for MAWC(Motion Aided Wireless
Connectivity) feature before sending the roaming or PNO based
MAWC WMI commands to the firmware.

Change-Id: I0cc344d8307cf43996c2eede835bf9069790fa56
CRs-Fixed: 2117825
2017-10-26 16:53:08 -07:00
Dustin Brown
05557181ba qcacld-3.0: Abort suspend if critical events are in flight
There are some events from firmware that the driver would prefer to
process immediately. In some cases, these events can race with the
suspend process such that the event is not processed until the device
resumes. Keep a counter of so called "critical events" so the suspend
process can be aborted in the event of the aforementioned race
condition.

Change-Id: Ic8a557368d6cb62bed9fba424c851b48b16bc574
CRs-Fixed: 2125904
2017-10-25 13:41:18 -07:00
Srinivas Girigowda
ea4d806da9 qcacld-3.0: Fix checkpatch warnings (SPACING)
Fix checkpatch warnings (SPACING).

Change-Id: I966fe641b4722cc15584defc42c90921090687fb
CRs-Fixed: 2126814
2017-10-24 16:40:54 -07:00
Dustin Brown
d0a7656c2b qcacld-3.0: Converge on recommended wake lock duration
Over time, many arbitrary wake lock durations were chosen with very
little observational evidence to support them. Converge on a standard
recommended wake lock duration, which can serve as a starting point for
finding an appropriate wake lock duration.

Change-Id: Ie54c415870c96117d72ead4d677c4bfb2aad3ae4
CRs-Fixed: 2126685
2017-10-23 20:23:56 -07:00
Naveen Rawat
d8feac152e qcacld-3.0: Update 11AX - HE IE's based on new draft - 4/4
Update HE Capability/Operation IE based on new draft version D1.3.

Update driver changes for the frame changes made as part of
Ia295422fa697edea8a571be359f9983110bba969.

Change-Id: I22e4641e8fd15d647eb655c41c61389da8775766
CRs-Fixed: 2092845
2017-10-20 01:11:15 -07:00
Vignesh Viswanathan
731186f0ff qcacld-3.0: Add service_available_event handler for FILS roam capability
Currently, wmi_service_bitmap field in WMI_SERVICE_READY_EVENT is
exhausted. WMI_SERVICE_AVAILABLE_EVENT is available for upcoming
capability intimations.

Add service_available_event handler in host driver to extract
FILS roaming capability of fw. Based on this capability only,
send RSO, update connect params, HLP IE commands, GTK offload
are sent to fw.

Change-Id: I320ba86d29109d8cba23830ef9cb5e159792f19a
CRs-Fixed: 2094229
2017-10-19 13:52:33 -07:00
Wu Gao
7afc615be0 qcacld-3.0: Remove legacy P2P codes in WMA
To reduce code size, remove legacy P2P codes in WMA layer

Change-Id: Id34951ac907365ab4fcff6783000d745e84a8de7
CRs-Fixed: 2111575
2017-10-18 23:50:53 -07:00
Nachiket Kukade
8983cf61d2 qcacld-3.0: Support for configuring voltage corner mode
This change adds support for configuring voltage corner mode
thorugh INI parameter. User will provide a bitmap which will
be passed on to the FW during initialization. In this bitmap,
each pair of bits till BIT27 correspond to different phymode,
bw combination. Bit values signify voltage corner configuration.

Change-Id: I9e86d43079225b6f08fdd281c8f424b18abcffe9
CRs-Fixed: 2109884
2017-10-18 03:55:01 -07:00
Himanshu Agarwal
a1539d3e22 qcacld-3.0: Add sanity check for num_hw_modes and num_phy
Add sanity check for num_hw_modes and num_phy in wma_populate_soc_caps()
for WMI_SERVICE_READY_EXT_EVENTID.

Change-Id: I023d737449283f9ac092d278bde016b208b2c891
CRs-Fixed: 2119887
2017-10-12 14:02:13 -07:00
Himanshu Agarwal
8bcec57472 qcacld-3.0: Add INI support for best candidate algo and RSSI scoring
1) Currently all the parameter to decide best candidate are chosen
   as by default.
   Add INI support for those parameters to change values on basis
   of performance.
2) At the time of calculating best candidate score, rssi consider
   bucket size, good rssi, bad rssi, good rssi percentage from total
   rssi percentage, bad rssi percentage from total percentage.
   Configure these all params from ini.

Change-Id: I808a40486473fcbb161c12fbd369b3b846beb8c2
CRs-Fixed: 2121735
2017-10-12 14:02:08 -07:00
Sandeep Puligilla
819d94f731 qcacld-3.0: Don't roam to 2G AP when 5G only configured
STA is roaming to 2G AP even though 5G
only is configured through ini.
Set weightage of the 2G social channels
to zero so that firmware will not roam
to 2G channels.

Change-Id: I7dea8413618265e0f1fe353da4b858583c1921af
CRs-Fixed: 2117614
2017-10-12 13:59:27 -07:00
Rajeev Kumar
155a3e4a88 qcacld-3.0: Add 1 second timed wake lock for 4 way handshake
Add 1 second wake lock for 4 way handshake to avoid APPS
power collapse in middle of eapol exchange which can delay
the association process.

Change-Id: Ife73dc00aa05b5a80d0a90afd18468bd033ebdd9
CRs-Fixed: 2118533
2017-10-12 13:58:53 -07:00
Jeff Johnson
5a6b660768 qcacld-3.0: Replace typedef tSirLedFlashingReq
The current driver strategy is to converge on unified APIs, and the
unified WMI struct flashing_req_params conveys the same information as
typedef tSirLedFlashingReq, therefore replace tSirLedFlashingReq with
struct flashing_req_params.

Change-Id: I4ef75ee3bff7c83dbf8197bba0802569282a414f
CRs-Fixed: 2121335
2017-10-12 13:57:01 -07:00
Krunal Soni
aadaa27fbd qcacld-3.0: Provide SME API to send unit test command to FW
Current driver forming a unit test command within HDD layer and uses
message passing method to deliver it to WMA layer which
requires HDD layer to have a knowledge of how to form a unit test command.

User SME API to send params to WMA layer and let WMA form a unit test
command and send it directly to FW through WMI layer instead of HDD
forming and passing it down.

CRs-Fixed: 2118725
Change-Id: Id1838939813e6cd2d52cee8720a1f4e0ca34329b
2017-10-06 19:30:50 -07:00
Krunal Soni
a5ccb8007f qcacld-3.0: Keep wake lock while mac config is getting changed
Host should keep the wake lock from the time it sends
WMI_PDEV_SET_MAC_CONFIG_CMDID to FW till it receives the
WMI_PDEV_SET_MAC_CONFIG_RESP_EVENTID. This will avoid any fatal
crash condition.

Change-Id: Id16a1957b38acee6cf45c123ea9dbab25aae9b39
CRs-Fixed: 2070779
2017-10-06 12:27:26 -07:00
Nachiket Kukade
aaf8a71ef5 qcacld-3.0: Implementation to change BmissFinalBcnt dynamically
Implementation to change BmissFinalBcnt dynamically.
User can set totalBcnt using the new command
QCA_WLAN_VENDOR_ATTR_CONFIG_TOTAL_BMISS_CNT.
BmissFirstBcnt will retain its default value or from ini.
BmissFinalBcnt will be configured as (totalBcnt - BmissFirstBcnt).

Change-Id: Ie3c3895d48248d349400e755f07edc807e335b44
CRs-Fixed: 2081906
2017-10-04 08:41:24 -07:00
Krunal Soni
332f4afc05 qcacld-3.0: For host-invoked roaming to same AP, don't to send null frm
During host invoked roaming, set WMI_ROAM_INVOKE_FLAG_NO_NULL_FRAME_TO_AP
flag so that FW will not send NULL data frame while doing transition to
same bssid.

CRs-Fixed: 2046964
Change-Id: I043c3d2431e4da5af36fb710bd36a520550abbd3
2017-10-03 16:02:56 -07:00
Krunal Soni
e6a1cda95e qcacld-3.0: Bring back changes of Antenna sharing for STA
Change-id Iafd5666179d079c7bcc950277092cef3046356bf was added to remove
antenna sharing support from SAP and STA case but customer needs those
changes for SAP case only.
So bringing back changes for STA case.

CRs-Fixed: 2117829
Change-Id: I79f7c5ae1fd642f0b26170f066a5409638cdd873
2017-10-03 03:30:44 -07:00
Naveen Rawat
903accac1f qcacld-3.0: Remove LTE ant sharing dependency on HT connection's NSS
While DUT is in SAP or GO mode, due to LTE antenna sharing mechanism,
DUT is associating in 2x1 chains to HT clients.

As per new requirement, remove dependency of number of chains on antenna
sharing. If HT client supports 2 chains, and due to DBS/LTE antenna
sharing SAP/GO drops down a chain then rate adaptation at peer takes
care of dropping down chains at peer side

Change-Id: Iafd5666179d079c7bcc950277092cef3046356bf
CRs-Fixed: 2108484
2017-10-03 03:30:29 -07:00
Manjeet Singh
70d3d931d9 qcacld-3.0: Check FW support for FW mem dump
Currently HDD sends a FW memory dump request to firmware without
checking support for this feature. This can lead to a crash as firmware
doesn't send the command response if feature is not supported.
Add a check in HDD so that the request is only sent when FW memory dump
capability is advertised by the firmware.

Change-Id: I73b980f50910e13aa5f2d2434f07b6f985dd5010
CRs-fixed: 1090806
2017-09-28 05:39:58 -07:00
Naveen Rawat
296a51846f qcacld-3.0: Add support to send rate information for mgmt frames
Add support to send rate information for mgmt frames.

Currently default rates are used by target for the mgmt frames before
association. If the AP does not support the default rates (1 Mbps for
2.4G and 6Mbps for 5G), STA would still send AUTH, ASSOC frames with
the default rates. Add support to send the minimum rate supported by
the AP as part of the MGMT Tx WMI command.

Change-Id: I38d832818bbbd5fe3dec5660bd01dd08798bf0be
CRs-Fixed: 2085006
2017-09-27 20:57:56 -07:00
Mukul Sharma
6398b253fb qcacld-3.0: Add support for changing LISTEN interval dynamically
Current method for calculating LISTEN INTERVAL are static
configuration a.ka. ini based. Now OEM / USER want to take
control of setting LISTEN INTERVAL as per their applications
need. Once if USER configure the LISTEN INTERVAL value using
vendor command then host should avoid changing the LI value
during each suspend/resume. User LI value will be override
configuration. Once USER will Disable the LI using vendor
command then host can fallback to current default method.

Change-Id: Ia9b412b073c059df0cdff7bcda8198f7581e796d
CRs-Fixed: 2040298
2017-09-27 20:57:54 -07:00
Abhishek Singh
0d74f9e664 qcacld-3.0: Fix double free del_sta_session_req
iface->del_staself_req is used to check if del sta self was defered
and if it is set vdev detatch is called. iface->del_staself_req is
also set in case  del sta self was not defered and thus del sta self
resp may get called twice, assuming it was differed and this result
in double free of del_sta_session_req.

To fix this added a bool to check if the del sta self was defered.

Change-Id: If4c2bc2a5bb6b8761f4130119a96602055d45b77
CRs-Fixed: 2116888
2017-09-27 19:24:02 -07:00
Yu Wang
46082dc0a6 qcacld-3.0: inject fw crash in crash-shutdown
When kernel panic happen, if WiFi FW is still active,
it may cause NOC errors/memory corruption, to avoid
this, inject a fw crash first.

Propagated from qcacld-2.0

Change-Id: I97a696a02dfd73aaca212ef1bca9f3597df1e382
CRs-Fixed: 2052332
2017-09-26 22:20:06 -07:00
Ganesh Kondabattini
3573957abf qcacld-3.0: set the limit off-channel command parameters
Set the limit off-channel command parameters and conc_system_pref
according to active tos indication from application.

CRs-Fixed: 2066088
Change-Id: I896999adb59aa468daf33364c708d95ef3062018
2017-09-26 17:53:00 -07:00
Jeff Johnson
adba396c07 qcacld-3.0: wma: Replace instances of unadorned %p
Replace instances of unadorned %p in core/wma.

Change-Id: I44a975caa73f0837274536babf1902bef06c591a
CRs-Fixed: 2100997
2017-09-25 21:56:49 -07:00
Vignesh Viswanathan
56f262563b qcacld-3.0: Add sanity check to limit mgmt frames data len
Currently the mpdu_data_len in Rx pkt meta is not checked for
upper bound in wma_form_rx_packet.

Add sanity check to drop the packet if mpdu_data_len is
greater than 2000 bytes. Also add upper bound check for
frame_len in lim_process_auth_frame function.

Change-Id: I7ab454045e2f6d278351dcabde6da556f9f741e0
CRs-Fixed: 2093392
2017-09-25 05:43:05 -07:00
Anurag Chouhan
3920c0f714 qcacld-3.0: Add Vendor command to set/get NUD debug stats
Add vendor commands to set/reset and get NUD debug stats
from firmware.

Change-Id: I773c04bb3f7c6d5ed28528cf2174b3d63de57d98
CRs-Fixed: 2011456
2017-09-20 06:22:06 -07:00
Jiachao Wu
712d4fd6a6 qcacld-3.0: Send beacon tx rate to firmware
Add data structures to save beacon tx rate.
The beacon data rate is multiples of 100 Kbps.
Firmware expects the data rate in the form of hw rate codes.
So convert the data rates to hw rate code.
And send it to firmware.

Change-Id: Ia39fd4c14defa729f75f2c45748fe5b04b909647
CRs-Fixed: 2099052
2017-09-19 04:18:34 -07:00
Varun Reddy Yeturu
061d4d63e4 qcacld-3.0: Introduce INI items for MAWC based roaming
Introduce the following items in WCNSS_qcom_cfg.ini for
user to modify them for MAWC based roaming.

mawc_roam_enabled
mawc_roam_traffic_threshold
mawc_roam_ap_rssi_threshold
mawc_roam_rssi_high_adjust
mawc_roam_rssi_low_adjust

Change-Id: Ief51e3e91603bfd7f6c6deed3ca48bc717b2b6fb
CRs-Fixed: 2081413
2017-09-14 13:26:37 -07:00
Jeff Johnson
ff6addf320 qcacld-3.0: Remove wma_open() cds_ctx parameter
Currently wma_open() takes a cds_ctx parameter. All of the other WMA
functions which previously took a cds_ctx no longer use that
parameter, and those functions have been modified to remove the unused
parameter. wma_open() still needs the cds_ctx, but it can get that
context by calling cds_get_global_context(), so remove the cds_ctx
parameter to be consistent with the other WMA functions.

Note: the fact that wma_open() needs the cds_ctx, and then
dereferences it, is a layering violation that needs to be addressed in
the future.

Change-Id: I176e2ac68cc2e8081645a4ce3c158b41d3018587
CRs-Fixed: 2109263
2017-09-13 20:07:37 -07:00
Jeff Johnson
7b3ddc2a5b qcacld-3.0: Remove wma_wmi_service_close() cds_ctx parameter
Currently wma_wmi_service_close() takes a cds_ctx parameter. All of
the other WMA functions which previously took a cds_ctx no longer use
that parameter, and those functions have been modified to remove the
unused parameter. wma_wmi_service_close() still needs the cds_ctx, but
it can get that context by calling cds_get_global_context(), so remove
the cds_ctx parameter to be consistent with the other WMA functions.

Note: the fact that wma_wmi_service_close() needs the cds_ctx, and
then dereferences it, is a layering violation that needs to be
addressed in the future.

Change-Id: I02564bae87077314fea58c1509b3a50b8d567a7a
CRs-Fixed: 2109262
2017-09-13 20:07:35 -07:00
Jeff Johnson
6b8473d136 qcacld-3.0: Remove wma_wmi_work_close() cds_ctx parameter
Currently wma_wmi_work_close() takes a cds_ctx parameter. At one time
this was needed for the call to cds_get_context(), but that is no
longer the case, so remove this unused parameter.

Change-Id: Ibc64cd1398babc899c21a1ee4c0fc280769c4d9e
CRs-Fixed: 2109261
2017-09-13 20:07:33 -07:00
Jeff Johnson
542da35e39 qcacld-3.0: Remove wma_close() cds_ctx parameter
Currently wma_close() takes a cds_ctx parameter. At one time this was
needed for the call to cds_get_context(), but that is no longer the
case, so remove this unused parameter.

Change-Id: I31d1016cff580f9330027f8104348466df9f01dd
CRs-Fixed: 2109259
2017-09-13 20:07:31 -07:00
Jeff Johnson
5be42abfb6 qcacld-3.0: Remove unused wma_mc_process_msg() parameter
Currently wma_mc_process_msg() takes a cds_context parameter.  At one
time this parameter was needed, but that is no longer the case, so
remove this now unused parameter.

Change-Id: Ia460afc5db932274cd960485af93fc48e899ff35
CRs-Fixed: 2109258
2017-09-13 20:07:29 -07:00
Jeff Johnson
f7ab814a0c qcacld-3.0: Remove cds_wma_complete_cback() parameter
Currently cds_wma_complete_cback() takes a parameter that is a pointer
to the CDS context. However CDS already maintains its own context,
hence this param introduces an unnecessary coupling, so remove it.

Change-Id: I1b4588f18f807008fd212a8e5d04e3895a12922c
CRs-Fixed: 2109257
2017-09-13 20:07:27 -07:00
Jeff Johnson
8ad89c6cd4 qcacld-3.0: Remove wma_pre_start() cds_ctx parameter
Currently wma_pre_start() takes a cds_ctx parameter. At one time this
was needed for the call to cds_get_context(), but that is no longer
the case, so remove this unused parameter.

Change-Id: Ic4582ecafbee6fc1d0f8ebbf3c62ed8c7b47a179
CRs-Fixed: 2109255
2017-09-13 20:07:24 -07:00
Jeff Johnson
acc1cc7a4e qcacld-3.0: Remove wma_stop() cds_ctx parameter
Currently wma_stop() takes a cds_ctx parameter. At one time this was
needed for the call to cds_get_context(), but that is no longer the
case, so remove this unused parameter.

Change-Id: Iba40ac86e5916be3b8c2a62cf5483c9b7a242be5
CRs-Fixed: 2109254
2017-09-13 20:07:23 -07:00
Jeff Johnson
d489255594 qcacld-3.0: Remove wma_start() cds_ctx parameter
Currently wma_start() takes a cds_ctx parameter. At one time this was
needed for the call to cds_get_context(), but that is no longer the
case, so remove this unused parameter.

Change-Id: If6756ca37a7e4ec4ade1c72eea080f3bc89ad7e4
CRs-Fixed: 2109253
2017-09-13 20:07:21 -07:00
Jeff Johnson
1f8d0a0a9c qcacld-3.0: Remove wma_setneedshutdown() cds_ctx parameter
Currently wma_setneedshutdown() takes a cds_ctx parameter. At one time
this was needed for the call to cds_get_context(), but that is no
longer the case, so remove this unused parameter.

Change-Id: I65f2af2e97b09523f5cf00369b5cf95ad01194d9
CRs-Fixed: 2109252
2017-09-13 20:07:19 -07:00
Jeff Johnson
1b5404e93c qcacld-3.0: Remove wma_needshutdown() cds_ctx parameter
Currently wma_needshutdown() takes a cds_ctx parameter. At one time
this was needed for the call to cds_get_context(), but that is no
longer the case, so remove this unused parameter.

Change-Id: I31fd07480719bf3401ed52b57951e19ccb4d143c
CRs-Fixed: 2109251
2017-09-13 20:07:17 -07:00
gaolez
e510894670 qcacld-3.0: Add new params in ACS calc process
qcacld-2.0 to qcacld-3.0 propagation

Before this change the ACS calc process only consider the
channel's rssi and bss count in this channel, in this change
add noise floor, channel free statistics and tx power in the
ACS calc process.

Change-Id: I654e53fa2441e03723f150d973c124985c67f2b4
CRs-fixed: 1050316
2017-09-11 23:27:25 -07:00
Jeff Johnson
a9b6657591 qcacld-3.0: Remove unused wma_register_roaming_callbacks param
Currently wma_register_roaming_callbacks() has a cds_ctx parameter. At
one time this was necessary since the global context was required to
get the module-specific context.  However the global context is no
longer required for this purpose, so remove the unused parameter.

Change-Id: Ida681fb20dd98a46f385f1e04662f72a334c68bf
CRs-Fixed: 2103626
2017-09-08 03:18:02 -07:00
Jeff Johnson
abb7404d2b qcacld-3.0: Remove unused wma_get_wcnss_software_version() param
Currently wma_get_wcnss_software_version() takes a p_cds_gctx
parameter which it does not use, so remove it.

Change-Id: I86a5893a9407bad034a32c105aec92d4e6054744
CRs-Fixed: 2102549
2017-09-07 22:52:18 -07:00
Will Huang
496b36c936 qcacld-3.0: Add support of request peer stats info(part 3)
qcacld-2.0 to qcacld-3.0 propagation

FW has limitation to support old WMI_REQUEST_STATS_CMDID and
WMI_UPDATE_STATS_EVENTID interface on AP vDev. FW suggest to use new
WMI_REQUEST_PEER_STATS_INFO_CMDID and WMI_PEER_STATS_INFO_EVENTID to
get tx/rx rate.

This checkin is about HDD layer, provide APIs/callbacks to upper layer
to query rssi/tx/rx statistics of peer station associated with SAP,
and provide a default disabled ini setting and checking FW's
WMI_SERVICE_PEER_STATS_INFO capability to control this get peer info
interface. Add/change iwpriv/QCA_NL80211_VENDOR_SUBCMD_GET_STATION/
cfg80211_ops.get_station interfaces to upper layer.

Change-Id: Ib1571219faa16e3bc8c3eb1260137ae08b8b6016
CRs-Fixed: 2059507
2017-09-01 22:09:05 -07:00