提交線圖

2843 次程式碼提交

作者 SHA1 備註 日期
Shiva Krishna Pittala
01c079b17b qcacmn: Add handlers for FW consumed and Host dropped MGMT frames
Consider the management frames that are consumed/dropped in the FW and also
the frames that are received at the Host but dropped in lower layers.
The host has the MGMT Rx REO parameters about these frames via WMI events.

There could be frames waiting in the MGMT Rx REO list for the above-said
frames. If we update the waiting frames with the MGMT Rx REO parameters of
the above-said frames, the waiting frames could be released and sent for
processing. Add the logic for the same.

Change-Id: I6be4577d30c4aefe2e964aefbb56472749a90cb4
CRs-Fixed: 2987941
2021-09-17 05:54:06 -07:00
Shiva Krishna Pittala
5d74978e0d qcacmn: Hook MGMT Rx REO algorithm in MGMT Rx path
When a management Rx frame enters the MGMT TxRx component, route it to the
MGMT Rx REO module where the REO algorithm decides whether the frame needs
to be processed right away or need to wait for frames on other links.

Change-Id: Ib7ca911dfaeee131fd71d9a4345f5bc720326228
CRs-Fixed: 2987784
2021-09-17 05:54:01 -07:00
sheenam monga
a554290f06 qcacmn: Fetch fw cap to support p2p + p2p concurrency
Fetch fw capability to support p2p+p2p concurrency and
store cap info in 29th bit of soc_fw_ext_caps.

Change-Id: Id8e4c0310f8db503a2997e8aed5a6f1ce813dcc7
CRs-Fixed: 3032068
2021-09-16 22:58:23 -07:00
Linux Build Service Account
135054f254 Merge "qcacmn: Add bss membership selector defines to wlan_cmn_ieee80211.h" 2021-09-16 12:10:27 -07:00
Will Huang
99e7db2551 qcacmn: Add bss membership selector defines to wlan_cmn_ieee80211.h
These defines are used by Supported Rates or Extended Supported Rates
IE to set additional information beside rate.

Change-Id: I44eac41a9a07d368a6fe3abc76e341915b3249b9
CRs-Fixed: 3034939
2021-09-16 08:28:34 -07:00
Pragaspathi Thilagaraj
b001e0e130 qcacmn: Add support to send connectivity logs from logging thread
Add support to send connectivity logs from g_wlan_logging thread.
Add new HOST_LOG_DRIVER_CONNECTIVITY_MSG event flag which wakes up
the gwlan_logging thread when set.
Also register connection manager callbacks to send the logging event.

Check if logging queue is empty whenever the gwlan_logging thread
is woken up and send the logs to userspace if the count doesn't
exceed the allowed threshold.

Change-Id: I3fdb8358f9048a277e2f03894c0e6a17376b0da0
CRs-Fixed: 3029279
2021-09-16 08:28:29 -07:00
Hariharan Basuthkar
b98c3e9250 qcacmn: Disable intersected AFC channels while switching to LPI
When SWITCH_TO_LPI event subtype or WMI_AFC_EVENT_ID is received,
disable the intersected channels in the AFC channel list.

Change-Id: Iee79b26953299d332c6f8925c8f21651fbd1f00c
CRs-Fixed: 3034456
2021-09-16 05:09:39 -07:00
Himanshu Batra
60d195db92 qcacmn: Reset chan info for ML partner link connect req
Reset chan info for ML partner link connect req

Change-Id: Ib6c456bde8b5e023ae13dd34bf2f3d8d48cc365f
2021-09-15 08:40:33 -07:00
Abhishek Singh
3d7143dc0e qcacmn: Add debug log in case BSS is filtered out due to freq list
Add debug log in case BSS freq is not matching the freq list
provided in scan filter.

Change-Id: I00da614f4a5b4fdf58122cf2750afe5c03114536
CRs-Fixed: 3035787
2021-09-15 06:13:11 -07:00
Ashish Kumar Dhanotiya
5c22ca493e qcacmn: Do not update dfs parameters for 6GHz frequencies
6GHz do not have any dfs channels so do not update dfs related
parameters for 6GHz frequencies

