mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-03 03:31:41 +03:00
fix(esp_hw_support): fix private shared interrupt release path
Treat ESP_INTR_FLAG_SHARED_PRIVATE as shared when selecting interrupt lines and avoid misclassifying private shared vectors as non-shared during free. Also fix two error-path leaks in esp_intr_alloc_info by freeing the temporary handle and rolling back group_name on allocation failure. refactor(esp_hw_support): add semantic vector descriptor helpers Introduce helper macros to classify vector descriptor state (shared, non-shared, private shared, and uninitialized) and apply them in allocator/free/dump paths. This makes private-shared semantics explicit and reduces repeated bitwise checks. Rename vector descriptor helpers to explicitly distinguish public shared, private shared, and shared-family states. This improves readability and avoids ambiguity when handling mixed shared/non-shared flag combinations.
This commit is contained in:
@@ -794,7 +794,7 @@ TEST_CASE("uart rx glitch filter (read write test + auto baud rate detection tes
|
||||
.test_times = 10,
|
||||
};
|
||||
TaskHandle_t inject_glitch_task_handle;
|
||||
xTaskCreate(uart_signal_inject_glitch_task, "uart_signal_inject_glitch_task", 1024, (void *)&port_param, 6, &inject_glitch_task_handle);
|
||||
xTaskCreate(uart_signal_inject_glitch_task, "uart_signal_inject_glitch_task", 2048, (void *)&port_param, 6, &inject_glitch_task_handle);
|
||||
|
||||
// 1. read write test
|
||||
#if !UART_LL_GLITCH_FILT_ONLY_ON_AUTOBAUD
|
||||
@@ -825,7 +825,7 @@ TEST_CASE("uart rx glitch filter (read write test + auto baud rate detection tes
|
||||
uint32_t detected_baudrate = res.clk_freq_hz * 2 / res.pos_period; // assume the wave has a slow falling slew rate
|
||||
uint32_t actual_baudrate = 0;
|
||||
uart_get_baudrate(uart_num, &actual_baudrate);
|
||||
TEST_ASSERT_INT32_WITHIN(actual_baudrate * 0.03, actual_baudrate, detected_baudrate);
|
||||
TEST_ASSERT_INT32_WITHIN(actual_baudrate * 0.05, actual_baudrate, detected_baudrate);
|
||||
// wait for write task to finish and self deleted
|
||||
while (eTaskGetState(write_task_handle) != eDeleted) {
|
||||
vTaskDelay(1);
|
||||
|
||||
Reference in New Issue
Block a user