refactor(rng): use adc_ll apis for ESP32-h4 and refactor rng_ll_enable/disable

This commit is contained in:
gaoxu
2026-05-26 19:02:41 +08:00
parent ad310ce681
commit 43317018d1
38 changed files with 533 additions and 418 deletions
+2 -2
View File
@@ -42,7 +42,7 @@
#include "hal/rtc_io_hal.h"
#include "hal/clk_tree_hal.h"
#if SOC_IS(ESP32C5) // Remove after all chips rng_ll.h implemented
#if RNG_LL_NEEDS_RESET_WHEN_WAKEUP
#include "hal/rng_ll.h"
#endif
@@ -756,7 +756,7 @@ static SLEEP_FN_ATTR void misc_modules_wake_prepare(uint32_t sleep_flags)
#if SOC_TEMPERATURE_SENSOR_SUPPORT_SLEEP_RETENTION
temperature_sensor_hal_i2c_saradc_reg_restore();
#endif
#if RNG_LL_DEPENDS_ON_LP_PERIPH
#if RNG_LL_NEEDS_RESET_WHEN_WAKEUP
if (sleep_flags & PMU_SLEEP_PD_LP_PERIPH) {
// Re-enable the RNG module.
rng_ll_reset();