The qdf_timer_multiplier is currently applied to qdf_mc_timer and
qdf_event. In addition to these cases, also apply qdf_timer_multiplier
to qdf_timer to enable more debugging scenarios.
Change-Id: Ie3bd340dd2e8f1bec7e5bfa7ec3f0d0ceaa32e6d
CRs-Fixed: 2393017
There are some changes to timer APIs in latest kernel,
update driver APIs accordingly to invoke correct kernel
APIs for timer functionalities.
Change-Id: Ie017c8b1ef8237ca34f696c23509519a1187167c
CRs-fixed: 2383574
With the changes made in Ibe0f8adc4df7bb98aceb509d438e241fac507393 and
Ic4cef0d6301230197443d4d5247188f2af643674 there are compilation issues
with converged code.
Resolve the issues by creating ifdefs for the timer_list definitions
according to kernel version.
Change-Id: Id9c29413ca0d21533a0afae245595051fa3a400f
CRs-Fixed: 2390884
The various setup_*_timer() APIs were removed from the linux kernel in
4.15, and replaced with similar timer_setup_*() APIs. Add conditional
compilation to qdf_timer to use the correct APIs depending on the
version of the kernel being compiled against.
Change-Id: Ibe0f8adc4df7bb98aceb509d438e241fac507393
CRs-Fixed: 2388570
There are a number of places where the kernel's timer_list type has been
used in conjunction with qdf_timer APIs. To prevent reintroduction of
similar issues in the future, do not directly alias qdf_timer_t to
timer_list.
See also: I410b7fafad18be01141008b6220fbe34ab07601e
Change-Id: Ic4cef0d6301230197443d4d5247188f2af643674
CRs-Fixed: 2388595
os_timer_t is a legacy wrapper around the kernel's timer_list type, and
is incorrectly used directly with qdf_timer APIs. Remove os_timer_t,
replacing instances with qdf_timer_t instead.
Change-Id: I410b7fafad18be01141008b6220fbe34ab07601e
CRs-Fixed: 2388575
Remove CONFIG_MCL flag for hif_bus_id in __qdf_device since
it can be shared by WIN and MCL.
Change-Id: I0f88aae7f3139485b99a029fa4f53d848875b0ac
CRs-Fixed: 2368166
Enable printing of QDF prints for QDF_TRACE_PRINT_ENABLE flag
irrespective of the flags WLAN_DEBUG and DEBUG.
Change-Id: I0b53d1759c3d38321d66bec325b855eb1e48e75a
CRs-Fixed: 2355333
Change default log level of serialization to QDF_TRACE_LEVEL_ERROR
Change error print to debug, when pending queue is empty,
which is a possible expected case.
Change-Id: I21cd6b5f158d5dffbc6e7309c9202e7e2e0162e8
CRs-Fixed: 2387017
To enable all the Spectral fatal and error logs by default,
set its default trace level to QDF_TRACE_LEVEL_ERROR.
Change-Id: I05d958f2206684f0e413e4e9a5576a96b228ddcd
CRs-Fixed: 2384360
Add mlme message queue handler as the call back for non scan commands
getting activated in the scheduler context.
Add cmd already exists enum to be returned if the command already exists
in the serialization queue.
Change-Id: I24fe453ffddbd4341459874458f11688adebc740
CRs-Fixed: 2377219
The network buffer (nbuf) history records the usual nbuf allocations
and frees, but does not record allocations due to copies or clones.
Record these allocations in the nbuf history as well to aid in
debugging.
Change-Id: If5bed9a41d301d43a1e610df4366d0bcf2c3efc4
CRs-Fixed: 2379866
Some compilers allow functions to be annotated such that a warning will
be emitted if the return value of that function is not used. Allow the
WLAN driver to leverage these annotations by introducing a wrapper in
QDF, qdf_must_check.
Change-Id: I9c1328ae904857717703aae3748b207967a8dd3d
CRs-Fixed: 2382837
To align with the converged nomenclature replace the identifier
session_id with vdev_id in qdf_trace APIs.
Change-Id: Ic97a2df848e2b687edbd29c419193f4285125f81
CRs-Fixed: 2381424
In function qdf_trace_msg_cmn va_end is called without va_start.
This can lead to delay in driver logging.
Change-Id: I9d2c9893037f5836cf902e6e311a0a521b8389e0
CRs-Fixed: 2373637
This change will resolve displaying NSS value
in stats in case of HT. And also it will give
proper NSS value to calculate rate value. Modify MCS
value to match with Tx stats from firmware.
Also retain original MCS value to use in radiotap code
for HT case.
Change-Id: I4dad068262a5e9188a5935db6b2cbf8d14138e7e
Add QDF abstraction macro to read ipa wdi out structure param
is over gsi member.
Change-Id: I48c848b432168cba46ded985023291077488b2be
CRs-Fixed: 2367310
Add peer_id and msdu_len in qdf_nbuf_cb these
fields are used for lithium rx performance
optimization
Change-Id: Iba291812397a5e7648953c2dc1b2c18a5c5a18af
Currently there is only tso segment and tso number segment
descriptor free operation when tso preparation failed, do dma
unmap for each segment as well.
Change-Id: I9a507f27341877dc062528ce77e02970d16aa098
CRs-Fixed: 2347279
Add support to dump only last n dpt records of debug fs
dump_set_dpt_logs file.
Change-Id: Ic6418803d53cc2abbfc200f62df2a24c3bc55d54
CRs-Fixed: 2362523
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
Add a thin wrapper in QDF around the kernel hashtable implementation.
Additionally, add basic unit tests for these APIs.
Change-Id: I07999e5fc8116e67b3850b866ced20af64342055
CRs-Fixed: 2359335
When MEMORY_DEBUG is enabled on WIN, it is reporting qdf_aligned_malloc_fl
as an unknown symbol. qdf_aligned_malloc_fl is defined under
MEMORY_DEBUG flag but its prototype is exposed globally.
Make this function definition available globally to fix the issue.
Change-Id: Ieb002bb892d6f3d525409fc9c3a6b2fa71ceebd8
CRs-Fixed: 2357476
qdf_mem_shared_mem_alloc invokes qdf_mem_dma_get_sgtable which will alloc
memory.
This memory should be free in qdf_mem_shared_mem_free by sg_free_table.
Change-Id: I3ad4bd2ff7a80d4051f15dcb04e0265707c2712d
CRs-Fixed: 2131270
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
Make ipa_owned bit common for TX and RX control block union
for MCL as it is used in qdf_nbuf_free API, which is used in
both TX and RX path to free skbs.
Change-Id: I3a4279d528a1b8a72a1ec307f1672efae84d2745
CRs-Fixed: 2353137
Currently qdf_mem contains a function, qdf_mem_validate_list_node(), for
validating a list node and ensuring it is currently part of a list.
Instead, abstract this function from qdf_mem, and move the definition to
qdf_list_node_in_any_list() in qdf_list. This is a more reasonable
location for the list-specific logic, and allows its reuse by other
callers.
Change-Id: I56a5d54e3c81470a111f168533faedf7fa525ff3
CRs-Fixed: 2359358
Currently, qdf_nbuf_map_check_for_leaks() logs the leak information
under spinlock before inducing a panic. This can cause a confusing false
positive panic upon releasing the spinlock if the logging took longer
than the spinlock timeout threshold. Since we already know we are going
to panic, panic under spinlock to ensure the panic message is always
appropriate.
Change-Id: Ib98b21e8feac0314b7c1f00f08b9e81112c4f2ba
CRs-Fixed: 2357806
Define qdf_aligned_mem_alloc_consistent() and qdf_aligned_malloc() which
allocates the memory and checks if allocated base address is aligned with
ring_base_align. If not, it frees the memory and re-allocates by adding
7 bytes to alloc_size and returns aligned address to the caller.
Change-Id: I412153c20e4e4566450b006356fe78d98f1fd3f0
Acked-by: Shashikala Prabhu <pshashik@codeaurora.org>
CRs-Fixed: 2336697
Typecast 'rowsize' to qdf_size_t, to avoid compiler error
'comparison of distinct pointer types lacks a cast'.
Change-Id: I29e05a1f0d165accf3bebefc0af2b9f97cac0f5d
CRs-Fixed: 2350601
Currently, if an uninitialized QDF mutex or spinlock is destroyed, the
issue is logged in dmesg. This has allowed multiple uninitialized
spinlock issues to merge into mainline and remain unnoticed for several
weeks. Instead, if an uninitialized lock is detected during destroy,
panic.
Change-Id: I929cfa3f295cb1e76634653bbd4aec3a6f1268b7
CRs-Fixed: 2347717
qdf set print verbose level is using pr_info to log debug logs
and pr_info logs are logged on console hence change pr_info
to pr_debug to avoid logging debug logs on console.
Change-Id: I43ccef244c9576483f1520c0a5027ac88e0cbb07
CRs-Fixed: 2342962
In case of 11w PMF tx frame, some target would dma write to this tx
buffer, it may cause smmu check fault.
Add a bi-direction map flag to mcl skb.cb[] for this special case.
Change-Id: I72a2c11abb9f3e7e8fb9c6f5290cd4f8d209b19a
CRs-Fixed: 2337204
NBUF alloc fail prints are flooding the console,
which is not allowing watchdog resetting to occur
ratelimit is added to reduce the print statements
flooding the console.
Change-Id: Ib6531070c8b80d64ffea62209912e5166e0414c1
One of the most common stability issues encountered by the stability
team is watchdog bite due to excessive logging. Add a feature to track
logging to dmesg using a tumbling window and counter, and panic if the
configured maximum number of logs for that window is exceeded.
Change-Id: If83c6dfccb9d191b02a3a7166b065c0a0704f969
CRs-Fixed: 2338385
For special packets DP tracing enable_check is called with
NULL nbuf, it returned false, preventing special packets from
logging. So ignore NULL nbuf and return true to enable DPT
logging.
Change-Id: Ieccc9e77195f5c8ff590c6964972705c362c16ba
CRs-Fixed: 2335301
Currently, the QDF debugfs feature returns a no-support error code for
the init call when the feature is compiled out. Instead, return success
to avoid wlan load failure on some configurations and to make error
checking by the caller more straight forward under all configurations.
The deinit call also has the same problem, but none of the callers pay
attention to the return status. Additionally, the deinit function
returns success unconditionally when the feature is compiled in.
Rather than changing the return status to success when the feature is
compiled out, change the return type of the deinit function to void.
Change-Id: Iac3a47505142e149f70c67c5ba6cf0b2428d9488
CRs-Fixed: 2336872
In addition to the other nbuf history events, track allocation failures.
This allows root causing issues due to nbuf exhaustion.
Change-Id: Ia0bbc6f12d26e32fcdb4cf7d0efef328417436ce
CRs-Fixed: 2329461
In preparation for QDF timer tracking, return QDF_STATUS from
qdf_timer_init(). This allows callers to handle the eventual possibility
of a QDF timer init failure.
Change-Id: I9da4643610099d32b002bda9218af26247a4edc6
CRs-Fixed: 2327724
In case of preallocation of nbufs, the debug nodes contain
allocation information with respect to the allocator
and not the user.
For more accurate debug info, add new QDF API
qdf_net_buf_debug_update_node to update the debug info
when the nbuf is requested.
Change-Id: Idfbcd15b6c561bbb57ba98a6b8376557ba909eec
CRs-Fixed: 2322989
Fix compilation error of implicit conversion from enumeration
type 'enum ipa_wlan_fw_ssr_event' to different enumeration type
'enum ipa_wlan_event' in function __qdf_to_ipa_wlan_event.
Change-Id: I7b5d3e964a5fa070a89aaf21bcb4ea2237a85a58
CRs-Fixed: 2324656
During FW rejuvenate, a message needs to be sent to
IPA driver to indicate of the event's occurrence.
Add a QDF abstraction for the FW rejuvenate event to
be sent as a message to IPA driver.
Change-Id: I3ffa220234f9690306c408a24ddd31ac94015124
CRs-Fixed: 2290656