diff --git a/dp/inc/cdp_txrx_ctrl_def.h b/dp/inc/cdp_txrx_ctrl_def.h index 54f0fa87fdad..93d86763fba3 100644 --- a/dp/inc/cdp_txrx_ctrl_def.h +++ b/dp/inc/cdp_txrx_ctrl_def.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2016 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2016,2018 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -72,8 +72,10 @@ void ol_ll_pdev_tx_unlock(void *); qdf_spin_unlock_bh(&((_x)->peer_lock[_id])) #else -#define OSIF_VAP_TX_LOCK(_x) ol_ll_pdev_tx_lock((_x)->iv_txrx_handle) -#define OSIF_VAP_TX_UNLOCK(_x) ol_ll_pdev_tx_unlock((_x)->iv_txrx_handle) +#define OSIF_VAP_TX_LOCK(_x) ol_ll_pdev_tx_lock( \ + wlan_vdev_get_dp_handle((_x)->os_if_vdev)) +#define OSIF_VAP_TX_UNLOCK(_x) ol_ll_pdev_tx_unlock( \ + wlan_vdev_get_dp_handle((_x)->os_if_vdev)) #define OL_TX_FLOW_CTRL_LOCK(_x) #define OL_TX_FLOW_CTRL_UNLOCK(_x) diff --git a/target_if/son/src/target_if_son.c b/target_if/son/src/target_if_son.c index 8860a3f702c5..22895a8d6141 100644 --- a/target_if/son/src/target_if_son.c +++ b/target_if/son/src/target_if_son.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017 The Linux Foundation. All rights reserved. + * Copyright (c) 2017-2018 The Linux Foundation. All rights reserved. * * * Permission to use, copy, modify, and/or distribute this software for @@ -27,15 +27,19 @@ bool son_ol_is_peer_inact(struct wlan_objmgr_peer *peer) { - struct wlan_objmgr_pdev *pdev = NULL; - struct wlan_objmgr_vdev *vdev = NULL; + struct wlan_objmgr_vdev *vdev; + struct wlan_objmgr_psoc *psoc; vdev = wlan_peer_get_vdev(peer); + if (!vdev) + return false; - pdev = wlan_vdev_get_pdev(vdev); + psoc = wlan_vdev_get_psoc(vdev); + if (!psoc) + return false; - return cdp_peer_is_inact(ol_if_pdev_get_soc_txhandle(pdev), - (void *)(ol_if_peer_get_txrx_handle(peer))); + return cdp_peer_is_inact(wlan_psoc_get_dp_handle(psoc), + (void *)(wlan_peer_get_dp_handle(peer))); } u_int32_t son_ol_get_peer_rate(struct wlan_objmgr_peer *peer, u_int8_t type) @@ -46,17 +50,26 @@ u_int32_t son_ol_get_peer_rate(struct wlan_objmgr_peer *peer, u_int8_t type) bool son_ol_enable(struct wlan_objmgr_pdev *pdev, bool enable) { + struct wlan_objmgr_psoc *psoc; - return cdp_start_inact_timer(ol_if_pdev_get_soc_txhandle(pdev), - (void *)(ol_if_pdev_get_soc_pdev_handle(pdev)), + psoc = wlan_pdev_get_psoc(pdev); + if (!psoc) + return false; + + return cdp_start_inact_timer(wlan_psoc_get_dp_handle(psoc), + (void *)(wlan_pdev_get_dp_handle(pdev)), enable); } /* Function pointer to set overload status */ void son_ol_set_overload(struct wlan_objmgr_pdev *pdev, bool overload) { - return cdp_set_overload(ol_if_pdev_get_soc_txhandle(pdev), - (void *)(ol_if_pdev_get_soc_pdev_handle(pdev)), + struct wlan_objmgr_psoc *psoc; + + psoc = wlan_pdev_get_psoc(pdev); + + return cdp_set_overload(wlan_psoc_get_dp_handle(psoc), + (void *)(wlan_pdev_get_dp_handle(pdev)), overload); } /* Function pointer to set band steering parameters */ @@ -65,9 +78,11 @@ bool son_ol_set_params(struct wlan_objmgr_pdev *pdev, u_int32_t inactivity_threshold_normal, u_int32_t inactivity_threshold_overload) { + struct wlan_objmgr_psoc *psoc; - return cdp_set_inact_params(ol_if_pdev_get_soc_txhandle(pdev), - (void *)ol_if_pdev_get_soc_pdev_handle(pdev), + psoc = wlan_pdev_get_psoc(pdev); + return cdp_set_inact_params(wlan_psoc_get_dp_handle(psoc), + (void *)wlan_pdev_get_dp_handle(pdev), inactivity_check_period, inactivity_threshold_normal, inactivity_threshold_overload); diff --git a/utils/pktlog/linux_ac.c b/utils/pktlog/linux_ac.c index cafaf3a8f836..26049712242f 100644 --- a/utils/pktlog/linux_ac.c +++ b/utils/pktlog/linux_ac.c @@ -110,8 +110,7 @@ int pktlog_alloc_buf(struct hif_opaque_softc *scn) if (!pl_dev) { printk(PKTLOG_TAG - "%s: Unable to allocate buffer " - "scn or scn->pdev_txrx_handle->pl_dev is null\n", + "%s: Unable to allocate buffer pdev_txrx_handle or pdev_txrx_handle->pl_dev is null\n", __func__); return -EINVAL; }