diff --git a/core/hdd/src/wlan_hdd_cfg.c b/core/hdd/src/wlan_hdd_cfg.c index 6b38770d723c..a52bc2d9dd80 100644 --- a/core/hdd/src/wlan_hdd_cfg.c +++ b/core/hdd/src/wlan_hdd_cfg.c @@ -5970,11 +5970,6 @@ QDF_STATUS hdd_parse_config_ini(hdd_context_t *pHddCtx) /* Loop through the registry table and apply all these configs */ qdf_status = hdd_apply_cfg_ini(pHddCtx, cfgIniTable, i); hdd_set_rx_mode_value(pHddCtx); -#ifdef FEATURE_NAPI - if (QDF_STATUS_SUCCESS == qdf_status) - hdd_napi_event(NAPI_EVT_INI_FILE, - (void *)pHddCtx->napi_enable); -#endif /* FEATURE_NAPI */ if (QDF_GLOBAL_MONITOR_MODE == cds_get_conparam()) hdd_override_all_ps(pHddCtx); diff --git a/core/hdd/src/wlan_hdd_driver_ops.c b/core/hdd/src/wlan_hdd_driver_ops.c index 2f9ef28f03fb..e4527bdb170a 100644 --- a/core/hdd/src/wlan_hdd_driver_ops.c +++ b/core/hdd/src/wlan_hdd_driver_ops.c @@ -219,6 +219,12 @@ int hdd_hif_open(struct device *dev, void *bdev, const hif_bus_id *bid, qdf_device_t qdf_ctx = cds_get_context(QDF_MODULE_ID_QDF_DEVICE); struct hif_driver_state_callbacks cbk; uint32_t mode = cds_get_conparam(); + hdd_context_t *hdd_ctx = cds_get_context(QDF_MODULE_ID_HDD); + + if (!hdd_ctx) { + hdd_err("hdd_ctx error"); + return -EFAULT; + } hdd_hif_init_driver_state_callbacks(dev, &cbk); @@ -252,6 +258,9 @@ int hdd_hif_open(struct device *dev, void *bdev, const hif_bus_id *bid, ret, reinit); ret = -EFAULT; goto err_hif_close; + } else { + hdd_napi_event(NAPI_EVT_INI_FILE, + (void *)hdd_ctx->napi_enable); } }