Граф коммитов

6009 Коммитов

Автор SHA1 Сообщение Дата
Amir Patel
d577d09497 qcacmn: Fix last_per overflow issue
Check if ucast pkts count is more than success pkts count,
compute last packet error rate only if ucast is less than success
pkts.

Change-Id: I0aa4d41d09b1691e4d554beab2f2ed7a7f2ceb1e
CRs-Fixed: 2343479
2018-11-30 06:45:20 -08:00
Alok Kumar
c1ec49e685 qcacmn: Fix max OL_TXRX_NUM_LOCAL_PEER_IDS for concurrency
Change max OL_TXRX_NUM_LOCAL_PEER_IDS to 35 to take care of
STA + SAP + P2P concurrency.

Each AP will occupy one ID, so it will occupy 2 IDs for AP-AP mode.
Clients will be assigned max 32 IDs and STA(associated)/
P2P DEV(self-PEER) will get one ID.

Change-Id: I4d3e74c550e34b1d3417825245990655ead87b28
CRs-Fixed: 2356032
2018-11-30 06:45:17 -08:00
Anish Nataraj
e9d4c3bf33 qcacmn: Reorganise DP init-deinit path to reuse memory
Avoid memory fragmentation that happens during
attach-detach flow.
- Reuse transmit allocated static pool memory across soc up/down.
 These memories are allocated during soc attach.
- Reuse DP source ring memory, DP soc context, DP pdev context
  across soc up/down.
- Reorganise structure members of DP soc and DP pdev so that
  we can zero out structure members across soc up/down
- Add cdp soc init/deinit and cdp pdev init/deinit that
  will be active across soc up/down

Change-Id: I5732453f617bdc16995fda916b645c41845c3ecb
2018-11-30 03:40:43 -08:00
jiad
5eb6276a46 qcacmn: Fix misleading-indentation build error
This change fixes build errors with compiler option
-Werror=misleading-indentation.

Change-Id: I56e0921b1319852109d978cf239b54c2941a0e8e
CRs-Fixed: 2353199
2018-11-30 03:40:41 -08:00
Venkateswara Swamy Bandaru
9fb7b7813a qcacmn: Enable WMI support for RU26 intollerent setting
Enable WMI support for RU26 intollerent setting for tlv case.

Change-Id: Ia088ac3803c437bb35ace21fd508906baf519a3b
CRs-Fixed: 2357397
2018-11-30 03:40:38 -08:00
Dustin Brown
da4fb2ad20 qcacmn: Avoid marking MSI as wakeable
On MSM platforms, MSI vectors are always wakeable, so calling
enable_irq_wake() on an MSI vector interrupt line is a no-op.
Additionally, on some product lines, this call will fail. This causes
suspend to fail despite the MSI already being wakeable. Simply avoid
marking the wake MSI as wakeable during suspend as a work around.

Change-Id: I32b2b4fb231681ad29b4e98b2410d0eb6e68c671
CRs-Fixed: 2357784
2018-11-29 23:33:28 -08:00
Dustin Brown
0497d105b0 qcacmn: Panic before unlock on missing unmap
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
2018-11-29 18:12:36 -08:00
Chaitanya Kiran Godavarthi
f6c061252f qcacmn: Reduce ASE aging for MEC entry type
ASE entry aging for MEC entry type was same as
WDS type for 120 secs, this creates an issue when
device roams from MEC to WDS connection by not
aging out till 120secs. So now we reduce the MEC
aging time to 1sec

Change-Id: I6ab3b095a85c6d09f9fcd95b3b39f7152064d297
2018-11-29 18:12:33 -08:00
Jianmin Zhu
74c34ff6b0 qcacmn: Avoid mem leak when create regulatory object
When x_psoc_create_handle return failed,  need free all resources
before return, x_psoc_destroy_handler has no chance to be called
any more.

Change-Id: I63fd3743dd4ef4c9cc35c9ae8464c2b728447818
CRs-Fixed: 2353795
2018-11-29 18:12:31 -08:00
Jianmin Zhu
5d9c2898db qcacmn: Avoid mem leak when create DFS object
When x_psoc_create_handle return failed,  need free all resources
before return, x_psoc_destroy_handler has no chance to be called
any more.

