diff --git a/components/ipa/core/inc/wlan_ipa_main.h b/components/ipa/core/inc/wlan_ipa_main.h index 469bdb17ffe0..2eb63928ea17 100644 --- a/components/ipa/core/inc/wlan_ipa_main.h +++ b/components/ipa/core/inc/wlan_ipa_main.h @@ -446,6 +446,13 @@ void ipa_fw_rejuvenate_send_msg(struct wlan_objmgr_pdev *pdev); */ void ipa_component_config_update(struct wlan_objmgr_psoc *psoc); +/** + * ipa_component_config_free() - Free ipa config + * + * Return: None + */ +void ipa_component_config_free(void); + /** * ipa_get_tx_buf_count() - get IPA config tx buffer count * @@ -474,6 +481,14 @@ void ipa_update_tx_stats(struct wlan_objmgr_pdev *pdev, uint64_t sta_tx, void ipa_flush_pending_vdev_events(struct wlan_objmgr_pdev *pdev, uint8_t vdev_id); +/** + * ipa_is_ready() - Is IPA register callback is invoked + * + * Return: true if IPA register callback is invoked or false + * otherwise + */ +bool ipa_is_ready(void); + #else /* Not IPA_OFFLOAD */ typedef QDF_STATUS (*wlan_ipa_softap_xmit)(qdf_nbuf_t nbuf, qdf_netdev_t dev); typedef void (*wlan_ipa_send_to_nw)(qdf_nbuf_t nbuf, qdf_netdev_t dev); diff --git a/components/ipa/core/src/wlan_ipa_core.c b/components/ipa/core/src/wlan_ipa_core.c index 7730d39b4242..590cf2c8af70 100644 --- a/components/ipa/core/src/wlan_ipa_core.c +++ b/components/ipa/core/src/wlan_ipa_core.c @@ -621,6 +621,9 @@ static void wlan_ipa_pm_flush(void *data) int wlan_ipa_uc_smmu_map(bool map, uint32_t num_buf, qdf_mem_info_t *buf_arr) { + if (!ipa_is_ready()) + return 0; + if (!num_buf) { ipa_info("No buffers to map/unmap"); return 0; @@ -3188,6 +3191,9 @@ QDF_STATUS wlan_ipa_cleanup(struct wlan_ipa_priv *ipa_ctx) struct wlan_ipa_iface_context *iface_context; int i; + if (!ipa_is_ready()) + return QDF_STATUS_SUCCESS; + if (!wlan_ipa_uc_is_enabled(ipa_ctx->config)) wlan_ipa_teardown_sys_pipe(ipa_ctx); @@ -3315,7 +3321,15 @@ static void wlan_ipa_uc_loaded_handler(struct wlan_ipa_priv *ipa_ctx) status); return; } - + /* Setup the Tx buffer SMMU mapings */ + status = cdp_ipa_tx_buf_smmu_mapping(ipa_ctx->dp_soc, + ipa_ctx->dp_pdev_id); + if (status) { + ipa_err("Failure to map Tx buffers for IPA(status=%d)", + status); + return; + } + ipa_info("TX buffers mapped to IPA"); cdp_ipa_set_doorbell_paddr(ipa_ctx->dp_soc, ipa_ctx->dp_pdev_id); wlan_ipa_init_metering(ipa_ctx); @@ -3561,6 +3575,15 @@ QDF_STATUS wlan_ipa_uc_ol_init(struct wlan_ipa_priv *ipa_ctx, goto fail_return; } + /* Setup the Tx buffer SMMU mapings */ + status = cdp_ipa_tx_buf_smmu_mapping(ipa_ctx->dp_soc, + ipa_ctx->dp_pdev_id); + if (status) { + ipa_err("Failure to map Tx buffers for IPA(status=%d)", + status); + return status; + } + ipa_info("TX buffers mapped to IPA"); cdp_ipa_set_doorbell_paddr(ipa_ctx->dp_soc, ipa_ctx->dp_pdev_id); wlan_ipa_init_metering(ipa_ctx); diff --git a/components/ipa/core/src/wlan_ipa_main.c b/components/ipa/core/src/wlan_ipa_main.c index bccce0ad2791..d0e283f7663e 100644 --- a/components/ipa/core/src/wlan_ipa_main.c +++ b/components/ipa/core/src/wlan_ipa_main.c @@ -43,6 +43,9 @@ QDF_STATUS ipa_config_mem_alloc(void) { struct wlan_ipa_config *ipa_cfg; + if (g_ipa_config) + return QDF_STATUS_SUCCESS; + ipa_cfg = qdf_mem_malloc(sizeof(*ipa_cfg)); if (!ipa_cfg) { ipa_err("Failed to allocate memory for ipa config"); @@ -164,6 +167,9 @@ QDF_STATUS ipa_rm_set_perf_level(struct wlan_objmgr_pdev *pdev, return QDF_STATUS_SUCCESS; } + if (!ipa_is_ready()) + return QDF_STATUS_SUCCESS; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -182,6 +188,9 @@ void ipa_uc_info(struct wlan_objmgr_pdev *pdev) return; } + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -200,6 +209,9 @@ void ipa_uc_stat(struct wlan_objmgr_pdev *pdev) return; } + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -218,6 +230,9 @@ void ipa_uc_rt_debug_host_dump(struct wlan_objmgr_pdev *pdev) return; } + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -236,6 +251,9 @@ void ipa_dump_info(struct wlan_objmgr_pdev *pdev) return; } + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -254,6 +272,9 @@ void ipa_uc_stat_request(struct wlan_objmgr_pdev *pdev, uint8_t reason) return; } + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -273,6 +294,9 @@ void ipa_uc_stat_query(struct wlan_objmgr_pdev *pdev, return; } + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -291,6 +315,9 @@ void ipa_reg_sap_xmit_cb(struct wlan_objmgr_pdev *pdev, wlan_ipa_softap_xmit cb) return; } + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -310,6 +337,9 @@ void ipa_reg_send_to_nw_cb(struct wlan_objmgr_pdev *pdev, return; } + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -328,6 +358,9 @@ void ipa_set_mcc_mode(struct wlan_objmgr_pdev *pdev, bool mcc_mode) return; } + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -346,6 +379,9 @@ void ipa_set_dfs_cac_tx(struct wlan_objmgr_pdev *pdev, bool tx_block) return; } + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -365,6 +401,9 @@ void ipa_set_ap_ibss_fwd(struct wlan_objmgr_pdev *pdev, uint8_t session_id, return; } + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -388,6 +427,9 @@ void ipa_uc_force_pipe_shutdown(struct wlan_objmgr_pdev *pdev) return; } + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -406,6 +448,9 @@ void ipa_flush(struct wlan_objmgr_pdev *pdev) return; } + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -424,6 +469,9 @@ QDF_STATUS ipa_suspend(struct wlan_objmgr_pdev *pdev) return QDF_STATUS_SUCCESS; } + if (!ipa_is_ready()) + return QDF_STATUS_SUCCESS; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -442,6 +490,9 @@ QDF_STATUS ipa_resume(struct wlan_objmgr_pdev *pdev) return QDF_STATUS_SUCCESS; } + if (!ipa_is_ready()) + return QDF_STATUS_SUCCESS; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -461,6 +512,9 @@ QDF_STATUS ipa_uc_ol_init(struct wlan_objmgr_pdev *pdev, return QDF_STATUS_SUCCESS; } + if (!ipa_is_ready()) + return QDF_STATUS_SUCCESS; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -479,6 +533,9 @@ bool ipa_is_tx_pending(struct wlan_objmgr_pdev *pdev) return QDF_STATUS_SUCCESS; } + if (!ipa_is_ready()) + return QDF_STATUS_SUCCESS; + ipa_obj = ipa_pdev_get_priv_obj(pdev); return wlan_ipa_is_tx_pending(ipa_obj); @@ -493,6 +550,11 @@ QDF_STATUS ipa_uc_ol_deinit(struct wlan_objmgr_pdev *pdev) return QDF_STATUS_SUCCESS; } + if (!ipa_is_ready()) { + ipa_debug("ipa is not ready"); + return QDF_STATUS_SUCCESS; + } + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -512,6 +574,9 @@ QDF_STATUS ipa_send_mcc_scc_msg(struct wlan_objmgr_pdev *pdev, return QDF_STATUS_SUCCESS; } + if (!ipa_is_ready()) + return QDF_STATUS_SUCCESS; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -528,6 +593,9 @@ QDF_STATUS ipa_wlan_evt(struct wlan_objmgr_pdev *pdev, qdf_netdev_t net_dev, { struct wlan_ipa_priv *ipa_obj; + if (!ipa_is_ready()) + return QDF_STATUS_SUCCESS; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -552,6 +620,11 @@ bool ipa_is_fw_wdi_activated(struct wlan_objmgr_pdev *pdev) return false; } + if (!ipa_is_ready()) { + ipa_debug("ipa is not ready"); + return false; + } + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err_rl("IPA object is NULL"); @@ -566,6 +639,11 @@ void ipa_uc_cleanup_sta(struct wlan_objmgr_pdev *pdev, { struct wlan_ipa_priv *ipa_obj; + if (!ipa_is_ready()) { + ipa_debug("ipa is not ready"); + return; + } + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -580,6 +658,9 @@ QDF_STATUS ipa_uc_disconnect_ap(struct wlan_objmgr_pdev *pdev, { struct wlan_ipa_priv *ipa_obj; + if (!ipa_is_ready()) + return QDF_STATUS_SUCCESS; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -594,6 +675,9 @@ void ipa_cleanup_dev_iface(struct wlan_objmgr_pdev *pdev, { struct wlan_ipa_priv *ipa_obj; + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -607,6 +691,9 @@ void ipa_uc_ssr_cleanup(struct wlan_objmgr_pdev *pdev) { struct wlan_ipa_priv *ipa_obj; + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -636,8 +723,11 @@ void ipa_fw_rejuvenate_send_msg(struct wlan_objmgr_pdev *pdev) void ipa_component_config_update(struct wlan_objmgr_psoc *psoc) { - if (!g_ipa_config) { - ipa_err("g_ipa_config is NULL"); + QDF_STATUS status; + + status = ipa_config_mem_alloc(); + if (QDF_IS_STATUS_ERROR(status)) { + ipa_err("Failed to alloc g_ipa_config"); return; } @@ -664,6 +754,12 @@ void ipa_component_config_update(struct wlan_objmgr_psoc *psoc) cfg_get(psoc, CFG_DP_IPA_ENABLE_FORCE_VOTING); } +void ipa_component_config_free(void) +{ + ipa_info("Free the IPA config memory"); + ipa_config_mem_free(); +} + uint32_t ipa_get_tx_buf_count(void) { return g_ipa_config ? g_ipa_config->txbuf_count : 0; @@ -694,6 +790,9 @@ void ipa_flush_pending_vdev_events(struct wlan_objmgr_pdev *pdev, if (!ipa_config_is_enabled()) return; + if (!ipa_is_ready()) + return; + ipa_obj = ipa_pdev_get_priv_obj(pdev); if (!ipa_obj) { ipa_err("IPA object is NULL"); @@ -702,3 +801,4 @@ void ipa_flush_pending_vdev_events(struct wlan_objmgr_pdev *pdev, wlan_ipa_flush_pending_vdev_events(ipa_obj, vdev_id); } + diff --git a/components/ipa/dispatcher/inc/wlan_ipa_obj_mgmt_api.h b/components/ipa/dispatcher/inc/wlan_ipa_obj_mgmt_api.h index b4e7e81b12ae..b53a6babc9d4 100644 --- a/components/ipa/dispatcher/inc/wlan_ipa_obj_mgmt_api.h +++ b/components/ipa/dispatcher/inc/wlan_ipa_obj_mgmt_api.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2018, 2020 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 @@ -40,6 +40,15 @@ QDF_STATUS ipa_init(void); * Return: QDF_STATUS_SUCCESS on success */ QDF_STATUS ipa_deinit(void); + +/** + * ipa_register_is_ipa_ready() - Register IPA ready callback + * @pdev: pointer to pdev + * + * Return: QDF_STATUS_SUCCESS on success + */ +QDF_STATUS ipa_register_is_ipa_ready(struct wlan_objmgr_pdev *pdev); + #else static inline QDF_STATUS ipa_init(void) @@ -51,6 +60,12 @@ static inline QDF_STATUS ipa_deinit(void) { return QDF_STATUS_SUCCESS; } + +static inline QDF_STATUS ipa_register_is_ipa_ready( + struct wlan_objmgr_pdev *pdev) +{ + return QDF_STATUS_SUCCESS; +} #endif /* IPA_OFFLOAD */ #endif /* _WLAN_IPA_OBJ_MGMT_H_ */ diff --git a/components/ipa/dispatcher/inc/wlan_ipa_ucfg_api.h b/components/ipa/dispatcher/inc/wlan_ipa_ucfg_api.h index b72790f3ae37..b03330dfecaa 100644 --- a/components/ipa/dispatcher/inc/wlan_ipa_ucfg_api.h +++ b/components/ipa/dispatcher/inc/wlan_ipa_ucfg_api.h @@ -357,6 +357,13 @@ void ucfg_ipa_fw_rejuvenate_send_msg(struct wlan_objmgr_pdev *pdev); */ void ucfg_ipa_component_config_update(struct wlan_objmgr_psoc *psoc); +/** + * ucfg_ipa_component_config_free() - Free IPA component config + * + * Return: None + */ +void ucfg_ipa_component_config_free(void); + /** * ucfg_get_ipa_tx_buf_count() - get IPA tx buffer count * @@ -588,6 +595,11 @@ void ucfg_ipa_component_config_update(struct wlan_objmgr_psoc *psoc) { } +static inline +void ucfg_ipa_component_config_free(void) +{ +} + static inline uint32_t ucfg_ipa_get_tx_buf_count(void) { diff --git a/components/ipa/dispatcher/src/wlan_ipa_obj_mgmt_api.c b/components/ipa/dispatcher/src/wlan_ipa_obj_mgmt_api.c index 8ca5779d33ff..305f5da1b982 100644 --- a/components/ipa/dispatcher/src/wlan_ipa_obj_mgmt_api.c +++ b/components/ipa/dispatcher/src/wlan_ipa_obj_mgmt_api.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2018, 2020 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 @@ -23,6 +23,13 @@ #include "wlan_ipa_main.h" #include "wlan_objmgr_global_obj.h" #include "target_if_ipa.h" +#include "wlan_ipa_ucfg_api.h" + +static bool g_ipa_is_ready; +bool ipa_is_ready(void) +{ + return g_ipa_is_ready; +} /** * ipa_pdev_obj_destroy_notification() - IPA pdev object destroy notification @@ -100,7 +107,41 @@ ipa_pdev_obj_create_notification(struct wlan_objmgr_pdev *pdev, } ipa_obj->pdev = pdev; + target_if_ipa_register_tx_ops(&ipa_obj->ipa_tx_op); + ipa_debug("ipa pdev attached"); + + return status; +} + +static void ipa_register_ready_cb(void *user_data) +{ + QDF_STATUS status = QDF_STATUS_SUCCESS; + struct wlan_objmgr_pdev *pdev = (struct wlan_objmgr_pdev *) + user_data; + struct wlan_objmgr_psoc *psoc; + qdf_device_t qdf_dev; + struct wlan_ipa_priv *ipa_obj; + + if (!ipa_config_is_enabled()) { + ipa_info("IPA config is disabled"); + return; + } + if (!pdev) { + ipa_err("Pdev obj mgr is NULL"); + return; + } + psoc = wlan_pdev_get_psoc(pdev); + qdf_dev = wlan_psoc_get_qdf_dev(psoc); + + if (!qdf_dev) { + ipa_err("QDF device context is NULL"); + return; + } + + g_ipa_is_ready = true; + ipa_info("IPA ready callback invoked: ipa_register_ready_cb"); + ipa_obj = ipa_pdev_get_priv_obj(pdev); status = ipa_obj_setup(ipa_obj); if (QDF_IS_STATUS_ERROR(status)) { ipa_err("Failed to setup ipa component"); @@ -108,14 +149,33 @@ ipa_pdev_obj_create_notification(struct wlan_objmgr_pdev *pdev, WLAN_UMAC_COMP_IPA, ipa_obj); qdf_mem_free(ipa_obj); - return status; + return; + } + if (ucfg_ipa_uc_ol_init(pdev, qdf_dev)) { + ipa_err("IPA ucfg_ipa_uc_ol_init failed"); + return; + } +} + +QDF_STATUS ipa_register_is_ipa_ready(struct wlan_objmgr_pdev *pdev) +{ + int ret; + + if (!ipa_config_is_enabled()) { + ipa_info("IPA config is disabled"); + return QDF_STATUS_SUCCESS; } - target_if_ipa_register_tx_ops(&ipa_obj->ipa_tx_op); - - ipa_debug("ipa pdev attached"); - - return status; + ret = qdf_ipa_register_ipa_ready_cb(ipa_register_ready_cb, + (void *)pdev); + if (ret == -EEXIST) { + ipa_info("IPA is ready, invoke callback"); + ipa_register_ready_cb((void *)pdev); + } else if (ret) { + ipa_err("Failed to check IPA readiness %d", ret); + return QDF_STATUS_E_FAILURE; + } + return QDF_STATUS_SUCCESS; } QDF_STATUS ipa_init(void) @@ -129,10 +189,6 @@ QDF_STATUS ipa_init(void) return status; } - status = ipa_config_mem_alloc(); - if (QDF_IS_STATUS_ERROR(status)) - return status; - status = wlan_objmgr_register_pdev_create_handler(WLAN_UMAC_COMP_IPA, ipa_pdev_obj_create_notification, NULL); @@ -172,7 +228,6 @@ QDF_STATUS ipa_deinit(void) if (!ipa_config_is_enabled()) { ipa_info("ipa is disabled"); - ipa_config_mem_free(); return status; } @@ -186,7 +241,5 @@ QDF_STATUS ipa_deinit(void) if (QDF_IS_STATUS_ERROR(status)) ipa_err("Failed to unregister pdev create handler"); - ipa_config_mem_free(); - return status; } diff --git a/components/ipa/dispatcher/src/wlan_ipa_ucfg_api.c b/components/ipa/dispatcher/src/wlan_ipa_ucfg_api.c index d3fc67335f49..2ef3d1c2b726 100644 --- a/components/ipa/dispatcher/src/wlan_ipa_ucfg_api.c +++ b/components/ipa/dispatcher/src/wlan_ipa_ucfg_api.c @@ -213,6 +213,11 @@ void ucfg_ipa_component_config_update(struct wlan_objmgr_psoc *psoc) ipa_component_config_update(psoc); } +void ucfg_ipa_component_config_free(void) +{ + ipa_component_config_free(); +} + uint32_t ucfg_ipa_get_tx_buf_count(void) { return ipa_get_tx_buf_count(); diff --git a/core/hdd/src/wlan_hdd_main.c b/core/hdd/src/wlan_hdd_main.c index f14efd647eab..6785302492fb 100644 --- a/core/hdd/src/wlan_hdd_main.c +++ b/core/hdd/src/wlan_hdd_main.c @@ -2304,10 +2304,6 @@ int hdd_update_tgt_cfg(hdd_handle_t hdd_handle, struct wma_tgt_cfg *cfg) ucfg_ipa_set_dp_handle(hdd_ctx->psoc, cds_get_context(QDF_MODULE_ID_SOC)); ucfg_ipa_set_pdev_id(hdd_ctx->psoc, OL_TXRX_PDEV_ID); - ucfg_ipa_reg_sap_xmit_cb(hdd_ctx->pdev, - hdd_softap_ipa_start_xmit); - ucfg_ipa_reg_send_to_nw_cb(hdd_ctx->pdev, - hdd_ipa_send_nbuf_to_network); status = ucfg_mlme_get_sub_20_chan_width(hdd_ctx->psoc, &sub_20_chan_width); @@ -3807,9 +3803,11 @@ int hdd_wlan_start_modules(struct hdd_context *hdd_ctx, bool reinit) void *hif_ctx; struct target_psoc_info *tgt_hdl; + hdd_enter(); qdf_dev = cds_get_context(QDF_MODULE_ID_QDF_DEVICE); if (!qdf_dev) { hdd_err("QDF Device Context is Invalid return"); + hdd_exit(); return -EINVAL; } @@ -4025,6 +4023,11 @@ int hdd_wlan_start_modules(struct hdd_context *hdd_ctx, bool reinit) hdd_ctx->driver_status = DRIVER_MODULES_ENABLED; hdd_nofl_debug("Wlan transitioned (now ENABLED)"); + ucfg_ipa_reg_sap_xmit_cb(hdd_ctx->pdev, + hdd_softap_ipa_start_xmit); + ucfg_ipa_reg_send_to_nw_cb(hdd_ctx->pdev, + hdd_ipa_send_nbuf_to_network); + hdd_exit(); return 0; @@ -13595,7 +13598,6 @@ int hdd_configure_cds(struct hdd_context *hdd_ctx) bool value; enum pmo_auto_pwr_detect_failure_mode auto_power_fail_mode; bool bval = false; - qdf_device_t qdf_ctx; mac_handle = hdd_ctx->mac_handle; @@ -13693,14 +13695,9 @@ int hdd_configure_cds(struct hdd_context *hdd_ctx) * observed otherwise. */ - qdf_ctx = cds_get_context(QDF_MODULE_ID_QDF_DEVICE); - if (!qdf_ctx) { - hdd_err("QDF device context is NULL"); - goto out; - } - - if (ucfg_ipa_uc_ol_init(hdd_ctx->pdev, qdf_ctx)) { - hdd_err("Failed to setup pipes"); + status = ipa_register_is_ipa_ready(hdd_ctx->pdev); + if (!QDF_IS_STATUS_SUCCESS(status)) { + hdd_err("ipa_register_is_ipa_ready failed"); goto out; } @@ -13971,6 +13968,7 @@ int hdd_wlan_stop_modules(struct hdd_context *hdd_ctx, bool ftm_mode) } /* pdev close and destroy use tx rx ops so call this here */ wlan_global_lmac_if_close(hdd_ctx->psoc); + ucfg_ipa_component_config_free(); } /*