Change-Id: I791622ce4b401bca65f132665eb2a1ebd7c9e931
CRs-Fixed: 3020653
2021-09-14 00:19:43 -07:00
Shiva Krishna Pittala
719e90b6dc qcacmn: Add API to update MGMT Rx REO Host snapshot
MGMT Rx REO algorithm maintains a host snapshot which contains MGMT Rx
REO parameters of the latest frame received by the Host.
Add an API to update the same using the parameters sent by the FW.

CRs-Fixed: 3029489
Change-Id: I7ea574507de4e96407207bcb57319680ae78f7c9
2021-09-13 06:20:19 -07:00
Edayilliam Jayadev
c85bc308e4 qcacmn: Add APIs to handle the reorder list
Add APIs to create/update/destroy reorder list.

CRs-Fixed: 3017570
Change-Id: I74528a7f13db8f48c0fc5c5516ea754caf4b686a
2021-09-13 06:20:13 -07:00
Shiva Krishna Pittala
5bae4f1b26 qcacmn: Add algorithm to compute wait count for an incoming mgmt frame
This is part of the MGMT Rx re-order algorithm for MLO (FR 69196).
Consider an MLD formed by multiple discrete MLO-capable chipsets.
Management frames received on individual links will be forwarded or
consumed by the firmware running on that chip. Each link could have
a variable delay in FW->Host messaging. Host can receive these management
frames in an order different from that in which the frames were received
over the air. This problem could be there in single-chip MLD cases also
due to race between FW threads that are handling management frames.
This FR solves this problem by introducing an REO queue in the MGMT Rx path
which reorders the frames and delivers them to upper layers in the order
in which they were received over the air.

Each incoming frame carries an MGMT packet number which is local to that
link, and a timestamp that is global across all the links. MAC HW and FW
capture the same details of the last frame that they have seen. Host also
maintains the details of the last frame it has seen.
Using all this information, calculate the number of frames an incoming
frame should wait for on all other links before it gets delivered.

Change-Id: Icdf5b9b55b2a360bac2d9ea676671702eade3282
CRs-Fixed: 3028766
2021-09-12 21:58:12 -07:00
Shiva Krishna Pittala
ff4f258129 qcacmn: Add circular arithmetic operations for MGMT Rx REO data
HW uses only 16-bits to represent MGMT packet counter and 32-bits to
represent global timestamp. Overflow is bound to happen with such sizes.
So, Host can't directly use regular comparison and subtract operators on
the REO data sent by the HW. Add support for operations that take
overflow into consideration.

CRs-Fixed: 3028771
Change-Id: I1c280409b023e0783bf05fe68351e071801f59bc
2021-09-12 21:58:07 -07:00
Huashan Qu
77f09f7272 qcacmn: Define rp_rssithresh for QCN7605 chip to different value
In dfs test mode, bandwidth detection test on dfs channel fails
with QCN7605 chip, reason is some pulses will be discarded due to
low rssi reported on some frequency channel, it's different halphy
design for QCN7605 chip, so need to define rp_rssithresh for QCN7605
chip to different value.

Fix is define rp_rssithresh for QCN7605 chip to different value for
FCC/ETSI/JP W56 table which are used for dfs certification.

Change-Id: I9132cf82e6d8d97f83ebb4cd8586f8d8ff48066e
CRs-Fixed: 2986947
2021-09-10 22:29:00 -07:00
Lincoln Tran
50e7e5c6ae qcacmn: Copy assoc IE for MLO link connect
When associating the partner link in an MLO connecting, reuse the
association IEs from the original connection. To do this, store the
connection manager connection request to query later, since this
holds the assoc IE data.

Change-Id: I100351a4c9cd439222af202ca3e80ef50554e1e3
CRs-fixed: 3016095
2021-09-10 20:09:48 -07:00
Vijay Krishnan
4637290552 qcacmn: Remove 6G domain check on Maschan list
If a country does not support 6G, then the 6G channel list is not
appended to the master channel list. Due to this, 6G center frequency
in the master channel list is zero. This leads to the problem in the
intersection of channels and chip range in the 5G Radio.