Change-Id: I4b9999dbc2597c4ea860f08a6f3334f7f5728146
CRs-Fixed: 2353795
2018-11-29 18:12:28 -08:00
Jianmin Zhu
3b50e73e0f qcacmn: Avoid leak and double free in serialization object
When wlan_serialization_pdev_create_handle return failed,  need
free all resources before return,
wlan_serialization_pdev_destroy_handler has no chance to be
called any more, same for psoc, pdev handlers.

Optimized destroy handlers to avoid double free and leak.

Change-Id: Iae2b7c2fa221502742cbe565b27bcb16b7fc56ed
CRs-Fixed: 2353795
2018-11-29 18:12:27 -08:00
Yeshwanth Sriram Guntuka
dca006cecc qcacmn: Remove ssid check for finding scan dup entry
Probe responses received from hidden AP after beacons
with non-zero ssid length will use a new entry in scan
db resulting in multiple scan entries for same AP.

Fix is to remove ssid check in util_is_scan_entry_match
api.

Change-Id: I1c094d483a40d40f7ca9d40b26d04a7f80099dd1
CRs-Fixed: 2353339
2018-11-29 18:12:24 -08:00
gaurank kathpalia
a6076f692d qcacmn: Fix scan policy type in default scan case
The driver has a default scan policy type of DBS scan
which is not overwritten in case of DBS disabled.

Fix is to have a default of NON-DBS scan, and overwrite the
scan policy if the low power, low span scan is triggered,
or if the DBS is disabled from ini.

Change-Id: I8c95b2ca5915e1a74ccdeae55dea5e65bcfe9664
CRs-Fixed: 2354103
2018-11-29 18:12:21 -08:00
Paul Zhang
da522d8f7c qcacmn: Ignore destroy callback if creating fail
objmgr should not call destroy callbacks for components
that have not successfully completed the creating callback.
Or the function wlan_objmgr_xxx_obj_destroy returns with
QDF_STATUS_E_FAILURE and doesn't call wlan_objmgr_xxx_obj_free
to free the psoc/pdev/vdev/peer.

Change-Id: I1ba5a6afd98254cbed4571d5fb1cd24543e1db54
CRs-Fixed: 2318184
2018-11-29 18:12:18 -08:00
Abhiram Jogadenu
ba7946a147 qcacmn: Support for Quiet IE count change in bcn
Added support for quiet IE count change in beacon for beacon
offload case.

Change-Id: Ic8de5910588b58c8ffce48ea888afe8e6ed30dc9
CRs-Fixed: 2334134
2018-11-29 18:12:15 -08:00
jitiphil
a3be364dfb qcacmn: Free buffer in ath_procfs_diag_read
A read buffer is allocated and used in
ath_procfs_diag_read and it is not freed
in one exit path which causes a memory leak

Free read buffer in all exit paths of
ath_procfs_diag_read

Change-Id: I1b2446a99f53c2f9130d395dd316eb4649eb24db
CRs-Fixed: 2352165
2018-11-29 18:12:12 -08:00
chenguo
2a73379e03 qcacmn: Add new cdp API to get vdev in monitor mode
After gerrit#2436786, vdev in monitor mode is removed from vdev
list of pdev. So it is needed to add one more cdp API to get vdev
in monitor mode.

CRs-Fixed: 2343290
Change-Id: I9d74302a464280881ce0cf25dbc8c4f9d8b8d48d
2018-11-28 03:57:17 -08:00
Jinwei Chen
40fafaf4b6 qcacmn: fix REO2SW ring full issue
When reap data from REO2SW ring and if the TP catches up to cached
HP, current logic will update HP again and give a second chance to
reap data. but the TP is not updated to ring register, if more data
is received on this ring then HP easily catches up to TP and the ring
is full.
Update TP as well if HP get chance be updated.

Change-Id: I92f381d2a31f3be987866a829e05b5578098649a
CRs-Fixed: 2334435
2018-11-27 23:54:50 -08:00
Viyom Mittal
27fe1239d3 qcacmn: Set ack_rssi_valid to 1 for successful TX
The ack_rssi_valid flag to set to 1 only when completion_status
value is 0 which shows that the TX was successful.

Change-Id: I9e520422995e374d7d35b9db0c060d1fce2f9067
2018-11-27 11:20:21 -08:00
Bala Venkatesh
c05f8e47be qcacmn: Avoid possible integer overflow
In function init_deinit_chainmask_table_alloc, alloc size is declared
as uint32 and is assigned the value the multiplying non zero value
sizeof(struct wlan_psoc_host_chainmask_capabilities) and uint32
value ser_ext_par->chainmask_table[i].num_valid_chainmasks.
This can lead to overflow as multiplies value can be more than uint32.

