Commit Graph

213 Commits

Author SHA1 Message Date
Abhijit Pradhan
d38a26937c qcacmn: Set country code for full-offload using iwpriv command
For full-offload, send user country code to FW using WMI
command.

Change-Id: I84acbd7ce30aa9a8ce590c8fadea2cb5914240fe
CRs-Fixed: 2053849
2017-07-13 22:02:53 -07:00
Srinivas Girigowda
245fa9e277 qcacmn: WMI: Reduce the log spam in kmsg
Move the logs to appropriate log levels to reduce
the log spam in kmsg.

Change-Id: Icc2d55626908b6e6448567b259af106e3314827e
CRs-Fixed: 2017427
2017-07-12 20:12:51 -07:00
Sathish Kumar
5b636937bb qcacmn: Populate tx params tlv for mgmt and offchan tx WMI commands
Populate tx params tlv that includes information related to power,
chainmask, bandwidth mask, preamble type, frame type etc to the mgmt
and offchan tx WMI fixed param

Currently, we send the command with TX params valid set to zero always
and hence target does not look for the TX param TLV. This change
implements API to populate TX params TLV that facilitates configuration
of parameters per TX frame be it data or management frame

If the TX params valid is set to false, target decides the values
to use for each of the mentioned TX parameters

Change-Id: I90a1b5e1c9bf0a54a907876ed3629c2d627b3c98
CRs-Fixed: 2070454
2017-07-12 20:12:47 -07:00
Abhishek Singh
54aa620814 qcacmn: Fix memory overflow in wmi roam scan filter cmd
The length of buffer used to send wmi roam scan filter cmd is not
properly calculated and thus the length is less than the actual data
to be copied.

Fix it by properly calculating the length of the buffer.

Change-Id: I6a3baa5ca5560d2d04f9bd41a709a37abc1b95a9
CRs-Fixed: 2072057
2017-07-11 23:48:13 -07:00
Sathish Kumar
d99852a914 qcacmn: Enable SET_MGMT_RETRY_LIMIT pdev param for TLV based host
TX management retries is configured by host through pdev param sent
to the target. Populate pdev param enum to support configuration
of management retries during TX

Change-Id: I3f8b976ef089a0455481923ce18147f167733b14
CRs-Fixed: 2073391
2017-07-11 23:48:07 -07:00
Amar Singhal
7d2040287d qcacmn: Modify reg-domain to pdev level
In worst case, different pdevs can be in different countries and
hence different reg-domains. Also there could be differences due
to front-haul and back-haul.

Change-Id: Ib9e998b5f7de4e42a1736d07e9e5602d8506e7b6
CRs-Fixed: 2048784
2017-07-10 09:36:58 -07:00
Selvaraj, Sridhar
55f1d1ebd5 qcacmn: Add support to pass lca_disallow_config_params to fw
Add LCA[Last Connected AP] AP disallow params to
roam_scan_filter_params structure.

Change-Id: Id7a47bdc40d08b356483114b71981df352386172
CRs-Fixed: 2054195
2017-07-07 00:50:11 -07:00
Srinivas Girigowda
61e086ff92 qcacmn: Move the logs to appropriate log levels
Move the logs to appropriate log levels.

Change-Id: I9e28ecc7a62be6108ba13e510b8b42b843c97468
CRs-Fixed: 2063646
2017-07-06 11:40:51 -07:00
Rajeev Kumar Sirasanagandla
4c1fecdc46 qcacmn: Send proper CTL info to fw in world regd
Currently, for world regd and some other regds where conformance test
limit is NO_CTL, host is sending invalid CTL info to fw instead of
NO_CTL (0xff) due to type conversion issues.

To fix this, use proper unsigned type for CTL info.

Change-Id: I0407d30c6cd6f7f485d767c97bc5381c9c731440
CRs-Fixed: 2056847
2017-07-03 15:58:01 +05:30
Keyur Parekh
7df8ca1c08 qcacmn: Packet log changes for wifi3.0
Change-Id: I82462f426e4e449c5bc65331e39f07a062e8e242
2017-06-27 23:37:33 -07:00
Ravi Kumar Bokka
ce4ac394dd qcacmn: Auto Detect SoC Power Collapse Failure changes
Add host support for detecting SOC power collapse failures in FW and
communicating the same to framework.

