Commit Graph

17823 Commits

Author SHA1 Message Date
gaurank kathpalia
71562069e1 qcacld-3.0: Fix combined weight issue in ACS
Currently the driver calculates the best channel
amoung the given spectrum and uses logic to select
best frequency amoung the BW members, but the logic
to maximize the weight before selecting the min
weight is wrong, and must be done after the selection
of the minimum weight frequency.

Fix is to maximize the weight after the minimum weight
channel is selected.

Change-Id: Ie196462fbcc4215e6eb655168d07305110ff0ee7
CRs-Fixed: 2578582
2019-12-03 15:00:24 -08:00
nshrivas
91f22a0bb7 Release 5.2.0.159L
Release 5.2.0.159L

Change-Id: Ice29b711c963b89255f84139b1a6f4a01bc0b5ca
CRs-Fixed: 774533
2019-12-03 13:10:46 -08:00
Wu Gao
202154866b qcacld-3.0: Get rx chainmask by mac phy capability
Since there is change in FW and doesn't provide rx chaimask 2G on phy0
and rx chainmask 5G on phy1, so add this change to get rx chainmask
2g/5g based on mac phy capability.

Change-Id: I99d5f21c7a8033adc75f3b21e3b486628da3a40f
CRs-Fixed: 2574148
2019-12-03 13:10:46 -08:00
Sourav Mohapatra
fab026a99a qcacld-3.0: Send RTT capability for STA mode
Based on the ini gfine_time_meas_cap, send enable/disable value to the
firmware for STA INITIATOR/RESPONDER mode using VDEV set param.

Change-Id: Idd4142e13061cd1af992bda88d0a0b81edc42fef
CRs-Fixed: 2574050
2019-12-03 13:10:29 -08:00
nshrivas
09db9462f7 Release 5.2.0.159K
Release 5.2.0.159K

Change-Id: Ib87f1d1ccabce37931eb73137c6da34abfeb3db4
CRs-Fixed: 774533
2019-12-03 08:05:50 -08:00
Sourav Mohapatra
b1c97cc483 qcacld-3.0: Change logging priority for offload logs
Currently in the driver, the checks performed before NS and ARP offload
to determine whether they are necessary or not, resulted in prints to
the kernel logs.

Change the above logging level to debug.

Change-Id: Ib039ee51d2763ab2a1340d2a4b17a85c530f68fa
CRs-Fixed: 2578328
2019-12-03 08:05:49 -08:00
nshrivas
63d6ddbaad Release 5.2.0.159J
Release 5.2.0.159J

Change-Id: Icbfeaa0f34cfea7c379777e5eaa49eebd88f6f1a
CRs-Fixed: 774533
2019-12-03 01:15:00 -08:00
Abhinav Kumar
d453c18981 qcacld-3.0: Enable roaming based on conn status in case of STA + STA
In case of STA + STA, If first STA (say STA1) is in connected state
and second STA (say STA2) has multiple candidate APs for connection,
STA2 tries connection with each APs one by one till either
successful a connection or no AP left to initiate connection.

Currently, If STA2 initiate connection with first candidate, and if
it fails, STA2 enables roaming on other interfaces (here STA1)
irrespective of connection status. This results, after connection
failure of STA2 with first AP, STA1 gets permission to start roaming.
So there could be a possibility that STA1 started roaming on VDEV0
and STA2 started connection with next AP on VDEV1 which results in
two VDEV start/re-start at the same time in FW.

Fix is to allow roaming on other interfaces only after if association
is successful or all possible candidates APs are tried by current
interface.

Change-Id: I5b765d5a8ffc10ad2903d746537e41501890ca8b
CRs-Fixed: 2577368
2019-12-03 01:15:00 -08:00
nshrivas
98a65e2167 Release 5.2.0.159I
Release 5.2.0.159I

Change-Id: I6424740e998bfe12d2884b49ad8c1c0041922d84
CRs-Fixed: 774533
2019-12-02 22:36:48 -08:00
Jianmin Zhu
a9c1b38b62 qcacld-3.0: Failed to add PMF required AP into LFR3 channel map
PMF info isn't filled in scan filter when find AP in scan
cache to build LFR3 channel map.

Change-Id: Ibacf0ee6534298415f97fc42e5223b7d85f203e0
CRs-Fixed: 2571777
2019-12-02 22:36:47 -08:00
nshrivas
68d802c271 Release 5.2.0.159H
Release 5.2.0.159H

