Grafik Komit

12812 Melakukan

Penulis SHA1 Pesan Tanggal
Pragaspathi Thilagaraj
d86c555e6a qcacmn: Add new reason code to TWT setup response
Add new reason code WMI_HOST_ADD_TWT_STATUS_SCAN_IN_PROGRESS
to handle add dialog rejection due to scan is in progress
at firmware.

Change-Id: I30c3d1096690bd0cb7a669206f087e006c23ea44
CRs-Fixed: 2923289
2021-05-01 17:43:34 -07:00
Adwait Nayak
9eb3468a87 qcacmn: Handle non-inhertance IE scanning
The earlier logic for scanning non-inheritance IE fails if
non transmitted bssid profile has any extension element
such as MU EDCA before the extension element with
non-inheritance IE.

Since MU EDCA is also an extension element and it does not
have noninheritance element id in it, the logic used to fail
as the driver does not check further for any other extension
element ID in non transmitted bssid profile. Because of this
the IEs part of non-inheritance list used to get inherited,
causing disconnection issue.

With current fix, the scanning for non-inheritance IE has been
taken care properly. Driver will go through the non transmitted
bssid profile until it finds the extension element with
non-inheritance element ID in it.

Change-Id: Ib4346600a880a8390c6d023cf403ed18c62406d2
CRs-Fixed: 2935065
2021-05-01 02:47:32 -07:00
Gururaj Pandurangi
57e7a0bcc7 qcacmn: Add country code check for ETSI dmn
Add country code check for ETSI domain, in other words
UK, since only UK supports 6G in EU as of today. The
TPC power calculation API calls this function to check
if programmed ctry is GB to allow STA to use VLP mode.
As and when more EU countries support 6G, the checks
will be appended to this API.

Change-Id: If985f3f64fc806cf1875f798ff3a86667a0861b8
CRs-Fixed: 2933678
2021-04-30 23:51:23 -07:00
Wu Gao
672bbe5490 qcacmn: Get vdev based on vdev id
Driver gets vdev by wlan_objmgr_pdev_get_first_vdev and returns wrong
vdev in some platforms, and then gets wrong channel/phy_mode. This
change gets vdev by id and fix this issue.

Change-Id: I814d516361238afbd0345bc362c286d1cb55a7d4
CRs-Fixed: 2933525
2021-04-30 16:51:06 -07:00
Amir Patel
ef543f271e qcacmn: Reset MON_BUF ring filters only when monitor mode is enabled
When enhanced stats are enabled/disabled, dp_mon_filter_update () API
sets/resets MON_BUF ring filters also, this is leading to connection issues
traffic stall on Rx side

Set/Reset MON_BUF ring filters when monitor mode is enabled

Change-Id: I0de7be81465b11224b95c0918b4e8c8e339e3802
2021-04-30 14:47:03 -07:00
sandhu
49846e25ef qcacmn: Add start sequence update count to rx stats
add ssn_updates_count to dp_soc_stats rx err stats.
Also add bar fail count on rx tid update during
bar handling.

Change-Id: Ic9a963c8d29ace2087e63cba56bc0d7e40907e1a
CRs-Fixed: 2918806
2021-04-29 21:07:07 -07:00
Yeshwanth Sriram Guntuka
43e51ba3d8 qcacmn: Do not add nbuf to emerg_nbuf_q on free when not initialized
When nbuf is freed via dp_rx_buffer_pool_nbuf_free, the
nbuf is enqueued to emerg_nbuf_q always even in the case
where the emerg_nbuf_q is not initialized. This will result
in NULL pointer dereference when any nbuf is enqueued to
emerg_nbuf_q.

Fix is to add initialization check before adding the nbuf
to emerg_nbuf_q and free the nbuf if emerg_nbuf_q is not
initialized.

Change-Id: I075b3b93203eec21d44ea3967b5f46d59c291a14
CRs-Fixed: 2934593
2021-04-29 17:40:39 -07:00
Chaithanya Garrepalli
970948916a qcacmn: print backpressure stats in work queue context
Avoid backpressure event prints in irq context and
defer work queue context

Change-Id: Ib68237d6a9930ead38f53aa89ec1d9e9a2f4147d
2021-04-29 14:29:33 -07:00
Utkarsh Bhatnagar
46a4d7c734 qcacmn: Configure Default DBS scan for DBS HW
Previously, for high accuracy scan,
configured scan policy SCAN_DBS_POLICY_FORCE_NONDBS
takes  more time to scan.
For DBS HW, to improve scan time, this should be
changed to SCAN_DBS_POLICY_DEFAULT.

