[5 PATCH] powerpc/motorola_power: Link all text sections into the executable image

Chris Johns chrisj at rtems.org
Wed Feb 24 21:36:47 UTC 2021


On 25/2/21 3:33 am, Gedare Bloom wrote:
> On Tue, Feb 23, 2021 at 11:07 PM <chrisj at rtems.org> wrote:
>>
>> From: Chris Johns <chrisj at rtems.org>
>>
>> - The change to building all code with code and data sections means
>>   we have a section per function. Make sure all functions are
>>   placed in the text section.
>>
>> Closes #4266
>> ---
>>  bsps/powerpc/motorola_powerpc/bootloader/ppcboot.lds | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/bsps/powerpc/motorola_powerpc/bootloader/ppcboot.lds b/bsps/powerpc/motorola_powerpc/bootloader/ppcboot.lds
>> index 0ee7447546..a87a07cfd7 100644
>> --- a/bsps/powerpc/motorola_powerpc/bootloader/ppcboot.lds
>> +++ b/bsps/powerpc/motorola_powerpc/bootloader/ppcboot.lds
>> @@ -38,6 +38,7 @@ SECTIONS
>>      BYTE(0x75); BYTE(0x78); /* Partition name */
>>      . = 0x400;
>>      *(.text)
>> +    *(.text*)
> Minor point, it should be sufficient to just have *(.text*) no need
> then for (*.text)

Yes and it does work as this was my first change then I wondered if the .text
parts in bootloader.o should be placed before the others as it is in the version
without the extra compile options so I made the script have the second step. The
change here makes this happen.

Also the read only sections below have this so it is consistent.

Chris

> 
>>      *(.sdata2)
>>      *(.rodata)
>>      *(.rodata*)
>> @@ -98,4 +99,3 @@ SECTIONS
>>      *(.comment)
>>    }
>>  }
>> -
>> --
>> 2.24.1
>>
>> _______________________________________________
>> devel mailing list
>> devel at rtems.org
>> http://lists.rtems.org/mailman/listinfo/devel


More information about the devel mailing list