Commit Graph

26 Commits

Author SHA1 Message Date
Amit Mehta
600b1dfc1c cnss2: Add DP rings to host SSR dump
Add DP rings to host SSR dump.

Change-Id: I6e2462085ee41e60cfd2e5772f03d081af86617f
CRs-Fixed: 3604908
2023-09-20 07:11:26 -07:00
Zhiwei Yang
f0a7661f00 cnss2: Dump event desc history when SSR occurs
Dump hif_event_desc_history and hif_ce_desc_history_buff
when SSR occurs.

Change-Id: I3c115e1d6b35107e4f97f442a51bd50f50bd79ae
CRs-Fixed: 3553092
2023-07-23 17:09:05 -07:00
Shailendra Singh
6ce40d5c60 cnss2: Update time sync period based on tsf sync start/stop
Add cnss_update_time_sync_period and cnss_reset_time_sync_period to
update time sync period vote sent from wlan driver based on use-case.
CNSS driver stores both wlan driver and sys config time sync period
value and will apply the minimum value of all votes.

Change-Id: I46ad2866bd70aefe121c8a68a9c869e75ffd8345
CRs-Fixed: 3502060
2023-06-07 11:12:47 -07:00
Alan Chen
f4e0145655 cnss2: Add AUX UC download functionality
Add support for AUX UC download functionality if aux support is
indicated by both host and fw.

Change-Id: I3bfbebbb5cdfbbaa350a34378ab2f0809f27affb
CRs-Fixed: 3402104
2023-05-25 19:54:56 -07:00
Yu Wang
b26c26e7b0 cnss2: notify WLAN driver of system reboot
Notify WLAN driver of system reboot to avoid state
mismatch between cnss driver and WLAN driver.

Change-Id: I03e867484ee450c796c0dfabac7ed550a1d0337c
CRs-Fixed: 3467387
2023-04-28 19:03:31 -07:00
Will Huang
33dff49a43 cnss2: Change AFC data pointer from char* to const uint8_t*
API cnss_send_buffer_to_afcmem pass AFC data from driver to target
which is not changed in platform driver, and it is pass-through byte
stream for platform driver.

Change the AFC data pointer in API from char* to const uint8_t*.

Change-Id: Ib492dbcf028776858926d8a3e11edc528566fac1
CRs-Fixed: 3478093
2023-04-28 00:50:19 -07:00
Alan Chen
7793f64f52 cnss2: Add 3 more log buffer regions to ssr driver logs
Add support to include hif_ce_desc_history, hif_ce_desc_history_buff,
and hang_event_data log buffer regions in ssr host dump collection.

Change-Id: I650b94973b8b12cb546a1bc2d121ee319a182767
CRs-Fixed: 3455747
2023-04-21 08:16:54 -07:00
Gangadhar Kavalastramath
4f03c58310 cnss2: Add support for QCN7605
Add support for QCN7605 in cnss2 driver

Change-Id: I529d76f8f6fa6eeea2117630b2a1e9d05ce5f5b4
CRs-Fixed: 3359985
2023-03-07 18:28:55 -08:00
Gangadhar Kavalastramath
6c09e62157 cnss2: Add code changes to support thermal mitigation
Add cnss2 code changes to register with thermal framework to support
thermal mitigation.

Change-Id: I9d427603bfc7e6bb5d732fa3e29ff66c965e153b
CRs-Fixed: 3386762
2023-02-06 00:02:18 -08:00
Naman Padhiar
2ac2197477 cnss2: icnss2: Remove unused macro
Remove unused temporary macros CNSS_API_WITH_DEV and
ICNSS_API_WITH_DEV.

Change-Id: I5dff354c08b6772d85d9fe0814e1b3a501810df9
CRs-Fixed: 3394987
2023-02-03 00:45:00 -08:00
Alan Chen
ae2498e987 cnss2: Collect and load elfdump data
Call collect_driver_dump() driver ops to add the data from the buffer
for the four log types.

Change-Id: Ic06d4520de6f87202d1c3ce24362d61002b85f61
CRs-Fixed: 3352310
2023-01-19 18:40:35 -08:00
Alan Chen
f12f76a73f cnss2: Create new driver ops for SSR Dump Collection
Create new driver ops for SSR Dump Collection.

Change-Id: I26b429ee3eba9e4d3125c0b9650c0801771816f2
CRs-Fixed: 3352309
2023-01-07 03:02:59 -08:00
Naman Padhiar
6660ad60be cnss2: Add support for Audio IOMMU map and unmap
Add support for IOMMU map and unmap of WLAN memory
regions into Audio SMMU for direct link usecases.

Change-Id: Ic136b1e5ac22641b6612ab5285452273233fcaea
2022-12-10 08:30:32 +05:30
Naman Padhiar
42fee6ecad cnss2: Add API to send WFC mode to WLAN FW
Add and export API to host driver to send WFC(WiFi Calling)
mode to WLAN FW.

Change-Id: I92d3d0baad9afc6fdf66f66b847a4e8a90a54341
CRs-Fixed: 3346550
2022-11-26 14:01:00 -08:00
Naman Padhiar
2fd60f792b cnss2: Add API to get FW supported capabilities
Add and export API to check whether FW capabilities like
DIRECT_LINK, etc are supported by FW or not.
Update WLAN Firmware Service QMI file as per latest IDL file.

