Commit Graph

327 Commits

Author SHA1 Message Date
Padma Raghunathan
aa83faab41 qcacmn: Lithium_DP: HAL support for qca6018
Interface files to access QCA6018 HAL registers

Change-Id: I5152d9fe0aae31609a82a32ee405e12a02a5aa25
CRs-Fixed: 2323724
2018-10-30 00:24:01 -07:00
Karunakar Dasineni
26ebbe4492 qcacmn: Flush REO descriptors entirely
To avoid race conditions where BA window size can change, always
flush entire REO descriptor from HW cache irrespective of current
BA window size.

Change-Id: I608996722e7dc2dc6acfd145b8c190b58ce09822
CRs-Fixed: 2251811
2018-10-18 02:17:04 -07:00
Mohit Khanna
81179cb75e qcacmn: Fixes for IPA enablement for lithium/Hastings
- Support to pass IPA enabled(disabled) flag from ini to DP layer
- Use ioremap call to translate tx_comp_doorbell_paddr obtained from
  calling ipa_setup api to tx_comp_doorbell_vaddr. This is needed to
  write the initial value of HP at the doorbell address.
- Change REO_DST_RING_SIZE and WLAN_CFG_TX_RING_SIZE to 1023
  for napier/hastings if IPA is enabled. This is needed because,
  ipa_setup API can handle only 16-bit values for the size param(bytes)
  of the ring.
- Disable hash based flow steering for SAP peers in case IPA is enabled
  and set default reo_dest_ring_4 as default RX ring. Since IPA will be
  reaping RX packets from reo_dest_ring_4 only, flow steering is not
  needed for SAP peers.
- Unmap pre-allocated TX buffers for IPA in the TX completion ring.
- Donot execute IPA functionality if IPA is disabled from ini.

Change-Id: I6855bfe293a457ccc0abd1ad5567f5c95232a9d2
CRs-Fixed: 2183519
2018-10-17 17:42:35 -07:00
chenguo
35695ddc8e qcacmn: Add radiotap dissector for TB-PPDU
So far, only HE_TRIG packet type parsing is supported for TB-PPDU
(OFDMA UL)frames, which is not enough for plugfest tests. Add all
radiotap dissecting from  HE Data 1 to HE Data 6

CRs-Fixed: 2316408
Change-Id: I49d91d4981291827b20f325d459fd1e60f3cc271
2018-10-09 23:20:17 -07:00
Ruchi, Agrawal
9d28e759ad qcacmn: dscp tid map change for second h/w version
change to update dscp tid table of hardware for
second version of hardware

Change-Id: Ia53886f677061e2fff819ac1adcc64a17b153b4d
CRs-Fixed: 2320609
2018-10-04 15:52:54 -07:00
Balamurugan Mahalingam
764219e1a8 qcacmn: move some hal functions to hal_generic_api.h
Functions hal_rx_wbm_err_info_get, hal_tx_comp_get_release_reason,
hal_rx_dump_mpdu_start_tlv uses some hardware macros directly and the
value differs between qca8074v1 and qca8074v2 targets.
Move these functions to generic api file and compile it per target.

Change-Id: Ib78fb6e69238577aac64da3f60f38a72cee316b0
2018-10-03 02:44:47 -07:00
Balamurugan Mahalingam
fa1d9c7098 qcacmn: group hal tx and rx functions
keep hal tx and rx functions grouped as it will look clean
and avoid confusions while browsing code for others.

Change-Id: I519690d42cd077689bf7afe697908f43d7055da5
2018-10-03 02:44:43 -07:00
Yuanyuan Liu
a33c0bea90 qcacmn: Fix constant-logical-operand error
Fix constant-logical-operand error, use '&' for a bitwise operation.

CRs-Fixed: 2323306
Change-Id: I926cdeab6d173bf9428d1f925886dc33d50c2249
2018-10-02 15:37:20 -07:00
Krunal Soni
ef1f0f90fc qcacmn: check hal_ring pointer before servicing the ring
Do null check before servicing the ring. When dp_service_srngs()
is common API which gets called when interrupt gets fired for
any ring. Within this API, driver goes one by one to each ring
and service the rings as it is not obvious from interrupt line that
which particular service ring needs to be served.

