Commit Graph

1016 Commits

Author SHA1 Message Date
Jeff Johnson
6df9155649 qcacmn: Rename sme_session_id in struct add_ts_param (2/2)
The sme_session_id field in struct add_ts_param is poorly named since
that is legacy MCL nomenclature, so there is a desire to rename it to
vdev_id to align with the converged nomenclature.

The first phase of renaming introduced a union so that both the old
and new name could be used by legacy projects, but only the new name
was used within the qcacmn project.

Now since all legacy projects have been updated to use the new name,
for the second phase remove the union, leaving behind just the new
name.

Change-Id: Ie86a3c0833899fbeacd458a53d9e23c6a67e7f12
CRs-Fixed: 2384157
2019-01-30 00:03:07 -08:00
Jeff Johnson
7929ba9084 qcacmn: Rename sme_session_id in struct add_ts_param (1/2)
The sme_session_id field in struct add_ts_param is poorly named since
that is legacy MCL nomenclature, so there is a desire to rename it to
vdev_id to align with the converged nomenclature. As the first phase
of renaming introduce a union so that both the old and new name can be
used by legacy projects, but otherwise only use the new name within
the qcacmn project.

Change-Id: I93743c3b1e3180589a3af83ed9e51d8dc95324d9
CRs-Fixed: 2384156
2019-01-29 21:47:28 -08:00
Manikandan Mohan
3c572b3e19 qcacmn: Fix null pointer dereference in NAN event processing
In function extract_nan_event_rsp_tlv processing WMI_NAN_EVENTID,
fix a potential null pointer dereference of NAN event info data
structure.

Change-Id: I2180d3ce75d89a698d34c56d2abc7687a5fdd485
CRs-fixed: 2381237
2019-01-29 16:55:02 -08:00
Shashikala Prabhu
7517a8d7b9 qcacmn: Call regdb wrapper functions from other components
Do not call regdb core functions from other components directly.
Instead, call regdb dispatcher  functions.

Also, wlan_objmgr_vdev_obj.h file is removed from reg_services.h file in
Ie43acc03a5c35200f3e43bc978b792d5047eeb77 and reg_services.h is removed
from wlan_reg_services_api.h in I891b14fac7a4eddf2697d2ecdc0ac4a82046f532.
Therefore to fix "'struct wlan_channel' declared inside parameter list"
error in wlan_dfs_utils_api.h file, I have included wlan_objmgr_vdev_obj.h
file before wlan_dfs_utils_api.h in scan, dfs and wmi component.

Change-Id: Id8816f5137c3b1f9200c59fc3f9041980631f22f
CRs-Fixed: 2349173
2019-01-23 15:14:32 -08:00
Jeff Johnson
6a00f1e830 qcacmn: Address Unified WMI "get link status" deficiencies
The original implementation of the "get link status" feature contains
some design and implementation details that are not ideal, so fix the
following deficiencies:
- The link_status_params struct contains three fields that are unused.
- The only link_status_params field that is used, session_id, uses
  legacy terminology instead of converged terminology
- The wmi_unified_link_status_req_cmd() implementation uses a void
  pointer instead of the correct underlying type for the WMI handle.

Note that change I508ec083298caa45d4cbb1ba28b21e47e379a804
("qcacld-3.0: Align with revised "get link status" Unified WMI") is
interdependent with this change.

Change-Id: I057ca0aff4a627c7fcdb9f90a5da46473813f60a
CRs-Fixed: 2381364
2019-01-22 05:06:43 -08:00
Harprit Chhabada
71c9846f58 qcacmn: Use the same callback signature for MCL as WIN
Callback signature in wmi_process_fw_event_default_ctx
is different for WIN and MCL. Make it same.

Change-Id: I28ad8e6068742095bdb9bc265e46dead8bfb217d
CRs-Fixed: 2372980
2019-01-21 03:55:04 -08:00
Shashikala Prabhu
4fbfffb536 qcacmn: Delete WIN only wmi header and source files
WIN WMI only header and source files are moved from cmn_dev to
qca-wifi-oss.

