From 823e1da54370754cc73143e3f483b2e8d6bbb062 Mon Sep 17 00:00:00 2001 From: Darian Leung Date: Tue, 21 Jun 2022 00:12:08 +0800 Subject: [PATCH] wifi: Fix linking of WiFi functions dependent on PM_ENABLE The following functions are only defined when CONFIG_PM_ENABLE is defined: - wifi_apb80m_request() - wifi_apb80m_release() This commit makes their linker script mapping statements also dependent on CONFIG_PM_ENABLE thus fixing some linker errors when CONFIG_PM_ENABLE is disabled. --- components/esp_wifi/linker.lf | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/components/esp_wifi/linker.lf b/components/esp_wifi/linker.lf index 27407adda9..3c5c0100e8 100644 --- a/components/esp_wifi/linker.lf +++ b/components/esp_wifi/linker.lf @@ -64,8 +64,9 @@ entries: phy_init:esp_phy_enable (noflash) phy_init:esp_phy_disable (noflash) phy_init:esp_wifi_bt_power_domain_off (noflash) - wifi_init:wifi_apb80m_request (noflash) - wifi_init:wifi_apb80m_release (noflash) + if PM_ENABLE = y: + wifi_init:wifi_apb80m_request (noflash) + wifi_init:wifi_apb80m_release (noflash) [mapping:driver_wifi_pm] archive: libdriver.a