So race happens when rings are getting initialized and packet has been
arrived to one of the rings. Due to dp_service_srngs() API's
implementation, driver goes to one by one each ring without checking
if all rings are initialized.

CRs-Fixed: 2310496
Change-Id: I3c8f668756c8d266abe082e8473d54cb4df9065e
2018-10-01 14:59:47 -07:00
Anish Nataraj
eb30aa7f83 qcacmn: Correct the Frame control info valid in hal API
Instead of frame control info valid parameter data sequence
control parameter was passed, corrected it

Change-Id: Iccaeb286c1003cbb58c5ebcacf4b0d99c979cbbc
2018-10-01 04:19:59 -07:00
Pramod Simha
627278cdfe qcacmn: Change Shadow Register configuration for QCA6390
- Change the SR mapping address for QCA6390
- Use ring direction field from HAL ring config instead of HAL ring
  directly as ring is not yet initialized here.

Change-Id: I900b2329367cc02ae2f9d7f164e5f867d8253d90
CRs-Fixed: 2299919
2018-09-28 10:41:39 -07:00
Pramod Simha
b2ef27ba26 qcacmn: Fixes for IPA datapath
1. Disable host processing of REO2SW4 when IPA is enabled.
2. Change buffer memory location provide to IPA TX transfer
   ring from consistent to non-consistent memory.

Change-Id: Ibb62d9faf5dc9adb5ee8a2e113d10a2912269cbd
CRs-Fixed: 2315889
2018-09-27 16:36:58 -07:00
Chaithanya Garrepalli
1f64b2453e qcacmn: in tx path set the lmac_id from wlancfg
in tx path set the lmac_id in the tx descriptor
from wlancfg

Change-Id: Ib7f355983142564500a20daa1f0eef41808df449
CRs-fixed: 2320597
2018-09-24 13:02:13 -07:00
Ruchi, Agrawal
fea1a84116 qcacmn: DSCP-TID map change for second hardware
Change to added entries for 48 DSCP TID  map
for second version of hardware.

Change-Id: Ie4aa0e27616e2f03b012e19d025444c8c53fe341
CRs-Fixed: 2315305
2018-09-18 07:50:15 -07:00
Sathish Kumar
86876490f2 qcacmn: CE services separation for legacy and lithium architecture
CE service file includes APIs for both legacy and lithium
architecture.

These are getting compiled for both targets today. Separate the CE
services into legacy and srng and selectively compile based on
targets present in the SoC.

Note: Generic APIs implemented for both legacy and SRNG services
      are separated out through this change. Fast path implementation
      will be de-coupled from common service and moved to legacy source
      in a follow-up change.

CRs-Fixed: 2258640
Change-Id: If86c21c0bf560a360474c9efcdbcd4841a09828d
2018-09-17 21:29:26 -07:00
Keyur Parekh
04e5a8614b qcacmn: Corrected SGI enum values for HE
For HE case, SGI enum values are different in FW and Host
So that firmware stats and host stats shows different values
To resolve this, change SGI enum value in host to match
firmware definitions.

Change-Id: I1b38dbe32a6c1ab2610c1c3a736a6898ddc73e30
2018-09-17 21:29:22 -07:00
Keyur Parekh
76eadf4265 qcacmn: Populate mcs value for legacy traffic
Populate mcs value for legacy traffic, to display
packet count in correct category in statistics

Change-Id: Ic5ddbc48d3378a884d5c7a189e53ddb7195c21d2
2018-09-17 17:53:47 -07:00
Keyur Parekh
ba75857390 qcacmn: Populate proper Rx reception type
Rx reception type for packet was populated from
wrong TLV. Populate reception type based on
HT,VHT or HE TLV tags

Change-Id: I3240a9f029b0bfeee8833761531e086bc5df6f91
2018-09-16 22:35:23 -07:00
Chaithanya Garrepalli
710e2959f2 qcacmn: Add HAL APIs to set search type and index
HAL APIs added to set search type and search index
in tx descriptor

