Created a new interrupt mask for msi chipsets so that both ahb
and pci chipsets can work together.
Change-Id: I78d1b9641e58f07d1582152c691c5ae29e6ddb03
Setting interrupt mode in dp_soc_init as setting it in
dp_soc_attach is resulting in interrupt mode not set on
subsequent wifi down/up. soc_attach is called only in case
of wifi unload/load and not in case of wifi down/up.
Adding interrupt mode setting in soc_init helps in setting
correct interrupt mode in case of wifi down/up.
Change-Id: I9e6ad94e42b7bc2bf84f832ece8dc8779e335905
If two back to back HTT msg sending happened in short time,
the second HTT msg source SRNG HP writing has chance to fail,
this has been confirmed by HST HW.
For monitor mode, HTT msg for monitor status ring configuration
is the last msg for sending, if the 2nd HTT msg for monitor status ring
sending failed, HW won't provide anything into 2nd monitor status ring.
as a WAR, add some delay before 2nd HTT msg start sending, > 2us is
required per HST HW, delay 100 us for safe.
Change-Id: Id2a5a8798fde79267f9d6f9ba23d8ed54a400aa7
CRs-Fixed: 2597248
Currently in lithium FW is not always in datapath. As a result
can not provide all the wlan vendor extended stats. So as part
of this host provides some of the extended stats.
Change-Id: I876b6e905f7e25b7088f80f07e55e26a7a409241
CRs-Fixed: 2594797
Channel Frequency Response(CFR) captures FFT bins corresponding to a PPDU
received and this is relayed to user space application. Since FFT bins
alone will not be meaningful, additional information about the PPDU such
as Peer addr, BW, NSS, etc are extracted from multiple PPDU status TLVs
and passed on to userspace along with CFR data.
Host RX monitor status ring is configured during CFR enable and the host
subscribes to relevant PPDU TLVs that provides all necessary information
for CFR data correlation.
Change-Id: Ia8080fe96c330db42d371634ba4363eb36c05402
CRs-Fixed: 2593416
Currently cdp ops are given pdev/vdev/peer
handle as its arguments, which is directly
accessed in those APIs. This can cause a
race-condition in access of the respective
handles if it has been deleted in parallel.
Hence as a part of cdp convergence, pass only
the pdev_id or vdev_id or peer mac address,
which will be used to get the respective handles,
and hence avoiding the unwanted access of the
handles if it has been deleted.
- txrx_peer_unmap_sync_cb_set
- txrx_fw_stats_get
- txrx_get_ctrl_pdev_from_vdev
- txrx_get_mon_vdev_from_pdev
Change-Id: I4472dc0905edb7700acb4401b117c8876ba455f3
CRs-Fixed: 2541460
Change cmn_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: I5716a87cad56b1dfe8dd56f193bbb6ff923a6af1
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
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
Reset ba_status to inactive irrespective of tid update status to make
sure the ba_status reset successfully.
And also use pe_err_rl instead of pe_err to avoid excessive logging.
Change-Id: Ifc6adc166b5093742b34dd7d74924f9d54146ea4
CRs-Fixed: 2577663
crash scenario:
a. pktlog is enabled, the timer mon_reap_timer is active,
reap mon_status_ring hal desc periodically.
b. rx_desc status pool is freed in dp_rx_pdev_mon_detach() when do
dp_pdev_deinit() while the mon_reap_timer is still active until
dp_rxdma_ring_cleanup() free it.
c. during the timeslot between dp_rx_pdev_mon_detach() and
dp_rxdma_ring_cleanup(), if some hal desc is pending to be
processed on mon_status_ring, invalid accessing to rx_desc_status
pool happened.
solution:
if pktlog is enabled, stop mon_reap_timer ahead of
dp_rx_pdev_mon_detach() in dp_pktlogmod_exit().
Change-Id: I91b16a88a5e4390587925d6eb2840b3ec1ec2187
CRs-Fixed: 2579817
Crash scenario:
a. monitor mode dp_vdev is freed in dp_vdev_detach_wifi3 without
checking whether any dp_peer is associated.
b. monitor mode self dp_peer do peer clean up when HTT peer
unmap MSG received, invalid accessing to dp_vdev as it has been
freed in step (a).
Check if there is dp_peer associated for monitor mode dp_vdev,
skip dp_vdev free, when all dp_peer is freed, dp_delete_pending_vdev
will free dp_vdev.
Change-Id: Iea4b0efc6e7bbd4109d9cd0b109dfddf727a9fff
CRs-Fixed: 2576604
Local peer_id is being cleaned up across DP, HDD and PS/WMA.
So, any references to local peer_id/sta_id will be replaced
by peer mac address and all interactions between the layers
will be based on peer mac address.
Cleanup local peer id usage from DP APIs.
Change-Id: I930e1c6a09092a373c093239632d6f310fee18e2
CRs-Fixed: 2529041
Local peer_id is being cleaned up across DP, HDD and PS/WMA.
So, any references to local peer_id/sta_id will be replaced
by peer mac address and all interactions between the layers
will be based on peer mac address.
Cleanup unusued DP APIs which are based on local peer_id.
Change-Id: Idd95bc640ca7e36a427be7202935034d4ed58979
CRs-Fixed: 2529026
Remove pdev and vdev control path handles from data path.
Instead send pdev_id and vdev_id along with opaque soc
handle in ol_if_ops.
Change-Id: I6ee083f07e464f283da0d70ada70a4e10e18e1b2
Avoid freeing flow_pool_array_lock when it is
not created. So free flow_pool_array_lock in 2
ways:
1. When dp_soc_cmn_setup fails free the flow_pool_array
lock only if it is created and then close the dp
soc handle.
2. As flow_pool_array_lock is created in dp_soc_cmn_setup
as part of dp_pdev_attach_wifi3 init sequence free the
lock only in the dp_soc_cmn_cleanup as part of the
dp_pdev_detach_wifi3 deinit sequence.
Change-Id: Ie3e11da0bc0854fa550c5d417ca3c0bc9e2593b1
CRs-Fixed: 2565603
This reverts commit I37a7c98eef6a8ad0b27541584927505ffc447cb2.
Reverting because below change address the compilation error
I4bb7bb14a2e521645be6e2677a44a78fa79fcb0b
Change-Id: Ib38276ab9974cf22486631f10ec345a629637b82
1. Add hif_force_wake_request API to wake the
mhi and umac before reading/writing the memory region
greater than BAR+4K.
2. Add hif_force_wake_release API to release the
PCIE_PCIE_LOCAL_REG_PCIE_SOC_WAKE_PCIE_LOCAL_REG so the
umac can power collapse again at a later point of time.
3. Add pci stats to dump the force wake status.
Change-Id: Ic6d5463ea0cdb28d9144be61da55e43033b53298
CRs-Fixed: 2478052
crash scenario:
a. dp_peer_unref_delete remove peer from vdev->peer_list.
b. dp_vdev_detach_wifi3 skip setting vdev->delete.pending as
vdev->peer_list is empty, dp_vdev is freed.
c. dp_peer_unref_delete still try to access dp_vdev after first
peer_ref_mutex released, invalid accessing happened.
solution:
a. Get vdev member like vdev->delete.pending flag within
first peer_ref_mutex in dp_peer_unref_delete to avoid vdev freed.
b. Separate dp_reset_and_release_peer_mem function into two function
dp_vdev_reset_peer/dp_peer_release_mem, dp__vdev_reset_peer
will be invoked within first peer_ref_mutex. after first
peer_ref_mutex is released, invoke dp_peer_release_mem since dp_soc
->cdp_soc.ol_ops->peer_unref_delete should be outside of
peer_ref_mutex in case deadlock issue reported from WIN.
Change-Id: I90f3b139030c5ce399d85723ae4f67ce0faf4b28
CRs-Fixed: 2568256
Currently after disabling mcopy mode, remaining status
buffers are not freed, free status buffers at proper place
Change-Id: I4a04a7ab58771ce1dd21f3ee08b42589f312eb76
Currently the cdp apis are given pdev/vdev/peer
handle as its arguments, which is directly
accessed in those APIs. This can cause a
race-condition in access of the respective
handles, if it has been deleted in parallel.
Hence as a part of cdp convergence, pass only
the pdev/vdev id or peer mac address, which will be
used to get the respective handles, and hence
avoiding the unwanted access of the handles, if
it has been deleted.
Converged bus_ops
- bus_suspend
- bus_resume
CRs-Fixed: 2539826
Change-Id: Id4d6ba16beae89f4052e72024ef8ce891ea33715
Currently the cdp apis are given pdev/vdev/peer
handle as its arguments, which is directly
accessed in those APIs. This can cause a
race-condition in access of the respective
handles, if it has been deleted in parallel.
Hence as a part of cdp convergence, pass only
the pdev/vdev id or peer mac address, which will be
used to get the respective handles, and hence
avoiding the unwanted access of the handles, if
it has been deleted.
Converged misc_ops
- tx_non_std
- get_opmode
- get_tx_ack_stats
- set_ibss_vdev_heart_beat_timer
- hl_tdls_flag_reset
- set_wisa_mode
- txrx_post_data_stall_event
- update_mac_id
- pkt_log_init
- pkt_log_con_service
- get_num_rx_contexts
- set_wmm_param
- flush_rx_frames
- bad_peer_txctl_set_setting
- bad_peer_txctl_update_threshold
- txrx_data_stall_cb_register
- txrx_data_stall_cb_deregister
- vdev_set_driver_del_ack_enable
- get_intra_bss_fwd_pkts_count
- mark_first_wakeup_packet
- register_pktdump_cb
- unregister_pktdump_cb
- pdev_reset_driver_del_ack
- runtime_suspend
- runtime_resume
CRs-Fixed: 2539811
Change-Id: I3080df033d6411d7078a322224b914bda2fddc0e
Fix compilation error in DP_PRINT which is
seen when compiled for lithium datapath.
CRs-Fixed: 2567068
Change-Id: I4bb7bb14a2e521645be6e2677a44a78fa79fcb0b
Currently the cdp apis are given pdev/vdev/peer
handle as its arguments, which is directly
accessed in those APIs. This can cause a
race-condition in access of the respective
handles if it has been deleted in parallel.
Hence as a part of cdp convergence, pass only
the pdev/vdev id or peer mac address, which will be
used to get the respective handles, and hence
avoiding the unwanted access of the handles if
it has been deleted.
Converged mob_stats_ops
- clear_stats
CRs-Fixed: 2539824
Change-Id: Id424b939c8ef77bd9fae55eaa4c08023efc32093
The datapath vdev handle is not to be used outside
datapath layer. So the cdp api for getting txrx stats
will pass vdev_id instead of the vdev handle.
Pass vdev id instead of vdev handle for the cdp api
used to get txrx stats. Use the vdev_id to retrieve
the corresponding vdev handle in the txrx stats handler.
CRs-Fixed: 2560364
Change-Id: I57b6c6b232d122583e85929fa972d68bc54e84e0
When a particular vdev is deleted, the corresponding rx
packets which have been queued to the rx thread are not
flushed. Hence when such packets are submitted to the
network stack, the dev for this skb will be invalid,
since we have already freed the adapter.
Flush out the packets in the rx thread queues, before
deleting the vdev.
CRs-Fixed: 2543392
Change-Id: I2490d0f5ce965f62152613a17a59232521ca058f
The reo destination ctrl registers
HWIO_REO_R0_DESTINATION_RING_CTRL_IX_2_ADDR and
HWIO_REO_R0_DESTINATION_RING_CTRL_IX_3_ADDR are used for mapping
msdu packets to different reo rings.
For QCA6390,
reo remap values varied from 0 - 7 so every 3 bits in
the register were used to map to a particular reo ring.
For QCA6490,
reo remap values vary from 0 - 9 as two extra reo rings are
added so we are using 4 bits in the register to map to a
particular reo ring.
Use the macros directly provided in the header files
to map reo rings.
Change-Id: I6d64266d3b388b3453b7df959048e3d693cf0a40
CRs-Fixed: 2544102
Add support to account for TSO jumbo packets on the
Tx path and print the statistics using dumpStats 3.
Change-Id: I6cc446df5c84e3ac436d922935fcd559e0704ec5
CRs-Fixed: 2356244
Add the following support for QCA6490:
1. Initialize the qca6490_hal_hw_txrx_ops
2. Initialize the hw_srng_table
3. Attach hal_qca6490_attach
Change-Id: Ic53c520ef804eb4fbe1434c704e9040c83011d3d
CRs-Fixed: 2522133
Currently the interrupt mode is set as a part of
interrupt attach. The interrupt mode is needed for
pdev attach and hence it is decoupled from the interrupt
attach, setting the interrupt mode during soc attach.
Set the correct interrupt mode during soc attach.
CRs-Fixed: 2500015
Change-Id: I68496bed68cac5a2a2bd19adf2377bae7eb8783c
Currently after runtime resume all SW2TCL data and reo cmd
srng rings hp and tp value are flushed. In case of IPA
offload case SW2TCL3 righ hp value will be updated by IPA
and not by host. In case of runtime pm enable host is
setting the value to zero as part of runtime resume which
results in incorrect hp value of SW2TCL3. As part of this
change set flush event for rings which are accessed by host
during link down state and after runtime resume flush the
rings for which flush event is set.
Change-Id: I5c9afa708277cf3a6e6d5ef99447bc21f88cfdcf
CRs-Fixed: 2514621
In cases where one of the interfaces is a P2P-GO and
IPA has been enabled, the P2P connection establishment
fails.
When IPA is enabled, the REO destination is changed to REO4
which can be reaped only by IPA module. But in case of P2P-GO
interface in operation, this change in configuration causes
all the RX packets to be stalled due to incorrect REO configuration.
Hence, to avoid this case, do not change the REO dest config
when the interface subtype is P2P.
CRs-Fixed: 2498315
Change-Id: Ie9f01c3b353c7c0503e1541d6c79c2f47c9782f3
Refine dp_vdev_flush_peers,
a. wrap ast entry flushing into dp_peer_flush_ast_entry()
b. if unmap_only is true, logic keep same.
c. if unmap_only is false, also use __dp_peer_find_by_id
instead of dp_peer_find_by_id to get peer object.
only if peer flag valid is true, then call dp_peer_delete_wifi3
to avoid peer member invalid accessing.
Change-Id: I7a6d53e124ff369305b91050731901ff0a43d6af
CRs-Fixed: 2534274
During special vap channel change, we see "monitor vap already created"
print on the console. This is the expected print, because
pdev->monitor_configured is set during wifi up. Therefore, change the
debug level of this print from ERROR to DEBUG.
Change-Id: Ia290b74d9be20691eac3ebc50f6cc3fff3e94953
CRs-Fixed: 2529580
During SSR in dp_vdev_flush_peers function, the else condition finds peers
to delete by calling dp_peer_find_by_id. If the delete_in_progress_ flag
has already been set to TRUE, then dp_peer_find_by_id will return NULL
and not delete the vdev object. Calling __dp_peer_find_by_id will always
return peer id so all peers are sure to be deleted.
Change-Id: I86bf2bdda7ebc5a9c2f4bbc877392ebff9cbaf59
CRs-Fixed: 2513104
Replace dp_srng_mem_alloc() by qdf_aligned_mem_alloc_consistent() and
qdf_aligned_malloc() in dp_srng_setup().
Change-Id: Iae236a3cc19ec7a9f94b04382d37fc95e6ed622f
CRs-Fixed: 2462455