Change-Id: Icee39c896802c4d7136e0b8ef442a33feeb4799c
CRs-Fixed: 2016580
2017-06-27 22:13:06 -07:00
Arif Hussain
7698b6d332 qcacmn: Fix setting WMI_ROAM_INVOKE_FLAG_REPORT_FAILURE
WMI_ROAM_INVOKE_FLAG_REPORT_FAILURE flag is not set correctly,
bit(1) in flags represents WMI_ROAM_INVOKE_FLAG_REPORT_FAILURE,
fix the same.

Change-Id: I8311b1e6999f3c741ec8be87536a73f3e7e3cb93
CRs-Fixed: 2044160
2017-06-27 21:32:06 -07:00
Varun Reddy Yeturu
1ad240c718 qcacmn: Indicate firmware to report failure for ROAM_INVOKE
Set the WMI_ROAM_INVOKE_FLAG_REPORT_FAILURE flag in the
WMI_ROAM_INVOKE_CMDID requesting the firmware to always
report the failure to the host

Change-Id: Ie1a10ba774cf43e791b48a2f675225c74e94b958
CRs-Fixed: 2023893
2017-06-27 21:32:05 -07:00
Gurumoorthi Gnanasambandhan
871fd6edef qcacmn: Changes to support pdev stats for TLV
Handle WMI_UPDATE_STATS event to process the PDEV stats

Change-Id: I33ebab8deec41a1c8c361e8ca3e3cde05f650325
2017-06-27 20:02:01 -07:00
Vivek
f85a42b39d qcacmn: Clean up unwanted prints or change to appropriate log levels
Remove unwanted prints from the dirver and also change tha log levels
from some of the prints which could be useful in debug pruposes only.

Change-Id: I2b4e0c94fcf1571b332fc005b34bc4b7bcb4b7c5
2017-06-27 18:12:57 -07:00
Linux Build Service Account
5e5f8efbd2 Merge "qcacmn: Initialize mac_phy_count to zero before populating macphy params" 2017-06-26 17:31:31 -07:00
Deepak Dhamdhere
2eff0120ad qcacmn: Enable PMK cache and OKC with RSO command
Firmware now supports PMK caching in addition to OKC
(Opportunistic Key Caching). Use additional bit flags to enable
PMK caching in PMK configuration in roam offload scan request.

CRs-Fixed: 2004963
Change-Id: I536a4d45d5d915ab02dc13db6124a1ce8949fe48
2017-06-26 11:57:55 -07:00
Linux Build Service Account
758f17463c Merge "qcacmn: Fix pdev_id used in WMI_PDEV_SUSPEND_CMDID command" 2017-06-21 09:53:27 -07:00
Kiran Venkatappa
330179cff8 qcacmn: Fix pdev_id used in WMI_PDEV_SUSPEND_CMDID command
Firmware expects pdev suspend to be sent per pdev. Fix odev_suspend
command to use proper pdev_id.

Change-Id: I17489bbfc55c0c49371a857148af80f66b342378
CRs-Fixed: 2062400
2017-06-20 21:34:17 -07:00
Linux Build Service Account
f0d113575c Merge "qcacmn: Add changes for PN check in REO" 2017-06-20 01:20:33 -07:00
Selvaraj, Sridhar
ba7e361f70 qcacmn: Add min_candidate_rssi to wmi_per_roam_config structure
Add min_candidate_rssi to wmi_per_roam_config. This is added to
provide the configured min candidate AP threshold to fw to be used
for PER(Packet Error Rate) based roaming.

Change-Id: I6e0ae1ebe578bcd6d858e1d5252dead6e849d54a
CRs-Fixed: 2050039
2017-06-19 12:43:28 -07:00
Linux Build Service Account
45ea82254b Merge "qcacmn: Converge WMI beacon template cmd implementation" 2017-06-18 21:45:36 -07:00
Govind Singh
dfc14b8327 qcacmn: Converge WMI beacon template cmd implementation
There are two implementation of WMI beacon template wmi cmd.
Remove redundant code by converging WMI beacon template
cmd implementation.