Change-Id: I9fc2eae5d1f75a7cb72ba141f45a60f248b52f9c
CRs-fixed: 2312178
2018-09-16 09:49:13 -07:00
Chaithanya Garrepalli
2467ed1445 qcacmn: avoid wds source port learning for STA in HKV2
Changes to avoid WDS source port learning in STA mode
if ast override feature is supported by HW

Change-Id: I248c8815429e7417dcf3f451912ee5f037af9c25
2018-09-15 21:21:23 -07:00
chenguo
f51e922a78 qcacmn: add radiotap flags for HE_TRIG frames
HE format in radiotap header are not being updated for HE_TRIG
frames. Add support for it. This is to support MU-OFDMA frames of
UL.

CRs-Fixed: 2223635
Change-Id: If0a93f6047185bcc51948b613d48d13ecb5e16cd
2018-09-11 16:42:19 -07:00
sumedh baikady
59a2d33a2d qcacmn: Use monitor direct for smart monitor
Set monitor direct filter when smart monitor is
enabled. Deliver header from NAC if md bit is set
and smart mesh feature is used.

Change-Id: If1ef865e013c21bbb58bcb89a87856b12d6c7278
Crs-fixed: 2246660
2018-09-08 12:29:31 -07:00
Nandha Kishore Easwaran
e6a27f7cf7 qcacmn: Add apis to set and get ba ageing timeout
Add hal apis to set and get ba ageing timeouts.

Change-Id: I6899f70597de1096d2b318cae1d20e7e1ccab9da
CRs-fixed: 2193128
2018-09-04 11:53:43 -07:00
Balamurugan Mahalingam
5d80641550 qcacmn: [1/2] Support both qca8074v1 and qca8074v2 from hal
Some of the macro names defined in qca8074v1, are defined with
a slightly different name in qca8074v2, and few macros have the
same name in both headers but are defined with different values.
Fixed the same.

Change-Id: I5e948baf5326d1d8fdfa2bd7ee8aa072c710d17c
2018-09-04 11:53:36 -07:00
sumedh baikady
1f8f319500 qcacmn: Add support for cfgtool ba aging timeout cmd
Adds dp handlers for cfgtool80211 cmd to get/set
block ack aging timeout.

Change-Id: I74bb6e9e25c01f1e712066cb1e41e9adb6619662
CRs-fixed: 2193128
2018-08-28 14:46:35 -07:00
Karunakar Dasineni
6a5267501f qcacmn: Fix 'need_status' during rxtid deletion
Set 'need_status' while sending REO queue update command
for deleting REO queues to get status from HW, which will
trigger callback to cleanup and free the queues.
Also fix issue in initializing REO command descriptor, causing
command number to be cleared.

Change-Id: Ie30fc80f76d835e239dd0b3d3e78c7f32bfa09a4
2018-08-27 22:07:33 -07:00
chenguo
4fd11a7234 qcacmn: Add NDP frame supporting for monitor mode of Lithium
NDP is a preamble only PPDU, which do not have payload information
from RXDMA destination ring. The detailed TLV sequence is:
 * RSSI legcy
 * LSIG_A
 * HE_SIGA_SU
 * RSSI_HT
 * GENERATED_CBF_DETAILS
 * PKT_END

CRs-Fixed: 2296348
Change-Id: I19f253c65969b59947bd9a21cf3912b16eb21324
2018-08-27 03:09:54 -07:00
Kai Chen
339b01d8ae qcacmn: Check the MPDU start tag before read ppdu id
Check the MPDU start tag before read ppdu id in MPDU
start TLV in the head of packet TLV.

Change-Id: I0b9a367e148d55a6c667adc8ad16e7c0fdf0a741
2018-08-21 14:16:42 -07:00
Kai Chen
0e79b6e5bd qcacmn: Fix ppdu id wrap around issue
When a ppdu id on a ppdu in status ring find a matching ppdu id
in destination ring. The old logic can cause ppdu id is destination
ring stuck on high value before wrap around. The new logic check
ppdu id between status ring and destination ring is no more than
20000.

