Commit Graph

8068 Commits

Author SHA1 Message Date
Alok Kumar
d08c290683 qcacmn: Add pktcapture support param and Offload event Id
Add wmi resource flag to send packet capture from host
to FW. Register Offload Event Id for packet capture mode.

Change-Id: Icd9e542a517c8b267a228324b7612ddded28f182
CRs-Fixed: 2528439
2019-12-19 14:15:23 -08:00
nobelj
219e7e57e2 qcacmn: Fix NULL data Tx frame capture
Handle ppdu descriptor for NULL data frame as payload come
mgmt payload tlv.

Change-Id: I0d9322c8132dc520d0274b9cf1abcf3018469bf7
2019-12-19 10:25:51 -08:00
nobelj
4771edbadc qcacmn: support for tx capture stats
added support to print debug stats for tx capture

Change-Id: Id5533e076f9b5d3f15a392f61b4af5fdffa9efb0
2019-12-19 10:25:35 -08:00
Manikandan Mohan
b199b73f43 qcacmn: Fix unused expression result warning
Fix unused return value warning for hif_fw_interrupt_handler function
usage.

Change-Id: I64a063f795e5087baff37d4bb63f9fe79ce811fc
CRs-fixed: 2587457
2019-12-19 04:39:39 -08:00
Jinwei Chen
5bd952ce05 qcacmn: fix srng lock hold long time due to logging
when lot of fragment frame with invalid peer_id indicated to
host through reo exception ring, excessive logging cause srng
lock hold long time.
  degrade log level as a WAR to avoid excessive logging.

Change-Id: Iffb18ad723d1ac5955868cc8ec99bb0198785ee5
CRs-Fixed: 2584610
2019-12-19 03:05:15 -08:00
Naga
1b9b61e7cd qcacmn: Add API to print start response status
Add inline API to print start response status as string
instead of value.

Change-Id: Ifed90ae2b2fd8b1dc31f35d3debf6bf5020c85c2
CRs-Fixed: 2586089
2019-12-19 03:04:50 -08:00
Pankaj Singh
e10977221a qcacmn: Print beacon info after RSSI/chan are updated from prev frame
In case of channel mismatch, RSSI and channel etc are updated from
previous frame. Also in hidden SSID case the SSID is updated from
prev frame for beacons.

So print the beacon after updating these params from previous frame.

Change-Id: Ia4dc4769f7bccf4698074a3bcedefd1909fd2e7b
CRs-Fixed: 2587067
2019-12-19 03:04:34 -08:00
Hangtian Zhu
7788a89ccd qcacmn: Fix compile issues when some features are disabled
Fix compile issues when some features are disabled, the features are:
BUILD_DEBUG_VERSION
CONFIG_CP_STATS
CONFIG_HOST_OPCLASS
CONFIG_FEATURE_ROAM_DEBUG
There are some other features depends on each other, so enabled features to
qcs40x.snoc.perf_defconfig, the features are:
CONFIG_WLAN_FEATURE_FILS
CONFIG_WMI_ROAM_SUPPORT
CONFIG_WMI_STA_SUPPORT
CONFIG_REG_CLIENT
CONFIG_WLAN_FEATURE_DP_BUS_BANDWIDTH
CONFIG_WMI_CONCURRENCY_SUPPORT
CONFIG_LL_DP_SUPPORT

Change-Id: I6fa1eacb79576a955e593dbb9ac52083742275e3
CRs-Fixed: 2584839
2019-12-18 23:55:00 -08:00
nobelj
68930ca688 qcacmn: tx capture update bar frames
as we are overriding bar ppdu information, we need bar start/end
timestamp and duration.
added resp_type, mprot_type, rts_success and rts_failure in
cdp completion user.

Change-Id: I53c215e948fad8d079e1d4c40ec07d34aff1fefe
2019-12-18 18:57:41 -08:00
Sumedh Baikady
48fdc2ddfb qcacmn: Add out of band advertisement in 6Ghz
Add WMI and objmgr support for maintaining RNR
buffer cache and receive tbtt events for all
vdevs using existing tbtt offset WMI.

Change-Id: Idfed63e104e629fbe455d1cf6202cd9b332f5cf9
2019-12-18 11:13:36 -08:00
Disha Das
cde63cdd01 qcacmn: Obtain current PN number for a peer
On rekey, the STA resets it’s PN to 0 but, the
AP sends out pending traffic with old PN values
before it resets the PN as well.
This causes traffic to stall and hence, TSC (transmit
sequence counter) should not be set to zero during rekey.

Instead, obtain last PN number for a non-bss peer while
configuring new key and pass the values to hostap.

