Commit gráf

239 Commit-ok

Szerző SHA1 Üzenet Dátum
Himanshu Agarwal
59c25048cd qcacmn: Add QDF APIs for SMMU Stage 1 translation
Add QDF APIs for DMA buffer allocation and sharing with SMMU
Stage 1 translation support. When SMMU Stage 1 is enabled,
DMA APIs return IO virtual address(IOVA) instead of physical
address. This IOVA needs to be mapped to physical address by
external module before accessing these buffers.

Change-Id: I88e938d8ebe1f32fdea79e3c3aa8a3638ddfd2b8
CRS-Fixed: 2072953
2018-03-19 09:34:37 -07:00
Dustin Brown
385b73090f qcacmn: Add per-level logging wrapper APIs
Depending on platform limitations and the intended audience of a
particular WLAN driver build, it would be useful to be able to compile
out specific logging level logs completely. To that end, introduce
per-level logging wrappers, which can be compiled in or out by the build
configuration.

Change-Id: Ie062ada403f8a31aebcde691396987ad9e5352b5
CRs-Fixed: 2205888
2018-03-16 21:51:49 -07:00
Rajeev Kumar
88de1dba44 qcacmn: Add common QDF API qdf_is_fw_down() to check fw status
Add common QDF API qdf_is_fw_down() to check if FW is down.

Change-Id: I8215665bec6975c8dd47ae3bb8423eeaaeba159c
CRs-Fixed: 2202731
2018-03-16 10:35:54 -07:00
Rachit Kankane
9cc217ab6a qcacmn: Compile out MTRACE feature
Fix to disabled MTRACE feature

Change-Id: I3cc30b47a9ba9dc9f99bf1185f99f0ae621f5f31
CRs-Fixed: 2189886
2018-03-15 08:05:06 -07:00
Sravan Kumar Kairam
4af5290d97 qcacmn: Add QDF abstraction for IPA enums
Add QDF abstraction for Linux kernel IPA driver enums.

Change-Id: I9b61917768a109d12aefdc19a7822287337c9c18
CRs-Fixed: 2194166
2018-03-14 22:34:15 -07:00
jinweic chen
c3546321b6 qcacmn: add nbuf map result check when replenish
add the nbuf map result checking when replenish rx
nbuf to monitor status ring, this could avoid the
case nbuf map failed and invalid dma address
posted to HW or do unmap for unmapped nbuf.

Change-Id: I45cfc015f71a2d7295f7fcb4803bd6e68e2752d4
CRs-Fixed: 2182546
2018-03-13 06:00:59 -07:00
Rajeev Kumar
e7abced1a1 qcacmn: Register fw down legacy callback with QDF
Register fw down legacy callback with QDF such that new UMAC
components can call QDF API to check if fw is down or not.

Change-Id: I8d68cb7625fd75aa90ba09adfe13955c5418b54f
CRs-Fixed: 2202605
2018-03-12 15:06:24 -07:00
Poddar, Siddarth
a9172bf24d qcacmn: Add APIs to get data packets info
Add APIs to get TCP syn/syn-ack/ack packets,
TCP src/dst port, DNS domain name/query/response,
ICMPv4 req/res, and ICMPv4 src/tgt ip information.

Change-Id: I1e4e92997a33e64fe2e4ae28a05b54b6ba5e8cff
CRs-Fixed: 2168412
2018-03-07 03:55:46 -08:00
Rajeev Kumar
83953b769c qcacmn: Change return type of fw down callback from void to bool
Change the signature of QDF FW down callback API to return bool
instead of void. Return type true indicates fw is down and return
type false indicates fw is not down.

Change-Id: I2be6f14e5fbdb7b24ccd604244e1314a8f127291
CRs-Fixed: 2196217
2018-03-06 20:10:14 -08:00
sumedh baikady
b882f93dbc qcacmn: Fix channel info in radiotap
Fix frequency and channel flags fields in radiotap API

