Skip to content

Commit b794d33

Browse files
sylvioalvesalmir-okato
authored andcommitted
espressif: modify SOC_FAMILY according to new HWMv2
Update FAMILY reference as needed. Signed-off-by: Sylvio Alves <[email protected]>
1 parent fefe701 commit b794d33

File tree

4 files changed

+9
-9
lines changed

4 files changed

+9
-9
lines changed

boot/zephyr/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -722,7 +722,7 @@ config MULTITHREADING
722722
default y if BOOT_SERIAL_CDC_ACM #usb driver requires MULTITHREADING
723723
default y if BOOT_USB_DFU_GPIO || BOOT_USB_DFU_WAIT
724724
default n if SOC_FAMILY_NRF
725-
default n if SOC_FAMILY_ESP32 && MCUBOOT
725+
default n if SOC_FAMILY_ESPRESSIF_ESP32 && MCUBOOT
726726
default y
727727

728728
config LOG_PROCESS_THREAD

boot/zephyr/flash_map_extended.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ BOOT_LOG_MODULE_DECLARE(mcuboot);
2828
#define FLASH_DEVICE_BASE 0
2929
#define FLASH_DEVICE_NODE DT_INST(0, jedec_spi_nor)
3030

31-
#elif defined(CONFIG_SOC_FAMILY_ESP32)
31+
#elif defined(CONFIG_SOC_FAMILY_ESPRESSIF_ESP32)
3232

3333
#define FLASH_DEVICE_ID SPI_FLASH_0_ID
3434
#define FLASH_DEVICE_BASE 0

boot/zephyr/include/target.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
*/
3333
#if (!defined(CONFIG_XTENSA) && !DT_HAS_CHOSEN(zephyr_flash_controller)) || \
3434
(defined(CONFIG_XTENSA) && !DT_NODE_EXISTS(DT_INST(0, jedec_spi_nor)) && \
35-
!defined(CONFIG_SOC_FAMILY_ESP32)) || \
35+
!defined(CONFIG_SOC_FAMILY_ESPRESSIF_ESP32)) || \
3636
!defined(FLASH_ALIGN) || \
3737
!(FIXED_PARTITION_EXISTS(slot0_partition)) || \
3838
!(FIXED_PARTITION_EXISTS(slot1_partition) || CONFIG_SINGLE_APPLICATION_SLOT) || \

boot/zephyr/main.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
#include "flash_map_backend/flash_map_backend.h"
4343

4444
/* Check if Espressif target is supported */
45-
#ifdef CONFIG_SOC_FAMILY_ESP32
45+
#ifdef CONFIG_SOC_FAMILY_ESPRESSIF_ESP32
4646

4747
#include <bootloader_init.h>
4848
#include <esp_loader.h>
@@ -63,7 +63,7 @@
6363
#define IMAGE1_PRIMARY_SIZE \
6464
DT_PROP_BY_IDX(DT_NODE_BY_FIXED_PARTITION_LABEL(image_1), reg, 1)
6565

66-
#endif /* CONFIG_SOC_FAMILY_ESP32 */
66+
#endif /* CONFIG_SOC_FAMILY_ESPRESSIF_ESP32 */
6767

6868
#ifdef CONFIG_MCUBOOT_SERIAL
6969
#include "boot_serial/boot_serial.h"
@@ -225,7 +225,7 @@ static void do_boot(struct boot_rsp *rsp)
225225

226226
#elif defined(CONFIG_XTENSA) || defined(CONFIG_RISCV)
227227

228-
#ifndef CONFIG_SOC_FAMILY_ESP32
228+
#ifndef CONFIG_SOC_FAMILY_ESPRESSIF_ESP32
229229

230230
#define SRAM_BASE_ADDRESS 0xBE030000
231231

@@ -254,7 +254,7 @@ static void copy_img_to_SRAM(int slot, unsigned int hdr_offset)
254254
done:
255255
flash_area_close(fap);
256256
}
257-
#endif /* !CONFIG_SOC_FAMILY_ESP32 */
257+
#endif /* !CONFIG_SOC_FAMILY_ESPRESSIF_ESP32 */
258258

259259
/* Entry point (.ResetVector) is at the very beginning of the image.
260260
* Simply copy the image to a suitable location and jump there.
@@ -266,7 +266,7 @@ static void do_boot(struct boot_rsp *rsp)
266266
BOOT_LOG_INF("br_image_off = 0x%x\n", rsp->br_image_off);
267267
BOOT_LOG_INF("ih_hdr_size = 0x%x\n", rsp->br_hdr->ih_hdr_size);
268268

269-
#ifdef CONFIG_SOC_FAMILY_ESP32
269+
#ifdef CONFIG_SOC_FAMILY_ESPRESSIF_ESP32
270270
int slot = (rsp->br_image_off == IMAGE0_PRIMARY_START_ADDRESS) ?
271271
PRIMARY_SLOT : SECONDARY_SLOT;
272272
/* Load memory segments and start from entry point */
@@ -278,7 +278,7 @@ static void do_boot(struct boot_rsp *rsp)
278278
/* Jump to entry point */
279279
start = (void *)(SRAM_BASE_ADDRESS + rsp->br_hdr->ih_hdr_size);
280280
((void (*)(void))start)();
281-
#endif /* CONFIG_SOC_FAMILY_ESP32 */
281+
#endif /* CONFIG_SOC_FAMILY_ESPRESSIF_ESP32 */
282282
}
283283

284284
#else

0 commit comments

Comments
 (0)