Change-Id: Icb7edfb309922de0aed537e89152e3b1cef3326b
CRs-Fixed: 2360078
2019-01-21 01:46:31 -08:00
Arif Hussain
2028c7f543 qcacmn: Fix possible OOB read in extract_reg_cap_service_ready_ext_tlv
OOB read can occur while handling WMI_SERVICE_READY_EXT_EVENTID event
when large invalid num_phy received in that event, as this value is used
as index to array.

Change-Id: I0e80d04d19160e219028b07599a8b9953a798fb2
CRs-Fixed: 2374726
2019-01-19 13:18:32 -08:00
Will Huang
5a453d8d40 qcacmn: Remove CONFIG_MCL for send_scan_chan_list_cmd_tlv
Currently we have same function name/different implementation when set
wmi scan channel list for WIN and MCL, the implementation for WIN side
send_scan_chan_list_cmd_tlv looks more intuitive which will remain with
minor change.

Remove definition of struct scan_chan_list_params and wmi_channel_param
which is no longer needed. Change HT flag set independent on VHT flag.
Add WMI DFS flag set if channel_param.dfs_set set.

Change-Id: I131ca09c12687bda5eb3eb03b7bcca1d62ac7aa9
CRs-Fixed: 2363675
2019-01-18 21:28:42 -08:00
Arif Hussain
61847a9ba6 qcacmn: Use function name instead of file name in debug logs
Replace all instance of file name to function name in debug logs.

