Skip to content

Commit 0c5bce6

Browse files
Harshal5espressif-bot
authored andcommitted
fix(bootloader_support): Make esp_flash_encrypt.h independent of spi_flash_mmap.h header
1 parent bef1fba commit 0c5bce6

File tree

10 files changed

+14
-8
lines changed

10 files changed

+14
-8
lines changed

components/app_update/esp_ota_ops.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
#include "esp_image_format.h"
1818
#include "esp_secure_boot.h"
1919
#include "esp_flash_encrypt.h"
20+
#include "spi_flash_mmap.h"
2021
#include "sdkconfig.h"
2122

2223
#include "esp_ota_ops.h"

components/bootloader_support/bootloader_flash/src/bootloader_flash.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@
1313
#include "hal/efuse_ll.h"
1414
#include "hal/efuse_hal.h"
1515

16+
#ifndef BOOTLOADER_BUILD
17+
#include "spi_flash_mmap.h"
18+
#endif
1619
#include "hal/spi_flash_ll.h"
1720
#include "rom/spi_flash.h"
1821
#if CONFIG_IDF_TARGET_ESP32

components/bootloader_support/include/esp_flash_encrypt.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@
99
#include "esp_attr.h"
1010
#include "esp_err.h"
1111
#include "soc/soc_caps.h"
12-
#ifndef BOOTLOADER_BUILD
13-
#include "spi_flash_mmap.h"
14-
#endif
1512
#include "hal/efuse_ll.h"
1613
#include "sdkconfig.h"
1714

components/bootloader_support/src/bootloader_init.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
#include "bootloader_random.h"
1515
#include "bootloader_clock.h"
1616
#include "bootloader_common.h"
17-
#include "esp_flash_encrypt.h"
1817
#include "esp_cpu.h"
1918
#include "soc/rtc.h"
2019
#include "hal/wdt_hal.h"

components/bootloader_support/src/bootloader_utility.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,9 @@
3434
#include "esp_app_desc.h"
3535
#include "esp_secure_boot.h"
3636
#include "esp_flash_encrypt.h"
37+
#ifndef BOOTLOADER_BUILD
38+
#include "spi_flash_mmap.h"
39+
#endif
3740
#include "esp_flash_partitions.h"
3841
#include "bootloader_flash_priv.h"
3942
#include "bootloader_random.h"

components/esp_partition/partition.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
#if !CONFIG_IDF_TARGET_LINUX
2828
#include "esp_flash.h"
2929
#include "esp_flash_encrypt.h"
30+
#include "spi_flash_mmap.h"
3031
#endif
3132
#include "esp_log.h"
3233
#include "esp_rom_md5.h"

components/esp_system/port/cpu_start.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,6 @@
9393
#include "bootloader_flash_config.h"
9494
#include "bootloader_flash.h"
9595
#include "esp_private/crosscore_int.h"
96-
#include "esp_flash_encrypt.h"
9796

9897
#include "esp_private/sleep_gpio.h"
9998
#include "hal/wdt_hal.h"
@@ -114,6 +113,7 @@
114113
#include "esp_rom_spiflash.h"
115114
#include "bootloader_init.h"
116115
#include "esp_private/bootloader_flash_internal.h"
116+
#include "spi_flash_mmap.h"
117117
#endif // CONFIG_APP_BUILD_TYPE_RAM
118118

119119
//This dependency will be removed in the future

components/espcoredump/src/core_dump_flash.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
#include "esp_flash_encrypt.h"
1313
#include "esp_rom_crc.h"
1414
#include "esp_private/spi_flash_os.h"
15+
#include "spi_flash_mmap.h"
1516

1617
#define BLANK_COREDUMP_SIZE 0xFFFFFFFF
1718

@@ -258,7 +259,7 @@ static esp_err_t esp_core_dump_flash_write_prepare(core_dump_write_data_t *wr_da
258259
padding = COREDUMP_CACHE_SIZE - modulo;
259260
}
260261

261-
/* Now we can check whether we have enough space in our core dump parition
262+
/* Now we can check whether we have enough space in our core dump partition
262263
* or not. */
263264
if ((*data_len + padding + cs_len) > s_core_flash_config.partition.size) {
264265
ESP_COREDUMP_LOGE("Not enough space to save core dump!");

components/mbedtls/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -200,10 +200,10 @@ endif()
200200
if(SHA_PERIPHERAL_TYPE STREQUAL "dma" OR AES_PERIPHERAL_TYPE STREQUAL "dma")
201201
target_link_libraries(mbedcrypto PRIVATE idf::esp_mm)
202202
if(CONFIG_SOC_SHA_GDMA OR CONFIG_SOC_AES_GDMA)
203-
target_sources(mbedcrypto PRIVATE "${COMPONENT_DIR}/port/crypto_shared_gdma/esp_crypto_shared_gdma.c")
204203
if(CONFIG_SOC_AXI_DMA_EXT_MEM_ENC_ALIGNMENT)
205-
target_link_libraries(mbedcrypto PRIVATE idf::spi_flash idf::bootloader_support)
204+
target_link_libraries(mbedcrypto PRIVATE idf::bootloader_support)
206205
endif()
206+
target_sources(mbedcrypto PRIVATE "${COMPONENT_DIR}/port/crypto_shared_gdma/esp_crypto_shared_gdma.c")
207207
endif()
208208
endif()
209209

components/nvs_flash/test_apps/main/test_nvs.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
#include "esp_log.h"
1818
#include "esp_partition.h"
1919
#include "esp_system.h"
20+
#include "spi_flash_mmap.h"
2021

2122
#include "nvs.h"
2223
#include "nvs_flash.h"

0 commit comments

Comments
 (0)