The kernel-doc script identified a large number of documentation
issues in the QDF. A series of patches has already fixed many of the
issues, so fix most of the remaining ones.
Note that the QDF IPA abstraction still has issues, but it is under
rework, so not trying to clean it up until after the rework is
complete.
Change-Id: I10c33e341cb6b46e0f8ada99069616d450c07189
CRs-Fixed: 3406197
Currently, when an unpermitted character is added to ini, driver
flags as an unknown config item and continues parsing. This could
be an issue. Change is to return error when invalid character is
parsed in ini.
Change-Id: I0249d187f0e05a31dd256d5de56798a575903e5b
CRs-Fixed: 3354669
Currently there is no api to parse a string to int32 array.
Write an api to parse a string to int32 array.
Change-Id: I2982a1bfeff94288a1bd76d8f4d87ea2eac934b2
CRs-Fixed: 3304318
In kernel 5.16, __alloc_size is defined in linux/compiler_types.h
file. So instead of calling this macro, define and use new macro
__qdf_alloc_size.
Change-Id: Ie1930bf2aaf0cb6bc079bc66aba9eeba92ec8c12
CRs-Fixed: 3295139
-Wimplicit-fallthrough is being enabled by default. Some compilers
such as clang require the attribute instead of just a fallthrough comment.
Change-Id: Ib87c694224af8e1331d813b64e02dc4ec0c176d8
CRs-Fixed: 3218237
Add support for section parsing in ini, such that we could
read specific section of the file and update the ini values
instead of redundant values or updating the same in the
scripts based on the config
Change-Id: Ibdb08a04d709746c04c3e7c47ee3bb4a7ce85346
CRs-Fixed: 3107545
Currently driver supports only one name for an ini parameter,
there is no aliasing support for ini names.
With this change add support for multiple ini names for the
same ini parameter.
Change-Id: Ib16a258975f5c3d152fa1dfbbdb6b3e6cc222784
CRs-Fixed: 3007156
Read the file wifi_module_param.ini, in which wifi module params
are present and compare these module params with qdf module params
in qdf module init function.
If any of the module params belongs to qdf module is present,
then that particular module param is updted during qdf module init.
Change-Id: I76ef876f6c7be3cdffd93b6050a190438d60bf39
Some times INI file is empty or wrongly formatted on device
and WiFi ON fails because of it and hence add a log message
to indicate INI file parse success or failure.
Change-Id: I2337fc4ffb4a443ac191f584e283fdc9699a4e04
CRs-Fixed: 2931228
INI parameters parsing can fail because of fail to read INI file or
failed to parse at least one parameter. In some scenarios, driver should
assert if parsing is failed for atleast one INI parameter.
To differentiate these two failures, return different error status
values.
Change-Id: I187d2b2e8f55af47a14561302d8b62e84de7da5a
CRs-Fixed: 2878966
spin_is_locked() provided by kernel has statement that we should not
rely heavily on the return value, it only tells that the spinlock is
seen to be locked, not that it is locked on your CPU.
Further, on CONFIG_SMP=n builds with CONFIG_DEBUG_SPINLOCK=n, the
return value is always 0.
So we should not use QDF_BUG to test/assert its return value, only be
used for debugging purpose.
Change-Id: I76765f567abf333ab6fa0d7c7c73f7c263e18495
CRs-Fixed: 2846186
Add new wrapper to get the bus specific register information via
the bus driver.
Change-Id: I544b23c8f6654e9215fb4f03203d6754c766dada
CRs-Fixed: 2833251
Whenever driver does a recovery because of the bus failure the
reason for the recovery is not known until the reason code is
read in the hif layer. So, update the recovery reason if there
is a bus id read failure in the hif.
Change-Id: I5ed6adc92ef2a94a031f682e5ffd17af9ac6893d
CRs-Fixed: 2833247
The function qdf_ini_parse returns QDF_STATUS as SUCCESS even if no
fields are read from the ini file. Because of this even if the
ini file is corrupted and no values are read from it the function
still returns SUCCESS.
So, to avoid that and ensure that the ini file is not corrupted,
add a variable ini_read_count to count the number of fields read
from the ini file and return SUCCESS only if its value is not zero.
Change-Id: I5ec9a9cdc9780b6c9487f6ac64b411b81328d75c
CRs-Fixed: 2804937
Currently there is no api to parse a string to uint32 array.
Write an api to parse a string to uint32 array.
Change-Id: I54ab4ba1009f6efeb535df1ad43c56e1c3e56d2b
CRs-Fixed: 2758878
Add changes to support new definition of
send_roam_scan_offload_mode_cmd() in connection manager.
Change-Id: Iea10907756ea785b0b0de72d01375f50ac3dbd6a
CRs-Fixed: 2758318
Add QDF API to check platform capability if DRV is supported or not.
Then component enables wow support based on it.
Change-Id: I9045b1982acfc4ed4cdce724b48430cb20e03274
CRs-Fixed: 2722639
As part of the new requirement to understand the reason for the
wifi hang the data need to be collected from the required modules
which will help in root-causing the reason for the hang.
Add the infrastructure so that the required modules can register for
this hang event notifier chain.
Change-Id: I32f1365eec1ad7d6e19be95e8faf9a980d054b76
CRs-Fixed: 2648304
Notifier chains are simple function list executed when an event
occurs. In qdf block and atomic notifier chains are defined.
Blocking notifier chains can be used to invoke a list of functions
based on event in a process context wherein atomic notifier chain
can be used in an interrupt context.
Change-Id: I9020b9f19915e084b017932fb6d0bfad792d745c
CRs-Fixed: 2648224
To undergo self recovery, the driver uses qdf_trigger_self_recovery to
initiate the sequence. Currently, this framework is valid for only a
single psoc driver.
Extend this framework to include support for multiple psoc driver by
providing the psoc on which the recovery has to be undertaken.
Change-Id: I782b505c03819223a914dabe7673b369aa175b7c
CRs-Fixed: 2617707
Add cases for NAN and TDLS in qdf_opmode_str to return the mode
in string format.
Change-Id: Ibdc22a337005d56485e5ee3b392f4d5d0089304a
CRs-Fixed: 2648590
Initialize to fix "maybe-uninitialized" compilation
error for specific compilers.
Change-Id: Ibb049891ef5847d1beda94470a6e75ebba145ef4
CRs-Fixed: 2634848
Define a QDF API to check if driver unload is in progress such that
driver unload can be checked from CMN components.
Change-Id: I397b0b6252ed8fd9558f04802cf55fdc61a39d83
CRs-Fixed: 2605656
Force wake request is sent before register write. If this req
fails check if FW is down or host is in recovery before
asserting.
Change-Id: I6d31b1f95b68ae4e462f59ed32ed933de55cacae
CRs-Fixed: 2601364
Add support for WMI over QMI to reduce power consumption for
periodic stats report.
Change-Id: Ic57b2bd18be803c97ffeea2e0073751d31e02202
CRs-fixed: 2521835
Currently there is no api to parse a string to uint16 array.
Write an api to parse a string to uint16 array.
Change-Id: Idbde9d70c64bc131813f5789c0453c9b3736228b
CRs-Fixed: 2478267
Add QDF API to check if DRV is connected or not such that
proper decision can be taken during wow enable request.
Change-Id: Ic128882d564b5717b6dc749c6fe229a6dbb86c8f
CRs-Fixed: 2457065
To identify the reason for recovery, add parameter
"reason" for qdf_trigger_self_recovery.
And revise comment for qdf_hang_reason, replace "CDS"
with "QDF".
Change-Id: I8b388b5e83dbbdf29246c264ada56290f0dd3bfc
CRs-Fixed: 2431282
qdf_tracker generically implements all of the logic necessary to
implement the qdf_nbuf map tracking. Rather than using the current
custom tracking solution for qdf_nbuf map tracking, use qdf_tracker
instead.
Change-Id: Id33138a9035653b45c66b712bd11e54873266a17
CRs-Fixed: 2425623
A common problem in any C code base is the proper management of various
resources, such as memory allocations, timers, works, locks, etc. To
that end, WLAN has added various one-off leak tracking features for
different resources over the years, to great benefit. However, this
approach is tedious, and prone to copy/paste and fix propagation issues,
making maintaining these various tracking features onerous.
Add a generic leak tracking data structure to WLAN for general use,
which implements these tracking logics. This will allow the various
resource tracking features to leverage this shared implementation for
ease of maintenance. Build on the hash table implementation added as
part of I7f5fc0c59ed220bde43044e7013b3c8573f1bf39.
Change-Id: I3247ace583108139dfb699ca077db3bdf5cfeace
CRs-Fixed: 2422958
The original implementation intended to back the qdf_psoc_op_start/stop
callbacks has evolved somewhat since the qdf_psoc_op interface was
added. Refactor this interface to better reflect the evolved
implementation.
Change-Id: Ia18949fc75bdc52313bc81976f79d3a76e9760ec
CRs-Fixed: 2418426
Due to a limitation in the memory leak detection logic when qdf_flex_mem
was written, qdf_flex_mem_release() was necessary to free any
dynamically allocated memory in the qdf_flex_mem_pool during certain
points in the WLAN driver lifecycle. This was done to avoid flagging any
dynamically allocated qdf_flex_mem_segments as false positive leaks
when the memory domains were changed and leak checking was performed.
With the introduction of qdf_talloc(), this workaround is no longer
required. Replace the calls to qdf_mem_malloc/free with qdf_talloc/free,
and remove qdf_flex_mem_release() altogether.
Change-Id: Ia5fd21386b94fc117af5f27853db5d8341601738
CRs-Fixed: 2404955
The IPv6 address format allows compression of _one_ or more zero hextets
using "::". However, the current implementation accepts _zero_ or more
zero hextets as valid. Adjust the minimum required hextets for a zero
compression to 1 from 0.
Change-Id: Ibdf406b04bbdc44d4a28fafa6179c104285c915c
CRs-Fixed: 2362739
Add APIs for t(ree) alloc(ated) memory management.
These APIs allocate memory like malloc, but track those allocations via
a parent-child relationship, or tree. If the parent is freed while it
still has children, a panic will be triggered. This effectively gives
you the ability to limit the lifetime of an allocation by ensuring the
child allocation lifetime will be strictly less than the parent
allocation lifetime.
Change-Id: I6308c96061e125b2e5a9c424ec2d2298c1c503ab
CRs-Fixed: 2359469
It is often useful to print the human readable version of an operating
mode in a log message or some other user-facing string. Add a function
for mapping QDF_OPMODE to human readable strings, qdf_opmode_str(), in
QDF such that various consumers do not have to implement it themselves.
Change-Id: I8756fb2ea97b3b8c7af2633b07694ad1e74d6d3e
CRs-Fixed: 2331888
Add new qdf API: qdf_is_recovering and
qdf_register_recovering_state_query_callback.
Client driver will register the state query callback
to common driver to report the recovering state.
Regulatory skip the chanlist update event during SSR
to keep the current regulatory setting.
Change-Id: I58e503cce162a0351d566148c1897a5012889c62
CRs-Fixed: 2321820
Add qdf_platform source file to qdf/Kbuild and
clean-up WAR introduced in change
I8172f3dbe0716be24a4dda739afb49f94528a4f6
Change-Id: Icb76d53544590b8bcace275ef52870606fb5d826
To speed up recovery trigger debugging, pass the caller's function name
and line number, such that the group needing to do the initial triage
can be easily identified via the panic message.
Change-Id: I64f62ec30de657deeff037ee99610e716cfc4377
CRs-Fixed: 2298195
QDF_DEBUG_PANIC has recently gained a reason parameter. Move instance of
logging followed immediately by QDF_DEBUG_PANIC to single calls.
Change-Id: Ifc00be410621005e8494074ed00b1b7e44cc6a03
CRs-Fixed: 2271769
As CDS is not usable by WIN, add callbacks that are
registered in QDF and correct the module dependencies.
Also moves the platform related function to qdf_platform.[c|h]
Change-Id: I3080e9df86770235ff46237b8a2ffb9c2a3c9c2c
CRs-fixed: 2130260
This reverts change-Id I38eb1d3be2840bfbb5fdc9c72606ce.
Zero_comp value can be 0 also; so revert the change.
Change-Id: I7ab10c20c74d005009f435d483d39e138687a547
CRs-Fixed: 2233854
Currently, the scheduler thread keeps a large, pre-allocated array of
messages for use in message posting. The vast majority of the time,
however, the scheduler thread has zero or one messages pending in the
queue. This leads to a huge memory overhead for nominal driver
operation.
Replace the current pre-allocated scheduler message pool with a
hybrid static/dynamic approach.
Change-Id: Ie942bacfef43edf142a9f35ad0309069096cda90
CRs-Fixed: 2204172