There is a compilation issue if a variable is passed to
kernel api DECLARE_HASHTABLE.
TO resolve this issue, instead of passing a variable
pass a constant to DECLARE_HASHTABLE.
Change-Id: Ie9782af541bb34cc50f79060b0007dc73881e5f4
CRs-Fixed: 2386893
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
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
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
According to the ucode and mac team, the new TB-PPDU (UL OFDMA
Dat frame) from any other users using the TLV's fields below:
* PHYRX_RSSI_LEGACY (has a reception type field that is
set to UL-MU)
* PHYRX_RSSI_HT
* PHYRX_COMMON_USER_INFO (has a reception type field that is
set to UL-MU)
* PHYRX_USER_INFO (has more detailed modulation info)
* PHYRX_USER_INFO (Could be more than one)
...
* PHYRX_DATA
* PHYRX_DATA (Could be more than one)
CRs-Fixed: 2329959
Change-Id: Ib5fa1734a5525d2b2d1db8756166f259be30b9c0
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 peer_id and msdu_len in qdf_nbuf_cb these
fields are used for lithium rx performance
optimization
Change-Id: Iba291812397a5e7648953c2dc1b2c18a5c5a18af
As part of supporting NAN DBS, new WMI TLVs are defined so
that Host can maintain the status of NAN Discovery in sync
with the Firmware. Move the older handlers into the NAN
related files. Also add modules to extract information from
the new TLV's and fill up the event parameters to pass
them to the NAN component. add support for explicitly
disabling NAN due to concurrencies.
Add modules to handle and extract the info from NAN events.
Change-Id: Ic03baaaef45106353c211a813e11e33a90cd41ca
CRs-Fixed: 2338059
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
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
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
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
Add TDLS device mode to get the nss chains shift params
and store the ini and dynamic nss config in vdev.
Change-Id: Ia2f3dba1860eda23018e6b930866931886834879
CRs-Fixed: 2349203
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
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
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
Compiler throws no previous prototype build error for cpuhp
on UP system.
Fix is to add static inline for UP build.
Change-Id: Ib867a19ac526b44766a8cbb1838e7e5b2b18b4b1
CRs-Fixed: 2328927
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
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
Instead of frame control info valid parameter data sequence
control parameter was passed, corrected it
Change-Id: Iccaeb286c1003cbb58c5ebcacf4b0d99c979cbbc
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
Add qdf_platform source file to qdf/Kbuild and
clean-up WAR introduced in change
I8172f3dbe0716be24a4dda739afb49f94528a4f6
Change-Id: Icb76d53544590b8bcace275ef52870606fb5d826
Add timer to flush out log buffers periodically. Add command to set the
time period value.
Change-Id: I8e796a9bc7caac2661d00852420dd5fa66f5bca5
CRs-Fixed: 2296362
Move network buffer null check to beginning of function to
cover possible case of null pointer dereference during free.
Change-Id: I8c998d4d1711ab28c94a946d04314c26a4c74278
CRs-fixed: 2309452
This change defines VDEV MLME object, and registers with object manager to
be notified on creation/destroy, and also initializes MLME SM
Change-Id: I75bb7de7326e4bbed21ef9653427c4e0694c3ffc
CRs-Fixed: 2307722
This is generic state machine framework, which provides APIs for state
definition, state transition, event posting
Change-Id: Ie7d5a064967098fcb77a663047c479d1d1576595
CRs-Fixed: 2307722
Kernel 4.14 and later supports dev_scratch for network
buffer which can be used to store data in a nbuf in the
format unsigned long.
Add APIs:
1) qdf_nbuf_is_dev_scratch_supported
2) qdf_nbuf_get_dev_scratch
3) qdf_nbuf_set_dev_scratch
Change-Id: I2a72d369bb53f8f86d4bcee3cf6d13f5e4aff57f
CRs-Fixed: 2313270
Use QDF_TRACE log macro to log spin lock abuse when spin lock
debug feature is defined.
Change-Id: I1e5db79f5e6f5fc343f1be000efff6907c4857e1
CRs-Fixed: 2312614
EWMA macros which were used for sojourn stats
time delay calculation, causing compilation issue
for x86 platform as x86 platform is on kernel
version less than 4.3 and EWMA macros were
introduced after that version.
Change-Id: I184844c7df8e5b317a095355c2f6a9af9e4747ff
CRs-Fixed: 2308338
For qdf_mtrace 15 bits are reserved for message id and currently
WMI message IDs are getting used as 32 bit IDs.
Write a wrapper function which accepts 32 bit message IDs and
converts this 32 bit message id to 15 bit by extracting
WMI_GRP_ID and WMI_MESSAGE_ID in that group. New 15 bit
message ID for qdf_mtrace will be constucted as 8 bits
(From LSB) specifies the WMI_GRP_ID and remaining 7 bits
specifies the actual WMI command. With this notation there
can be maximum 256 groups and each group can have max 128
commands which can be supported.
Change-Id: Ia5adfc079b63c2311bdc8ae4c73488d89afd462f
CRs-Fixed: 2298877
Currently qdf_mtrace is defined outside TRACE_RECORD macro which
is using qdf_trace api and this is defined inside TRACE_RECORD
macro for MCL. since qdf_trace is having different definitions
for MCL and WIN as for MCL it is defined as a function and for
WIN it is defined as a MACRO.
To resolve this put qdf_mtrace inside TRACE_RECORD macro
Change-Id: I5de2cdff3942ca10b6d5d562f28d359f7f655ed4
CRs-Fixed: 2310167
Set monitor direct filter when smart monitor is
enabled. Deliver header from NAC if md bit is set
and smart mesh feature is used.
Change-Id: If1ef865e013c21bbb58bcb89a87856b12d6c7278
Crs-fixed: 2246660
Put the nbuf map/unmap code under NBUF_MAP_UNMAP_DEBUG.
nbuf map/unmap debug will be enabled on WIN once
the nbuf map/unmap related false positives are fixed.
Change-Id: I6b62539d39664db3ff62411fe8632633f53488c8
CRs-Fixed: 2284128
In qdf_nbuf_alloc() function, pass function name and
line number of caller and log the same in case of failure,
this approach helps to remove error logs in caller function
there by reducing text segment.
Also add qdf_rl and qdf_rl_nofl_* macros.
Change-Id: Ib8ce83335807cfbd2d83d1f165d6bec1dc1e4c94
CRs-Fixed: 2281983