When the target sends the WMI_REG_CHAN_LIST_CC_EXT_EVENT, do not set
the is_6g_channel_list_populated flag based on the presence of a 6G
subdomain code. The flag should be set to true whenever the event is
received.

Change-Id: Ice714c961512fc1d86f8553b9870ab7385bbe9d5
CRs-Fixed: 3007334
2021-09-08 14:55:38 -07:00
Hariharan Basuthkar
9a9f5974af qcacmn: Break from the loop when EIRP power is filled
In reg_search_afc_power_info_for_freq, break from the loop when EIRP
power is filled.

Change-Id: Id559f4a92fe7945370e6a334b4dc1e7c1d9d7adf
CRs-Fixed: 3031979
2021-09-08 14:55:28 -07:00
Vignesh Mohan
6d3d7d5f11 qcacmn: Enable 149 to 177 HT160 channels in random channel selection
During random channel selection after radar, channels 149 to 177 are
not considered as a potential random HT160 channel after the
introduction of the 5.9G channels. This is because, the last 80MHz
band (165, 169, 173, 177) are not added to the list of 80MHz band
list that is used to find the next random channel.

Update the 80MHz band list with 165-177 and update the band count.

Change-Id: Id881adaa07dab07400435d559940f4bdf837eb75
2021-09-08 03:08:47 -07:00
Adwait Nayak
535fd627c8 qcacmn: Fix memory leak if beacon is corrupted
In case of split profile, while parsing the other segment
of the non transmitted profile present in the subsequent
MBSSID tag, it is possible that the beacon is corrupted where
the non tx profile length has gone out of bound.
In case of above scenario, the MBSSIE parsing code does not
free up the memory allocated for split_prof_start before
returning, which could possibly result into a memmory leak.

Handling the split_profile_continue bit before non tx profile
length check can avoid this situation.

Change-Id: Iaa491fd2803d88759e74ca5a668dddb9f8a42708
CRs-Fixed: 3023554
2021-09-07 18:07:38 -07:00
Vignesh U
cd59d89a50 qcacmn: Reset AFC power event received status
The power event received status is set when AFC power event is received
but is not reset when AFC expiry event received.

Reset AFC power event received status on receiving AFC expiry event.

Change-Id: I6e3415682b682e7a0f5d15a190d4cf72f5ff935a
2021-09-07 07:59:11 -07:00
Hariharan Basuthkar
d386ccb51a qcacmn: Check the num of reg_rules before setting AP power type
In reg_set_ap_pwr_and_update_chan_list, before setting the AP power type
check the number of reg_rules present for the input AP power type.

Change-Id: I3af82cf8b7ff6ed7525b5284390361a618da4140
CRs-Fixed: 3030223
2021-09-06 13:57:54 -07:00
Kiran Venkatappa
03a407cea5 qcacmn: Add API to get pdev object from hw_link_id
Add API to lookup pdev object based on hw_link_id and return this with
reference held. Caller is responsible for releasing the ref

Change-Id: I6e3e371462c0d2a4b590b4a5de5c098a72577827
CRs-Fixed: 3026072
2021-09-06 03:12:28 -07:00
Hariharan Basuthkar
8fbbf2af16 qcacmn: Fix a compilation error in ucfg_reg_get_partial_afc_req_info
Fix a compilation error in ucfg_reg_get_partial_afc_req_info, when
CONFIG_AFC_SUPPORT is enabled.

Change-Id: I9834170b08bd72ee4201284c22211e3b1e5fc560
CRs-Fixed: 3029969
2021-09-04 23:16:19 -07:00
Lincoln Tran
6deace5e8f qcacmn: Remove locking mechanism when getting link vdevs
Remove the locking mechanism when getting the link vdevs since it is
causing a deadlock.

