Commit graph

6,473 commits

Author SHA1 Message Date
Chaithanya Garrepalli
af34aae9cd qcacmn: add counters for sa_idx invalid issue
Add counters in case where we identify
HW issue where sa_valid and da_valid bit
are set and sa_idx and da_idx are invalid

Change-Id: I690b626dd3c2b7f20b35982514b0f27576221250
CRs-fixed: 2340521
2019-02-27 03:14:02 -08:00
Ankit Kumar
7ace978f3b qcacmn: Reduce print level while dumping chainmask info
While kernel boots, lots of chainmask information gets printed
on console and which decreases readability and dumps lots of
unwanted prints at boot time.

This patch reduces some print level from INFO->DEBUG and can be
enabled and used for debugging whenever needed.

Change-Id: Id1ec1eb4d46c6883f7c22152c765e99074c537ec
CRs-Fixed: 2404102
2019-02-27 03:13:59 -08:00
Amir Patel
78824b1d4e qcacmn: Add changes for RDK statistics
Change API signature for dp_getrateindex to populate rate index
and add additional stats required for RDK.
Add QDF abstraction for EWMA average rssi

CRs-Fixed: 2397918
Change-Id: Id878971799c5df2ae60057a86b2769724ee0dcc5
2019-02-27 03:13:56 -08:00
Keyur Parekh
25ee316744 qcacmn: Modify HE GI enum values and populate ldpc for HE
In PPDU Rx stats GI value for HE displaying wrong,
because of wrong enum values. Corrected enum values
to match GI values to Tx stats.

Also LDPC shows always 0 in PPDU Rx stats for HE.
Populated LDPC value for HE case as well to display
in PPDU Rx stats.

Change-Id: I6054d3e8c8e8672bcc2d43daa8a6e2a1bc859985
2019-02-27 03:13:52 -08:00
Abhiram Jogadenu
db3bb4b4a7 qcacmn: Add extract API for ring params from DBR
Extract ring parameters using dbr_rx_ops for functions in umac.

CRs-Fixed: 2404710
Change-Id: I6fa02668b4fead35ace9e1b4886954ca4cca09c6
2019-02-27 03:13:49 -08:00
Nijun Gong
1eb84e39fe qcacmn: Remove improper kernel API for coherent memory
Memory allocated by dma_alloc_coherent() doesn't need cache sync, which
is only needed for stream dma mapping, eg, mapping passed-in memory
using dma_map_single().

More seriously, when SMMU enabled, physical memory returned by
dma_alloc_coherent() is no longer continuous. If pass this memory to
dma_sync_single_for_device(), a do_bad_area exception will hang system,
noting that dma_sync_single_for_device() only handles single contiguous
memory. Refer to Documentation/DMA-API.txt for more info.

Change-Id: Ia0b5bdcc2cb9335aa2e309efccd91e57e844c7cc
CRs-Fixed: 2381886
2019-02-26 21:18:50 -08:00
Srinivas Girigowda
03bd4b6b30 qcacmn: Replace struct ether_header with qdf_ether_header_t
Replace struct ether_header with qdf_ether_header_t.

Change-Id: I30d06dcf94e3149bf77f1f99e7a854bc9d7ae3ac
CRs-Fixed: 2404851
2019-02-26 21:18:44 -08:00
Srinivas Girigowda
99f2a29945 qcacmn: Replace ETHERTYPE_8021Q with ETHERTYPE_VLAN
Replace ETHERTYPE_8021Q with ETHERTYPE_VLAN.

CRs-Fixed: 2404839
Change-Id: I5a1f721246ae71848f259a19ee3aa0de005ea43b
2019-02-26 21:18:40 -08:00
Srinivas Girigowda
4468047f83 qcacmn: Remove references of cds_ieee80211_defines.h
The file cds_ieee80211_defines.h is removed as part of
Change-Id: I3b7a3f61f82ea15b7975fb5d143257c80382f20d.
Hence remove the references of this file.

Change-Id: Ie94a748d062b65824e5b1f8aba8b7f7d92e937aa
CRs-Fixed: 2405051
2019-02-26 21:18:36 -08:00
Alok Kumar
acc11e646e qcacmn: Return the correct error code for PEER UNMAP RESPONSE cmd
In send_peer_unmap_conf_cmd_tlv() return the correct error code
while sending PEER UNMAP RESPONSE command to FW.

Change-Id: I3cc87101310a7f0c6e82dc91ac33d747f5282796
CRs-Fixed: 2398586
2019-02-26 16:29:00 -08:00
Surya Prakash Raajen
3a01bdd783 qcacmn: Add CDP api to fetch data rates
Add new CDP api to fetch data rates accordingly
from datapath

