mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-12-27 01:28:46 +00:00
Add support for ARM's NOREAD section flag.
include/elf
* arm.h: Add arm SHF_ARM_NOREAD section flag.
bfd * bfd-in2.h: Regenerate.
* section.c: Add SEC_ELF_NOREAD.
* elf32-arm.c (elf32_arm_post_process_headers): Only set
PF_X attribute if a segment only contains section with
SHF_ARM_NOREAD flag.
(elf32_arm_fake_sections): Add SEC_ELF_NOREAD conversion.
(elf32_arm_section_flags): New function to convert SHF_ARM_NOREAD
to bfd flag.
(elf32_arm_lookup_section_flags): New function to allow
INPUT_SECTION_FLAGS directive with SHF_ARM_NOREAD flag.
(elf32_arm_special_sections): Add special sections array
to catch section prefix by '.text.noread' pattern.
ld/testsuite
* ld-arm/arm-elf.exp: New tests.
* ld-arm/thumb1-input-section-flag-match.d: New
* ld-arm/thumb1-input-section-flag-match.s: New
* ld-arm/thumb1-noread-not-present-mixing-two-section.d: New
* ld-arm/thumb1-noread-not-present-mixing-two-section.s: New
* ld-arm/thumb1-noread-present-one-section.d: New
* ld-arm/thumb1-noread-present-one-section.s: New
* ld-arm/thumb1-noread-present-two-section.d: New
* ld-arm/thumb1-noread-present-two-section.s: New
binutils
* readelf.c (get_elf_section_flags): Add support for ARM specific
section flags.
This commit is contained in:
committed by
Nick Clifton
parent
6d265cb4a9
commit
ac4c9b0459
@@ -361,6 +361,9 @@ CODE_FRAGMENT
|
||||
. when memory read flag isn't set. *}
|
||||
.#define SEC_COFF_NOREAD 0x40000000
|
||||
.
|
||||
. {* Indicate that section has the no read flag set. *}
|
||||
.#define SEC_ELF_NOREAD 0x80000000
|
||||
.
|
||||
. {* End of section flags. *}
|
||||
.
|
||||
. {* Some internal packed boolean fields. *}
|
||||
|
||||
Reference in New Issue
Block a user