Prevent the linker from locating sections to a particular memory area, TASKING ARM tool chain

0

On an embedded target(ARM CORTEX M3), I would like to reserve a certain memory area to be loaded by another binary, and prevent the linker from allocating any symbol in the current binary to this particular area. I am successful in locating all default code/const sections to a desired memory area, but the linker places some symbols belonging to sections like .text.veneer.long* to the area I want to reserve. How can this be prevented?

What I have tried already is to allocate all .text.veneer.* also to the desired area, but what i want to achieve is to prevent anything being allocated to the reserved area. I also tried using type = reserved rom definition for the memory area in the linker script, but it's still being used by the linker.

Under memory definition I have done the following:

memory FLASH_RESERVED
{
    mau = 8;
    type = reserved rom;
    size = 16k;
    map ( size = 16k, dest_offset = 0x80000000, dest = bus:local_bus );
}

And under groups definition this is done:

group CODE_DEFAULT(ordered, contiguous, fill, align=4)
{
   select "[.]text";
   select "[.]text.veneer.*";
}

The linker however puts .text.veneer.* in FLASH_RESERVED.

I use Tasking compiler/linker toolchain for ARM and use a .lsl Linker script file.

linker
arm
embedded
memory-mapping
asked on Stack Overflow Sep 7, 2020 by Soju T Varghese • edited Sep 7, 2020 by Jeanne Pindar

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0