Change-Id: I1cf08d396e0f611c61a02c868c9c31759ef52a79
CRs-Fixed: 2394226
2019-02-26 16:28:57 -08:00
Dustin Brown
d33659b98d qcacmn: Provide reason to QDF_DEBUG_PANIC()
A common pattern in WLAN to panic the driver is to log the reason and
then unconditionally panic. QDF_DEBUG_PANIC() takes a reason string to
help make the reason for the panic more obvious, but it is not always
used. Ensure all callers of QDF_DEBUG_PANIC() provide a reason string.

Additionally, make the reason string parameter of QDF_DEBUG_PANIC()
mandatory.

Change-Id: Ia3c7acfe590f7f465823fff3f2393653b2d20fe5
CRs-Fixed: 2403830
2019-02-26 14:21:37 -08:00
Ajit Pal Singh
79f6d9e609 qcacmn: Reduce hif usb logging
Remove function entry/exit logs in hif_send_head(),
usb_hif_post_recv_bundle_transfers(), usb_hif_cleanup_recv_urb() and
usb_hif_post_recv_transfers().

Change-Id: I5638d99b4c6a3ace792a81957735c3ccd2d405f9
CRs-Fixed: 2398290
2019-02-26 11:30:23 -08:00
Santosh Anbu
3e67f9aa15 qcacmn: Fix typo in conditional check
Add change to fix typo on a conditional check.

Change-Id: I5928ed07f6bca18e2f6266b658365fd5317de31b
CRs-Fixed: 2404622
2019-02-26 11:30:16 -08:00
Jeff Johnson
a171ad234e qcacmn: Replace session_id in roam_offload_scan_rssi_params
In struct roam_offload_scan_rssi_params the legacy identifier
session_id is currently used to identify the vdev of interest. To
align with the converged nomenclature rename this to vdev_id.

This is co-dependent with Ifb2282b8977ad1fb999e8460c0d276343793a0c6
("qcacld-3.0: Use vdev_id in roam_offload_scan_rssi_params").

Change-Id: Ifbbca30b9aca9688931ac0f4e4f703c28ad0ad32
CRs-Fixed: 2404094
2019-02-26 04:27:08 -08:00
Jeff Johnson
855f0b1346 qcacmn: Replace session_id in rssi_monitor_param
In struct rssi_monitor_param the legacy identifier session_id is
currently used to identify the vdev of interest. To align with the
converged nomenclature rename this to vdev_id.

This is co-dependent with Icf5d5797eed143837c57a2b7d9a6c9b1b63387e9
("qcacld-3.0: Use vdev_id in rssi_monitor_param").

Change-Id: I6087c5018af98a84e7e784527000448ace7fac6e
CRs-Fixed: 2404081
2019-02-26 04:27:04 -08:00
Jeff Johnson
5f5bfc9775 qcacmn: Replace session_id in hidden_ssid_vdev_restart_params
In struct hidden_ssid_vdev_restart_params the legacy identifier
session_id is currently used to identify the vdev of interest. To
align with the converged nomenclature rename this to vdev_id.

This is co-dependent with Ie8c426aff1a8a1e7f75199c8cf7c761f1a893a05
("qcacld-3.0: Use vdev_id in hidden_ssid_vdev_restart_params").

Change-Id: Iea0bf0a3dcae9186cce4eb176b974515fd0d7624
CRs-Fixed: 2403934
2019-02-25 21:47:33 -08:00
Min Liu
ae79cfd733 qcacmn: Cleanup CONFIG_MCL for qdf_mem.c
Remove CONFIG_MCL and include the header file for both MCL and
WIN code since this feature is already handled by the feature macro
FEATURE_WLAN_DIAG_SUPPORT.

Change-Id: I4d4ed46ed5cb62950bb8b25af0a173bfe5f86474
CRs-Fixed: 2399386
2019-02-25 20:13:36 -08:00
Qun Zhang
af8a081505 qcacmn: Add vendor subcmd/attribute to check firmware state
Add the support to allow user space applications through cfg80211
vendor command to check if wlan firmware is alive or not.

Change-Id: If8346537eea6fe5c4978f6bc973e8d7b420557d9
CRs-Fixed: 2399493
2019-02-25 20:13:32 -08:00
Chaithanya Garrepalli
4c952f1039 qcacmn: For HKv2 use ast find by pdev in case of roaming
When client roams from repeater to AP we need to delete the
existing WDS while creating a peer. In this case use AST search
by pdev_id to find the AST entry when ast_override support is
enabled for soc

