From 4a987dacca4760aed96c505a363ffde52405ff91 Mon Sep 17 00:00:00 2001 From: Mahavir Jain Date: Fri, 24 Aug 2018 17:56:38 +0530 Subject: [PATCH] bootloader: keep bootloader_common code to retention region It is possible to utilize some of the routines related to otadata partition validation, after firmware image is downloaded to RAM. Hence these routines should be part of app cpu cache, so that they do not get overwritten by firmware. Signed-off-by: Mahavir Jain --- components/bootloader/subproject/main/esp32.bootloader.ld | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/components/bootloader/subproject/main/esp32.bootloader.ld b/components/bootloader/subproject/main/esp32.bootloader.ld index 8930d5305f..384488125b 100644 --- a/components/bootloader/subproject/main/esp32.bootloader.ld +++ b/components/bootloader/subproject/main/esp32.bootloader.ld @@ -36,11 +36,12 @@ SECTIONS { . = ALIGN (16); _stext = .; - _text_start = ABSOLUTE(.); + _loader_text_start = ABSOLUTE(.); *(.stub .gnu.warning .gnu.linkonce.literal.* .gnu.linkonce.t.*.literal .gnu.linkonce.t.*) *(.iram1 .iram1.*) /* catch stray IRAM_ATTR */ *liblog.a:(.literal .text .literal.* .text.*) *libgcc.a:(.literal .text .literal.* .text.*) + *libbootloader_support.a:bootloader_common.o(.literal .text .literal.* .text.*) *libbootloader_support.a:bootloader_flash.o(.literal .text .literal.* .text.*) *libbootloader_support.a:bootloader_random.o(.literal .text .literal.* .text.*) *libbootloader_support.a:bootloader_utility.o(.literal .text .literal.* .text.*) @@ -56,7 +57,7 @@ SECTIONS *(.fini.literal) *(.fini) *(.gnu.version) - _text_end = ABSOLUTE(.); + _loader_text_end = ABSOLUTE(.); _etext = .; } > iram_loader_seg