Change-Id: Iff731675772859f02c975005b2656eaa41c6f360
CRs-Fixed: 2377894
2019-01-17 22:20:46 -08:00
Jeff Johnson
3caa53099c qcacmn: Remove SSID hotlist support
Change Ie6c4a9847f2daa9ba2aebd17f386d584201b86d6 ("qcacld-3.0: Remove
obsolete set/reset ssid hotlist") in the qcacld-3.0 project removed
the only client of the WMI SSID hotlist infrastructure. Since this
infrastructure is obsolete, remove it.

Change-Id: I4a1de39c982947bbf4958d976426f95e3217f1a3
CRs-Fixed: 2381277
2019-01-17 13:12:49 -08:00
tinlin
d6bdb6eb36 qcacmn: Add check for num_hw_modes
In extract_mac_phy_cap_service_ready_ext() the num_hw_modes
is used as loop bounds and may be attacked.

hw_mode_caps is a pointer defined by firmware. The exact
array length cannot be got since hw_mode_caps pointing array
length is variable. So use max number to  check
num_hw_modes before loop.

The max number of hw modes is 24 including 11ax.

Change-Id: I72f30ba819bca89915bb09f271e3dbe7c0f157a6
CRs-Fixed: 2369233
2019-01-17 02:22:20 -08:00
Shiva Krishna Pittala
860140027e qcacmn: Correct the formatting in Spectral WMI logs
Current Spectral WMI logs on TLV systems are
difficult to interpret, correct it.
Also, set their log level to QDF_TRACE_LEVLE_DEBUG.

Change-Id: I6f19143df230d82edc2fb8dd86b18addbb327d6b
CRs-Fixed: 2369960
2019-01-16 17:09:59 -08:00
Wu Gao
6b70d468e7 qcacmn: Check the valid of chain mask capabilities number
The pointer to chain masks capabilities is increased, and the number
of chainmask capabilities isn't check if valid. Which will cause oob
read list of chain mask capabilities.

Change-Id: I1f11fb49d545a4f88fe4d0734968dbe17c3f1a7e
CRs-Fixed: 2347661
2019-01-16 17:09:56 -08:00
Jeevan Kukkalli
b6efb747d7 qcacmn: Add peer param to indicate FT roam
Add peer param to indicate start/stop of FT roam to fw.

Change-Id: I5b685fb1265656d319cae9272b7eca2ef2e7c3e3
CRs-Fixed: 2353125
2019-01-16 12:57:06 -08:00
Jianmin Zhu
7d37e84cf7 qcacmn: Fix possible OOB read in extract_hw_mode_cap_service_ready_ext_tlv
When WMI_SERVICE_READY_EXT_EVENT is received from firmware, the
function extract_hw_mode_cap_service_ready_ext_tlv is called to
update the soc caps and other capabilities to the host. hw_caps
is extracted directly from the param_buf value received from the
firmware and hw_caps->num_hw_modes is used to traverse
through the hw_mode_caps and update the values to it from the
param_buf->hw_mode_caps, need validate hw_caps->num_hw_modes and
param_buf->hw_mode_caps before use them.

Change-Id: I459f0afce7701ddf1d041912e3406643d27a7f9c
CRs-Fixed: 2336910
2019-01-16 10:37:50 -08:00
Jianmin Zhu
60e9d43aae qcacmn: Fix OOB read in extract_ndp_ind_tlv()
In the call to QDF_TRACE_HEX_DUMP in extract_ndp_ind_tlv(),
the buffer, event->ndp_cfg is dereferenced an additional time
and then read the length number of bytes in hex_dump_to_buffer,
resulting in an OOB read.
As WMI logging is already enabled, remove the hex dump.

Change-Id: I1ebe2469a6bb2baefc76980405d97700c1c57b5c
CRs-Fixed: 2336856
2019-01-14 21:47:37 -08:00
Abhishek Singh
00f80b6094 qcacmn: fix out of bound access of memories in wlan_cfg80211_scan
In wlan_cfg80211_scan the number of ssid, ssid length and number of
channels are not checked for max size of array and thus can lead to
Out of bound access of memories.

Fix is to add bound check before copying the params.

Change-Id: Ie6d4e546fb9c884d5988493b611ef7b217f0a95c
CRs-Fixed: 2375217
2019-01-13 11:26:48 -08:00
tinlin
ab5cba5cbb qcacmn: Fix NULL pointer dereference
In extract_hal_reg_cap_tlv(), hal_reg_capabilities
can be optionally defined. This field can be NULL
resulting in a NULL pointer read. Add NULL pointer
check before qdf_memory_call().

Change-Id: I142bed65e80aa9b4bb88a4e68f74235dd50e3624
CRs-Fixed: 2368284
2019-01-13 11:26:45 -08:00
Jeff Johnson
fe762b2d22 qcacmn: Rename ptspecIE in send_set_ric_req_cmd_tlv()
Per the Linux coding style both mixed-case names and so-called
Hungarian notation are frowned upon, so rename local variable
ptspecIE in send_set_ric_req_cmd_tlv() to align with the coding
style.

Note that there are other instances of mixed-case names in this
function, but these are global in scope and will need to be cleaned up
in a global effort.

Change-Id: I10780e2f751d1a1ed8f14a5ee4890794f498ec0b
CRs-Fixed: 2374719
2019-01-10 01:14:14 -08:00
Kiran Kumar Lokere
25531c4717 qcacmn: Add support for SET KEY convergence
Make changes to the cmn driver to support SET KEY
convergence feature

Change-Id: I17b5f368a1f735eb394ea70f9b61cc033c3eb20a
CRs-Fixed: 2358796
2019-01-08 18:21:17 -08:00
Shiva Krishna Pittala
ec27e10c2a qcacmn: Remove OL_SPECTRAL_DEBUG_CONFIG_INTERACTIONS macro
Logs of the Spectral WMI interaction prints are under
OL_SPECTRAL_DEBUG_CONFIG_INTERACTIONS macro and is disabled by default.
As the WMI logs are already controllable at runtime from qdf_cv_lvl,
there is no need for OL_SPECTRAL_DEBUG_CONFIG_INTERACTIONS anymore.

Change-Id: I3b89192de4deb420d853631064c20add894fb1e3
CRs-Fixed: 2369846
2019-01-07 19:59:17 -08:00
Edayilliam Jayadev
208e64c189 qcacmn: Rearrage the debug prints
Rearrange the debug prints in the wmi path
so that valid information gets printed.

CRs-Fixed: 2368173
Change-Id: I8900eda444c9d1dee69f5c1e30662022580d2a7b
2019-01-07 00:12:54 -08:00
Arif Hussain
4576e298ca qcacmn: Validate number of entries in extract_host_mem_req_tlv()
Validate num_mem_reqs should be less than TLV size in
extract_host_mem_req_tlv() function.

Change-Id: I88ebfc4bfe3abb9b0926990f5f777fc0d62e1fc1
CRs-Fixed: 2347667
2019-01-03 04:35:13 -08:00
Jeff Johnson
da8409437e qcacmn: Rename pAddPeriodicTxPtrnParams
Per the Linux coding style both mixed-case names and so-called
Hungarian notation are frowned upon, therefore replace the identifier
pAddPeriodicTxPtrnParams everywhere it occurs.

Change-Id: Id80fc4cd22a8e4af125f01b937e03eea0b898283
CRs-Fixed: 2371906
2018-12-27 20:02:31 -08:00
Wu Gao
779d274148 qcacmn: Remove structure wmi_tdls_params
Using both structure wmi_tdls_params and tdls_info if TDLS component
sets FW states, which will cause memory corruption potentially. Use
enum wmi_tdls_state as type of tdls state.

Change-Id: Ia1e78a5c6d8aee9ab5166c0704dd7827f42c2457
CRs-Fixed: 2372452
2018-12-27 01:05:21 -08:00
Harprit Chhabada
6407dc4721 qcacmn: Create header file for wmi_unified_bcn_buf_ll_cmd
wmi_unified_bcn_buf_ll_cmd in wmi_unified.h had compilation flag
CONFIG_MCL. To get rid of the compilation flag, a separate header
file is created

Change-Id: I0bbcdf749f461f6880aacc1e3ef4e8e8fdc08ff6
CRs-Fixed: 2366773
2018-12-26 20:27:35 -08:00
Pragaspathi Thilagaraj
2937e1aee1 qcacmn: Send roam_score_delta, roam_score_delta_bitmap to firmware
Two new WCNSS_qcom.ini values "roam_score_delta" and
"roam_trigger_bitmap" are introduced. These values are sent to
firmware over the WMI command WMI_ROAM_AP_PROFILE over the
structure wmi_roam_cnd_scoring_param. The values to this
structure are populated from struct scoring_params.

Add roam_score_delta and roam_trigger_bitmap in scoring_param.
Populate these values from roam request to the structure
wmi_roam_cnd_scoring_param to be sent over the wmi command.

Change-Id: I012867e60ddf18a276250ef3bd27015f191d8a6a
CRs-Fixed: 2368263
2018-12-26 10:12:34 -08:00
Pragaspathi Thilagaraj
13130ebe99 qcacmn: Add rct_validity_timer and disassoc_timer to wmi roam structures
Two new WCNSS_qcom.ini values "btm_validity_timer" and
"disassoc_timer" are introduced. These values are sent to
firmware over the structures wmi_roam_offload_tlv_param and
wmi_btm_config_fixed_param respectively. The values to this
structure are populated from struct roam_offload_scan_params.

Add rct_validity_timer in roam_offload_scan_params.
Populate these values from roam request to the structure
roam_offload_scan_params to be sent over the wmi command.

Change-Id: I6130e9966d520169b0f74b9726d35aa4fef6d81d
CRs-Fixed: 2369040
2018-12-26 10:12:30 -08:00
Pragaspathi Thilagaraj
935a05da75 qcacmn: Handle the wmi event WMI_ROAM_BLACKLIST_EVENTID
The firmware sends a new wmi event WMI_ROAM_BLACKLIST_EVENTID
to send the blacklist AP list.

Change-Id: I04fab853efbded48285ac063bb39c64f342c229b
CRs-Fixed: 2369107
2018-12-26 07:47:53 -08:00
Pragaspathi Thilagaraj
9327725639 qcacmn: Send bss_load_bss_sample_time over WMI_ROAM_BSS_LOAD_CONFIG_CMDID
Add changes to send bss_load_bss_sample_time over the wmi
command WMI_ROAM_BSS_LOAD_CONFIG_CMDID.

Change-Id: Iab882f0474071458ed8b8876d8edda987b76e94d
CRs-Fixed: 2372167
2018-12-26 07:47:47 -08:00
Pragaspathi Thilagaraj
9341ee36b8 qcacmn: wmi changes to send bss load trigger config to firmware
Populate the load bss trigger configuration values based on the
ini values and send them to firmware.

Add wmi changes to send bss load trigger config to firmware.

Change-Id: Ib2e21904bc7b8d87e5f51824d2694b90a3ac53f2
CRs-Fixed: 2367773
2018-12-26 07:47:44 -08:00
Yeshwanth Sriram Guntuka
c4a14ea149 qcacmn: Add host support for db2dbm RSSI changes
Add host support for db2dbm RSSI changes. Firmware
indicates this capability when underlying hardware
has RSSI reporting feature. Based on this capability
host will know if firmware sends SNR or RSSI. If no
capablity is present then host will convert SNR to
rssi using a fixed offset of -96. If capability is
present host will directly use the rssi as it is.

Change-Id: I9058f16c6280d466feb96cf88a8a0d8cd7b02032
CRs-Fixed: 2364025
2018-12-24 03:33:04 -08:00
Edayilliam Jayadev
4c002343ad qcacmn: Time stamp WAR for spectral
Spectral HW time stamp gets reset when a reset happens in
within target. This can potentially result in unpredictable
behaviour during classification. To mitigate this calculated
offset is added to the time stamp value in the FFT report.

HT = Spectral HW timer
AT = Actual time stamp in spectral report
CF = Time stamp correction factor
CT = Corrected time stamp
L = Time stamp in the last FFT report before reset
F = Time stamp in the first FFT report after reset
D = Time gap between the last spectral report before reset
    and the end of reset(This is provided by FW via direct
    DMA framework)

                         ***Target Reset***
                                 ^
                                 |
                            |<---D---->|           time line--->
       _______________________________________________________
       ^                    ^          ^  ^
       |                    |          |  |

HT --> 0                    L          0  F

AT --> 0                    L             F

CF --> 0                    0           (L+D)

CT --> 0                    L          (F+L+D)

Spectral driver corrects the time stamp received from target
using the following formula and sends upwards.

CT(Corrected time stamp) = AT(Actual time stamp) +
                           CF(Correction Factor)

Calculation of Correction factor (CF):-
---------------------------------------
Initialization : CF = 0
CF += (L + D) (Done only for the first spectral report after reset)

This scheme takes care of the wrap around in the 32 bit time stamp
which would have occurred if the timer was not restarted due to
target reset.

CRs-Fixed: 2356382 2355486
Change-Id: I17b55d39eb91eb03b867bcfddaf3eb03d1fc5d1b
2018-12-24 03:32:52 -08:00
Jianmin Zhu
1aed4e8324 qcacmn: Remove CONFIG_MCL in roam_offload_scan_params
Replace CONFIG_MCL with WLAN_FEATURE_ROAM_OFFLOAD in
struct roam_offload_scan_params

Change-Id: Ibf9c393effc78a201525ae53cb9ced127244ee67
CRs-Fixed: 2363094
2018-12-22 02:54:15 -08:00
Akshay Kosigi
46050aa104 qcacmn: Add NULL check for WMI handle
Adding NULL checks for WMI handle while registering or unregistering
events or event handlers

Change-Id: Icdf7032bad7289e62f5d7b17aab9780bcdf0ab1d
2018-12-21 10:05:40 -08:00
Rajeev Kumar Sirasanagandla
cc123bcab3 qcacmn: Ignore default country update during wlan restart
After driver load and interface up, if user changes the country code
and performs the interface down, now if interface change timer expires,
stop modules is invoked. When user again tries to do interface up, as a
part of start modules, update channel list indication comes from FW
with default country info from BDF file which overwrites user specified
country information.

To resolve this issue, if current country is set by user and if
driver gets notification to update channel list from FW with
different country code during restart of wlan modules then ignore
master channel list and send the current user country to FW.

Change-Id: I0a0c57eda03827dc3fef59928569bf2f0bc32634
CRs-Fixed: 2340798
2018-12-21 02:40:57 -08:00
Nachiket Kukade
c64e33df96 qcacmn: Add modules to handle and extract NAN events
As part of supporting NAN DBS, new WMI TLVs are defined so
that Host can maintain the status of NAN Discovery in sync
with the Firmware. Move the older handlers into the NAN
related files. Also add modules to extract information from
the new TLV's and fill up the event parameters to pass
them to the NAN component. add support for explicitly
disabling NAN due to concurrencies.

Add modules to handle and extract the info from NAN events.

Change-Id: Ic03baaaef45106353c211a813e11e33a90cd41ca
CRs-Fixed: 2338059
2018-12-18 14:29:29 -08:00
Nachiket Kukade
30ed5c4456 qcacmn: Add support for the new NAN EXT vendor command
As part of the NAN Discovery DBS support, new vendor command
- QCA_NL80211_VENDOR_SUBCMD_NAN_EXT - has been defined that
can carry the binary blob encapsulated within an attribute
and can carry additional attributes to enhance the NAN command
interface. Add the related definitions to support this command.

Add definitions to support the new NAN EXT vendor command.

Change-Id: I83c12c7512066434f8974619e1d953ac78d3a40d
CRs-Fixed: 2339032
2018-12-18 10:13:08 -08:00
Kiran Venkatappa
c0d010216a qcacmn: Add support to choose hw_mode_id from FW supported modes
Add support to choose the hw_mode_id from FW supported modes. Preferred
mode will be selected if it is not configured in ini params. It is
selected based on the precedence as per capabilities supported by the
mode. For eg., if FW supports DBS and DBS_SBS, DBS_SBS is selected as it
supports three radio compared to DBS's two radio.
This can be overridden by user by setting proper hw_mode_id in ini file.

Change-Id: I162c3a66182882890c416a68f7f64d5149b8f1e5
CRs-Fixed: 2361280
2018-12-14 14:26:25 -08:00
Sourav Mohapatra
1bc4bc2a25 qcacmn: Add converged enum for WMI_SERVICE_VDEV_LATENCY_CONFIG
Currently there is no converged wmi_service enum for the
WMI_SERVICE_VDEV_LATENCY_CONFIG.

Add wmi_service_vdev_latency_config as the converged enum.

Change-Id: I90d54ccd507b4267cd7310b4e6e5b1473c7dc41c
CRs-Fixed: 2366187
2018-12-14 07:15:29 -08:00
Jeff Johnson
b0e6f8dc79 qcacmn: Refine struct wmi_unified_pmk_cache (phase 3)
The original definition of struct wmi_unified_pmk_cache had several
anomalies:
1) It contains an unnecessary tlv_header field. Only the fw-api
   structs should contain TLV headers.