Change-Id: I1c7bfb8173416b6e155d3c58e94c395028c9b16d
CRs-fixed: 2399868
2019-02-25 20:13:29 -08:00
Jingxiang Ge
c9aed3dc45 qcacmn: Fix excessive log in send_wow_delete_pattern_cmd_tlv
Once user configs hundreds of wow pattern, it will cause
log flood here.

Remove the log here.

Change-Id: I56d749ca4b7db91a72c5a7fe12dbcd751397d19e
CRs-Fixed: 2402655
2019-02-25 20:13:25 -08:00
Om Prakash Tripathi
feecb9f343 qcacmn: Pass milliseconds instead of jiffies to qdf_wait_single_event
qdf_wait_single_event expects milliseconds to passed but instead
jiffies were passed making actual wait time smaller than expected.

Change-Id: I920d7183e30dd4490b64c6ae9875811db57183f3
CRs-Fixed: 2401129
2019-02-25 17:17:14 -08:00
Aditya Sathish
821e61be5e qcacmn: Replace %d specifier to %u for unsigned int variables
Replace %d specifier to %u for unsigned int variables in stats
outputs.

Previously, %d would cause uint32_t values to roll over to
negative values.

CRs-Fixed: 2402160
Change-Id: I3d3c02ac44a38d311e8e8e0e933af79f362f42b7
2019-02-25 14:14:23 -08:00
Aditya Sathish
2f3f538531 qcacmn: Fix compilation warnings caused by dp tx debug print
Fix compilation warnings caused by dp tx debug print due to an
incorrect specifier being used for the mentioned variable.

"%d" was used instead of "%lu" for printing the output of the
sizeof operator.

Change-Id: I051a3acbb95148fa2d9fbd6db5b4ec7a6144dd99
CRs-Fixed: 2400276
2019-02-25 14:14:19 -08:00
Priyadarshnee S
c4080ec27b qcacmn: Update the "radarfound channel" print with correct offset
When sub-channel marking is enabled, radarfound freq is computed as
freq_center + freq_offset. Freq offset is obtained from
dfs->dfs_freq_offset variable which gets populated only for PO
(Partial Offload) chips and does not get populated for full offload chips.
Instead radar_found->freq_offset is used which gets populated with radar
freq_offset on all chips.

Change-Id: I138b1160a8b9d67801bd0852266c2e7139265c02
CRs-Fixed: 2383294
2019-02-25 12:45:13 -08:00
Wu Gao
45c6576e42 qcacmn: Format ini descriptions about EGAP
The description about EGAP ini items is different to others, correct
them and use unified form.

Change-Id: I119721ad805cdbc2b3515eadafa36bdb35a4eb2c
CRs-Fixed: 2402450
2019-02-25 12:45:09 -08:00
Naga
7dd88340fe qcacmn: Enhance and update target_if/mlme/vdev_mgr
Enhance target_if/mlme/vdev_mgr by addressing
review comments and update response handling
APIs to handler timers and response bit maps
as expected

Change-Id: I8a5bf3f2931f0c36a367dfebfc898ed2621f3516
CRs-Fixed: 2397184
2019-02-24 20:04:45 -08:00
Akshay Kosigi
1726ae21c5 qcacmn: Add API to update cmn vdev mlme structures
Add API to update cmn vdev mlme structures,
with the addition of new members to the new mlme
vdev structure,new api's are required to update
those members which will be subsequently used the
new mlme target if layer to send commands to the firmware

Change-Id: I9618613c0ad00f78003cd32951b30b631934ba71
2019-02-24 20:04:41 -08:00
Jeff Johnson
9963d87b8e qcacmn: Replace session_id in gateway_update_req_param
In struct gateway_update_req_param the legacy identifier session_id is
currently used to identify the vdev of interest. To align with the
converged nomenclature rename this to vdev_id.

This is co-dependent with I2d24a54e80931a944580e968a841679d2da7b2a1
("qcacld-3.0: Use vdev_id in gateway_update_req_param").

Change-Id: I84b28aa734b570f0a7834fbac7d27e9c66b8b026
CRs-Fixed: 2404012
2019-02-24 20:04:37 -08:00
Karunakar Dasineni
f8ec0cbe57 qcacmn: Fix defrag waitlist flush issues
Check if peer is valid before access during flush.

Check waitlist during peer cleanup even if REO queue was
not allocated, since these are independent.

Add a timeout to avoid calling flush function too frequently.

