qcacmn: cdp: Convergence of cdp_misc_ops
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
This commit is contained in:
@@ -30,13 +30,17 @@
|
||||
|
||||
/**
|
||||
* cdp_hl_fc_register() - Register HL flow control callback.
|
||||
* @soc - data path soc handle
|
||||
* @flowcontrol - callback function pointer to stop/start OS netdev queues
|
||||
* @soc: data path soc handle
|
||||
* @pdev_id: datapath pdev identifier
|
||||
* @flowcontrol: callback function pointer to stop/start OS netdev queues
|
||||
*
|
||||
* Register flow control callback.
|
||||
* return 0 success
|
||||
*
|
||||
* Returns: 0 for success
|
||||
*/
|
||||
static inline int
|
||||
cdp_hl_fc_register(ol_txrx_soc_handle soc, tx_pause_callback flowcontrol)
|
||||
cdp_hl_fc_register(ol_txrx_soc_handle soc, uint8_t pdev_id,
|
||||
tx_pause_callback flowcontrol)
|
||||
{
|
||||
if (!soc || !soc->ops) {
|
||||
QDF_TRACE(QDF_MODULE_ID_DP, QDF_TRACE_LEVEL_DEBUG,
|
||||
@@ -49,7 +53,7 @@ cdp_hl_fc_register(ol_txrx_soc_handle soc, tx_pause_callback flowcontrol)
|
||||
!soc->ops->l_flowctl_ops->register_tx_flow_control)
|
||||
return -EINVAL;
|
||||
|
||||
return soc->ops->l_flowctl_ops->register_tx_flow_control(soc,
|
||||
return soc->ops->l_flowctl_ops->register_tx_flow_control(soc, pdev_id,
|
||||
flowcontrol);
|
||||
}
|
||||
|
||||
@@ -76,7 +80,8 @@ static inline int cdp_hl_fc_set_os_queue_status(ol_txrx_soc_handle soc,
|
||||
}
|
||||
#else
|
||||
static inline int
|
||||
cdp_hl_fc_register(ol_txrx_soc_handle soc, tx_pause_callback flowcontrol)
|
||||
cdp_hl_fc_register(ol_txrx_soc_handle soc, uint8_t pdev_id,
|
||||
tx_pause_callback flowcontrol)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user