2) It contains a mis-named session_id field. Common structures should
   use converged terminology, in this case vdev_id

Change If4be27111c604c16ea437aa654210cdff28220a7 ("qcacmn: Refine
struct wmi_unified_pmk_cache (phase 1)") completely addressed the
first issue, and as the first phase of fixing the second issue it
replaced the session_id field with an anonymous union which contains
both the existing session_id field and a new vdev_id field. Being part
of a union these field will overlay each other.

qca-wifi-host_cmn change Ie8cc453751b95c332e3df32794506a4bd3c324ad
("qcacmn: Refine struct wmi_unified_pmk_cache (phase 2)") and
qcacld-3.0 change Ief4bcb819cb3c842adb74904f2cb2483476eaeb9
("qcacld-3.0: Use the refined struct wmi_unified_pmk_cache") replaced
all references to session_id with references to vdev_id.

For phase 3 remove the anonymous union introduced in phase 1, leaving
just the vdev_id field.

Change-Id: Ic5a274b9e2e8e603eef801a9d6422f55829f9735
CRs-Fixed: 2363432
2018-12-14 07:15:26 -08:00
Jeff Johnson
3ef2b9613d qcacmn: Refine struct wmi_unified_pmk_cache (phase 2)
The original definition of struct wmi_unified_pmk_cache had several
anomalies:
1) It contains an unnecessary tlv_header field. Only the fw-api
   structs should contain TLV headers.
