Commit Graph

1247 Commits

Author SHA1 Message Date
Shashikala Prabhu
9cd113574d qcacmn: Add vdev_id to peer_chan_width_switch_params structure
Add vdev_id variable to peer_chan_width_switch_params structure.

Change-Id: I9a2f5598a6e5d946e7e8546c925306b85c910d2f
CRs-Fixed: 2812110
2020-11-10 07:03:28 -08:00
Abhinav Kumar
2bce1a8132 qcacmn: Print roam related info in kmsg
The event WMI_ROAM_STATS_EVENTID is received after
every roam, once the roam synch complete is sent by the host.
This event contains details regarding the btm response.

This helps to debug the scenario when roam failure happen.

Print the info received related to roam scan type & roam status
info into kmsg.

Change-Id: I7c01d482e3152dfbf500dba97001c328f39564de
CRs-Fixed: 2812515
2020-11-06 06:02:00 -08:00
Srinivas Dasari
d7b3042685 qcacmn: 6g scan optimizations based on the ini
Below optimizations can help to improve 6g scan,
1. RNR-only: Consider only 6g RNR(PSC and non-PSC) channels found
   while scanning 2g and 5g bands, as the 6g APs are likely to
   present in RNR channels.
2. Duty cycle: There is a chance to miss the standalone 6g APs as
   they don't advertise RNR IEs. So, instead of optimizing all
   scan requests, we can consider to do a full scan with duty
   cycle(n) where optimization is skipped for every nth full scan.
   The full scan requests 1 to n-1 are going to be optimized as
   per RNR-only policy.
Driver shall maintain a scan count to track the full scans and
decides whether to optimize the scan (scan count 1 to n-1) or
send it as it is(scan count n) to firmware.

Change-Id: I35b31e900b74dbcd7791f4c2fcfe87b3c629758b
CRs-Fixed: 2806409
2020-11-05 16:13:04 -08:00
Srinivas Dasari
da54959f21 qcacmn: Get per channel scan config service capability
Firmware advertises the service capability bit
WMI_SERVICE_SCAN_CONFIG_PER_CHANNEL when it supports per channel
scan config flags. Get this and cache in psoc.

If firmware supports WMI_SERVICE_SCAN_CONFIG_PER_CHANNEL, it uses
the upper-12 bits(bit-20 to bit 32) of channel_list for flags and
lower 20-bits(bit-0 to bit-19) for frequency. If firmware doesn't
support it, then channel_list holds the frequency value only.
Fill the flags and frequency accordingly.

Change-Id: I88a6f29f61e1ecea75bc5574cadcbbfbb7f8b188
CRs-Fixed: 2806405
2020-11-05 16:12:54 -08:00
Aditya Kodukula
74b41a6d6a qcacmn: Add WMI command to enable wow mode logging
Add the WMI command WMI_DBGLOG_MOD_WOW_LOG_LEVEL to enable
debug logs while in wow mode.

Change-Id: Ia1902d989964a5e35f590a075a2de64a9f66d5b7
CRs-Fixed: 2810326
2020-11-05 01:20:46 -08:00
Srinivas Girigowda
1aefc8972b qcacmn: Remove obsolete WMI_LOG(I/E/P/W/D) macros
Remove obsolete WMI_LOG(I/E/P/W/D) macros and
instead use wmi_(err/debug/info/alert/warn).

Change-Id: Ib401c5da873efc7a87323d9857d7f33989c3b29c
CRs-Fixed: 2776741
2020-11-03 13:17:04 -08:00
hqu
fc4c9c5a86 qcacmn: Remove old rso path code [PART 1]
Since new rso ROAM_OFFLOAD_V1 path is enabled, remove
the old rso path code for wmi related files.

Change-Id: Ie519ca7fac2d721f87a4c9bd11507cd83ddfb504
CRs-Fixed: 2810241
2020-11-03 06:23:32 -08:00
aloksing
b5692dc64c qcacmn: Replace WMI_LOGD() with wmi_debug()
Replace WMI_LOGD() with wmi_debug().

