Skip to content

Commit 370e79e

Browse files
committed
Merge branch 'feature/clean_up_some_tasks_in_epic' into 'master'
driver: clean up some tasks in epic Closes IDF-11118, IDF-12003, IDF-10243, IDF-10245, IDF-10246, IDF-10248, IDF-10249, IDF-10252, IDF-10253, IDF-10255, and IDF-10259 See merge request espressif/esp-idf!36377
2 parents 7675456 + c13ac70 commit 370e79e

File tree

24 files changed

+100
-51
lines changed

24 files changed

+100
-51
lines changed

components/esp_adc/test_apps/adc/CMakeLists.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,9 @@ if(CONFIG_COMPILER_DUMP_RTL_FILES)
2121
DEPENDS ${elf}
2222
)
2323
endif()
24+
25+
message(STATUS "Checking adc registers are not read-write by half-word")
26+
include($ENV{IDF_PATH}/tools/ci/check_register_rw_half_word.cmake)
27+
check_register_rw_half_word(SOC_MODULES "rtc_io" "sens" "syscon" "rtc_cntl" "apb_saradc"
28+
"system" "pmu" "pcr" "hp_sys_clkrst" "lpperi" "lp_adc"
29+
HAL_MODULES "adc")

components/esp_driver_ana_cmpr/test_apps/analog_comparator/CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,8 @@ if(CONFIG_COMPILER_DUMP_RTL_FILES)
1919
DEPENDS ${elf}
2020
)
2121
endif()
22+
23+
message(STATUS "Checking analog comparator registers are not read-write by half-word")
24+
include($ENV{IDF_PATH}/tools/ci/check_register_rw_half_word.cmake)
25+
check_register_rw_half_word(SOC_MODULES "gpio_ext" "lp_system" "gpio"
26+
HAL_MODULES "ana_cmpr")

components/esp_driver_cam/test_apps/csi/CMakeLists.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,9 @@ set(COMPONENTS main)
66

77
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
88
project(test_csi)
9+
10+
11+
message(STATUS "Checking camera registers are not read-write by half-word")
12+
include($ENV{IDF_PATH}/tools/ci/check_register_rw_half_word.cmake)
13+
check_register_rw_half_word(SOC_MODULES "lcd_cam" "hp_sys_clkrst" "*csi*"
14+
HAL_MODULES "cam" "*csi*")

components/esp_driver_dac/test_apps/dac/CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,8 @@ if(CONFIG_COMPILER_DUMP_RTL_FILES)
1919
DEPENDS ${elf}
2020
)
2121
endif()
22+
23+
message(STATUS "Checking dac registers are not read-write by half-word")
24+
include($ENV{IDF_PATH}/tools/ci/check_register_rw_half_word.cmake)
25+
check_register_rw_half_word(SOC_MODULES "rtc_io" "sens" "apb_saradc"
26+
HAL_MODULES "dac")