Change-Id: I360bd1ad609cfe1d0eb3576b66aeeb93495811fa
CRs-fixed: 3025767
2021-09-03 18:17:27 -07:00
Hariharan Basuthkar
94e4707d98 qcacmn: Update 6G ap power type for every FW load
When the host driver is insmod-ed, and first time the pdev object
is created, the AP power mode starts with LPI. When the FW sends the AFC
power values, the Host switches to SP mode.

If 'wifi down and wifi up' happens, all the VAPs are deleted but
pdev object is retained in the memory. Since, during 'wifi down and
wifi up' the FW is reloaded again, the FW starts with LPI always.
However, since pdev object already exists the AP power mode variable
in the regulatory private object has the same old power mode.

To fix the problem described above, update the power mode whenever
the WMI_REG_CHAN_LIST_CC_EXT_EVENT is received from the target.

Change-Id: I7a349e4defcd50cd46117d8ee55bbe8c7c8f7e80
CRs-Fixed: 3028659
2021-09-03 11:03:50 -07:00
Vignesh U
fc7e74f044 qcacmn: Create intersected AFC channel before calling ACS
ACS needs the intersection of SP channel and the channel list in the AFC
response.

Create intersected AFC channel before calling ACS.

Change-Id: I9443edfc4d8b31edf5ae7e040c0743de9a0851b3
CRs-Fixed: 3023930
2021-09-03 03:25:12 -07:00
Vignesh U
a4b1ed87f0 qcacmn: Fix compilation error in reg_get_partial_afc_req_info
The function reg_get_partial_afc_req_info() declaration is different from
its definition prototype.

Change-Id: Idd36e1343dd2af1d5ecaf3b8dcbaf7dc6839d560
CRs-Fixed: 3023862
2021-09-03 03:25:07 -07:00
Hariharan Basuthkar
e1708ea080 qcacmn: Add a condition in reg_compute_chan_to_freq for 6G channel 2
When 6G IEEE channel 2 (5935 MHz) is enabled in the master channel list,
and if the channel 1 (5955 MHz) is the input to the API
reg_compute_chan_to_freq, the API returns 0 as the output channel
frequency.

Since the IEEE number 2 is greater than 1 (but in terms of frequency it
is a lesser value), the break condition in the for-loop gets
satisfied, and since the enum of channel 2 is equal to MIN_6GHZ_CHANNEL,
the API returns 0.

To fix this issue, in reg_chan_band_to_freq, handle 6G channel 2 as a
special case by directly returning its frequency, and also
skip it from the search space of reg_compute_chan_to_freq.

Change-Id: Ief79ee2d93f4d547688e10113a8105a763c767f8
CRs-Fixed: 3013255
2021-09-02 23:58:12 -07:00
Hariharan Basuthkar
b136efc7a5 qcacmn: Intersect AFC and SP regulatory power
While appending one of the 6g_master_channel lists (based on power
type) to the master channel list, if the power type is standard power,
intersect the standard power list with the afc power list and append
the intersected list to the master channel list if the afc power
list is available.

Change-Id: I606e765a4abd5cd71cf35a13ac799fdec8e87ffd
CRs-Fixed: 3023853
2021-09-02 14:32:05 -07:00
Hariharan Basuthkar
033605a031 qcacmn: Add a dispatcher API to read the ini AFC config
Add a regulatory dispatcher API to fetch the value of AFC action
from the ini config.

Change-Id: I053262f98991a656d1919817ce37227202a46bc3
CRs-Fixed: 2997899
2021-09-01 21:38:11 -07:00
Hariharan Basuthkar
8c2dd12d3c qcacmn: Fix driver crash observed during AFC request processing
Currently the AFC request buffer is being freed twice in
reg_free_expiry_afc_info and tgt_afc_event_handler.
Make changes to free the AFC req buffer only once.

Change-Id: I6d0f5c783a124da40eae6166132f7d7132cf76e4
2021-09-01 17:13:31 -07:00
Kiran Venkatappa
7aaef9935d qcacmn: Extract hw_link_id and store in target_if pdev context
hw_link_id is unique across psoc to identify pdev in multi-soc ML cases.
Exract hw_link_id from mac_phy_cap and provide APIs in target_if to set
and get this for pdev