Change-Id: Ic991ea796d0b19f8adc16a5bc33cfde0042c167e
CRs-fixed: 2189914
2018-03-03 23:44:46 -08:00
Dustin Brown
f16867f4c2 qcacmn: Remove qdf_str include from qdf_mem
In order to migrate existing qdf_str_* APIs to qdf_str.h from
qdf_mem.h, qdf_mem.h included qdf_str.h. Now that consumers are
including qdf_str.h directly, remove this include.

Change-Id: I6b0ee3a4a2ad17db922b8e19087c1d730ad9b419
CRs-Fixed: 2196132
2018-03-02 16:34:32 -08:00
gaurank kathpalia
1435fba5e0 qcacmn: Add qdf time api to get time of the day in millisec
qcacld-2.0 to qcacmn propagation

Adds qdf time api to get time of the day in millisec

Also send host timestamp to firmware, so that firmware can print the
logs timestamp in sync with host via the wmi interface,with
api wmi_send_time_stamp_sync_cmd_tlv()

Change-Id: Id6acfc5227fdca2fbf8d266998fdfc4046adc5f4
CRs-Fixed: 2193978
2018-02-28 23:35:53 -08:00
Dustin Brown
d5ff73ebc7 qcacmn: Move existing qdf_str APIs to qdf_str
A set of files for string abstractions has recently been added to QDF.
Move any existing qdf_str_* APIs from qdf_mem to qdf_str.

Change-Id: I6e1e5d1edcdfae2af83a6497ebd872fba981cdec
CRs-Fixed: 2196098
2018-02-28 11:55:20 -08:00
nobelj
9ab76e283f qcacmn: Add support for ppdu length in ppdu_stats
Rx PPDU length is calculated from number of MSDU length in each MPDU
Rx PPDU stats are populated after updating PPDU length.

Change-Id: I2af6a82eaddc4e791d4e7445c933a5886304e8f3
2018-02-27 21:17:19 -08:00
Nirav Shah
b432e7c080 qcacmn: [QDF] Add support for QCA9379 on x86 platform
Add support for QCA9379 chip on x86 platform for
USB and SDIO attach.

Change-Id: I50353d069e3b2edfb73c5421b73e18273bc243af
CRs-Fixed: 2181012
2018-02-27 21:17:15 -08:00
Dustin Brown
d1f73fa8ef qcacmn: Add const to qdf_*_parse function parameters
Add const to the 'char *' parameters of the qdf_*_parse family
of functions.

Change-Id: Ia106da9b9832bfe08a594a43926d68b4aa840f1f
CRs-Fixed: 2194529
2018-02-27 01:57:44 -08:00
Dustin Brown
b067d27d61 qcacmn: Add context parameter to qdf_ini_parse()
In order to avoid global state, add a context parameter to
qdf_ini_parse. This parameter will get passed back to consumers via
the existing callbacks.

Change-Id: Icd74a58815701b4603924838bb84c7956058da6b
CRs-Fixed: 2194517
2018-02-26 15:57:53 -08:00
Sravan Kumar Kairam
68a824774c qcacmn: Add qdf utility functions for ARP debug stats
Implement QDF utility functions to operate on ARP data packet to
support ARP debug stats feature.

Change-Id: Idce70799bd3698dc8a8ecd8cfc8ef7d9bf1f5764
CRs-Fixed: 2019789
2018-02-26 04:07:21 -08:00
Dustin Brown
e50d168ba5 qcacmn: Add qdf_str_dup() API
Add a QDF abstraction for strdup().

Change-Id: I141e625a91e3433c2a66bc75b4e860ed6ef266ac
CRs-Fixed: 2194537
2018-02-23 17:45:52 -08:00
Dustin Brown
64740289bc qcacmn: Add qdf_str_eq() API
strcmp() is regularly used to compare two strings for equality. However,
reading source code using strcmp in this manner can be prone to errors
because the return values are not obvious from the function's name. In
the best case, this leads to referring to the strcmp documentation more
often than one would like. In the worst case, this leads to difficult to
spot bugs. Add a thin wrapper for this use case to make intentions
abundantly clear to future readers. This wrapper is effectively sugar
for 'strcmp(left, right) == 0'.

For example:
	if (!strcmp(left, right))
	/* reads: if not string compare: left, right */