Change-Id: Ic33104ec55e18845b8c33ff611d1ecc15ec5cd77
CRs-Fixed: 3335259
2022-11-12 17:29:28 -08:00
Will Huang
6dcd57f602 cnss2: Add support for handling AFC memory request from FW
Add APIs for handling AFC memory request from FW:
cnss_send_buffer_to_afcmem() and cnss_reset_afcmem().

cnss_send_buffer_to_afcmem() will be called if receive valid AFC
response data, cnss_reset_afcmem() will be called if receive
invalid AFC response data. After memory copy done, another WMI
command will indicate FW ready to read.

Change-Id: I34b9add3d7721d778e5474d9b11ad64adb4f04f0
CRs-Fixed: 3223607
2022-11-06 19:34:15 -08:00
Bing Sun
fe37b559b9 cnss2: Add one MSI vector support
Some platforms can't meet the number of MSI interrupt vectors that
wlan driver requires.
Add one MSI interrupt vector support.
If CONFIG_ONE_MSI_VECTOR is not defined, wlan driver fails to load
if reuired MSI vector allocation fails. It is current behavior.
If CONFIG_ONE_MSI_VECTOR is defined, firstly it will allocate multiple
MSI vectors based on MSI config. If MSI vector allocation fails, it
fallbacks to one MSI vector automatically.

Change-Id: I813f7ddf678ecf405e573f3bc72af3e758d1c96d
CRs-Fixed: 3312670
2022-10-25 10:08:12 -07:00
Sandeep Singh
39e099aa46 cnss2: pass fw build id in soc info to wlan host driver
Pass fw build id as part of  soc info to wlan host driver.

Change-Id: If1906abe5efc8f98a1e396e19574c817169a954a
CRs-Fixed: 3298924
2022-09-23 18:14:18 +05:30
Sandeep Singh
db6c6ce1d2 cnss2: Return kobject to wlan host driver
Return kobject to wlan host driver. Host driver
asks platform driver for wifi kobject. If wifi kobject
provided by platform driver is NULL, it creates wifi
kobject itself.

Change-Id: I7f44350a84ad054c674442ae0c0272885dc95d38
CRs-Fixed: 3262907
2022-08-09 01:27:16 -07:00
Sandeep Singh
1e6a925b34 cnss2: Add base changes for pci hang data support on HMT
Add base changes for pci hang data support for HMT.

Change-Id: I0e1dde6649b36ffdca5a6a75f2198f4fde50d211
CRs-Fixed: 3111908
2022-07-12 21:55:24 -07:00
Manikandan Mohan
ad4399e37a cnss2: Add support secured wlan HW disable mode
WLAN HW can be securely disabled. Add support in platform driver to
handle WLAN cold boot initialization sequence changes if HW is disabled
at boot and WLAN resume sequence after WLAN HW is enabled.

Change-Id: If5036560820c54653801298ceebe4f50b7532f3f
CRs-fixed: 3211229
2022-06-16 16:23:19 -07:00
Kai Liu
add05df61f cnss2: loads different fw binary per running mode
Kiwi-v2 supports separates image for MM and FTM mode,
platform driver will load difffernt binary according to the mode
indicated by wlan driver.
If seprate binary is not there, fall back to default binary.

Change-Id: I848309440fdffd6517463e18190c03c1b7ed9269
2022-05-31 21:54:57 +08:00
Mohammed Siddiq
0db7057bb6 cnss2: Add shadow register version 3 for kiwi
Add shadow register version 3 structure for kiwi
CE7 support for wmi logging.

Change-Id: Ie37dcc47ff4b63726cee43a3d26cb0aad24d44ed
2022-05-15 18:52:52 +05:30
Kai Liu
6df6dd4662 cnss2: Check chip version before accepting wlan registration
There are multiple subversions of one chip, platform driver needs check
chip version info that wlan driver provides to decide whether reject
this registration.

Change-Id: I43bc9cb0c20021a2add3e8e5f812d82c31f217f4
2022-02-22 08:23:26 -08:00
Mohammed Siddiq
7efdab657b cnss2: Add api to return the pci slot in use
Add api to return the pci slot in use. With the new targets,
QCA6490/kiwi devices are getting attached on pci slot 1
as well, so host driver call this exported api to get the pci
slot of device attached.

Change-Id: Ief51204258090df16b48267f3aeb851ded365525
2021-12-29 17:43:01 +05:30
Yue Ma
5b29459b17 wlan_platform: Bring initial files for CNSS family drivers
Bring CNSS family drivers from msm-5.10 kernel as of commit
cc3bc4b888af (cnss2: Fix a few switch statement fallthrough
issues) to WLAN platform project. Fix SPDX-License format for
a few files as well.

drivers/net/wireless/cnss* -> .
include/net/cnss* -> inc/

Above shows how directories and header files are relocated.

Change-Id: If8fd40a35c9fdbeb1aa76a8aac5fdb1fc1c7e786
2021-10-08 15:28:40 -07:00