fix(esp_hw_support): Fix deepsleep leakage after initializing USB HS phy
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* SPDX-FileCopyrightText: 2024 Espressif Systems (Shanghai) CO LTD
|
||||
* SPDX-FileCopyrightText: 2024-2025 Espressif Systems (Shanghai) CO LTD
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
@@ -13,7 +13,8 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#if SOC_USB_OTG_SUPPORTED && SOC_PM_SUPPORT_CNNT_PD
|
||||
#if SOC_USB_OTG_SUPPORTED
|
||||
#if SOC_PM_SUPPORT_CNNT_PD
|
||||
/**
|
||||
* @brief Backup usb OTG phy bus_clock / stoppclk configuration and
|
||||
* before light sleep to avoid current leakage
|
||||
@@ -26,6 +27,16 @@ void sleep_usb_otg_phy_backup_and_disable(void);
|
||||
void sleep_usb_otg_phy_restore(void);
|
||||
#endif
|
||||
|
||||
#if SOC_USB_UTMI_PHY_NO_POWER_OFF_ISO
|
||||
/**
|
||||
* @brief The DP/DM part of the UTMI PHY circuit of esp32p4 that converts logic level to digital
|
||||
* has no power off isolation, which will cause leakage when entering deepsleep.
|
||||
* This problem can be workarounded by enabling USB-OTG's HNP (Host negotiation protocol)
|
||||
* to enable DM pull-down to suppress leakage.
|
||||
*/
|
||||
void sleep_usb_suppress_deepsleep_leakage(void);
|
||||
#endif
|
||||
#endif
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user