[PATCH] Properly convert address load of __start_XXX/__stop_XXX
H.J. Lu
hjl.tools@gmail.com
Mon Oct 26 15:17:00 GMT 2015
On Mon, Oct 26, 2015 at 6:00 AM, H.J. Lu <hjl.tools@gmail.com> wrote:
> Since __start_XXX and __stop_XXX symbols aren't defined when address
> load is being converted, we need to check if there is an XXX output
> section to get their section and value. This patch adds a new function,
> bfd_link_get_defined_symbol, to search for the XXX output section to
> check if __start_XXX and __stop_XXX symbols are defined.
>
> bfd/
>
> PR ld/19171
> * elf32-i386.c (elf_i386_convert_load): Call
> bfd_link_get_defined_symbol to check if a symbol is defined.
> * elf64-x86-64.c (elf_x86_64_convert_load): Call
> bfd_link_get_defined_symbol to get defined symbol section and
> value.
> * linker.c (bfd_link_get_defined_symbol): New function.
> * bfd-in2.h: Regenerated.
>
This is what I checked in. I changed bfd_link_get_defined_symbol
to properly return __stop_XXX symbol value.
--
H.J.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Properly-convert-address-load-of-__start_XXX-__stop_.patch
Type: text/x-patch
Size: 20248 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20151026/0f128e81/attachment.bin>
More information about the Binutils
mailing list