Change-Id: I692e2a8b4fd9c97b526197edc57b830fa091a456
CRs-Fixed: 2927022
2021-04-29 04:37:51 -07:00
Karthik Kantamneni
3bc4b99247 qcacmn: Add support for Rx refill ring history
Add support for Rx refill ring history, maintain records of refill info
during RXDMA ring replenish.

Change-Id: I034014eacfc510ec6f416fca601fa864326de9c2
CRs-Fixed: 2930005
2021-04-29 04:37:47 -07:00
Amit Mehta
4982427333 qcacmn: Rate limit excessive logging in case of HW enqueue failure
Currently, excess logging is causing a crash when enqueuing
of Tx MSDU descriptor to HW failed.

Rate limiting the log messages to avoid the crash.

Change-Id: Ibb230ce03c23518b6f7feda61a49bf155c7ddc69
CRs-Fixed: 2933002
2021-04-29 01:45:27 -07:00
Karthik Kantamneni
dff5788d14 qcacmn: Fix duplicate additon of same WDI events to list
Same WDI subscribe event can be added multiple times to event list
since this is triggered by user control this will result to undefined
behaviour during events handling.

To avoid this add check to detect duplicate entry before adding
to list and reset list elements once removed from list.

Change-Id: Iaf23927f8439d4ac503776b915a8fe8cb6abfec5
CRs-Fixed: 2931068
2021-04-29 01:45:23 -07:00
Vivek
57cacda10f qcacmn: Remove locks from object manager debug API
The object manager global lock is used in few
debug APIs. In these instances the log is taken
only on the local copy and the updates are happening
on the local copy without the lock.

So there is nothing that is protected by taking these locks
and there is also a scenario where this lock is resulting in
deadlock, so removing these locks.

Change-Id: I583de096538a5f9c87cbcfa2b267e82630f3278f
CRs-Fixed: 2930205
2021-04-28 21:38:41 -07:00
Kiran Kumar Lokere
eb4b6bf958 qcacmn: Update the security check mask for 6GHz AP
Update the security check mask value for 6GHz AP.

Change-Id: I8d9637a95c6191124372a7bdba119837e6553ed4
CRs-Fixed: 2930941
2021-04-28 16:42:04 -07:00
Lincoln Tran
3bed44b5cd qcacmn: Update wifi_pos logs to debug
Update some logs in the wifi positioning module to be debug prints.
This helps reduce unnecessary prints in dmesg.

Change-Id: I9828fb4c2360e7d25195130da0315d605c04c14b
CRs-fixed: 2928849
2021-04-28 12:05:13 -07:00
Abdul Muqtadeer Ahmed
3921edb0ae qcacmn: Fix the integer overflow issue
In the assignment of varaible expected_field_info_size with an expression,
there might be an issue of integer overflow.

To fix this issue add a check for the expression with UINT_MAX
before assigning the expression to variable expected_field_info_size.

Change-Id: Iaa58fc164655d5b074eef55f8fd78f83a71e3fdf
CRs-Fixed: 2825846
2021-04-27 16:13:16 -07:00
Adwait Nayak
c2c89243d8 qcacmn: Parse and update qdf module params
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
2021-04-27 16:13:11 -07:00
Shwetha G K
8159fecc91 qcacmn: Update cfr metadata len calculation logic
Separate the common fields of csi_cfr_header and update
the logic of calculating the cfr_metadata_len.
Move cmn header update code to single place.

CRs-Fixed: 2916901
Change-Id: I97d99df45f667f4ed3b80264b12d3d09a3bcae95
2021-04-27 09:14:16 -07:00
Karthik Kantamneni
26086e7971 qcacmn: Add history for REO queue descriptor events
Add history to log REO queue desc update and free events.

Change-Id: If2992ff1256fad49ea4ea6bd90b6dfe4a63d2bc4
CRs-Fixed: 2926919
2021-04-27 09:14:12 -07:00
Shashikala Prabhu
5d097b9e40 qcacmn: Add support to send channel info to WIN LOWI application
In the current code, host does not send the channel list information to
WIN LOWI application. LOWI application populates the TX power in OEM RTT
request frame from the host received channel list information. Since the
channel list was not received from host TX power was set to 0. This was
leading to low RSSI for RTT ack frames.

Send the channel list information of all the PDEVs and PSOCs to WIN LOWI
application  to set a valid TX power.