Becomes:
	if (qdf_str_eq(left, right))
	/* reads: if string equal: left, right */

Change-Id: Iabcb7c7e9f37dcb6cf1bdf5d7cc6c69ea926ba5c
CRs-Fixed: 2194508
2018-02-23 15:33:20 -08:00
Dustin Brown
61cabef5b6 qcacmn: Update qdf_trace for CONFIG module
QDF_MODULE_ID_CONFIG was previously defined for use by the configuration
component, but qdf_trace was not updated. Set the default logging level
for the configuration module in qdf_trace.

Change-Id: I8946b5473f03f3b85f8c2d6783039e03c9a49494
CRs-Fixed: 2194542
2018-02-23 15:33:18 -08:00
Rajeev Kumar
28dba98f8b qcacmn: Define QDF API to register fw down callback
Define QDF API such that legacy module can register fw down
callback and new components can use QDF API to check if fw
is down or not.

Change-Id: I2f5423943f351ee3a0fd84616c904a27702c10e3
CRs-Fixed: 2194451
2018-02-23 00:37:05 -08:00
Sravan Kumar Kairam
8fb188fc9a qcacmn: Add qdf abstraction for byte order identifiers
Add qdf abstraction for Linux byte order type identifiers.

Change-Id: I4ff55ffcb92a86e7d067bcb78b404b8deb3ee0f0
CRs-Fixed: 2193638
2018-02-21 23:49:16 -08:00
Varun Reddy Yeturu
52c506d034 qcacmn: Add caller info to memory debug infrastructure
Currently, the detected memory leaks would not dump
the caller of the function which is leaking the memory.
Add an extra parameter to the table to store the caller
address and print the function during an assert.

Change-Id: I6dc31b55fd4e78dc69df9eb6166ebb63086891c1
CRs-Fixed: 2177486
2018-02-15 14:10:51 -08:00
Yun Park
1ba3ada3aa qcacmn: Add IPA WDI Unified API support
Support for WDI2 in the Unified IPA WDI APIs.

Change-Id: Ife42a6a96ce80070de51f994e29ded252b3dd980
CRs-Fixed: 2183501
2018-02-15 09:20:35 -08:00
Dustin Brown
89a217419e qcacmn: Perform minor cleanup of qdf_*_parse APIs
Perform the following cleanup items for qdf_*_parse() APIs:
 1) Many qdf_*_parse APIs use a custom left-trim function called
    qdf_skip_whitespace(). Recently, qdf_str_left_trim was added,
    so use this function instead.
 2) Remove 'const' from 'const char *' parameters. 'const' protects
    modification of the pointer, which is already duplicated for the
    function call. Since the qdf_*_parse() APIs modify the pointer
    parameter anyway, using const is incorrect (and should have failed
    compilation).
 3) Ensure the public qdf_*_parse APIs are properly exported.

Change-Id: I89725c68cc0d61a66fe95ef02fa2deda110411ac
CRs-Fixed: 2185978
2018-02-13 17:24:13 -08:00
Dustin Brown
6461e566f4 qcacmn: Add int/bool parse functions to QDF
Add the following function implementations to QDF:
 * qdf_bool_parse()
 * qdf_int32_parse()
 * qdf_uint32_parse()
 * qdf_int64_parse()
 * qdf_uint64_parse()

Change-Id: Ic31e3eb70f684799bd6e1e524cfc1cb816ddc01a
CRs-Fixed: 2185282
2018-02-13 13:14:47 -08:00
Dustin Brown
677a261213 qcacmn: Add qdf_file and qdf_parse files to QDF
Add an QDF abstraction for reading a file. Also, add the first consumer,
qdf_ini_parse(), as well. This is pure parsing logic, which offloads the
actual content handling to the caller via callback functions.

Change-Id: Idfca74c5543a5b0da7ddd1bdc6e2ad2be59ed36b
CRs-Fixed: 2184463
2018-02-10 07:15:00 -08:00
Dustin Brown
a4fd883481 qcacmn: Add qdf_str files to QDF
Add files for QDF string APIs. Existing qdf_str_* APIs will be moved as
part of a future change.