Change-Id: I9a886d9ee5213ae8989a2c5d4502336cc275418a
CRs-Fixed: 2347650
2018-11-27 02:01:39 -08:00
Basamma Yakkanahalli
5f7cfd49c2 qcacmn: Device and Target type support for qca6018
Added target and device type support for qca6018.

Change-Id: I85382bf053d0a5f34cfaf0cca78a4b66b4265989
CRs-Fixed: 2323023
2018-11-27 00:32:00 -08:00
Basamma Yakkanahalli
30265f8aeb qcacmn: add target_service_to_ce_map for ipq6018
Populating the data structure target_service_to_ce_map
for IPQ6018 platform.

Change-Id: If89f873a6124240f56b93b4b12464a1e388df272
CRs-Fixed: 2324518
2018-11-27 00:31:56 -08:00
Jinwei Chen
1adbd73547 qcacmn: fix excessive logging about rx defrag
Change rx defrag related log level from info to debug,
it's not necessary to print normal rx defrag operation related
log default, this can avoid panic caused by excessive logging
when receive lot of fragment data.

Change-Id: Id712d546a760377a6f59b321f73d7ae5ca4af564
CRs-Fixed: 2353869
2018-11-26 15:52:48 -08:00
Vignesh Mohan
cca9e9baaa qcacmn: Add WMI command to set Sub Channel Marking
Introduce a new wmi_send pdev param to enable/disable
"Subchannel Marking" in Firmware (only in  Full Offload)

Change-Id: I3cd4f4f13ebca72c4505b6195cc8dc4856d41671
CRs-Fixed: 2334258
2018-11-23 10:13:18 -08:00
Vignesh Mohan
4974032991 qcacmn: Add dfs tgt API to set Sub Channel Marking
Introduce dfs_tgt API to send the WMI command to enable/disable
"Subchannel Marking" in Firmware (only in  Full Offload)

Change-Id: If739409521c8704b612e52dfc8ed6b86ffe32bca
CRs-Fixed: 2334258
2018-11-23 10:13:16 -08:00
Vignesh U
c008454014 qcacmn: Add support to enable/disable NOL subchannel marking
Add DFS function to enable or disable NOL subchannel marking.

Change-Id: Ibb6dbdb373af5b328c813c3b80b0f2296f644406
CRs-Fixed: 2334258
2018-11-23 10:13:13 -08:00
Debasis Das
5e2539c087 qcacmn: Protect TxLookupqueue while flushing
The htc TxLookupQueue needs to be protected with
relevant lock while flushing.

Change-Id: Ib6c8878c024ef623dfb63ca0745d41b140f2b1c3
2018-11-23 02:00:17 -08:00
Hariharan Basuthkar
3fb68e1e6d qcacmn: Correct frequency offset computation during bin5 radar
Changes configured to operate in Channel 100(HT80), if bin5 chirp
radar is injected at center frequency at 5530 MHz, instead of adding
channel 108(HT20), it adds channel 116(HT20) of adjacent 80 MHz band
to NOL list.

We have the following variable assignments in function
dfs_pulses_within_window:

dfs->dfs_min_sidx = pl->pl_elems[*index].p_sidx
dfs->dfs_max_sidx = pl->pl_elems[*index].p_sidx

Since the variable pl->pl_elems[*index].p_sidx is of signed type
and variables dfs->dfs_min_sidx/dfs->dfs_max_sidx are of unsigned type,
if the value of the variable pl->pl_elems[*index].p_sidx is negative,
the values of the variables dfs->dfs_min_sidx/dfs->dfs_max_sidx become
very large unsigned value.

When sidx is converted to frequency offset, the frequency offset
also becomes very large and it is greater than 40Mhz(half of HT80).
In this case, 50MHz is added to center frequency 5530 MHz, which
becomes 5580MHz(channel 116(HT20)). This results in the channel
116(HT20) of adjacent 80 MHz band to be added to NOL list.

Change the type of the variables dfs->dfs_min_sidx/dfs->dfs_max_sidx
from unsigned to signed so that assignments do not alter the actual
value of the frequency offset.