Change-Id: I9b7d740b37349d092629aa2f9550555901fb4331
2021-04-27 01:15:20 -07:00
Will Huang
aab2fe978c qcacmn: Fix possible spinlock vdev->peer_list_lock recursion
It is possible to hit spinlock vdev->peer_list_lock recursion if
running SSR case, the call stack is as following:
dp_vdev_flush_peers
    dp_vdev_iterate_peer
    qdf_spin_lock_bh(&vdev->peer_list_lock);  -> first time lock
        dp_peer_delete
            dp_peer_delete_wifi3
                dp_peer_vdev_list_remove
                    qdf_spin_lock_bh(&vdev->peer_list_lock) ->
lock again in same thread.

Replace it with dp_vdev_iterate_peer_lock_safe.

Change-Id: I40fe492d43b376b404b855a7e86aa2cd66ba1d22
CRs-Fixed: 2926284
2021-04-26 22:54:27 -07:00
Rajeev Kumar
034e1c4507 qcacmn: Add INI file parse success and failure logs
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
2021-04-26 20:37:14 -07:00
Manikanta Pubbisetty
9f6ccf3fe6 qcacmn: assert on IPA SMMU map/unmap failures
The status of the IPA SMMU MAP/UNMAP operation is stored in the
result field of the mem info structure that is passed to the
IPA driver. Currently, this field is not checked for MAP/UNMAP
failures; when IPA HW accesses such a buffer for which
mapping is not correctly setup, it will lead to SMMU faults.
Check the result and assert(on failures) to avoid such issues.

Also, check if the physical address passed to the IPA driver is
non zero value.

Change-Id: Iec0702bdf4a07ea37e1213a33dc970028da654df
CRs-Fixed: 2928744
2021-04-26 12:23:40 -07:00
abhinav kumar
28138b7558 qcacmn: Don’t consider PCL weightage for STA iface
In case of one STA interface is active and/or the
secondary is about to come up. If host receives
CONCURRENT_DUAL_STA_POLICY vendor command with policy
PREFER_PRIMARY. Then don’t consider PCL weightage for
all subsequent STA connections. Due to this host/FW
allows all subsequent connections with the best
available candidate (either in DBS, SCC or in MCC).

Change-Id: Id200e1011ef8560b763ec1cbc3664666da6d395f
CRs-Fixed: 2915748
2021-04-26 10:01:49 -07:00
Jingxiang Ge
5b31c536c4 qcacmn: trigger recovery in hif_check_detection_latency
Replace as qdf_trigger_self_recovery here, so it can trigger
fw dump firstly.

Change-Id: I39e3bc11829a1969ac60bd3bbd71f3e2d1fa4f43
CRs-Fixed: 2928096
2021-04-26 00:17:53 -07:00
Jingxiang Ge
4cb1ee5c0c qcacmn: Add vendor hang reason code for tasklet/credit latency
Define a new reason code in enum qca_wlan_vendor_hang_reason,
QCA_WLAN_TASKLET_CREDIT_LATENCY_DETECT, for tasklet/credit latency
detection.

Change-Id: I4852fc22f57d14d6eac30ddfd8361f2a63326981
CRs-Fixed: 2929164
2021-04-26 00:17:48 -07:00
Alan Chen
61161d0a6e qcacmn: Increase periodicity of LOG_DEL_OBJ_TIMEOUT_VALUE_MSEC
obj_mgr_alert() function is currently used in
wlan_objmgr_iterate_log_del_obj_handle() to print and is causing
spinlock to be held too long and timing out. Thus, increase the
periodicity of LOG_DEL_OBJ_TIMEOUT_VALUE_MSEC to 10 seconds.

Change-Id: I00fb3a468d6035856efe07c08299c471f72ba863
CRs-Fixed: 2928906
2021-04-23 22:46:38 -07:00
Ashish Kumar Dhanotiya
70c3875209 qcacmn: Fill bonded_chan_ptr correctly
Driver does not update bonded_chan_ptr correctly in
reg_get_320_bonded_chan_array api which may lead to undefined
behavior.

To address above issue, fill bonded_chan_ptr correctly.

Change-Id: I13ffe96ad855dbf97b72f32e982c73322a29626f
CRs-Fixed: 2929853
2021-04-23 12:54:51 -07:00
Pragaspathi Thilagaraj
a9ba1ebb26 qcacmn: Add vendor reason code for TWT setup reject due to scan in progress
The firmware rejects the TWT setup request when scan is in
progress. Extend enum qca_wlan_vendor_twt_status to represent new
reason code for it.