Change-Id: I4a604f23944c941c6ade2f57ab03781bc78f7b40
2019-12-18 09:24:44 -08:00
Liangwei Dong
7628a42ab1 qcacmn: Add VHT/HE 160Mhz rate flag
Add TX_RATE_HE160 and TX_RATE_VHT160 for 160Mhz
rate report.

Change-Id: Ica39b5dd65f1ca5bedece344456bb4e628b406af
CRs-Fixed: 2583923
2019-12-17 16:38:42 -08:00
Abhinav Kumar
b2669ba62b qcacmn: Possible OOB write in send_roam_scan_offload_mode_cmd_tlv
While preparing roam offload buffer, possible out of bound write
for pmk buffer in send_roam_scan_offload_mode_cmd_tlv.

Change-Id: Iadaf8261ef4440c7cb282af7b1321ebc5d08b5e5
CRs-Fixed: 2579401
2019-12-17 05:59:51 -08:00
nobelj
c5cb3bf9c5 qcacmn: multiple update of tid for same ppdu stats
remove multiple update of tid for same ppdu stats.
tid is populated from user rate, completion common and
ack ba status tlv. As tid from ack ba status tlv comes wrong
for non-qos tid. we remove the tid populate in ack ba status tlv.

Change-Id: Ia8b0004fc329bf0fecc1a622e199635034c213a7
2019-12-17 01:38:27 -08:00
Jeevan Kukkalli
66f08b7be6 qcacmn: Avoid infinite loop while parsing RNR IE
A value of 0 in TBTT Information Count subfield indicates
one TBTT Information field is present.Test expression in
for loop should consider 0 as a valid value to avoid infinite
loop.

Change-Id: I0dc0f694147b6c4f91a8be0bfbd7c6d4bb95e1f1
CRs-Fixed: 2582936
2019-12-17 01:38:14 -08:00
Abhijit Pradhan
5a6aec0277 qcacmn: Control the size of the freq and chan_num (GUMAC-SCAN)
Depending on the requirement, a bigger size or a smaller size for
the frequency variable can be chosen. The advantages of each size
are described below:

Advantage of a bigger size:
When two technologies (e.g. 802.11AX and 802.11AD) are controlled
by the same driver software, the frequency range may be very large
and a bigger size (e.g. 32bit integer) is more appropriate.

Advantage of a smaller size:
When the frequency range is not very large, a smaller size
(e.g. 16bit integer) can be used. It saves a large amount of space
especially when many large arrays containing elements of this type/size
are defined in the driver.

Also, change the size of the IEEE channel variables to unsigned
8-bit integer.

Change-Id: I6349c0665bf0a7329627427913f9eebba2821043
CRs-Fixed: 2586177
2019-12-17 00:13:24 -08:00
Abhijit Pradhan
0f16cba633 qcacmn: Control the size of the freq and chan_num (Scan)
Depending on the requirement, a bigger size or a smaller size for
the frequency variable can be chosen. The advantages of each size
are described below:-

Advantage of a bigger size:
When two technologies (e.g. 802.11AX and 802.11AD ) are controlled
by the same driver software, the frequency range may be very large
and a bigger size (e.g. 32bit integer) is more appropriate.

Advantage of a smaller size: When the frequency range is not very
large, a smaller size(e.g. 16bit integer) can be used. It saves a
large amount of space especially when many large arrays containing
elements of this type/size are defined in the driver.

Also, change the size of the IEEE channel variables to unsigned
8-bit integer.

Change-Id: Ie503623ec6e4473abe8ee95c19dc4470853326dd
CRs-Fixed: 2586177
2019-12-17 00:13:09 -08:00
Abhijit Pradhan
2c1420a617 qcacmn: Control the size of the freq and chan_num (Regulatory)
Depending on the requirement, a bigger size or a smaller size for
the frequency variable can be chosen. The advantages of each size
are described below:

Advantage of a bigger size:
When two technologies (e.g. 802.11AX and 802.11AD) are controlled
by the same driver software, the frequency range may be very large
and a bigger size (e.g. 32bit integer) is more appropriate.

Advantage of a smaller size:
When the frequency range is not very large, a smaller size (e.g.
16bit integer) can be used. It saves a large amount of space especially
when many large arrays containing elements of this type/size are
defined in the driver.

Also, change the size of the IEEE channel variables to unsigned
8-bit integer.

Change-Id: Ie205befb82f643808973286ae578d7add7738eec
CRs-Fixed: 2586071
2019-12-17 00:12:55 -08:00
Yue Ma
9c43a47af0 qcacmn: Clean up channel number usage for CDP API
For cdp_hl_fc_set_td_limit() API, use channel frequency instead of
channel number.

