diff --git a/core/hdd/src/wlan_hdd_main.c b/core/hdd/src/wlan_hdd_main.c index d34f6693195e8..2784007c35a3a 100644 --- a/core/hdd/src/wlan_hdd_main.c +++ b/core/hdd/src/wlan_hdd_main.c @@ -1874,6 +1874,8 @@ void hdd_update_tgt_cfg(hdd_handle_t hdd_handle, struct wma_tgt_cfg *cfg) } } + hdd_objmgr_update_tgt_max_vdev_psoc(hdd_ctx, cfg->max_intf_count); + ret = hdd_green_ap_update_config(hdd_ctx); ucfg_ipa_set_dp_handle(hdd_ctx->hdd_psoc, diff --git a/core/hdd/src/wlan_hdd_object_manager.c b/core/hdd/src/wlan_hdd_object_manager.c index 9fe3044f1cae9..353dfbe55be63 100644 --- a/core/hdd/src/wlan_hdd_object_manager.c +++ b/core/hdd/src/wlan_hdd_object_manager.c @@ -116,6 +116,19 @@ int hdd_objmgr_release_and_destroy_psoc(struct hdd_context *hdd_ctx) return qdf_status_to_os_return(status); } +void hdd_objmgr_update_tgt_max_vdev_psoc(struct hdd_context *hdd_ctx, + uint8_t max_vdev) +{ + struct wlan_objmgr_psoc *psoc = hdd_ctx->hdd_psoc; + + if (!psoc) { + hdd_err("Psoc NULL"); + return; + } + + wlan_psoc_set_max_vdev_count(psoc, max_vdev); +} + int hdd_objmgr_create_and_store_pdev(struct hdd_context *hdd_ctx) { QDF_STATUS status; diff --git a/core/hdd/src/wlan_hdd_object_manager.h b/core/hdd/src/wlan_hdd_object_manager.h index d3f957ca11424..c41ec80d49778 100644 --- a/core/hdd/src/wlan_hdd_object_manager.h +++ b/core/hdd/src/wlan_hdd_object_manager.h @@ -78,6 +78,17 @@ int hdd_objmgr_create_and_store_psoc(struct hdd_context *hdd_ctx, */ int hdd_objmgr_release_and_destroy_psoc(struct hdd_context *hdd_ctx); +/** + * hdd_objmgr_update_tgt_max_vdev_psoc() - Update target max vdev number + * @hdd_ctx: Hdd context + * + * This API update target max vdev number to psoc object + * + * Return: None + */ +void hdd_objmgr_update_tgt_max_vdev_psoc(struct hdd_context *hdd_ctx, + uint8_t max_vdev); + /** * hdd_objmgr_create_and_store_pdev() - Create pdev and store in hdd context * @hdd_ctx: Hdd context