Change-Id: Icc9e1f5326c3197a7994ed10ea1ef6386edc7efd
CRs-Fixed: 2061681
2017-06-18 17:36:52 -07:00
Linux Build Service Account
526ba9b305 Merge "qcacmn: Reduce log level in RSSI_BREACH_MONITOR_CONFIG_CMDID" 2017-06-17 07:53:36 -07:00
Rajeev Kumar
ca1de3e816 qcacmn: Reduce log level in RSSI_BREACH_MONITOR_CONFIG_CMDID
Reduce log level in RSSI_BREACH_MONITOR_CONFIG_CMDID to avoid
excessive logging on console.

Change-Id: Ifcafbe64ac6c4c3fdc43abdf1822ebe0261de1b1
CRs-Fixed: 2061307
2017-06-14 10:41:03 -07:00
Nitesh Shah
52323d0cf1 qcacmn: Add support to send DBS Scan command to firmware
This change adds support to send the DBS Scan command to
the firmware.

Change-Id: I147855690f09af03a43f85f2e57626d7f73998de
CRs-Fixed: 2029402
2017-06-14 08:23:51 -07:00
Venkateswara Swamy Bandaru
23e00ed196 qcacmn: Add support for wmi_service_chan_load_info
Added support for wmi_service_chan_load_info which is newly
added in wmi service bitmap.

Change-Id: I95905ac95c5305f8f84ec512ecf1859955704193
CRs-Fixed: 2057719
2017-06-12 09:07:06 -07:00
Dustin Brown
9d865648dd qcacmn: Expose scan_backoff_multiplier for NLO/PNO
For Network Listen Offload and Perfered Network Offload, the fast scan
period is multiplied by scan_backoff_multiplier after max cycles have
occurred. Expose scan_backoff_multiplier to consumers of the WMI API,
so this parameter can be configured.

Change-Id: I478fb61cd096d3496205f4ff556e180dabf99b77
CRs-Fixed: 2035201
2017-06-09 21:36:26 -07:00
Sreelakshmi Konamki
76d62afee4 qcacmn: Fix different types of case labels used in switch statement
Fix to update same enum wmi_scan_event_type types in switch statement
of extract_vdev_scan_ev_param_tlv()

Change-Id: I4817e57f2a9f309581392faadc1640c05d7fcf2b
CRs-Fixed: 2049514
2017-06-09 17:23:13 -07:00
Amar Singhal
7db15c88ca qcacmn: Implement 11d state machine
Regulatory component needs to listen to vdev messages in order to track
whether a master mode vdev is getting created or destroyed. It is also
used to kick-start the state machine. Also re-run the state machine when
user-space country code is set.

Change-Id: I5112396314a936f84dad2f0e07329f9cb237aa78
CRs-Fixed: 2048784
2017-06-08 13:46:53 -07:00
Kiran Kumar Lokere
b12cf5cae1 qcacmn: Add support for 11d FW commands and events
Add support to send 11d scan start and stop commands to FW and
process the 11d new country update event from FW.

Change-Id: I5c1588cfb5af672cdb5738784de1bd0b83bdbe77
CRs-Fixed: 2048784
2017-06-08 13:46:51 -07:00
Kiran Venkatappa
2bd431e8f9 qcacmn: Add support to extract pdev_id from utf seg info
pdev_id is required to get the pdev object from utf event. Extract
pdev_id from the seg info within utf event's data stream.

Change-Id: Id8d3263a7f33d234c7cb43c99a0a44f28df5724d
CRs-Fixed: 2055128
2017-06-05 11:41:39 -07:00
Sathish Kumar
e5f0e0e801 qcacmn: Add and modify extract APIs for TBTT offset and SWBA events
Recently, FW changes were implemented to support WMI resource config for
multi-radio. As part of this, the TBTT offset and SWBA events were modified
to support increase in the number of vdevs per SOC.

Brief description of the changes with respect to TBTT offset
------------------------------------------------------------

Converged FW will send extended TBTT offset event when the number of vdevs
configured is greater than 32 and will continue to send normal TBTT offset
event when the number of vdevs configured is less than 32. Legacy FW will
continue to send vdev map and tbttoffset list array as part of the TBTT
event.