Change-Id: Ib8da2014f81a48ccc3ca6a330209a942ac0998a2
2019-02-24 01:30:00 -08:00
Srinivas Girigowda
7950297868 qcacmn: Replace IEEE80211_IS_BROADCAST with QDF_IS_ADDR_BROADCAST
Replace IEEE80211_IS_BROADCAST with QDF_IS_ADDR_BROADCAST.

Change-Id: I199797ea402ee68dd0addf6698aa5ccd0ddc8f97
CRs-Fixed: 2396621
2019-02-23 16:02:59 -08:00
hangtian
f08f9461ff qcacmn: Add warning message on qdf_mem_set() document
Add warning message on qdf_mem_set() document.

Change-Id: I82afa828f6bce295533c63b42515e526f1b01110
CRs-Fixed: 2380158
2019-02-23 14:06:59 -08:00
Mohit Khanna
5f2634882b qcacmn: Mark RING_ID_DISABLE for WBM ring during init
Set the RING_ID_DISABLE flag for WBM_IDLE_LINK ring during
hal_srng_src_hw_init_generic.

Change-Id: I725b14a35f453e416a3721fd6c1b68ce59a8c1c0
CRs-Fixed: 2392172
2019-02-23 14:06:56 -08:00
Mohit Khanna
d31b666c22 qcacmn: Set RING_ID_DISABLE for WBM_IDLE_LINK_RING
Currently RING_ID_DISABLE field of the
UMAC_WBM_R0_WBM_IDLE_LINK_RING_MISC register is set to 0. In this
configuration, the producer ring may take the libery of snooping the
datastruct passing through it. This may cause 12 MSBs of the last dword
to be replaced by RING_ID field. This happens when ENTRY_SIZE of the
ring is 2.
Set RING_ID_DISABLE (=1) to avoid this snooping.

Change-Id: I40f71131f8fd27871597dd254fb37ce4614fe92a
CRs-Fixed: 2392172
2019-02-23 14:06:53 -08:00
Rajeev Kumar Sirasanagandla
19565fd876 qcacmn: Update ETSI1 and ETSI13 countries
According to regulatory master sheet, update ETSI1 and ETSI13 countries
with REGULATORY_CHAN_INDOOR_ONLY flag for frequency ranges:
(5170 - 5250) and (5250 - 5330).

Change-Id: I8fece78155ae7513ceb49da214e2d64accf53f3b
CRs-Fixed: 2401828
2019-02-23 12:32:58 -08:00
Hariharan Basuthkar
f0fc34b2b1 qcacmn: Update regdb with regulatory database version 28
Update regdb with QCA regulatory database version 28 with
following changes:

1) Change ETSI10, ETSI11, ETSI12 lower 5G channels to "Indoor-Only"
2) Add 40MHz 5835 channel to India APL19
3) Remove HT/VHT20 Ch 5825 and Add HT/VHT20 Ch. 5720 (straddle) channel
   to ETSI15 for Saudi Arabia

Change-Id: Id3075d22ec4403685ce3eaf00f0070b6ecab1fdf
CRs-Fixed: 2396234
2019-02-23 12:32:55 -08:00
Srinivas Pitla
8d19efa7c2 qcacmn: Optimize VDEV MLME SM prints
Reduced VDEV SM debug level, and added prints for state abd substates at
event handling API

Change-Id: I3076c590131581a8728548592e0a9b4e66db377e
CRs-Fixed: 2394012
2019-02-23 11:06:11 -08:00
Dustin Brown
e6c7bff8d9 qcacmn: Revert "Fix kernel 4.15 timer list dependencies"
This reverts change Id9c29413ca0d21533a0afae245595051fa3a400f. This
change was a work around to allow compiling against legacy code. Now
that these compilation issues have been resolved, remove the work
around.

Change-Id: I38a474f50076320cf961d6fd340960e4c9b148a0
CRs-Fixed: 2401315
2019-02-23 05:19:10 -08:00
Abhishek Singh
7c1fe52d51 qcacmn: Get vdev_id before releasing ref while flushing active cmd
In wlan_ser_cancel_non_scan_cmd, cmd.vdev pointer is used to get vdev id
after WLAN_SER_CB_RELEASE_MEM_CMD is called. In WLAN_SER_CB_RELEASE_MEM_CMD
the command release the vdev ref count and it may lead to physical
deletion of vdev. Thus getting vdev id from vdev may result in invalid
vdev_id and thus proper bits are not reset in vdev_active_cmd_bitmap
for the vdev.

Thus no new blocking command will be allowed in serialization active queue.

Fix is to get proper vdev_id before WLAN_SER_CB_RELEASE_MEM_CMD is called
and use that to reset the pdev_q->vdev_active_cmd_bitmap bit for vdev_id