Change-Id: Ia5f00e0b54de30e2251e3313b46badbde7a90b40
CRs-Fixed: 2807905
2020-11-02 03:54:22 -08:00
Kai Liu
4be28ba641 qcacmn: Enhance hang info feature
Add bus related info in hif layer in order to get bus status
when hang issue happened.

Change-Id: If922e0892e0f65de778b9696bbc56fc63c25c169
CRs-Fixed: 2801350
2020-10-30 13:03:35 -07:00
Bapiraju Alla
47c0d5465e qcacmn: Validate NDP app info length before accessing NDP app info
Currently, NDP app info length is not being validated with max NDP
app info length. This may result in buffer oveflow wile accessing
NDP app info received from the firmware.

To address this, validate NDP app info length before accessing NDP
app info

Change-Id: Ifddf1afca7ecf2585e8eb450864d9ba127238f6e
CRs-Fixed: 2795961
2020-10-28 13:27:10 -07:00
Gururaj Pandurangi
00d6ce30a3 qcacmn: Add action OUI to disable TWT
Add a new action OUI to disable TWT for certain APs.

Change-Id: I10fe6218d03f45c132268a120bdeb19d58696d9d
CRs-Fixed: 2793128
2020-10-28 09:21:49 -07:00
Christopher Chopp
36627ac5e9 qcacmn: Add WMI Handler for TSF Event
Add handling for WMI TSF Event, including registration,
sending event and extracting response.

Change-Id: Icccf9b5eb7e46bd87caf7a644be903747eac025c
2020-10-26 18:56:43 -07:00
Linux Build Service Account
eb9b6ee897 Merge "qcacmn: Add support for peer create response event" 2020-10-23 12:36:44 -07:00
Naga
457c3d62e8 qcacmn: Add support for peer create response event
Add host data structure and api declarations
corresponding to peer response event and register
WMI_PEER_CREATE_CONF_EVENTID in global wmi event_ids.

Change-Id: I143a4a85d079cc113397348512b0d86f500cae5b
CRs-Fixed: 2797197
2020-10-23 12:13:02 -07:00
Liangwei Dong
bf189853b7 qcacmn: Add host definition for target thermal throttle level
Convert target thermal throttle level to host definition -
enum thermal_throttle_level.

Change-Id: I9914aaf56b781533565cd6a3f8b279ee67215c23
CRs-Fixed: 2786660
2020-10-23 10:03:25 -07:00
Abhishek Ambure
06ac6b2604 qcacmn: Add support to send FILS DISC TX enable/disable to FW
Add support to send WFA test config FILS DISC frames TX
enable/disable to FW.

Change-Id: I5b0abed1b6fe517b12c29269da6456c48b21725c
CRs-Fixed: 2801138
2020-10-23 05:48:10 -07:00
Shashikala Prabhu
31f750cb6f qcacmn: Use FW macro to set BCAST_TWT flag in TWT_enable cmd
Add b_twt_enable variable to enable/disable broadcast TWT in
wmi_twt_enable_param structure and use FW macro in WMI layer
to enable/disable BCAST_TWT in TWT_ENABLE cmd.

Change-Id: I892e922dda14d16019f3f433f885d1eb5b7169fc
CRs-Fixed: 2793360
2020-10-20 00:53:14 -07:00
Bapiraju Alla
bc159feb4e qcacmn: Use wmi msg length to allocate WMI buffer for QMI events
For QMI events, recevid QMI event length is used to allocate wmi buffer
using wmi_buf_alloc. The received QMI event length includes WMI head
room and wmi_buf_alloc also try to reserve WMI head room again.
Because of this, WMI buffer allocation is exceeding max WMI msg length.

To resolve this, use length of the received actual WMI msg to allocate
WMI event buffer using wmi_buf_alloc.

Change-Id: Icd259988c4b1091580a35aaf2c3fabc606e0f2a9
CRs-Fixed: 2786326
2020-10-16 13:46:43 -07:00
Surabhi Vishnoi
e906b00a65 qcacmn: Fix the incorrect check in is_service_enabled_tlv
Many firmware do not send wmi_ext_service bitmap in wmi_ready event
so the ext_service_bitmap will be empty in such cases. So the condition
in the is_service_enabled_tlv to check for wmi_ext_service bitmap
and return false is wrong as wmi_ext_service bitmap support is not
necessity. This condition leads to incorrect behavior in cases when
firmware do not support wmi_ext_service bitmap as is_service_enabled_tlv
returns false for every service.