2) It contains a mis-named session_id field. Common structures should
   use converged terminology, in this case vdev_id

Change If4be27111c604c16ea437aa654210cdff28220a7 ("qcacmn: Refine
struct wmi_unified_pmk_cache (phase 1)") completely addressed the
first issue, and as the first phase of fixing the second issue it
replaced the session_id field with an anonymous union which contains
both the existing session_id field and a new vdev_id field. Being part
of a union these field will overlay each other.

For phase 2 replace the reference to session_id with a reference to
vdev_id in send_set_del_pmkid_cache_cmd_tlv().

Change-Id: Ie8cc453751b95c332e3df32794506a4bd3c324ad
CRs-Fixed: 2363431
2018-12-14 07:15:23 -08:00
Rajeev Kumar Sirasanagandla
33d9b7fc64 qcacmn: Add WMI support to disable aggressive TX
Add WMI support to send action oui DISABLE_AGGRESSIVE_TX
to firmware to disable some of aggressive tx features for peer mac
when DUT is operating in softap mode.

Aggressive TX features disabled are SIFS bursting, assist and support of
more than 32 frames in AMPDU.

Change-Id: Iaad1917a6a4897cef4d65a8951d3d1f207a9167b
CRs-Fixed: 2364937
2018-12-13 23:21:39 -08:00
Jeff Johnson
b9f08212f6 qcacmn: Refine struct wmi_unified_pmk_cache (phase 1)
The current definition of struct wmi_unified_pmk_cache has the
following anomalies:
1) It contains an unnecessary tlv_header field. Only the fw-api
   structs should contain TLV headers.