Change-Id: I13995888b618d9dd8a91447d5dffe27aa2e27a27
CRs-Fixed: 2342743
2018-11-22 22:35:41 -08:00
jitiphil
e65cc2defe qcacmn: New HTT H2T msg support
Current HTT_H2T messages from host driver does not have
consistency in message length set by host driver. Some
message types include HTC header length also within the
message length, while other types have message length
itself only, which causes difficulty in handling message
length in FW.

Change-Id: I885a21530a2d8f852387ae54cf7ee0751aad2516
CRs-Fixed: 2345075
2018-11-22 16:38:39 -08:00
Rachit Kankane
264fe67fd1 qcacmn: Set TDLS channel offset correctly
Set TDLS channel offset correctly when TDLSSECONDARYCHANNELOFFSET
command is sent with offset 20.

Change-Id: Ifac48da3fea0c83415f3d30caa2919a559f5c3c5
CRs-Fixed: 2341883
2018-11-22 09:39:40 -08:00
Amar Singhal
64ea8064b1 qcacmn: Avoid setting SOURCE_DRIVER for non-BDF CC event
Firmware could send same channel list for each pdev. Since SOURCE DRIVER
is default, it would be set for the second event. Avoid that. Remember the
source of the first event itself.

Change-Id: Ib9db58da1fa27673b04a4c62e10f2a05702348ad
CRs-Fixed: 2352151
2018-11-22 04:18:28 -08:00
Amir Patel
3ccfa6a645 qcacmn: Add accumulated last_tx_rate in cdp_tx_stats
Add accumulated last_tx_rate stat in cdp_tx_stats

Change-Id: I3d939b0f058e838e426c5fd77d576deb008288b6
2018-11-22 02:29:56 -08:00
Shashikala Prabhu
dae5623949 qcacmn: Use qdf API to allocate aligned memory for direct buffers
In target_if_dbr_fill_ring(), min_buf_align (8 bytes) was added to
min_buf_size before allocating the memory for dbr_buf_pool. This leads to
extra 1MB allocation.

To avoid this extra allocation, call qdf_aligned_malloc() to allocate
aligned memory for direct rx buffers.

Change-Id: I72f7c616c7a699437b081de7149a4a67a3ad30c4
Acked-by: Shashikala Prabhu <pshashik@codeaurora.org>
CRs-Fixed : 2336697
2018-11-22 00:43:55 -08:00
Shashikala Prabhu
f09216fe1b qcacmn: Add qdf API to align the allocated memory
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
2018-11-22 00:43:51 -08:00
Kiran Venkatappa
74e6d8b510 qcacmn: Enable AST workaround only for HKV1
HKV1 does not have support to maintain per pdev AST table.
Hence workaround is required to ensure that AST entry is deleted before
adding an entry with same MAC. This syncronization needs to done across
pdev. This workaround in required on for HKV1, add changes to enable
workaround only for HKV1 and disabled for other platforms.

Change-Id: I9aa43ea51fdff2f02cdcc8ff7e906c7305446317
CRs-Fixed: 2344921
2018-11-22 00:43:47 -08:00
Kiran Kumar Lokere
7ec465930a qcacmn: Add support to configure action frame in HE TB PPDU
Add support to send the action frame in HE TB PPDU configuration
to firmware.

Change-Id: I8f8f63652e0890736266766b283411464f8903b9
CRs-Fixed: 2347028
2018-11-22 00:43:44 -08:00
Kiran Kumar Lokere
605e7a710b qcacmn: Add new crypto serivce apis for security checks
Add new crypto component service apis to check the security
match.

Change-Id: I66336c4924b2a2c203d6ba197ab649725f960ef8
CRs-Fixed: 2337195
2018-11-22 00:43:41 -08:00
sumedh baikady
61cbe85a14 qcacmn: Per tid BA window size enhancement for HKv2
For HKv2, BA window size can be configured on per tid
basis as opposed to per peer basis on Hkv1. This per
peer per tid configuration on Hkv2 is for Tid 0 to 7.

Change-Id: Ic4afee92792af829a9ad8fdfc211625743b9d052
2018-11-21 22:59:19 -08:00
Aniruddha Paul
c34164e97e qcacmn: Add support for NSS DBTC mode
Add dbtc support for NSS offload mode.

Change-Id: I3673c0a42071f7d7767e086618c0171658e8a6f0
CRs-Fixed: 2330655
2018-11-21 22:59:16 -08:00
Chaithanya Garrepalli
0a5f71bca1 qcacmn: remove the QDF_BUG in src port learn when peer found
Remove the QDF_BUG in sa valid case when AST entry is not found
and peer is found as this can be a valid case in DBDC repeater