components/esp_driver_i2s/i2s_common.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* SPDX-FileCopyrightText: 2015-2024 Espressif Systems (Shanghai) CO LTD
2+
* SPDX-FileCopyrightText: 2015-2025 Espressif Systems (Shanghai) CO LTD
33
*
44
* SPDX-License-Identifier: Apache-2.0
55
*/
@@ -892,12 +892,12 @@ void i2s_gpio_check_and_set(i2s_chan_handle_t handle, int gpio, uint32_t signal_
892892
if (gpio != (int)I2S_GPIO_UNUSED) {
893893
gpio_func_sel(gpio, PIN_FUNC_GPIO);
894894
if (is_input) {
895-
/* Set direction, for some GPIOs, the input function are not enabled as default */
896-
gpio_set_direction(gpio, GPIO_MODE_INPUT);
895+
/* Enable the input, for some GPIOs, the input function are not enabled as default */
896+
gpio_input_enable(gpio);
897897
esp_rom_gpio_connect_in_signal(gpio, signal_idx, is_invert);
898898
} else {
899899
i2s_output_gpio_reserve(handle, gpio);
900-
gpio_set_direction(gpio, GPIO_MODE_OUTPUT);
900+
/* output will be enabled in esp_rom_gpio_connect_out_signal */
901901
esp_rom_gpio_connect_out_signal(gpio, signal_idx, is_invert, 0);
902902
}
903903
}
@@ -908,7 +908,7 @@ void i2s_gpio_loopback_set(i2s_chan_handle_t handle, int gpio, uint32_t out_sig_
908908
if (gpio != (int)I2S_GPIO_UNUSED) {
909909
i2s_output_gpio_reserve(handle, gpio);
910910
gpio_func_sel(gpio, PIN_FUNC_GPIO);
911-
gpio_set_direction(gpio, GPIO_MODE_INPUT_OUTPUT);
911+
gpio_input_enable(gpio);
912912
esp_rom_gpio_connect_out_signal(gpio, out_sig_idx, 0, 0);
913913
esp_rom_gpio_connect_in_signal(gpio, in_sig_idx, 0);
914914
}

components/esp_driver_i2s/test_apps/i2s/CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,8 @@ if(CONFIG_COMPILER_DUMP_RTL_FILES)
1919
DEPENDS ${elf}
2020
)
2121
endif()
22+
23+
message(STATUS "Checking i2s registers are not read-write by half-word")
24+
include($ENV{IDF_PATH}/tools/ci/check_register_rw_half_word.cmake)
25+
check_register_rw_half_word(SOC_MODULES "i2s" "pcr" "hp_sys_clkrst"
26+
HAL_MODULES "i2s")

components/esp_driver_i2s/test_apps/lp_i2s/CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,8 @@ set(COMPONENTS main)
66

77
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
88
project(lp_i2s_test)
9+
10+
message(STATUS "Checking lp_i2s registers are not read-write by half-word")
11+
include($ENV{IDF_PATH}/tools/ci/check_register_rw_half_word.cmake)
12+
check_register_rw_half_word(SOC_MODULES "lp_i2s" "pcr" "hp_sys_clkrst"
13+
HAL_MODULES "lp_i2s")

components/esp_driver_isp/test_apps/isp/CMakeLists.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,9 @@ set(COMPONENTS main)
66

77
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
88
project(test_isp)
9+
10+
11+
message(STATUS "Checking isp registers are not read-write by half-word")
12+
include($ENV{IDF_PATH}/tools/ci/check_register_rw_half_word.cmake)
13+
check_register_rw_half_word(SOC_MODULES "isp" "hp_sys_clkrst"
14+
HAL_MODULES "isp")

components/esp_driver_spi/test_apps/master/CMakeLists.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,8 @@ if(CONFIG_COMPILER_DUMP_RTL_FILES)
1919
DEPENDS ${elf}
2020
)
2121
endif()
22+
23+
message(STATUS "Checking spi registers are not read-write by half-word")
24+
include($ENV{IDF_PATH}/tools/ci/check_register_rw_half_word.cmake)
25+
check_register_rw_half_word(SOC_MODULES "spi" "syscon" "pcr" "system" "hp_sys_clkrst"
26+
HAL_MODULES "spi")

components/esp_driver_touch_sens/test_apps/touch_sens/CMakeLists.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,3 +20,9 @@ if(CONFIG_COMPILER_DUMP_RTL_FILES)
2020
DEPENDS ${elf}
2121
)
2222
endif()
23+
24+
message(STATUS "Checking touch sensor registers are not read-write by half-word")
25+
include($ENV{IDF_PATH}/tools/ci/check_register_rw_half_word.cmake)
26+
check_register_rw_half_word(SOC_MODULES "rtc_cntl" "sens" "rtc_io" "lp_analog_peri"
27+
"lp_clkrst" "lp_system" "lpperi" "touch" "pmu"
28+
HAL_MODULES "touch_sensor")

0 commit comments

Comments
 (0)