2) It contains a mis-named session_id field. Common structures should
   use converged terminology, in this case vdev_id

To fix the first issue just remove the tlv_header field since it isn't
used.  To fix the second issue takes a phased approach. For phase 1
replace the session_id field with an anonymous union which contains
both the existing session_id field and a new vdev_id field. Being part
of a union these field will overlay each other.

Subsequent phases will replace session_id references with vdev_id
references, and then remove the union, leaving just the vdev_id field.

Change-Id: If4be27111c604c16ea437aa654210cdff28220a7
CRs-Fixed: 2363430
2018-12-13 16:46:11 -08:00
Arunk Khandavalli
84acb9ff6e qcacmn: Add support query per Vdev Beacon reception
Add WMI support query per Vdev Beacon reception.

Change-Id: I535c03eaefba9fbbcdc51cead1093680f451da10
CRs-Fixed: 2360914
2018-12-11 12:27:14 -08:00
Alok Kumar
b5ec642075 qcacmn: Add WMI support for WMI_PEER_UNMAP_CONF_CMDID
Add WMI support to send WMI_PEER_UNMAP_CONF_CMDID to FW
for peer unmap confirmation.

Change-Id: I1a260f840ed28f90568d9cba912cc5e5128c8c7d
CRs-Fixed: 2358066
2018-12-09 22:42:00 -08:00
Abhishek Singh
b2405ece84 qcacmn: Return failure if sending WMI_PDEV_SET_MAC_CONFIG_CMDID fail
Function send_pdev_set_dual_mac_config_cmd_tlv return success even
if it fails to send WMI_PDEV_SET_MAC_CONFIG_CMDID. Thus the
e_sme_command_set_dual_mac_config cmd stuck in active queue leading
to active command timeout.