Change-Id: If98d41380b2f7f62bbe5de141b6827e9427944ab
CRs-Fixed: 2184462
2018-02-10 07:14:57 -08:00
Kabilan Kannan
56800ad9a5 qcacmn: Add debug support for DMA memory allocations
Add debug support to detect memory leaks and corruption
in DMA memory operations.

Change-Id: I1478973828ddc147367c4a579c97c3840c106f44
CRs-Fixed: 2155603
2018-02-09 12:18:40 -08:00
Tallapragada Kalyan
32e74e669d qcacmn: Linearize nbuf in intra-bss forwaring case
with fragmented pkts re-injected back to REO destination
ring as frag_list, we need to linearize these nbufs while
handling intra-bss forwarding cases.

Change-Id: Id692974ac5d80f369fafae39aec32e2066dffb0b
2018-02-09 01:51:24 -08:00
Paul Zhang
ca6152167b qcacmn: Support 11d for non-offload platform
Support 11d for non-offload platform by maintaining
count of beacons encountered for each country code
and choosing country code with max votes as device's
country code.

Change-Id: I83b66e980854eded17e254386561fa32b1f8c4ac
CRs-Fixed: 2154048
2018-02-08 21:37:37 -08:00
Keyur Parekh
4d36b32991 qcacmn: Add Indication for MSDU or MPDU level aggregation
populate flags for MPDU or MSDU level aggregation in
mon_rx_status structure.

Change-Id: I5d8d026a42ffef9e95f579178b4f8cdc581699ec
2018-02-08 19:46:08 -08:00
Varsha Mishra
d385dbe43d qcacmn: Add QDF API to find packet type
Add qdf API to know whether packet is broadcast or not

CRs-Fixed: 2125569
Change-Id: If91685ae7b72c6ce52426648e9e01cba92fee86e
2018-02-08 14:13:14 -08:00
Chaithanya Garrepalli
221c795fea qcacmn: Add nbuf count support
Add a global nbuf count variable and add support to update
this count.

Change-Id: I08a50b54cae25ab9f356cd05d7635f1ba3b6bf55
CRs-Fixed: 2008240
2018-02-07 05:43:53 -08:00
Srinivas Pitla
1ddc439f46 qcacmn: Add wait_timeout API in qdf
Introduces QDF API for wait_queue_timeout() to allow
driver to use. This API helps to wait for the event for
configured time

Change-Id: I9640368120fd09b19f64f028f1eb3aab46b7c97a
CRs-Fixed: 2177109
2018-02-03 15:10:48 -08:00
Dustin Brown
57a7ff2f9b qcacmn: Remove QDF_MAC_ADDRESS_STR
QDF_MAC_ADDRESS_STR has been replaced by QDF_MAC_ADDR_STR. Remove
QDF_MAC_ADDRESS_STR.

Change-Id: I810d56ef62009375422a69b66d75b4d03ddaee0f
CRs-Fixed: 2176528
2018-02-02 09:31:03 -08:00
Akshay Kosigi
9e7f12f7da qcacmn: Fix Scatter-Gather and TSO
Fix SG and TSO for ftp data transfer

Change-Id: Ide7eec987436beea08711f31362c1fa61f5bf8c3
CRs-fixed: 2159610
2018-01-30 15:26:48 -08:00
Zhang Qian
82377ce4dd qcacmn: ADD OCB module ID
Add module ID and trace log for componentized OCB feature.

CRs-Fixed: 2177252
Change-Id: I794ce0809afed19863b52d26d9fcf1bde5e5e754
2018-01-25 23:39:28 -08:00
Dustin Brown
1b4e6b5e21 qcacmn: Remove QDF_MAC_ADDR_BROADCAST_INITIALIZER
QDF_MAC_ADDR_BROADCAST_INITIALIZER has been depreciated in favor of
QDF_MAC_ADDR_BCAST_INIT. Replace all usages with the new macro.

Change-Id: I5214558cd3788eacfe27188c230641edc86b1670
CRs-Fixed: 2176525
2018-01-25 13:26:01 -08:00
Anish Nataraj
28490c4c5e qcacmn: Add checks in rx_mon_status handler to filter spurious frames
1. find_first_bit API returns Size value if it doesn’t find any bit set.
   This was causing VOICE AC counter to go high even for TID 0