Extraction API is added to extract the number of vdevs configured for both
legacy and converged FW. Number of vdevs is sent directly by the FW for
extended TBTT offset event but sent as vdev map for the normal TBTT offset
event. In order to handle normal TBTT offset event, extraction API for
normal TBTT event adds logic to convert vdev map into the number of vdevs
configured.

Extraction APIs are added to extract vdev id and tbttoffset information per
vdev that are configured. The vdev id information is sent as vdev map and
tbttoffset list as an array for normal TBTT event and as an array of
structures containing vdev id and tbttoffset in the case of extended TBTT
event. In order to support normal TBTT event based on num vdevs, extraction
API for normal TBTT eventadds logic to determine the vdev id from vdev map
based on the index(running through 1 to total number of vdevs) passed from
the driver.

Brief description of the changes with respect to SWBA
-----------------------------------------------------

Converged FW will send additional information num vdevs and vdev id
embedded in tim info and p2p noa TLVs for SWBA event. Legacy FW will
continue to send vdev map and array of tim info and p2p noa desciptors.

Extraction APIs is added to extract the number of vdevs configured for both
legacy and converged FW. Number of vdevs is sent directly by the FW for
SWBA event in the case of converged FW and as a vdev map in the legacy FW.
In order to handle legacy FW, extraction API for non-TLV adds logic
to convert vdev map into number of vdevs configured.

Extraction APIs are modified to extract newly embedded vdev id information
in tim info and p2p noa descriptors. The vdev id information is sent as
vdev map for legacy. In order to handle legacy FW, extraction API for
non-TLV adds logic to determing the vdev id from vdev map based on the
index (running through 1 to total number of vdevs) passed from the driver.

Change-Id: Ibf84adbb1c526321ec031d5539aff66dcbd1315b
CRs-Fixed: 2053628
2017-06-02 20:38:50 -07:00
Naveen Rawat
42cd1e66cb qcacmn: Add implementation for WMI_OEM_DMA_RING_CFG_REQ_CMDID
Program the DMA ring configuration to firmware using
WMI_OEM_DMA_RING_CFG_REQ_CMDID.

Change-Id: I99e5b3a369d7eeee1d1fe41782285ed54cdb82cf
CRs-Fixed: 2053958
2017-06-02 14:47:33 -07:00
Dustin Brown
f31f88b9a8 qcacmn: Expose full hardware filter capabilities via WMI
The WMI API exposes the broadcast hardware filter. Modify the WMI API
to expose all of the supported modes of the hardware filter.

Change-Id: I185b149f4d1ad38692d8ff5810acd52bf84565b2
CRs-Fixed: 2040419
2017-06-01 12:32:20 -07:00
Ravi Kumar Bokka
0f3f04d682 qcacmn: Configure and clear packet filter
Add PMO changes to configure and clear default packet filters
over suspend and resume

Change-Id: I1f3fab170d2669865da8ba09673df6ec8e755b31
CRs-Fixed: 2034458
2017-05-30 17:31:17 -07:00
Subrat Mishra
a1c92f584a qcacmn: ATF multiradio support
Changes added to support multiradio feature.
Included pdev_id and/or vdev_id in required ATF specific WMI data
structures. All ATF commands will be sent with pdev_id and/or vdev_id.

Change-Id: I723a9a6e4a67a417d4aa2b392285dc4afa590a21
CRs-Fixed: 2052786
2017-05-29 06:08:21 -07:00
Kapil Gupta
0692a1aa70 qcacmn: validate hw caps before dereferencing
Currently we are dereferencing hw caps without validation which
may cause kernel panic.

Add changes to validate hw caps before dereferencing.

Change-Id: I642dd4c0db872c4cf3bdff7e5fbccbacc82f307d
CRs-Fixed: 2049122
2017-05-25 02:19:34 -07:00
Kiran Venkatappa
1241bb8f85 qcacmn: Changes to support pdev_id in host from zero
pdev_id in FW starts from one. Zero is reserved for Soc. But host uses
pdev_id starting from zero. Make WMI changes to take care of this
difference and always provide and accept pdev_id starting from zero at
WMI. Use 0xFF for SoC on host.