Return failure if WMI_PDEV_SET_MAC_CONFIG_CMDID fails.

Change-Id: I9593c7369a4e152c8c233e60216ecd7fc301b944
CRs-Fixed: 2362270
2018-12-06 19:23:26 -08:00
Shashikala Prabhu
bfd50437fd qcacmn: Use UNBOUND flag to create WMI RX workqueue
WMI RX workqueue is created with WQ_MEM_RECLAIM flag. When host receives
the WMI service ready event it queues the work. There is 50sec delay in
scheduling workqueue to process WMI service ready event. This results in
host timeout (timeout = 15sec) and wifi load failure. This cleans up the
host data structures related to data path. But work got scheduled after
50sec resulting in init path handling with inconsistent data structures.

Use workqueue UNBOUND flag to create WMI RX workqueue. Works queued to
unbound workqueues are implicitly HIGHPRI and dispatched to unbound
workers as soon as resources are available.

Change-Id: I46eb0242ad88103268df99be9fd2e0759ebec4b2
CRs-Fixed: 2343181
2018-12-06 13:44:13 -08:00
Keyur Parekh
c28f839a84 qcacmn: FR-50469 Pktlog for particular peer mac address support
This FR is to enhance existing pktlog debug tool
This feature will allow to capture pktlog for particular
peer mac address.

Change-Id: I3676095536185f25b0d498e03f70246260a324fd
2018-12-06 00:03:13 -08:00