PR ld/14926
* elf.c (_bfd_elf_map_sections_to_segments): Include elf header size when determining phdr_in_segment.
This commit is contained in:
parent
ae2eea65c6
commit
d2bcb0d1aa
|
@ -1,3 +1,9 @@
|
||||||
|
2012-12-07 Alan Modra <amodra@gmail.com>
|
||||||
|
|
||||||
|
PR ld/14926
|
||||||
|
* elf.c (_bfd_elf_map_sections_to_segments): Include elf header
|
||||||
|
size when determining phdr_in_segment.
|
||||||
|
|
||||||
2012-12-06 Yufeng Zhang <yufeng.zhang@arm.com>
|
2012-12-06 Yufeng Zhang <yufeng.zhang@arm.com>
|
||||||
|
|
||||||
* elf64-aarch64.c (elf64_aarch64_grok_prstatus): New function.
|
* elf64-aarch64.c (elf64_aarch64_grok_prstatus): New function.
|
||||||
|
|
|
@ -3874,6 +3874,7 @@ _bfd_elf_map_sections_to_segments (bfd *abfd, struct bfd_link_info *info)
|
||||||
|
|
||||||
if (phdr_size == (bfd_size_type) -1)
|
if (phdr_size == (bfd_size_type) -1)
|
||||||
phdr_size = get_program_header_size (abfd, info);
|
phdr_size = get_program_header_size (abfd, info);
|
||||||
|
phdr_size += bed->s->sizeof_ehdr;
|
||||||
if ((abfd->flags & D_PAGED) == 0
|
if ((abfd->flags & D_PAGED) == 0
|
||||||
|| (sections[0]->lma & addr_mask) < phdr_size
|
|| (sections[0]->lma & addr_mask) < phdr_size
|
||||||
|| ((sections[0]->lma & addr_mask) % maxpagesize
|
|| ((sections[0]->lma & addr_mask) % maxpagesize
|
||||||
|
|
Loading…
Reference in New Issue