Change-Id: I62448dfa453d9340a15ed9c95f7e81f82fc1cf09
CRs-Fixed: 774533
2019-12-02 12:39:08 -08:00
Abhishek Singh
91562fa4be qcacld-3.0: Free connected profile, roam info etc during HB failure
In case of disconnect from peer or HB failure the connected profile,
roam info etc are not freed. So connected BSSID is still present in
sme session.

Now in STA+STA case if the vdev0 STA connect to a BSSID say AP1 and
then disconnect due to HB failure. Now if the 2nd vdev1 STA connect to
AP1 and again disconnect due to HB failure, in
csr_roam_chk_lnk_deauth_ind it will try to find the session using
BSSID, but as vdev0 BSSID is not yet deleted it will get the vdev0
vdev id and continue the process on the wrong BSSID.

This result in actual CSR session in connected state for the vdev1
but all other layer in disconnected state.

Now if a connect request is received on vdev1 again, as CSR is
connected state it lead to reassoc req to LIM and lead to out of
sync issues.

To fix this free connected profile, roam info etc during peer
initiated disconnects. Also ignore the BSSID if a vdev is already
connected to it.

Change-Id: I0f862259dc297217c7b9ecd5d1521a8ded2aadc3
CRs-Fixed: 2577795
2019-12-02 12:39:08 -08:00
hqu
bcd0a8f349 qcacld-3.0: Clear wlan_reg_freq_to_chan
Clear wlan_reg_freq_to_chan in is_dfs_unsafe_extra_band_chan,
refine unsafe_channel_list for hdd_context to store frequency.

Change-Id: I48a75e053228b202122633a32e750f446f839ea3
CRs-Fixed: 2574028
2019-12-02 12:38:55 -08:00
nshrivas
3fac0ecfcd Release 5.2.0.159G
Release 5.2.0.159G

Change-Id: I53286c495eaab0af95712b2065f8fe9be298f6cc
CRs-Fixed: 774533
2019-12-02 07:19:10 -08:00
hqu
e947f6524f qcacld-3.0: Clear wlan_reg_freq_to_chan
Clear wlan_reg_freq_to_chan in csr_scan_filter_results.

Change-Id: I4c6815171f51790a795af3635c924225cdf5ac35
CRs-Fixed: 2570951
2019-12-02 07:19:10 -08:00
nshrivas
86e54350b3 Release 5.2.0.159F
Release 5.2.0.159F

Change-Id: Ifa5b57d1ddafdf034f37c5ab87881aba50f13e00
CRs-Fixed: 774533
2019-12-02 02:08:36 -08:00
Jia Ding
8d4db30812 qcacld-3.0: Add dual STA support in WLAN IPA component
Currently dual STA is not supported in WLAN IPA component,
where first STA interface info will be overridden by second
STA including iface_ctx and interface registration to IPA
driver.

When second STA is switched to SAP and a ref-client is
connected to SAP, IPA datapath will be enabled for Wifi
sharing feature. But wlan0 interface is not registered
to IPA driver and this will lead to packet drops for
STA on the RX IPA exception path. IPA driver relies
on information such as vdev_id wlan driver registered
to correctly set skb->cb[0] and wlan driver uses
skb->cb[0] to find the correct vdev to pass packets up
to stack. Since STA interface info is not in IPA,
vdev_id for RX exception packets are thus wrong.

Fix is to store multiple STA interfaces in iface_ctx
and all of them are registered to IPA driver.

Change-Id: I745618c22e24b6c56719f8ae5faf653f55b99bca
CRs-Fixed: 2573567
2019-12-02 02:08:35 -08:00
nshrivas
57e608a9ad Release 5.2.0.159E
Release 5.2.0.159E

Change-Id: I5624b8f622f389b3d3f54fbacb128a9ec7081564
CRs-Fixed: 774533
2019-12-01 22:00:50 -08:00
Sravan Goud
90c34e58ff qcacld-3.0: Avoid 64 bit division for 32bit targets compatibility
In function wlan_hdd_rx_rpm_mark_last_busy math division is performed
on unsingned 64bit integer. This leads to driver load failure on 32
bit machine targets. So avoid the math division for 64bit integer.

Change-Id: I967a0a64b421b47113821e1af5379cdd0125a34d
CRs-Fixed: 2576125
2019-12-01 22:00:50 -08:00
nshrivas
94ac0e3fa1 Release 5.2.0.159D
Release 5.2.0.159D

Change-Id: I65faeb76a9829d947abf9c6bebbec561b647ff37
CRs-Fixed: 774533
2019-12-01 17:40:55 -08:00
Nirav Shah
fb9b1df409 qcacld-3.0: Add logic to bundle packets for HL
Add logic to queue and bundle packets before
giving it to scheduler to ensure predictive HTC
bundling for improvement in TX throughput.