Change-Id: I852f1fc192374a4b603e615664d7fb27ea984f5f
CRs-fixed: 2565737
2019-12-16 19:46:13 -08:00
Li Feng
106027ba1b qcacmn: Correct chan num assignment
Correct chan num assignment in utils_dfs_get_channel_list.

Change-Id: I18f09b21de80c19f8b67acfd56f394c0e9949faf
CRs-Fixed: 2584402
2019-12-16 18:21:34 -08:00
Vignesh U
49a3bbbe28 qcacmn: Add filters to the MKKN filter table
The w53 updated pulses should be detected by the DFS algorithm.

- Add new DFS filters to MKKN filter table.
- Introduce duration margin check in confirm radar routine.

Change-Id: Icf3fecb5c6027ba827cac05dbd43a1a55463209b
CRs-Fixed: 2582300
2019-12-16 16:17:55 -08:00
Mohit Khanna
82382b32e9 qcacmn: Handle BAR OOR/2K_JUMP REO errors
Currently in dp_rx_wbm_err_process, we donot handle
HAL_REO_ERR_BAR_FRAME_2K_JUMP and HAL_REO_ERR_BAR_FRAME_OOR REO errors.
Add support for the same.

Change-Id: I22147fcd2d531c1e08214626796994593ffeb3a6
CRs-Fixed: 2580876
2019-12-16 14:20:15 -08:00
Mohit Khanna
63055510e0 qcacmn: Add IEEE 802.11 control frame type/subtypes
Add 802.11 CTRL frame type and subtype subfields.

Change-Id: I2105d0ee52cf948f79b6614a063238312443fa6d
CRs-Fixed: 2580876
2019-12-16 14:19:57 -08:00
Pankaj Singh
b18fc398bb qcacmn: For 6Ghz beacons get chan from HE OPs 6 Ghz params
In 6Ghz the HT and VHT IE are not present and channel info is
present in HE OPs 6 Ghz params.

So fill channel from HE OPs for 6Ghz AP.

Change-Id: I2dbe6ecedb8949b7d9d3b26b43fbe4b6d3ef0a42
CRs-Fixed: 2585788
2019-12-14 16:18:31 -08:00
Amruta Kulkarni
d0189add9b qcacmn: Enhance logic for active dwell time
With this change, in concurrent mode
(SAP on 2.4ghz and peer connected + STA Scan ongoing),
active dwell time is kept unchanged.

Change-Id: I465873dec79906d078f5ec00c49641f66867c6a7
CRs-Fixed: 2581121
2019-12-13 14:12:16 -08:00
Ruben Columbus
282f3a5ce1 qcacmn: RSSI averaging function accuracy
improvement on function for avergaging rssi accuracy

Change-Id: I4fb231aacb2ed76a2e5e1b5843a8b095e9901406
2019-12-13 12:15:02 -08:00
Nirav Shah
8f44a7e494 qcacmn: Add credit tracking for HL Data Path
Add credit tracking for HL Data Path in DPTRACE.

Change-Id: I6e2971209940c16a13a8ca7f1f0a3d7c1a26e305
CRs-Fixed: 2574057
2019-12-13 07:04:10 -08:00
Yue Ma
4b48131ce2 qcacmn: Clean up wmi.h in target_if_scan.c
Add WMI unified APIs to extract PNO related WMI events in order to
remove wmi.h inclusion in target_if_scan.c.

Change-Id: I7fd28f175de002b48c294783f69b819ce2f3e37a
CRs-fixed: 2519032
2019-12-13 07:03:53 -08:00
Akshay Kosigi
28d1d127aa qcacmn: Use correct vdev_id to fetch the vdev_rsp timer info
Fetch correct vdev_rsp timer info in case of multivdev restart case
using the right vdev_id.

Change-Id: I0d9cbb886ffcc66ada354e6db2b084beb2417bcb
2019-12-13 01:59:55 -08:00
Hariharan Basuthkar
c41566955e qcacmn: Add regulatory 6G changes for Update 30
Update the regulatory database with the following changes:

1) Add full reg domain FCC15_FCCA, FCC16_FCCA and FCC17_FCCA.
2) Add associated 5G reg rules and channel bands for the new regdomains.