Change-Id: I49f481e54bbaeea9359753bc7d3da9092fc9559a
CRs-Fixed: 2045125
2017-05-22 17:05:25 -07:00
Amar Singhal
a522f219dc qcacmn: Add callback for dynamic changes to current channel list
For dynamic master channel list, compute per pdev current channel
list as well. Provide API for user to register callback to be called
whenever current channel list for a pdev changes.

CRs-Fixed: 2012415
Change-Id: Ie86a719306178a1c3579c2b534a52a12ec3e0b1d
2017-05-18 13:42:24 -07:00
Kiran Kumar Lokere
daf91e333c qcacmn: Add support to send new country to FW
Add support to set new country code to the FW

Change-Id: Id24967b7c9e93bfbf045f494f142be9e33e16483
CRs-Fixed: 2042879
2017-05-18 13:42:21 -07:00
Linux Build Service Account
6fcc2020d3 Merge "qcacmn: Extract pdev id from vdev id received in WMI_CHAN_INFO_EVENTID" 2017-05-17 07:51:31 -07:00
Sathish Kumar
8458a056db qcacmn: Fix to set TLV header correctly for coex config command
TLV header is incorrectly set for coex config command due to wrong
TLV length passed to the set TLV header API.

Fix issue by setting TLV header passing correct TLV length.

Change-Id: Ica3e2468d26bdaed26cade048f4d440c067ad929
CRs-Fixed: 2037499
2017-05-16 22:08:08 -07:00
Om Prakash Tripathi
c569cdb9f5 qcacmn: Add TLV support for thermal throttling
1. Add multi radio support for thermal throttling
2. Add TLV WMI support for thermal throttling

Change-Id: I2cdbf9a4acdd9346c0fe3dd24c510885cc8fef8e
CRs-Fixed: 2041264
2017-05-15 17:00:09 -07:00
Sathish Kumar
87db1bd6f2 qcacmn: Extract pdev id from vdev id received in WMI_CHAN_INFO_EVENTID
Add support in utils layer to extract pdev id from vdev id using object
manager APIs.

Use the API to extract pdev id from vdev id received through the
chan info event handler for lithium based chipsets.

CRs-Fixed: 2043869
Change-Id: Ibf1f1f91d505d53219ca9a2f5d94beb8553edfe3
2017-05-12 19:54:18 +05:30
Linux Build Service Account
6f536620c2 Merge "qcacmn: Update host WMI service enums with new additions" 2017-05-10 10:22:54 -07:00
Kiran Venkatappa
95c82a6e33 qcacmn: Update host WMI service enums with new additions
Update enums in WMI service enums that got introduced in the latest
FW headers.

Change-Id: I46f70ff5eb41aee15f8cac784cc85201a3362fca
CRs-Fixed: 2045146
2017-05-10 15:20:29 +05:30
Amar Singhal
a2d575fda4 qcacmn: Fixes for master channel list
When a new master channel list is created, populate master chan list to all
pdevs. Do not make any assumption on availability of pdevs. Make other
stability and initialization fixes. Also add extra fields to data
structures.

Change-Id: I0a59c41e9425435f6069807a3c5de0b389d8fa5e
CRs-Fixed: 2002892
2017-05-07 06:56:22 -07:00
Abhijit Pradhan
b5a1d245f3 qcacmn: Fill antenna gain in master channel list
Antenna gain is per regulatory structure. However we need it in
per channel during transmission. Firmware sends antenna gain per
regulatory rule. Host copies it to per channel structure.

Change-Id: Ia163f46facec03ccd450994acbeb28d1e9f2a111
CRs-Fixed: 2002892
2017-04-28 09:47:04 -07:00
Kiran Venkatappa
9d59bd6594 qcacmn: Add send beacon by ref WMI for TLV target
WMI_PDEV_SEND_BCN_CMDID WMI is used to send Beacon from host.
Implement this API for TLV target to send beacon from host
when beacon offload is disabled.

Change-Id: I0b01fb4be349d032622a43a43224680946ecfcd3
CRs-Fixed: 2038176
2017-04-27 23:59:23 -07:00