In DBDC repeater case we may receive the L2UF frame sent on 5G
radio on 2G interface

In this case SA will be valid and peer will be found for 5G VAP
mac address, but ast entry will not be found in ast_table as we
dont receive peer map events for STA vaps

Change-Id: I22e8582605f59a8691d8fcbb43627655d1a6500c
2018-11-20 12:19:12 -08:00
Aditya Sathish
1ce1a2e34a qcacmn: Fix WMI for peer channel re-intersection
Fix WMI message for peer channel width switching to account
for reserve space allocated in the message between num_peer
and chan_width_peer_list.

Change-Id: I5f0cec3c263cb68f44f0fcaa2aa26d120e807b1a
CRs-Fixed: 2352372
2018-11-20 10:31:40 -08:00
Lin Bai
5c0d751414 qcacmn: Typecast variable to same type before comparison
Typecast 'rowsize' to qdf_size_t, to avoid compiler error
'comparison of distinct pointer types lacks a cast'.

Change-Id: I29e05a1f0d165accf3bebefc0af2b9f97cac0f5d
CRs-Fixed: 2350601
2018-11-20 05:28:55 -08:00
Pavankumar Nandeshwar
ad5e0bd66f qcacmn: Change fwlogs API for smartlogs
Add function pointers for calling smartlogs init and deinit.

CRs-Fixed: 2008290
Change-Id: I4734e490394a24f5a39eb50f3ac386ad99834cb3
2018-11-19 11:05:49 -08:00
chenguo
420a4425dc qcacmn: Fix peer ref_cnt unmatch issue in TQM bypass mode
The reference counter will be increased after using peer find by
id API. So the unreference operation must be performed whenever
the peer which is returned by this API is released. Fix one peer
ref_cnt unmatch issue in TQM bypass mode.

CRs-Fixed: 2348316
Change-Id: Icae09b351315f38d9b7521b29c0e930339c9f83a
2018-11-19 08:04:11 -08:00
Vivek
0844327b5e qcacmn: Remove unused and duplicate members from vdev_start_params
Remove the unused fields from WMI unified vdev_start_params structure.
The channel information duplicated in vdev_start_params and
it sub structure channel is removed and all implementations
can use the channel sub structure directly.

Change-Id: I47cf4c4223111b6f564ec8336dbfcda4592e8e0c
CRs-Fixed: 2350505
2018-11-19 03:19:44 -08:00
Lin Bai
fba89964c1 qcacmn: Fix unresolved function compiler error
reset_control_get not defined without CONFIG_RESET_CONTROLLER, use
reset_control_get_optional instead accordingly.

Change-Id: Ibd1c68a2fe8f063dffb556b4c0e49eca96eb0b86
CRs-Fixed: 2350601
2018-11-18 22:08:04 -08:00
Lin Bai
e4599388bd qcacmn: Fix variable uninitialized compiler error
Initialize revision_id to avoid compiler error as
'variable may be used uninitialized'.

Change-Id: Ia76b297e0f0f745284c7d0ede72a55dcc3d0dc65
CRs-Fixed: 2350601
2018-11-18 22:08:01 -08:00
Karunakar Dasineni
700ad73754 qcacmn: WAR for duplicate buffers in monitor mode
WAR to discard duplicate indications (buffers and link descriptors)
from monitor DMA seen sometimes on RXDMA2SW ring.

Change-Id: I687b782f54fbbf85ae932ee833ac9263b5879ca6
2018-11-17 10:48:13 -08:00
Abhinav Kumar
45cff82c5f qcacmn: Block all new scan during suspend mode
After driver suspend some thread can still queue scan req
which will cause scan during suspend and WOW_ENABLE received
while SCAN in progress.

TO avoid this block all new scan during suspend.

Change-Id: I02ddc9b5e6ba5f1782d00e34f044ace34c54d0b0
CRs-Fixed: 2343385
2018-11-17 03:25:31 -08:00
Bala Venkatesh
b966910cb6 qcacmn: Add BSS peer for P2P client mode
Set bss peer for both STA and P2P client mode.

Change-Id: Ic25e48930511ff6c6e3af8c9bbdb9425ec654f04
CRs-Fixed: 2332938
2018-11-17 01:59:13 -08:00