Change-Id: Ib00135ca59b4c5f0f05edc93dca115bf17174a36
CRs-Fixed: 2561671
2019-12-01 17:40:55 -08:00
Abhishek Singh
f37d49f5b4 qcacld-3.0: Rename sessionId of struct tagSmeCmd to vdev id
Rename sessionId of struct tagSmeCmd to vdev id

Change-Id: I3b0d9c1f7e173e4f45bd3d0a29df6ab7dd0de64d
CRs-Fixed: 2575198
2019-12-01 17:40:42 -08:00
Arun Kumar Khandavalli
0c9d5017c3 qcacld-3.0: Initialize the stop bss work in the adapter
In the latest kernels asserts if there is any unitialized work
gets flushed, stop_bss work is presently getting flushed from
multiple places and it is initialized only when there is no
channel to start the sap.

Fix it by intializing the work when the adapter is created.

Change-Id: I232247c2389f865471c7c2175bb93e254b29fc29
CRs-Fixed: 2565974
2019-12-01 17:40:28 -08:00
Subrat Dash
9ba2ff8162 qcacld-3.0: Add support to restart TSF cap when traffic resumes
When the chip is in power save mode, it fails to report valid
TSF in the WMI_VDEV_TSF_REPORT_EVENT_ID. Even the retry may fail.

Fix this by restarting the capture when the Tx/Rx resumes.

Change-Id: Ibd0aa9275583ba40e5f53a11910960351bb76e7d
2019-12-01 17:40:14 -08:00
tinlin
9abd17fe45 qcacld-3.0: Add debugfs for MIB statistics
Define debugfs node in driver to
export MIB counters to user app.

Define macro WLAN_FEATURE_MIB_STATS for this
feature that gets MIB statistics from fw.

Change-Id: Icae8826309094d17e8f6d4503f617a3a7116d3c9
CRs-Fixed: 2548241
2019-12-01 17:39:59 -08:00
Srinivas Dasari
b24bdd3f73 qcacld-3.0: Consider NAN enabling also as connection in progress
There is a race condition while handling the below scenario,
1. NAN enable request is received from framework.
2. Policy mgr opportunistic timer expired and set hw mode
   initiated to Single MAC mode in scheduler thread at
   the same time

As the opportunistic timer handler doesn't have any info if
NAN enable initiated in DBS mode, it's configuring the hw
mode to Single Mac Mode just before NAN enable request is sent
to firmware. So the NAN enable request is sent to firmware in
Single Mac Mode which is not allowed by firmware.

NAN enable/disable is also similar to connection in progress
status in case of STA. So provide NAN enable/disable status
through hdd_is_connection_in_progress() to the opportunistic
timer handler. Opportunistic timer handler restarts the timer as
connection(NAN enable/disable) is in progress.

Also set hw_mode_change_in_progress before checking the
connection progress status. This is to avoid a possible race in
the below scenario,
1. NAN-enable sets the state but scheduler thread had read the
   state just before that
2. NAN-enable read the hw_mode_change_in_progress just
   before it gets set by scheduler thread.

Change-Id: I1a184c84520deb3f6ad1ec010a0fdefda96a5364
CRs-Fixed: 2566841
2019-12-01 17:39:45 -08:00
nshrivas
c04d699a6d Release 5.2.0.159C
Release 5.2.0.159C

Change-Id: I0776032899be6db5d56763bf6aadcabb48ccf13d
CRs-Fixed: 774533
2019-12-01 13:10:49 -08:00
Gururaj Pandurangi
847342e013 qcacld-3.0: Remove logs in csr_nonscan_active_ll_peek_head
Remove logs in csr_nonscan_active_ll_peek_head to prevent
excessive logging while testing CVE-2017-0624

Change-Id: Ie5ab57d36fc05a3eac0d4fdba33a72b11eb7c561
CRs-Fixed: 2573914
2019-12-01 13:10:49 -08:00
Abhishek Singh
a827b4e71b qcacld-3.0: Don't Update limMlmState in invalid state in set key resp
In case set key is sent to firmware and Roaming updated the session
before set key resp is processed in LIM, the limPrevMlmState will
be 0 and thus updating limMlmState to limPrevMlmState will result
in improper limMlmState, leading to sync issue.

So do not update the limMlmState in invalid state in set key resp.
Also update limPrevMlmState to limMlmState during roaming.

Change-Id: I96291e7c3eb34df8b5741745448c76cf63b1f200
CRs-Fixed: 2574731
2019-12-01 13:10:34 -08:00
nshrivas
17482ca893 Release 5.2.0.159B
Release 5.2.0.159B