Change-Id: I9dcc4c1e4b515e83151ca88f5f026c0dd0b04646
CRs-Fixed: 3023496
2021-09-01 17:13:27 -07:00
Sridhar Selvaraj
bfb04859c6 qcacmn: Reset skip_bssid_copy flag in split profile parsing
While parsing MBSS IE split profiles, bssid copy flag
is not reset in between sub element parsing resulting
in skipping the bssid copy for next non tx profile.

Reset skip_bssid_copy flag for each sub element parsing
so that correct bssid is copied for next non tx profile

CRs-Fixed: 3019298
Change-Id: I429190b21a3ddafdc75a73e8b063f6b6f629492a
2021-09-01 09:03:13 -07:00
Hariharan Basuthkar
258d7f4c16 qcacmn: Implement the 6G AFC power event processing
Add regulatory functions to handle the WMI_AFC_EVENTID. This
includes processing the AFC power information received from the FW,
and constructing the AFC channel list in the regulatory component.

Change-Id: I5da8fc7faae847476f88ff35b20e6444115af7f1
CRs-Fixed: 3023789
2021-08-31 14:44:50 -07:00
Bing Sun
7fcc2ebd13 qcacmn: Fix issue when getting rnr
When getting rnr IE information, instead of getting rnr pointer through
input parameter,  we can just return rnr pointer.

Change-Id: I57f683eb86bb813018a38fa3a6286e9b6e40037f
CRs-Fixed: 3025194
2021-08-31 12:23:26 -07:00
Ashish Kumar Dhanotiya
8082901907 qcacmn: Set default value of mawc_nlo_enabled ini as 0
Set value of mawc_nlo_enabled ini as 0 by default.

Change-Id: I7779072deecc9390f3df929355788ee8d73cb48f
CRs-Fixed: 3024972
2021-08-31 07:54:49 -07:00
Santosh Anbu
bb40ebd9a8 qcacmn: Use vdev list when dispatch sync complete event to MLO
In few of the scenarios, as part of sync complete handling mld_dev_context
lock is been acquired, which causes deadlock as it is already taken before
dispatching the event.

Hence get the vdev list under lock and reference taken and then dispatch
mlo_sync_complete individually.

Change-Id: Id23dba89276ecaadb02cd3a39a66b4fca3f97c7c
CRs-Fixed: 2924329
2021-08-31 01:15:41 -07:00
Santosh Anbu
d445d62fd9 qcacmn: MLO quiet vdev bitmap support for AP
Add change to support indication of quiet vdev for MLO AP context.

Change-Id: I7368e023976c29ae98fef2b86ef6aee0b7621390
CRs-Fixed: 2924329
2021-08-31 01:15:33 -07:00
Utkarsh Bhatnagar
b7ab2f5cd7 qcacmn: Add support for Thermal Stats Events
Add support for extracting Thermal Stats Events
from thermal event TLV for FW event
WMI_THERM_THROT_STATS_EVENTID.

Also, added support for FW Cmd to request for
Thermal Stats: WMI_REQUEST_THERMAL_STATS_CMDID

Change-Id: I2bc80d082bda45e2255371bcb0c31d35d9806525
CRs-Fixed: 3016845
2021-08-27 10:23:50 -07:00
Abhijit Pradhan
bd02b05aa5 qcacmn: Move repetitive function bodies into a single function
The body of the two following functions:
1)reg_get_num_sp_freq_ranges,
2)reg_cp_freq_ranges
have much in common.

Move the common part into a single function in order to optimize code size.

Change-Id: Ice9e925ef0e64baa41f867a92a3c3d2902374d74
CRs-Fixed: 3019338
2021-08-27 08:08:53 -07:00
Abhijit Pradhan
575da29354 qcacmn: Find the frequency ranges for AFC request
The regulatory rules contain the frequency ranges that are supported
by the current regulatory domain. Also every radio has a chip range
which indicates the range of frequencies supported by the radio. To
find the list of frequencies for the AFC request, add each regulatory
frequency range that are within the chip range to the AFC list of
frequency ranges. If a regulatory range has a partial overlap with the
chip range add only the overlapping part of the range to the AFC list
of frequency ranges.