Fix the above failure by addition of condition check for wmi_ext_service
bitmap only when wmi_ext2_service bitmap is supported by firmware.

Change-Id: I94d0b65e640d44f41d14de889955a6d6330e88b2
CRs-Fixed: 2786491
2020-10-13 08:53:32 -07:00
Balaganapathy Palanisamy
766838ebaa qcacmn: Reset WMI sequence counter after recovery
Reset the WMI sequence counter after FW recovery to avoid
false assert due to CE pending packets freed in htc layer
instead of WMI completion handler.

CRs-Fixed: 2787424
Change-Id: I109ff56655e5fb428aca637e6420efed5943b3f7
2020-10-13 04:13:39 -07:00
Karthik Kantamneni
e26cc77333 qcacmn: Cleanup WMI DIAG over CE7 change
Cleanup changes for WMI DIAG over CE7 code

Change-Id: I4b2718e37ba16d62b585aa26c56213698078e25a
2020-10-13 04:13:36 -07:00
Alan Chen
bc0d7713ed qcacmn: Remove code relating to ocl_cfg
As part of removing gOclCfg ini, remove code used for it that is
no longer needed.

Change-Id: I00c32988cb3b852381be9810377aeefdd22454db
CRs-Fixed: 2791469
2020-10-13 00:08:22 -07:00
sheenam monga
58857b048c qcacmn: Avoid excessive logging
log level for some frequent prints is set to info those
logs would be present in dmesg as well as driver logs
and System performance may get affected due to excessive
logging.

Avoid redundant logs which may affect system performance
and change default log level to debug.

Change-Id: Ic8669c2d7158200e5881bc1ffd15079c8d24af68
CRs-Fixed: 2794518
2020-10-12 17:05:36 -07:00
Manikanta Pubbisetty
f2ce9cfc04 qcacmn: log additional info to WMI TX completion record
Add WMI command buffer address information(DMA/Physical addr) to
the WMI TX completion logging. This will help in debugging issues
when HW DMAs copies data from a different location than the one
configured.

Change-Id: I60586b865a97e7ff88e48606806ec151321ff0aa
CRs-Fixed: 2789492
2020-10-09 02:14:33 -07:00
Chaoli Zhou
4fad4e8636 qcacmn: Add wmi interfaces for GPIO configuration
Add wmi interfaces for GPIO configuration.

Change-Id: Ic7c23a67bab752012ded147908238faa8ecc4789
CRs-Fixed: 2753648
2020-10-08 15:34:07 -07:00
Bapiraju Alla
7af72345b6 qcacmn: Send unified ll_stats and get_station request over qmi
Send unified ll_stats and get_stats request over qmi based on INI
configuration.

Change-Id: Icc43352c1ba19696148619100ee27fda4d5ffb41
CRs-Fixed: 2791043
2020-10-08 12:23:58 -07:00
Ashish Kumar Dhanotiya
a24cd669cc qcacmn: Add support to handle multiple radio stats event
Currently driver can handle only one radio stats event,
if the size of radio event exceeds more than the size which
can be accommodated in single WMI event in that case FW needs
to send multiple radio stats events.

Add support in host to send WMI capability to indicate FW
that host supports the multiple radio events.

Change-Id: Ifb89419715c87959095c0c88a23c8dd650d456e7
CRs-Fixed: 2783251
2020-10-06 04:11:00 -07:00
Rajasekaran Kalidoss
9ba4f14c9a qcacmn: Add TWT wmi status code for already suspended session
The firmware sends a new status code to indicate an already suspended
TWT session. Update WMI_HOST_PAUSE_TWT_STATUS status code to represent
this state.

CRs-Fixed: 2786636
Change-Id: Id1fbdde8691084e408144454214d59c8ad532f9b
2020-10-01 23:58:41 -07:00
Rajeev Kumar
0d04766b88 qcacmn: Log WMI work queue call stack on WMI WD bite
Log WMI work queue call stack when WD timer expires to assist
in debugging on non slub debug enabled builds.