Change-Id: Ia601403b0a4fc6cdfff980c7745e055c814137b7
2018-08-21 14:16:37 -07:00
sumedh baikady
df4a57cd31 qcacmn: Handle 2k exception and rate limit delba
Upon receiving 2k jump exception, send delba
and track delba tx status and retries.

Change-Id: Ida35256233869dfa390c40030c9296b9c48481ce
Crs-fixed: 2239856
2018-08-20 01:36:58 -07:00
Venkateswara Swamy Bandaru
29757ad9ee qcacmn: Add DP support for qca8074v2
Add datapath support for qca8074v2.

Change-Id: I8d1a84f011b8fccedd85ca445a0e69a1a4071f72
CRs-Fixed: 2292314
2018-08-13 19:57:52 -07:00
Adil Saeed Musthafa
61a21697f6 qcacmn: Add new radiotap header fields
Add the following fields in Radiotap header:
Antenna noise (in dBM)
Vendor Namespace containing the following information
->L_SIG_A
->Device_ID
->L_SIG_B
->PPDU_START_TIMESTAMP

CRs-Fixed: 2285143
Change-Id: I977be73778ab27383f12214c73b56c9b80d9f02d
2018-08-10 20:45:27 -07:00
Aditya Sathish
ded018e406 qcacmn: Clean up dp component prints
Clean up datapath component prints by correcting trace levels for
regularly occurring prints and removing newlines from converged
print APIs since qdf_trace_msh appends them by default.

Change-Id: Ie8fe319fcb737720f7400a165e134b6a18bd15b5
CRs-Fixed: 2243843
2018-08-10 18:11:21 -07:00
Karunakar Dasineni
b277479e83 qcacmn: Retain defaults in REO_GENERAL_ENABLE
Use read-modify-write to retain default values in
REO_GENERAL_ENABLE register.

Change-Id: I94eb05328117adf02acc2cb14b50b02a008cd322
CRs-Fixed: 2254739
2018-08-09 16:24:52 -07:00
chenguo
1b88046171 qcacmn: Add preamble only PPDU support in monitor mode
There are some particular PPDUs which have preamble only:
     * NDP frames
     * TB_PPDU frames
Add support to the above frames.

Change-Id: I7022433d3765575eaf28d7baf3a11e8b6ce13890
CRs-Fixed: 2275161
2018-08-09 14:34:17 -07:00
Venkata Sharath Chandra Manchala
79860aa182 qcacmn: Enable QCA6390
1. Allocate and Initialize host and target copy engine configuration
   for QCA6390 based products.
2. Setup Copy engine service map for QCA6390.
3. Add conditional compilation flag QCA_WIFI_QCA6390 to support
   QCA6390 based products.

Change-Id: Ia4dd4d436b8ecae0e9f91faa0c1fe7dbd14f001f
CRs-Fixed: 2259312
2018-08-08 12:53:51 -07:00
Gyanranjan Hazarika
7f9c050df4 qcacmn: ba_window size in WMI for rx_reorder_queue_setup
ba_window_size_valid and ba_window size support is missing
while sending wmi_peer_reorder_queue_setup. This is needed
for handing 256 BA which is not FW default.

Change-Id: I3218921c48c0f82225b7992076e73ac0acf7bd11
CRs-fixed: 2285423
2018-08-07 02:19:31 -07:00
Chaithanya Garrepalli
95fc62f8fc qcacmn: populate RSSI for the neighbor clients
Populate the RSSI value for the non associated clients
added in pdev->neighbour_peers_list from monitor status
ring

Change-Id: I509d06bec6eafe8377681c8a3da9a64f301c3c73
CRs-fixed: 2286571
2018-08-06 13:44:01 -07:00
Balamurugan Mahalingam
21b0086b02 qcacmn: define hal tx and rx routines for qca6290 non 11ax
define the hal rx and tx functions
for non 11ax headers as it causes compilation failure

Change-Id: I0fda769fddcf8b54faa22ce55438e84c427a7a2e
2018-07-21 00:03:41 -07:00
Balamurugan Mahalingam
ca15415988 qcacmn: make hal target specific functions as static
This is needed to fix a compilation warning
reported as error due to Werror gcc option

