diff --git a/core/hdd/inc/wlan_hdd_spectralscan.h b/core/hdd/inc/wlan_hdd_spectralscan.h index 02fe1fc1d57f..c1754e5b56cf 100644 --- a/core/hdd/inc/wlan_hdd_spectralscan.h +++ b/core/hdd/inc/wlan_hdd_spectralscan.h @@ -207,8 +207,22 @@ int wlan_hdd_cfg80211_spectral_scan_get_status(struct wiphy *wiphy, struct wireless_dev *wdev, const void *data, int data_len); + +/** + * hdd_spectral_register_to_dbr() - Register spectral to DBR + * @hdd_ctx: pointer to hdd context + * + * This function is that register spectral to Direct Buffer RX component. + * + * Return: None + */ +void hdd_spectral_register_to_dbr(struct hdd_context *hdd_ctx); #else #define FEATURE_SPECTRAL_SCAN_VENDOR_COMMANDS +static inline void +hdd_spectral_register_to_dbr(struct hdd_context *hdd_ctx) +{ +} #endif #if defined(CNSS_GENL) && defined(WLAN_CONV_SPECTRAL_ENABLE) diff --git a/core/hdd/src/wlan_hdd_main.c b/core/hdd/src/wlan_hdd_main.c index 55768ec2523a..6a6e79492f2c 100644 --- a/core/hdd/src/wlan_hdd_main.c +++ b/core/hdd/src/wlan_hdd_main.c @@ -3303,6 +3303,13 @@ int hdd_wlan_start_modules(struct hdd_context *hdd_ctx, bool reinit) hdd_register_policy_manager_callback( hdd_ctx->psoc); + /* + * Call this function before hdd_enable_power_management. Since + * it is required to trigger WMI_PDEV_DMA_RING_CFG_REQ_CMDID + * to FW when power save isn't enable. + */ + hdd_spectral_register_to_dbr(hdd_ctx); + hdd_sysfs_create_driver_root_obj(); hdd_sysfs_create_version_interface(hdd_ctx->psoc); hdd_sysfs_create_powerstats_interface(); diff --git a/core/hdd/src/wlan_hdd_spectralscan.c b/core/hdd/src/wlan_hdd_spectralscan.c index b8c2b9eb6b78..6733472649d0 100644 --- a/core/hdd/src/wlan_hdd_spectralscan.c +++ b/core/hdd/src/wlan_hdd_spectralscan.c @@ -395,6 +395,11 @@ int wlan_hdd_cfg80211_spectral_scan_get_status(struct wiphy *wiphy, return errno; } +void hdd_spectral_register_to_dbr(struct hdd_context *hdd_ctx) +{ + ucfg_spectral_register_to_dbr(hdd_ctx->pdev); +} + #if defined(CNSS_GENL) && defined(WLAN_CONV_SPECTRAL_ENABLE) static void spectral_get_version(struct wlan_objmgr_pdev *pdev, uint32_t *version,