2. Reset stats was not resetting the stats immediately
3. Added checks to avoid spurious stats increment
4. Detect data/mgmt pkt to avoid spurious stats increment

Change-Id: Ic9c5695fc7bdf58d1237e7e20bb79378a02a21f6
2018-01-25 05:08:23 -08:00
Dustin Brown
8bf184d6e4 qcacmn: Remove QDF_MAC_ADDR_ZERO_INITIALIZER
QDF_MAC_ADDR_ZERO_INITIALIZER has been depreciated in favor of
QDF_MAC_ADDR_ZERO_INIT. Replace all usages with the new macro.

Change-Id: I565a01fe3c75da645d5f410ce2c54f02034fb14c
CRs-Fixed: 2176469
2018-01-24 13:19:43 -08:00
Dustin Brown
2e93d637cf qcacmn: Add MAC/IPV4/IPV6 address parsing to QDF
Add converged implementations of MAC, IPV4 and IPV6 address parsing to
QDF. This allows for reuse wherever address parsing is done. This also
supports the upcoming configuration component, which will support all
three address types.

Change-Id: I5158e2a40169da979a219363c6d2a25784c5a7e8
CRs-Fixed: 2174072
2018-01-20 01:45:05 -08:00
Subrat Mishra
bf12587bd1 qcacmn: Support for SWFDA Event & FD Frame tx
Add new WMI EVENT, SW FILS Discovery Alert Event, to get
firmware trigger to transmit FILS Discovery Frames.
Add WMI command to send FD frame buffer to firwmare.
Add WMI command to set FD period interval in mili seconds.

Change-Id: I8cb6279ec4431b9236bd32c548228a0dc6598664
CRs-Fixed: 2118098
2018-01-19 17:26:23 -08:00
Santosh Anbu
d5fdfacb1b qcacmn: Add debug trace for extender AP
Add commonly used header in Extender ap to qdf

Change-Id: Ifdf97973cc30c193e5ca81b2aec06fc350115ce6
CRs-Fixed: 2148247
2018-01-19 02:03:44 -08:00
Dustin Brown
976a7f6f6e qcacmn: Add nbuf map/unmap history tracking
An nbuf free history circular buffer already exists for tracking recent
nbuf frees in the system. This is very useful for debugging tricky nbuf
related failures in the driver. In addition to tracking frees, track
alloc, map, and unmap nbuf events as well.

Change-Id: I253d454d689deb8328b3636e92063e9d33ea1a52
CRs-Fixed: 2170365
2018-01-18 05:45:52 -08:00
Dustin Brown
4082a0951f qcacmn: Add nbuf map/unmap tracking
When MEMORY_DEBUG is enabled, track calls to nbuf map/unmap to detect
the following usage problems:

	* double map
	* double unmap
	* unmap without map
	* never unmap

Change-Id: I7326bb628d4cf0be9004398fd396907b1a06bf22
CRs-Fixed: 2155599
2018-01-18 01:49:45 -08:00
Keyur Parekh
71ab9ef0b7 qcacmn: Populate mon_rx_status structure fields
Update mon_rx_status fields for HE case. Also
added rs_fcs_err field to structure and populate
its value.

Change-Id: I4681543c7d6c6c7ac0d666cd93072caaee285585
2018-01-17 23:38:07 -08:00
akosigi
fffcebf2e9 qcacmn: Converge FTM feature
Support for FTM to make it common between WIN and MCL.

Change-Id: I4a65ca6d73d83e71f6a04405b5c41cdddb0a3c71
CRs-fixed: 2148283
2018-01-16 18:29:53 -08:00
Padma, Santhosh Kumar
f5d592433f qcacmn: Add support for GMAC MIC calculation
Add changes to calculate MIC using aead calls in linux

Change-Id: I710b1c748c36babc8e66aaf920a07f9657f6e273
CRs-Fixed: 2164910
2018-01-13 00:42:51 -08:00