Change-Id: I02578fd1c624f6aa829dded3a6fb7d34146a84be
CRs-Fixed: 774533
2019-11-29 06:16:33 -08:00
Abhinav Kumar
8fb17305d1 qcacld-3.0: Make call to cfg80211_ap_stopped() conditional
cfg80211_ap_stopped() not supported anymore for kernel 5.4.
changes added to protect call to cfg80211_ap_stopped under kernel
version compilation flag.This will allow the call to be invoked for
MSM kernels which have been patched, but not for any other kernels,
including the GKI kernels.

Change-Id: I05470469eb82da174e5b9c46f7d19fc77aaca85d
CRs-Fixed: 2558981
2019-11-29 06:16:32 -08:00
hqu
a07736a6da qcacld-3.0: Clear wlan_reg_freq_to_chan
Clear wlan_reg_freq_to_chan in csr_fill_bss_from_scan_entry.

Change-Id: I06b2eef0f1c965466c1ec67edd3ea48db07dddc7
CRs-Fixed: 2570933
2019-11-29 06:16:20 -08:00
Abhishek Ambure
a7f1c222a9 qcacld-3.0: Set RSN capability flag for SAP peers
Peer assoc command send to firmware updates  peer params in
firmware ex. peer_new_assoc, peer_associd, need_gtk_2_way etc.

If RSN capability flags are present in peer assoc request of SAP and
P2P-Go peers, host updates need_gtk_2_way, need_ptk_4_way peer assoc
params to firmware.

If need_gtk_2_way, need_ptk_4_way params are not updated for RSN capable
peers of SAP/P2P-Go, firmware is not able to hanlde data packets(HTT)
before the key installation(WMI) is successful.

Change-Id: I0a24aab3ac4ff4ca061782f6a4d0ba62dd227b04
CRs-Fixed: 2575133
2019-11-29 06:16:09 -08:00
nshrivas
92cf14d5f5 Release 5.2.0.159A
Release 5.2.0.159A

Change-Id: Ida4ada23bfe4d93dbb78a8eb4fce57507bf928bb
CRs-Fixed: 774533
2019-11-27 21:17:48 -08:00
Abhishek Ambure
95093b55d7 qcacld-3.0: Update number of TIDs supported
Host configures number of TIDs supported by in WMI_RESOURCE_CONFIG
command.

Firmware supports 8 TIDs per peer, with the existing formula to
calculate num_tids_supported i.e. 2 * (no_of_peers_supported is 32 +
num_vdevs is 4 + 2) firmware can allocate max 76 TIDs. As 76 TIDs are
not enough to serve 32 peers, as a new peer requests to allocate TID
after 76th TID, firmware crash is observed.

example as, SAP is running in DUT and 7 clients are conneted, connect
DUT STA to AP. Here total number of peers are 10 and required TIDs 80
i.e number of peers(10) * TIDs per peer(8) = 80, which exceeds limit of
76 number of TIDs configured at the initialization.

Hence, Host enlages the number of TIDs supported for Low Latency targets
i.e. USB or SDIO based solutions. Host calculates max number of TIDs
supported as follows,

num_tids_supported = (8 * no_of_peers_supported + num_vdevs + 2)

Change-Id: I024e03e4ac46f8118da544889de3ffd7cc67a1b4
CRs-Fixed: 2573130
2019-11-27 21:17:47 -08:00
nshrivas
18a2e2ece6 Release 5.2.0.159
Release 5.2.0.159

Change-Id: Idd9c156a0d63cffdf29bed58bf084e0a09413271
CRs-Fixed: 774533
2019-11-27 14:15:41 -08:00
Nirav Shah
3c677d7708 qcacld-3.0: Display FW rx_ovfl_errs count in txrx stats
Display FW rx overflow count in txrx stats.

Change-Id: I53afeb03303b8ee0df9d906d7a8de1d916c6c143
CRs-Fixed: 2571542
2019-11-27 14:15:41 -08:00
Liangwei Dong
17b35c18f9 qcacld-3.0: Remove op_chan and wlan_reg_freq_to_chan
Remove unused op_chan local variable. Remove call to
wlan_reg_freq_to_chan.

Change-Id: I351fe9df7f419fe9345dce73c948d34a73bfcc8a
CRs-Fixed: 2940016
2019-11-27 14:15:28 -08:00
nshrivas
67f98a07a8 Release 5.2.0.158Z
Release 5.2.0.158Z