Change-Id: I2756f1632a72f086e9d214a437ad794ae08afc45
CRs-Fixed: 2395851
2019-02-23 05:19:07 -08:00
Jeff Johnson
1d002854d3 qcacmn: Converge on struct tdls_peer_update_state
As part of the original TDLS componentization the legacy typedef
tTdlsPeerStateParams was replicated as qca-wifi-host-cmn struct
tdls_peer_state_params. Subsequently when the TDLS component was
relocated back to qcacld-3.0 this struct was replicated again as
struct tdls_peer_update_state in the qcacld-3.0 TDLS public structs.
Unfortunately this left the driver with three different data
structures which serve the same purpose. Not only is this pointless,
but due to the way in which these structures are used there is an
implicit requirement that they be exactly identical. Further
complicating matters is the fact that these three structures each have
embedded structs which are also replicated. This approach is very
fragile since any change to any of these structs must be replicated
across the entire set. To align with the converged software
architecture and to improve code maintainability exclusively use the
TDLS public structs.

Change-Id: Ifc976815fea57afae86cc91b91c6b48f70b2a9a7
CRs-Fixed: 2395340
2019-02-23 01:49:32 -08:00
narayan
d9e53400e9 qcacmn: CFR Feature support
Add CFR component specific Rx-Ops callbacks

Change-Id: Ic1e89ca2ba049f9579964de50d7285cd40a0d3a7
CRs-Fixed: 2397716
2019-02-22 22:52:26 -08:00
narayan
b7293e46c3 qcacmn: Spectral Kbuild changes for CFR
Including CFR libs in spectral's ko.

Change-Id: I86cbf3137df0222e06786e2239359aac425e935a
CRs-Fixed: 2397716
2019-02-22 22:52:23 -08:00
Linux Build Service Account
a2ef333aad Merge "qcacmn: Add internal stop send event" 2019-02-22 11:34:53 -08:00
Srinivas Pitla
ae6c9ee9d1 qcacmn: Add internal stop send event
In current code, EV_DOWN event in stop-progress sub state sends
stop command to FW, As EV_DOWN is generic, it is casuing multiple
stop commands to FW. To avoid, for internal transitions added new
event STOP_REQ, which send stop command to FW

EV_DOWN event is not honored in STOP state, as it is not initial state

Change-Id: I5a3b44ab6e12f6d1c2d10ad55954c6a0510e5f9e
CRS-Fixed: 2401298
2019-02-22 08:24:35 -08:00
Linux Build Service Account
e993df4e99 Merge "qcacmn: Send STA authorized status to supplicant for AP" 2019-02-22 07:36:33 -08:00
Ashish Kumar Dhanotiya
38a0c9fe44 qcacmn: Send STA authorized status to supplicant for AP
Currently there is no support from driver to send STA authorized
event to supplicant.
Use QCA_NL80211_VENDOR_SUBCMD_LINK_PROPERTIES vendor command to
send STA authorized event to supplicant.

Change-Id: I46416949f04dd28a1713cbebf1f7d0e84b5efda2
CRs-Fixed: 2175481
2019-02-22 06:56:47 -08:00
Paul Zhang
9c8c20f6c0 qcacmn: Clean CONFIG_MCL for send_flush_completion_to_user
The aim is to remove CONFIG_MCL or CONFIG_WIN from
cmn component.

This change takes care send_flush_completion_to_user.
Cleaning up cmn code by replacing the CONFIG_MCL
with macro FEATURE_WLAN_DIAG_SUPPORT.

CRs-Fixed: 2397824
Change-Id: I57a82fec17210b49f778a950034ca442d11eb511
2019-02-22 06:56:44 -08:00
Abhiram Jogadenu
b692339f5a qcacmn: Add umac support for CFR
Add UMAC support for CFR module.

CRs-Fixed: 2372061
Change-Id: Idf5991d2cb43e8165ae4eed12d675f1039f4bc77
2019-02-22 02:50:17 -08:00
Abhiram Jogadenu
975303cc41 qcacmn: Add wmi support for CFR capture command
Add wmi support for CFR capture command.

CRs-Fixed: 2372061
Change-Id: Icaeb30ccf619058383314317864be65380a551fd
2019-02-22 02:50:14 -08:00
Venkata Sharath Chandra Manchala
cad74add80 qcacmn: Add support for full pktlog
1. Enable CE5 and allow it to service
   pktlog messages from the firmware.
2. Register full pktlog callback handlers
   for handling sw_events and full tx pktlog.

Change-Id: Ifb70ac0993f2402201f88758845f730cf677b1a0
CRs-Fixed: 2388906
2019-02-21 23:25:30 -08:00