Change-Id: I1ffab78b01266d5d0dabd843a03d44fc6b56b477
2018-07-21 00:03:38 -07:00
Balamurugan Mahalingam
96d2d41c87 qcacmn: Fix compilation issues and a minor issue
Removed qdf exports on functions defined in target specific
header files and defined those functions as static. Revert
changes on hal_rx_msdu_end_sa_idx_get and make
hal_rx_msdu_end_da_idx_get target specific

Change-Id: I2858b1d77118f0a26b54bf983bd342c7a4fe757d
2018-07-21 00:03:36 -07:00
Balamurugan Mahalingam
fe9c9c038c qcacmn: implement qca6390 specific hal functions
implement qca6390 target specific hal_rx_msdu_end_sa_idx_get,
hal_rx_dump_msdu_end_tlv as these routines differs a bit from
rest of the lithium chipsets. this target specific function
will be called through callbacks

Change-Id: I4b71da2d39217c2920597fb36c936218359e6c3a
2018-07-21 00:03:34 -07:00
Balamurugan Mahalingam
97ad1061a3 qcacmn: introduce few target specific hal functions
make hal_rx_msdu_end_sa_idx_get and hal_rx_dump_msdu_end_tlv
routines target specific as qca6390 implementation differs
a bit. add target specific functions for qca6290 and qca8074

Change-Id: Ie05b91d965bae3642e3264620c6d8427ad368044
2018-07-21 00:03:32 -07:00
Balamurugan Mahalingam
6cf4c27417 qcacmn: add HAL support for qca6390
hal_hw_srng table and register offsets array, some target specific
functions  are defined separately for each new target.
define the same for qca6290.

Change-Id: I08c1243bc50460fac776e28186acfa192fb1ff66
2018-07-21 00:03:30 -07:00
Balamurugan Mahalingam
f72cb1f1ff qcacmn: include hal_hw_headers.h header file
macros and fw cmn headers included in hal_internal.h is moved
to a new hal_hw_headers.h to avoid these getting included in hif
layer. Include the new hal_hw_headers.h file

Change-Id: I3390ae9e71ca561d94a265e1fdf4d9354e7b2474
2018-07-21 00:03:27 -07:00
Balamurugan Mahalingam
d0159640ea qcacmn: Separate hal for qca6290 and qca8074
Create separate individual hal_srng_table and hal register
offset in target specific source files. Create separate
functions for qca6290 and qca8074 for few hal rx tx
functions as the macro value differs between the chipsets.

Assign target specific hal tx, rx ops as part of hal_attach
and call respective hal tx, rx ops through callbacks.

Change-Id: Ibbf490c678c39fdd9d54191aad7aaec786db30ec
2018-07-21 00:03:20 -07:00
Krunal Soni
37bf7f4d22 qcacmn: Update radiotap header with LTF symbol value
As per the updated spec, 11AX PPDU's HE SIG_A data-5 field has added
LTF symbol field which is 3bits in size.

Add logic to parse the TLV coming from hardware and update the
LTF symbol value.

Change-Id: I05e2ff8ece7e14dc22ce747e9a9b906bf130462f
CRs-Fixed: 2235233
2018-07-17 00:58:29 -07:00
Venkata Sharath Chandra Manchala
9a59bd6483 qcacmn: Add a new parameter to the srng table
Add max_size parameter in the hw_srng_table
to hold the maximum size for a given ring.

Change-Id: Ibfce021505ab9a55d3208b1c5aba26021d1fe230
CRs-Fixed: 2262818
2018-07-11 14:29:27 -07:00
nobelj
a0c640b5fb qcacmn: Fix rx nss stats for fixed rate nss 1
rx nss calculated based on stbc.

Change-Id: I355f28bc8dcf1460247d51753c9309f4d2e8010b
2018-07-08 19:42:44 -07:00
Venkata Sharath Chandra Manchala
9347b8dbd0 qcacmn: Select window mask based on target
For QCA6390 PCI address space is reduced to 1MB.
Change bitmask to map it to appropriate range.

Change-Id: I70385df91855b7e7ddbedf7f0c6bf6e364b7d78c
CRs-Fixed: 2259194
2018-06-27 03:44:55 -07:00