Change-Id: Ida3e2217783db82fef2825c6a6603e79ef65951b
CRs-Fixed: 3019336
2021-08-27 08:08:48 -07:00
Shashikala Prabhu
d4c52fb8ef qcacmn: Remove the 'multi_link is null' error print
"scan_entry->ie_list.multi_link is null" print is
flooding the scan component. Hence, remove this print.

Change-Id: I921eea8afc2dba5637c7c02717e2d1fb544ba103
CRs-Fixed: 3023813
2021-08-27 08:08:43 -07:00
Hariharan Basuthkar
0b8e97ac32 qcacmn: Add dispatcher APIs for AFC in the regulatory
1) Add an ucfg dispatcher for reg_afc_start.
2) Add an API wlan_reg_get_afc_req_id, to fetch AFC request id.
3) Add an API wlan_reg_is_afc_expiry_event_received, to check if the AFC
   expiry event is received from the target.

Change-Id: I45841706c500e74632b60546d945cde4d634a5d2
CRs-Fixed: 3011675
2021-08-27 05:44:45 -07:00
Kiran Kumar Lokere
e2ada05cee qcacmn: Config support to use BSSID in probe request RA
User configuration support to use scan request BSSID value
in Probe Request frame RA during the scan.

Change-Id: I40d07e4c3e4814a9c816b3e426dcbb63df7ddf27
CRs-Fixed: 2945679
2021-08-27 01:06:23 -07:00
Will Huang
64d063094f qcacmn: Change beacon drop log to rate limit log
Although beacon drop info is important, but if continually print with
info level it will flood serial log and lead to low performance.
Security mode check is mandatory in 6Ghz band, so it is by default
enabled, so possible to see many beacon drop log because of this check.

Change beacon drop log to rate limit and fix one potential memory
leak in __scm_handle_bcn_probe().

Change-Id: Ic9032b99504d6ff41256d547e2d8fad101301589
CRs-Fixed: 3014786
2021-08-27 01:06:19 -07:00
Liangwei Dong
71ba53089e qcacmn: Add API wlan_reg_get_next_lower_bandwidth
Export regulatory API wlan_reg_get_next_lower_bandwidth to
get next lower bandwidth of given channel bandwidth.

Change-Id: Id86d83c1bf738061d325b23d3f46b77d45eaeca5
CRs-Fixed: 3021976
2021-08-26 20:56:17 -07:00
Lincoln Tran
ce48d77998 qcacmn: Add debug MLO changes
-Add debug logs to MLO manager code.
-Add ml_dev validation checks for ML peer operations.
-Add pointer checks to avoid NULL pointer dereference

Change-Id: I8e9ddf177a999a43e8612f8c6acedd08ffce63d5
CRs-fixed: 2998964
2021-08-25 19:45:02 -07:00
Himanshu Batra
df25501b83 qcacmn: Fill ML info while getting active connect/disconnect request
Fill ML info while getting active connect/disconnect request

Change-Id: Ifdbfacab64bfcc144ac3f2afb68854f2108e729d
CRs-Fixed: 3022005
2021-08-25 13:07:19 -07:00
Shiva Sankar Gajula
d3b7b11795 qcacmn: Reset mgmt ciphers and key mgmt to 0 by default
The 11r roaming is not happening when PMF disabled STA is trying to
roam from PMF disabled AP to PMF optinally configured(ieee80211w=1)
AP which is due to candidate_list is not found because of mgmt
ciphers mismatch (the PMF disabled mgmt cipher is None(1<<17) and PMF
optional AP's mgmt cipher is CMAC(1<<6)) happening while comparing
security params and is due to mgmt cipher value is reset to None(17)
after STA connected to AP.

So, Added changes to reset the mgmt cipher value to zero. Also, added
changes to reset the keymgmt to 0 instead of None since this is
missing in earlier implementation.

Change-Id: I9f24a215011b4984937e98225bcb3975bc3f685f
2021-08-25 07:25:20 -07:00