Change-Id: Id3dd575700ca586b0738a88ca2af88a757238d1b
CRs-Fixed: 2789114
2020-10-01 19:08:59 -07:00
Karthik Kantamneni
268ab400cd qcacmn: Add support for WMI DIAG events over CE7
Add support for handling firmware WMI DIAG events over CE7.

Change-Id: I3d6c0b08313e816809a65eb77d9728fc4b4488f3
CRs-Fixed: 2787010
2020-09-30 11:10:33 -07:00
Bapiraju Alla
0ff4421b30 qcacmn: Send get_station and ll_stats req in a single command
Currently ll_stats and get_station requests are sent back to back
from user space. The firmware time difference between these two commands
results in extra sleep and wakeup for Q6.

To avoid this extra Q6 sleep and wake, send both requests in a single
command from the driver if the firmware supports that operation. Cache
the get_station results in the driver until user space request reach
to the driver.

Change-Id: I5e6f42f9e3836ef4bf61d3d9220f8cedb775cbd5
CRs-Fixed: 2778479
2020-09-28 17:08:12 -07:00
Alan Chen
cc93b4f071 qcacmn: Add log to print wow flag parameter
Add log to print wow flag parameter to log various wow parameters.

Change-Id: I5da00d0720fd7abc0f95699b3fcd41925ae2a2d1
CRs-Fixed: 2784062
2020-09-26 01:18:12 -07:00
Rhythm Patwa
224d4e2276 qcacmn: Add peer assoc param for Max BSS Idle option
Add peer assoc parameter 'peer_bss_max_idle_option' to
update the peer's Max BSS Idle option cap to FW.

Change-Id: If7fd4369bade8b289655c491849562c2357de877
CRs-fixed: 2781050
2020-09-23 17:13:52 -07:00
Abhishek Ambure
7c64a2c250 qcacmn: Add support to send wfa test config to FW
Host add support to send WFA test configs to FW using WMI command
i.e. WMI_WFA_CONFIG_CMDID.

Change-Id: Id9bdec16c69a8c16cb4ce1fac87688023c768ee6
CRs-Fixed: 2772004
2020-09-21 03:53:33 -07:00
Srinivas Girigowda
cdf81dddd3 qcacmn: Replace WMI_LOGD() with wmi_debug()
Replace WMI_LOGD() with wmi_debug().

Change-Id: I9c69cabfd84882fa1daff6e219de5f2643e7d214
CRs-Fixed: 2774563
2020-09-17 10:18:55 -07:00
Srinivas Girigowda
8c756066a7 qcacmn: Replace WMI_LOGE() with wmi_err()
Replace WMI_LOGE() with wmi_err().

Change-Id: I4c2e2c278101224a967080c073c46004ea60f5af
CRs-Fixed: 2774563
2020-09-17 10:18:52 -07:00
Srinivas Girigowda
e6d0bc490d qcacmn: Replace WMI_LOGI() with wmi_* appropriate log level
Replace WMI_LOGI() with wmi_* appropriate log level.

Change-Id: I7b0c32a2aefc5eb300348edbc6a60e7ad0401439
CRs-Fixed: 2774563
2020-09-17 10:18:48 -07:00
Srinivas Girigowda
a5aa1420d2 qcacmn: Replace WMI_LOGW() with wmi_* appropriate log level
Replace WMI_LOGW() with  with wmi_* appropriate log level.

Change-Id: Idfc41fed4f31fb197ca8f46d3ed3a4af21f2fdae
CRs-Fixed: 2774563
2020-09-17 10:18:45 -07:00
Srinivas Girigowda
29eadb8bc6 qcacmn: Replace WMI_LOGP() with wmi_* appropriate log level
Replace WMI_LOGP() with wmi_alert() or with appropriate log level.

CRs-Fixed: 2774563
Change-Id: I53ad75f3b645306551250f7f400f8802692a01a3
2020-09-17 10:18:41 -07:00
Manikanta Pubbisetty
9c25cded62 qcacmn: add WMI service flag to place FST in CMEM
Firmware advertizes the capability to allocate CMEM memory for
FST via a WMI service flag; adding the support for the same.