Change-Id: I2b6038d0f106555adf650c12ca48efcaacc69071
CRs-Fixed: 2582502
2019-12-13 01:59:38 -08:00
Linux Build Service Account
142a72f4fd Merge "qcacmn: Add support for oem data event" 2019-12-12 20:30:30 -08:00
Linux Build Service Account
bf21ef2e02 Merge "qcacmn: Remove unused API in the regulatory component" 2019-12-12 20:30:29 -08:00
nobelj
ab929fe416 qcacmn: update tlv bitmap check and fix retries counter
expected tlv bitmap can't be guaranteed as different ppdu frame has
different expected tlv bitmap. Check last tlv before sending stats
as tlv are coming from firmware in sequential order.

retry counter is not populate correctly, only successful
completion ppdu status get update

Change-Id: Ia4b71371bbf38996df9dbb67746078d5fbd628a1
2019-12-12 18:32:25 -08:00
Rakesh Pillai
30294e2c79 qcacmn: Skip setting BA window size to 2 for NON BA case
As per the REO logic, if a packet is received with
SN <= current SN, then it will be treated as a 2K jump
error or OOR and the packet in consideration will be
dropped by REO. For NON-BA case this case will be
treated as 2k-jump error.

For the NON-BA case, the packets with SN <= current SN
should not be dropped.
The current REO configuration, sets the BA window size
to 2 for NON-BA case, which in turn enables 2k-jump
detection.

For configuring the REO to not drop packets with previous
SN, we need not set the BA window size to 2, thereby
disabling the 2k-jump check for NON-BA case.

A. SN = 1, 2, 3, 4, 2096, … 
   (good case, as long as the SN is within 2K range)
B. SN = 3, 5, 2
   (3, 5 are good packet, 2 is bad packet and will
   be dropped to ‘2K error’ with error code = 2K error.)
   (note that this is for non-BA session, for BA session,
    we detect SN as either
   2K error or OOR error based on SN and window size).
After this change, we will treat this as a good packet.

C. SN = 1, 1, 1, 1, with duplicate detect enabled – these are duplicate
                    packets and will be dropped to ‘DD queue’ with
                    error code = DD
(No change)

D. SN = 1, 1, 1, 1, with duplicate detect disabled – packets will be
                    dropped to ‘2K error’ with error code = 2K error.
After this change, we will treat this as a good packet.

Skip the setting of BA window size to 2 for aggregated
packets in NON BA case.

CRs-Fixed: 2580605
Change-Id: I19d5eced7c8730a9c3820fd6fc69923d2a98263a
2019-12-12 06:33:55 -08:00
Vignesh U
8fd74a017d qcacmn: Add a new DFS domain for Japan (MKKN)
Introduce a new DFS domain MKKN that supports new w53 Japan RADAR
pattern only.
Initialize a new empty RADAR table dfs_mkkn_radars for MKKN DFS domain.
Map The 5G regdamain MKK17 to the new DFS domain MKKN to make sure that
the new w53 Radar pulses should be detected only by JP country or
MKK17 5G regdomain.

Change-Id: Ib0f6a7e98353c9930e90703ead2342b932e491e3
CRs-Fixed: 2575347
2019-12-12 18:19:38 +05:30
Jinwei Chen
3172ed4419 qcacmn: degrade log level in monitor dst processing
Degrade log level from ERROR to INFO_HIGH to prevent excessive
logging into dmesg console.

Change-Id: Ic0ef72cf2564ed2354b3db4d6e09e7ac7c832560
CRs-Fixed: 2582400
2019-12-12 18:17:36 +05:30
phadiman
a73cc69157 qcacmn: Fix pool alloc issue in detach path
Memory is freed and allocated only during
wifi load and unload in case of WIN and not
during wifi up/down

Calling dp_tx_soc_detach unconditionally
was leading to memory free in wifi down
path and when wifi up was issued the
memory which was freed was never allocated

Call dp_tx_soc_detach conditonaly only for
MCL in dp_soc_cmn_cleanup and for WIN in
dp_soc_detach using dp_soc_reinit flag which 
is set for WIN during wifi unload

Change-Id: I9da34f7945d65a34e719c7db58da13e85ae3d228
2019-12-12 18:15:18 +05:30
Edayilliam Jayadev
b3a66311cc qcacmn: Add Agile channel width to SAMP message
Add a new member to SAMP structure describing the channel width of
Agile Spectral scan.

Change-Id: Ib27fe9ed63bf8f89c59762150fb58943e6bcf7ea
CRs-Fixed: 2582670
2019-12-12 18:14:27 +05:30
Ashish Kumar Dhanotiya
6078a89c07 qcacmn: Add support for oem data event
Currently use of comamnd QCA_NL80211_VENDOR_SUBCMD_OEM_DATA
is to pass data blobs from Application to FW but there is
no mechanism to send the data blobs from FW to Application.

