boards/xtensa/esp32[|s2|s3]: Fix unknown disassembling instructions

This commit adds sections used by the debugger and disassembler to
get more information about raw data present in the code.

Signed-off-by: Tiago Medicci Serrano <tiago.medicci@espressif.com>
This commit is contained in:
Tiago Medicci Serrano
2025-04-23 11:14:19 -03:00
committed by Alan C. Assis
parent da74a5e368
commit 4a8af202c6
3 changed files with 62 additions and 0 deletions
@@ -460,6 +460,26 @@ SECTIONS
_sheap = ABSOLUTE(.);
} >dram0_0_seg AT>ROM
/* This section will be used by the debugger and disassembler to get more
* information about raw data present in the code.
* Indeed, it may be required to add some padding at some points in the
* code in order to align a branch/jump destination on a particular bound.
* Padding these instructions will generate null bytes that shall be
* interpreted as data, and not code by the debugger or disassembler.
* This section will only be present in the ELF file, not in the final
* binary.
*/
.xt.prop 0 :
{
KEEP (*(.xt.prop .gnu.linkonce.prop.*))
}
.xt.lit 0 :
{
KEEP (*(.xt.lit .gnu.linkonce.p.*))
}
_image_drom_vma = ADDR(.flash.rodata);
_image_drom_lma = LOADADDR(.flash.rodata);
_image_drom_size = LOADADDR(.flash.rodata) + SIZEOF(.flash.rodata) - _image_drom_lma;
@@ -382,6 +382,28 @@ SECTIONS
_sheap = ABSOLUTE(.);
} >dram0_0_seg AT>ROM
/* This section will be used by the debugger and disassembler to get more
* information about raw data present in the code.
* Indeed, it may be required to add some padding at some points in the
* code in order to align a branch/jump destination on a particular bound.
* Padding these instructions will generate null bytes that shall be
* interpreted as data, and not code by the debugger or disassembler.
* This section will only be present in the ELF file, not in the final
* binary.
*/
.xt.prop 0 :
{
KEEP (*(.xt.prop .gnu.linkonce.prop.*))
}
.xt.lit 0 :
{
KEEP (*(.xt.lit .gnu.linkonce.p.*))
}
_image_drom_vma = ADDR(.flash.rodata);
_image_drom_lma = LOADADDR(.flash.rodata);
_image_drom_size = LOADADDR(.flash.rodata) + SIZEOF(.flash.rodata) - _image_drom_lma;
@@ -495,6 +495,26 @@ SECTIONS
_sheap = ABSOLUTE(.);
} >dram0_0_seg AT>ROM
/* This section will be used by the debugger and disassembler to get more
* information about raw data present in the code.
* Indeed, it may be required to add some padding at some points in the
* code in order to align a branch/jump destination on a particular bound.
* Padding these instructions will generate null bytes that shall be
* interpreted as data, and not code by the debugger or disassembler.
* This section will only be present in the ELF file, not in the final
* binary.
*/
.xt.prop 0 :
{
KEEP (*(.xt.prop .gnu.linkonce.prop.*))
}
.xt.lit 0 :
{
KEEP (*(.xt.lit .gnu.linkonce.p.*))
}
/* The alignment of the ".flash.text" output section is forced to
* 0x00010000 (64KB) to ensure that it will be allocated at the beginning
* of the next available Flash block.