mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-02 11:10:54 +03:00
refactor(esp_clk_tree): rename esp_clk_tree_enable_src API
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -117,7 +117,7 @@ static void gptimer_unregister_from_group(gptimer_t *timer)
|
||||
static esp_err_t gptimer_destroy(gptimer_t *timer)
|
||||
{
|
||||
if (timer->clk_src) {
|
||||
ESP_RETURN_ON_ERROR(esp_clk_tree_enable_src((soc_module_clk_t)(timer->clk_src), false), TAG, "clock source disable failed");
|
||||
ESP_RETURN_ON_ERROR(esp_clk_tree_release_src((soc_module_clk_t)(timer->clk_src)), TAG, "clock source disable failed");
|
||||
}
|
||||
#if CONFIG_PM_ENABLE
|
||||
if (timer->pm_lock) {
|
||||
|
||||
@@ -91,7 +91,7 @@ esp_err_t gptimer_select_periph_clock(gptimer_t *timer, gptimer_clock_source_t s
|
||||
uint32_t counter_src_hz = 0;
|
||||
int timer_id = timer->timer_id;
|
||||
int group_id = timer->group->group_id;
|
||||
ESP_RETURN_ON_ERROR(esp_clk_tree_enable_src(src_clk, true), TAG, "clock source enable failed");
|
||||
ESP_RETURN_ON_ERROR(esp_clk_tree_acquire_src(src_clk), TAG, "clock source enable failed");
|
||||
timer->clk_src = src_clk;
|
||||
|
||||
// get clock source frequency
|
||||
|
||||
Reference in New Issue
Block a user