Change-Id: Ic33bf0584f5ce4880fdfe5abe8fd4cf2a653a06e
CRs-Fixed: 2771256
2020-09-17 10:18:30 -07:00
Abhinav Kumar
a253ce3577 qcacmn: Remove unused roam ini gRoamBeaconRssiWeight
Currently, gRoamBeaconRssiWeight is not used in HOST or
FW.

Remove logic to pass value of INI gRoamBeaconRssiWeight
to FW.

Change-Id: Ifa1472ef413d20d0e54649bc24dd6c8d6aac4bc7
CRs-Fixed: 2770278
2020-09-16 04:51:51 -07:00
aloksing
a9d5d1ee00 qcacmn: Change return type to QDF_STATUS
wmi_unified_register_event return QDF_STATUS

CRs-Fixed: 2764185
Change-Id: I266e5042ff45ba33ab5d53592515bceb4fec92ac
2020-09-15 18:24:32 -07:00
Liangwei Dong
2b2ff01a06 qcacmn: Set thermal action to FW in thermal mgmt command
Set "action" field when send WMI_THERMAL_MGMT_CMDID
to firmware. Then driver can configure the target management action
based on different customer requirement.

Change-Id: I3da5eea0d756444ede816be5cb74407863d63781
CRs-Fixed: 2767144
2020-09-15 11:38:52 -07:00
Jhalak Naik
41e8d82db9 qcacmn: Hex dump generation for WMI events and commands
This records all the WMI events and commands, for all
PDEVs. Set WMI_EXT_DBG flag to enable this feature. Refer
Original Change-Id: I18e46f683e35912cad717ca3b9cc3d1885315362

Change-Id: I4c9bdfe6fdd195656ca0c01ca400eba595be24a3
CRs-Fixed: 2762266
2020-09-15 11:38:47 -07:00
Rhythm Patwa
60b5f9357a qcacmn: Add support for fc_duration in injector frame WMI struct
Add support for fc_duration field in the injector frame WMI struct

Change-Id: I8662c3037c32bd9c39914e0b7c77818fac4a6e36
CRs-fixed: 2770504
2020-09-10 21:00:51 -07:00
Balaganapathy Palanisamy
55650d9c02 qcacmn: Add sequence number for WMI pipe
Add sequence number to each packet queued on wmi pipe and
match it against expected sequence number in wmi completion handler.
WMI packets are consumed internally, use the skb mark field to capture
the sequence number of the wmi packet.

Change-Id: I1421e3fcff0a2b326f6d899780c773950544ef26
CRs-Fixed: 2741465
2020-09-07 03:18:00 -07:00
Pragaspathi Thilagaraj
52173647db qcacmn: Add support for WMI_CHAN_LIST_CMD in connection mgr
Add support for WMI_CHAN_LIST_CMD in connection mgr

Change-Id: Ie28eba05da82bfdd928bbd7ef2bf3d21ec2ef782
CRs-Fixed: 2768969
2020-09-04 23:17:28 -07:00
Nandha Kishore Easwaran
72f98bced8 qcacmn: Send diag wmi command to FW
Donot block wmi command sending inside #if macro.
This change is needed because WIN uses only the FW log level
setting and not the complete feature. Only the feature
should be enclosed in #if macros and not the wmi command
sending part.

Change-Id: Ia28c0487d360c1b0a54374bb237811eba6b1af41
2020-09-04 05:28:39 -07:00
Neha Bisht
2b49081472 qcacmn: Remove Wno-format flag while compilation of driver
To show formating errors at compile time, removing Wno-format flag
while compilation of driver and also handling associated errors

Change-Id: If990cc9110fe3042dd486e31d9b44fce79861e77
2020-09-03 19:27:42 -07:00
Balaganapathy Palanisamy
e5b0acba4d qcacmn: Add config option for each WMI log buffer size
Make each WMI debug log buffer size configurable through
compile time config option. Now memory constraint platforms
can use these config options. Use default values if no
values are configured.

Change-Id: Ibc924e12a56ae7d529aea91e55bcc0bbce72ac7e
CRs-Fixed: 2741465
2020-09-03 01:58:47 -07:00