Change-Id: I8576d8cce2fac62d9e3cf020a3dadee06ec14d5c
CRs-Fixed: 2923272
2021-04-23 10:49:15 -07:00
Amir Patel
fda11e2e76 qcacmn: Configure monitor rings for special vap case
configure monitor ring for special vap case

Change-Id: Idebcfecf61dceb2cad5b7ea07297b5f682778c43
2021-04-23 06:43:05 -07:00
Deeksha Gupta
34fcba4a4a qcacmn: Avoid excessive kmsg log in target_spectral
Sometimes firmware sends spectral events repeatedly with
wrong vdev. This causes continuous error logs are
written to kmsg.

Replace info prints in target_if_consume_spectral_report_gen3()
with debug level prints.

Change-Id: I2ca4be7d0d13e841a6dbd4efbc02ecd2b12893f8
CRs-Fixed: 2926759
2021-04-23 04:36:06 -07:00
Ananya Gupta
304d6b1fe5 qcacmn: Add enum for FISA flow table
Moving FISA flow table to prealloc.
Create a context type for FISA Flow table.

Change-Id: Iaf3f4bd66c2c73a5ba38ae6baf914ff2a1b900ac
CRs-Fixed: 2928697
2021-04-23 02:06:07 -07:00
Subrat Dash
6e6fa7db85 qcacmn: Use SA based address lookup for station mode
The dp_tx_da_search_override API wrongly returns DA based
address lookup instead of SA based for station mode when
FEATURE_WDS build flag is enabled.

Fix dp_tx_da_search_override API to return SA based
address lookup for station mode.

CRs-Fixed: 2924299
Change-Id: Ibb0c2a6df5f73fd5a361900036316375fc29dbbd
2021-04-22 23:56:28 -07:00
Abhishek Singh
7f449d83f1 qcacmn: Add null pointer handling in cm_get_first_roam_command
Add null check for the cm_ctx in cm_get_first_roam_command.

Change-Id: I1c9a666d845936e24c87d5560b158febb9ccc854
CRs-Fixed: 2929651
2021-04-22 23:56:24 -07:00
bings
8144d64a26 qcacmn: Set NOL left time as 0 in print nol if it is negative
In some platform the timer is not precise. NOL timer may take more
than expected. During this time When print nol is called, NOL left
time is negative.

Set NOL left time as 0 in print nol if it is negative.

Change-Id: Ic6aec5f7ee080625adb39ae75785a271ad782f6c
CRs-Fixed: 2926548
2021-04-22 21:59:32 -07:00
Ananya Barat
b76f24187d qcacmn: Do not start Spectral Scan if RCAC is enabled
Agile scans (preCAC/RCAC) use the Agile Engine which is also needed
for the Agile spectral scan. Hence, both cannot run at the same time.

Currently, if Agile preCAC is enabled, Agile spectral scan is not
started. Do not start the spectral scan if either RCAC is enabled or
preCAC is enabled.

Change-Id: I242c28c2c3f8872ceab6314dde80361c283d3ac1
CRs-Fixed: 2922250
2021-04-22 21:59:27 -07:00
Kiran Kumar Lokere
10ec6a98fd qcacmn: Fix the issue with OWE AP scan in 6GHz
Check the RSNXE IE presence only for SAP key mgmt type.

Change-Id: I3c9df627589e351a30dc9899ccaa7f24e9516965
CRs-Fixed: 2924842
2021-04-22 19:43:28 -07:00
abhinav kumar
7bb4eb806a qcacmn: Vendor command to config concurrent STA connection policies
Introduce a QCA vendor command to configure the concurrent connection
policies when multiple STA interfaces are (getting) active.

Change-Id: I574880e526e4aa8e179b417fbcba6d7e9e9fcfb1
CRs-Fixed: 2915545
2021-04-22 17:34:21 -07:00
Deeksha Gupta
209a75fa6c qcacmn: Convert WMI status code for TWT get_stats
Convert firmware enum WMI_GET_STATS_TWT_STATUS_T status code
into host enum WMI_HOST_GET_STATS_TWT_STATUS.

Change-Id: I8fbb497bff11a3629689d6d8e2be5b8c9835b2de
CRs-Fixed: 2923085
2021-04-22 17:34:17 -07:00
Shiva Sankar Gajula
4bdf46d8ed qcacmn: Access wlan_crypto_cipher structure if key->valid flag is set
Access wlan_crypto_cipher structure if the key and cipher_table's
are valid. Also, added changes to avoid dangling pointer accessing
after deleting key.