To meet the above requirement update the usage of existing
OEM DATA command to use it as a vendor event as well to
send data blob from host to Application.

Change-Id: I8df98f850f4dd56f55dba43c5364a52c425ba9ed
CRs-Fixed: 2573468
2019-12-11 16:12:28 -08:00
Hariharan Basuthkar
45ac9f5bf7 qcacmn: Remove unused API in the regulatory component
Remove the unused API wlan_reg_get_5g_bonded_channel_and_state in the
regulatory component

Change-Id: I45c9b083dfb6faf6c97293d54200ed4f15a7d289
CRs-Fixed: 2574154
2019-12-11 06:28:48 -08:00
Linux Build Service Account
42992cd389 Merge "qcacmn: populate qos_null in rx state" 2019-12-11 03:52:31 -08:00
Linux Build Service Account
5dcd71e7eb Merge "qcacmn: Add support for WMI_ROAM_STATS_EVENTID event" 2019-12-11 03:52:31 -08:00
Linux Build Service Account
c75fdb7ba2 Merge "qcacmn: Decoupling changes for stats, wds, raw and pflow ops" 2019-12-11 03:52:31 -08:00
Ruben Columbus
fadeef890b qcacmn: populate qos_null in rx state
sw_frame_group_id decides process for frame. USER_STATS tlv case uses
sw_frame_group_id to add qos_null frame control to rx_status.

Change-Id: Ia3da8dbe4fc4c2d0f21fa8864e6b4e87170ba8f6
2019-12-11 00:19:50 -08:00
Pragaspathi Thilagaraj
ab6b497e6d qcacmn: Add support for WMI_ROAM_STATS_EVENTID event
After every roam happens or when neighbor report is sent by the
firmware, it sends the WMI_ROAM_STATS_EVENTID to host.

Add support to handle WMI_ROAM_STATS_EVENTID event from target
after every roam.

Change-Id: I4474135ac64ebfb17109d503fbd1c3d637457a73
CRs-Fixed: 2576258
2019-12-10 19:40:49 -08:00
Pavankumar Nandeshwar
e54c584723 qcacmn: Decoupling changes for stats, wds, raw and pflow ops
Change cdp_host_stats_ops, cdp_wds_ops, cdp_raw_ops
and cdp_pflow_ops APIs to replace pdev, vdev and peer
dp handles with pdev_id, vdev_id and peer mac address
along with dp soc handle.

Change-Id: Ia956882535cc04e57a006905d46ccfe9d95bb731
2019-12-10 19:40:36 -08:00
Jeffin Mammen
084f936b71 qcacmn: Correct message in backpressure event
Correct the debug message to print the appropriate
ring id when backpressure events are reported

Change-Id: I4cb2af9c802469ecd0c38bdd3789439048de876f
CRs-Fixed: 2556208
2019-12-10 04:21:43 -08:00
Abhinav Kumar
04b61d6e39 qcacmn: Get the valid vdev in get_vdev_by_macaddr_from_pdev
In wlan_objmgr_get_vdev_by_macaddr_from_pdev driver checks the
first vdev matching the mac address and try to get ref and return
NULL if it fails.

In case if a vdev is logically deleted but not physically deleted
(some ref are pending) and a new vdev is added with same mac address
at the tail of the vdev list, the
wlan_objmgr_get_vdev_by_macaddr_from_pdev always return NULL cheking
for the logically deleted vdev, even when a valid vdev is present
after the logically deleted vdev.

Thus continue to next vdev if try get ref fails for the vdev.

Change-Id: Icd67ce8830460fca7bb4c19e81b2e9f764fb5dba
CRs-Fixed: 2580697
2019-12-10 00:51:59 -08:00
Abhinav Kumar
4c3c73a375 qcacmn: Remove unused serialization API
Remove unused serialization API
wlan_serialization_get_active_list_count.

Change-Id: I80c1cd5693fb3dda91ffd7de01c1df244e648135
CRs-Fixed: 2580681
2019-12-10 00:51:51 -08:00
Shashikala Prabhu
1e7bd262fd qcacmn: Add restricted 80+80 MHz bit in soc caps
Restricted 80+80 MHz  capability is reported by FW in service bitmap.
Based on this support set soc's extcap feature bit.

Please note, wmi_service_bw_165mhz_support will be renamed as
wmi_service_restricted_80p80_support once the FW changes are available.

Change-Id: I88f89eecd916c40ea8669c792dde3a335e4bac56
CRs-Fixed: 2579543
2019-12-10 00:51:42 -08:00