Change-Id: Ib22bf466fe5f0b7ea0e82d7f2a8344f75d6f39ea
CRs-Fixed: 774533
2019-11-27 13:01:08 -08:00
Lin Bai
d3557ff59f qcacld-3.0: Eliminate trivial warn-level print
Eliminate unnecessary warn-level print in
sch_set_fixed_beacon_fields().

Change-Id: I9ccaa077ee522665df4554f1a2c6be636d69804a
CRs-Fixed: 2574158
2019-11-27 13:01:07 -08:00
nshrivas
0792dd15bd Release 5.2.0.158Y
Release 5.2.0.158Y

Change-Id: Iac0dd247657cd6a975c16627eb4696acfaab167e
CRs-Fixed: 774533
2019-11-27 07:04:34 -08:00
wadesong
d8a7719df3 qcacld-3.0: Convert CSR legacy channel ID usage
1) Change the following functions to make them use channel
   frequencies intead of channel IDs:

   csr_process_roam_sync_callback
   csr_save_to_channel_power2_g_5_g
   csr_save_tx_power_to_cfg

2) Remove some local variable and code within function
   csr_save_tx_power_to_cfg as they're not used.

3) Retain the code for channel ID utilization within
   csr_get_channel_power_info as they're used to
   indicate diag info to upper layer apps.

Change-Id: Ib294fd04f770c008afaa0049fb1951aa912caf34
CRs-Fixed: 2573403
2019-11-27 07:04:33 -08:00
nshrivas
e5388d1ca9 Release 5.2.0.158X
Release 5.2.0.158X

Change-Id: Ia5f621f2c8d723ba3f380139791b0371f70d713d
CRs-Fixed: 774533
2019-11-27 05:37:47 -08:00
Ajit Pal Singh
f9e06bcb45 qcacld-3.0: DP: HL: Use netif_rx_ni to hand over packets
On HL systems use netif_rx_ni to hand over packets to network stack.

Change-Id: I14f9e50d74a6aca44c74e97c07372d391ada9aa9
CRs-Fixed: 2574352
2019-11-27 05:37:46 -08:00
Ajit Pal Singh
4c8f6720a1 qcacld-3.0: Kbuild: Do not enable SG and RX_THREAD_PRIO for QCN7605
Do not enable CONFIG_FEATURE_SG and CONFIG_RX_THREAD_PRIORITY for QCN7605

Change-Id: I3320e863dfbe427e326890d2f1d2ccfb2ea04db7
CRs-Fixed: 2574197
2019-11-27 05:37:34 -08:00
nshrivas
cc971f716c Release 5.2.0.158W
Release 5.2.0.158W

Change-Id: I088521cc71b15fa9d2cc213a1c0d87e796f71abb
CRs-Fixed: 774533
2019-11-27 04:17:03 -08:00
Saket Jha
a842ded897 qcacld-3.0: ndo_select_queue support for 5.4 kernel
In the 5.4 Linux kernel, the ndo_select_queue function signature has
changed. Add support for it under the kernel version compilation flag.

Change-Id: I7298f27ada14c0d96c19f5168a20971ad760fd77
CRs-Fixed: 2558984
2019-11-27 04:17:03 -08:00
Liangwei Dong
b5e89852ab qcacld-3.0: Fix Memory leak sta_ap_intf_check_work_info
At present policy_mgr_check_concurrent_intf_and_restart_sap
will allocate memory for sta_ap_intf_check_work_info for each
work scheduling of sta_ap_intf_check_work. Potential race condition
would be the pm_ctx->sta_ap_intf_check_work_info is overwritten
in other thread context which is calling same function.
It is not necessary to maintain the memory
sta_ap_intf_check_work_info dynamically since only one work
sta_ap_intf_check_work is expected to run at same time.

Move the sta_ap_intf_check_work_info memory allocation to
psoc open handler and free it when psoc close.

Change-Id: I29b2f2528a6d537cb853968153340a75fd5fe88b
CRs-Fixed: 2571624
2019-11-27 04:16:41 -08:00
nshrivas
1b3b9c352d Release 5.2.0.158V
Release 5.2.0.158V

Change-Id: I783f89265752283fb14f733651c4c50fe13530dd
CRs-Fixed: 774533
2019-11-26 23:19:15 -08:00
Min Liu
71abe09ede qcacld-3.0: Return error when invalid channel is set for SAP
For the vendor command QCA_NL80211_VENDOR_SUBCMD_SET_SAP_CONFIG,
if invalid channel is specified, wlan driver return success.
It should return error for such case.

Change-Id: Ic5dbfaf04a41ee75b97ecba52a577e9ebf78dc05
CRs-Fixed: 2573244
2019-11-26 23:19:15 -08:00