Change-Id: Ia9a5942c9597f03eb1707d149797f33760eeac21
2021-04-22 15:25:32 -07:00
Shiva Sankar Gajula
7aa318326f qcacmn: Fix to avoid accessing crypto_priv after releasing peer refernce
Adding changes to avoid accessing crypto_priv structure members after
peer reference is released.

Change-Id: I4e1298bff1d05136f0ecd74695719a844b15e19d
2021-04-22 15:25:29 -07:00
Tushnim Bhattacharyya
f9a9545d64 qcacmn: Remove all CONFIG_CHAN_NUM_API instances
Replace below APIs used under CONFIG_CHAN_NUM_API
in DFS module with corresponding channel frequency
APIs as part of regulatory cleanup effort,

dfs_get_bonding_channels
dfs_is_en302_502_applicable
dfs_nol_timer_cleanup
dfs_remove_spoof_channel_from_nol
dfs_tlv_calc_freq_info
dfs_print_radar_found_freq
dfs_compute_radar_found_cfreq

Change-Id: I962449264fa76783ea83b271ca2e5fa67dfe478c
CRs-Fixed: 2916463
2021-04-22 13:13:46 -07:00
Alan Chen
a1aa15b70c qcacmn: Change log level to debug for hif_runtime_lock_init/deinit
To avoid excessive logging, we whould not logs RTPM lock init and
deinit to the console. Thus, change the log level to debug.

Change-Id: Ib11045fe50f729b0580284fa913da48d3a59b323
CRs-Fixed: 2927959
2021-04-22 13:13:42 -07:00
Aditya Sathish
2f02bce0e4 qcacmn: Rate limit MBSSID scan entry generation failure print
If multiple MBSSID beacons fail during scan entry generation,
it can lead to flooding of the console.

Rate limit this print to avoid scheduler timeouts.

CRs-Fixed: 2918649
Change-Id: I71ed2dafcedc7da4be130569776870a2bbb6b28f
2021-04-22 13:13:38 -07:00
Tiger Yu
2cd64402c6 qcacmn: Support IPA WDI 3.0 with two tx pipes
Currently a set of IPA2TCL and WBM2IPA rings is used for
IPA TX data path. Issue is when wlan is configured as
SAP-SAP DBS mode, slow 2G traffic will consume much more
TX resources and thus 5G traffic will have starvation,
which leads to severe degradation of DBS KPI.

Therefore separate IPA2TCL (SW2TCL2) and WBM2IPA (WBM2SW4)
rings are added to support alternative IPA TX pipe for 2G
traffic.

Change-Id: I4b648d0bcacbcde0b9b0a824516c1f06e3b0c7ad
CRs-Fixed: 2750079
2021-04-21 11:03:45 -07:00
Kiran Venkatappa
63e6497955 qcacmn: regtable changes for qcn9224
regtable abstraction changes for qcn9224 target

Change-Id: Idff6814b2c53feb7c80e41801206808bb4855be3
CRs-Fixed: 2916304
2021-04-21 06:32:10 -07:00
Amir Patel
a255cb4196 qcacmn: Avoid enabling full monitor mode if already enabled
Avoid enabling full monitor mode if already enabled

Change-Id: I728105006af497d18174bc7eba33a2508990caa2
2021-04-21 06:32:07 -07:00
Tiger Yu
9ed639bc59 qcacmn: Limit the excessive logging during processing CE completion
The hw_index reading from the DDR by the RRI feature might be not
updated in time which might cause the excessive logging in the dmesg.

Change-Id: Ic9c3648b032ba59a6b7f92d8c27b63cb6a650381
CRs-Fixed: 2919867
2021-04-21 04:23:34 -07:00
Manikanta Pubbisetty
42c4fca998 qcacmn: add runtime PM stats for HTC layer
Runtime PM for HTC layer has multiple cases of GET/PUT operations.
Adding runtime PM stats for HTC layer, this helps in debugging
RTPM GET/PUT out of sync issues.

Change-Id: Ib27efd73dce0bb5bd3ff030bd7ae1bc833f29610
CRs-Fixed: 2923250
2021-04-21 04:23:30 -07:00
sandhu
bdb8bb9c35 qcacmn: Add error handling for ce_init mem allocation
Add error handling for ce_init mem allocation of
alloc_mem_ce_debug_history.

Change-Id: I042799f9966660ab56b53fe707037db2db6b5ddf
CRs-Fixed: 2910841
2021-04-21 04:23:26 -07:00