mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
spi test: replace several SPIRAM_SUPPORT with SPIRAM configs
The previous config option is renamed to ESP32_SPIRAM_SUPPORT, which cannot cover the ESP32-S2 case.
This commit is contained in:
parent
c7b1436485
commit
8165025320
@ -1032,7 +1032,7 @@ TEST_CASE("spi_speed","[spi]")
|
||||
for (int i = 0; i < TEST_TIMES; i++) {
|
||||
ESP_LOGI(TAG, "%.2lf", GET_US_BY_CCOUNT(t_flight_sorted[i]));
|
||||
}
|
||||
#ifndef CONFIG_SPIRAM_SUPPORT
|
||||
#ifndef CONFIG_SPIRAM
|
||||
TEST_PERFORMANCE_LESS_THAN(SPI_PER_TRANS_NO_POLLING, "%d us", (int)GET_US_BY_CCOUNT(t_flight_sorted[(TEST_TIMES+1)/2]));
|
||||
#endif
|
||||
|
||||
@ -1049,7 +1049,7 @@ TEST_CASE("spi_speed","[spi]")
|
||||
for (int i = 0; i < TEST_TIMES; i++) {
|
||||
ESP_LOGI(TAG, "%.2lf", GET_US_BY_CCOUNT(t_flight_sorted[i]));
|
||||
}
|
||||
#ifndef CONFIG_SPIRAM_SUPPORT
|
||||
#ifndef CONFIG_SPIRAM
|
||||
TEST_PERFORMANCE_LESS_THAN(SPI_PER_TRANS_POLLING, "%d us", (int)GET_US_BY_CCOUNT(t_flight_sorted[(TEST_TIMES+1)/2]));
|
||||
#endif
|
||||
|
||||
@ -1069,7 +1069,7 @@ TEST_CASE("spi_speed","[spi]")
|
||||
for (int i = 0; i < TEST_TIMES; i++) {
|
||||
ESP_LOGI(TAG, "%.2lf", GET_US_BY_CCOUNT(t_flight_sorted[i]));
|
||||
}
|
||||
#ifndef CONFIG_SPIRAM_SUPPORT
|
||||
#ifndef CONFIG_SPIRAM
|
||||
TEST_PERFORMANCE_LESS_THAN(SPI_PER_TRANS_NO_POLLING_NO_DMA, "%d us", (int)GET_US_BY_CCOUNT(t_flight_sorted[(TEST_TIMES+1)/2]));
|
||||
#endif
|
||||
|
||||
@ -1085,7 +1085,7 @@ TEST_CASE("spi_speed","[spi]")
|
||||
for (int i = 0; i < TEST_TIMES; i++) {
|
||||
ESP_LOGI(TAG, "%.2lf", GET_US_BY_CCOUNT(t_flight_sorted[i]));
|
||||
}
|
||||
#ifndef CONFIG_SPIRAM_SUPPORT
|
||||
#ifndef CONFIG_SPIRAM
|
||||
TEST_PERFORMANCE_LESS_THAN(SPI_PER_TRANS_POLLING_NO_DMA, "%d us", (int)GET_US_BY_CCOUNT(t_flight_sorted[(TEST_TIMES+1)/2]));
|
||||
#endif
|
||||
|
||||
|
@ -86,7 +86,7 @@ typedef void (*flash_test_func_t)(esp_flash_t* chip);
|
||||
|
||||
These tests run for all the flash chip configs shown in config_list, below (internal and external).
|
||||
*/
|
||||
#if defined(CONFIG_SPIRAM_SUPPORT)
|
||||
#if defined(CONFIG_SPIRAM)
|
||||
#define FLASH_TEST_CASE_3(STR, FUNCT_TO_RUN)
|
||||
#define FLASH_TEST_CASE_3_IGNORE(STR, FUNCT_TO_RUN)
|
||||
#else
|
||||
@ -695,7 +695,7 @@ TEST_CASE("SPI flash test reading with all speed/mode permutations", "[esp_flash
|
||||
test_permutations(&config_list[0]);
|
||||
}
|
||||
|
||||
#ifndef CONFIG_SPIRAM_SUPPORT
|
||||
#ifndef CONFIG_SPIRAM
|
||||
TEST_CASE("SPI flash test reading with all speed/mode permutations, 3 chips", "[esp_flash][test_env=UT_T1_ESP_FLASH]")
|
||||
{
|
||||
for (int i = 0; i < TEST_CONFIG_NUM; i++) {
|
||||
@ -880,7 +880,7 @@ static void test_flash_read_write_performance(esp_flash_t* chip)
|
||||
|
||||
TEST_ASSERT_EQUAL_HEX8_ARRAY(data_to_write, data_read, total_len);
|
||||
|
||||
#if !CONFIG_SPIRAM_SUPPORT && !CONFIG_FREERTOS_CHECK_PORT_CRITICAL_COMPLIANCE
|
||||
#if !CONFIG_SPIRAM && !CONFIG_FREERTOS_CHECK_PORT_CRITICAL_COMPLIANCE
|
||||
# define CHECK_DATA(bus, suffix) TEST_PERFORMANCE_GREATER_THAN(FLASH_SPEED_BYTE_PER_SEC_##bus##suffix, "%d", speed_##suffix)
|
||||
# define CHECK_ERASE(bus, var) TEST_PERFORMANCE_GREATER_THAN(FLASH_SPEED_BYTE_PER_SEC_##bus##ERASE, "%d", var)
|
||||
#else
|
||||
|
@ -298,7 +298,7 @@ TEST_CASE("Test spi_flash read/write performance", "[spi_flash]")
|
||||
TEST_ASSERT_EQUAL_HEX8_ARRAY(data_to_write, data_read, total_len);
|
||||
|
||||
// Data checks are disabled when PSRAM is used or in Freertos compliance check test
|
||||
#if !CONFIG_SPIRAM_SUPPORT && !CONFIG_FREERTOS_CHECK_PORT_CRITICAL_COMPLIANCE
|
||||
#if !CONFIG_SPIRAM && !CONFIG_FREERTOS_CHECK_PORT_CRITICAL_COMPLIANCE
|
||||
# define CHECK_DATA(suffix) TEST_PERFORMANCE_GREATER_THAN(FLASH_SPEED_BYTE_PER_SEC_LEGACY_##suffix, "%d", speed_##suffix)
|
||||
# define CHECK_ERASE(var) TEST_PERFORMANCE_GREATER_THAN(FLASH_SPEED_BYTE_PER_SEC_LEGACY_ERASE, "%d", var)
|
||||
#else
|
||||
|
Loading…
x
Reference in New Issue
Block a user