diff options
-rw-r--r-- | bfd/ChangeLog | 8 | ||||
-rw-r--r-- | bfd/elf-bfd.h | 12 | ||||
-rw-r--r-- | bfd/elf32-ppc.c | 12 |
3 files changed, 22 insertions, 10 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog index 202a4e0..ed63720 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,5 +1,13 @@ Thu Jan 11 11:23:30 1996 Ian Lance Taylor <ian@cygnus.com> + * elf-bfd.h (struct bfd_elf_section_data): Add tdata field. + (struct elf_obj_tdata): Rename ppc_flags_init field to flags_init. + (elf_flags_init): Rename from elf_ppc_flags_init. + * elf32-ppc.c (ppc_elf_set_private_flags): Use elf_flags_init, not + elf_ppc_flags_init. + (ppc_elf_copy_private_bfd_data): Likewise. + (ppc_elf_merge_private_bfd_data): Likewise. + * elf32-m68k.c (howto_table): Change src_mask to 0 for all relocation entries. diff --git a/bfd/elf-bfd.h b/bfd/elf-bfd.h index e7baaa9..75c8c5d 100644 --- a/bfd/elf-bfd.h +++ b/bfd/elf-bfd.h @@ -441,7 +441,8 @@ struct elf_backend_data /* Information stored for each BFD section in an ELF file. This structure is allocated by elf_new_section_hook. */ -struct bfd_elf_section_data { +struct bfd_elf_section_data +{ /* The ELF header for this section. */ Elf_Internal_Shdr this_hdr; /* The ELF header for the reloc section associated with this @@ -464,6 +465,8 @@ struct bfd_elf_section_data { record the dynamic symbol index for a section symbol corresponding to this section. */ long dynindx; + /* A pointer available for the processor specific ELF backend. */ + PTR tdata; }; #define elf_section_data(sec) ((struct bfd_elf_section_data*)sec->used_by_bfd) @@ -532,8 +535,8 @@ struct elf_obj_tdata find_nearest_line. */ struct mips_elf_find_line *find_line_info; - /* Used by PowerPC to determine if the e_flags field has been intiialized */ - boolean ppc_flags_init; + /* Used to determine if the e_flags field has been initialized */ + boolean flags_init; }; #define elf_tdata(bfd) ((bfd) -> tdata.elf_obj_data) @@ -553,11 +556,12 @@ struct elf_obj_tdata #define elf_local_got_offsets(bfd) (elf_tdata(bfd) -> local_got_offsets) #define elf_dt_needed_name(bfd) (elf_tdata(bfd) -> dt_needed_name) #define elf_bad_symtab(bfd) (elf_tdata(bfd) -> bad_symtab) -#define elf_ppc_flags_init(bfd) (elf_tdata(bfd) -> ppc_flags_init) +#define elf_flags_init(bfd) (elf_tdata(bfd) -> flags_init) extern char * bfd_elf_string_from_elf_section PARAMS ((bfd *, unsigned, unsigned)); extern char * bfd_elf_get_str_section PARAMS ((bfd *, unsigned)); +extern boolean _bfd_elf_print_private_bfd_data PARAMS ((bfd *, PTR)); extern void bfd_elf_print_symbol PARAMS ((bfd *, PTR, asymbol *, bfd_print_symbol_type)); #define elf_string_from_elf_strtab(abfd,strindex) \ diff --git a/bfd/elf32-ppc.c b/bfd/elf32-ppc.c index e08b9b7..201d1bb 100644 --- a/bfd/elf32-ppc.c +++ b/bfd/elf32-ppc.c @@ -930,11 +930,11 @@ ppc_elf_set_private_flags (abfd, flags) bfd *abfd; flagword flags; { - BFD_ASSERT (!elf_ppc_flags_init (abfd) + BFD_ASSERT (!elf_flags_init (abfd) || elf_elfheader (abfd)->e_flags == flags); elf_elfheader (abfd)->e_flags = flags; - elf_ppc_flags_init (abfd) = true; + elf_flags_init (abfd) = true; return true; } @@ -950,11 +950,11 @@ ppc_elf_copy_private_bfd_data (ibfd, obfd) if (bfd_get_flavour (obfd) != bfd_target_elf_flavour) return true; - BFD_ASSERT (!elf_ppc_flags_init (obfd) + BFD_ASSERT (!elf_flags_init (obfd) || elf_elfheader (obfd)->e_flags == elf_elfheader (ibfd)->e_flags); elf_elfheader (obfd)->e_flags = elf_elfheader (ibfd)->e_flags; - elf_ppc_flags_init (obfd) = true; + elf_flags_init (obfd) = true; return true; } @@ -991,9 +991,9 @@ ppc_elf_merge_private_bfd_data (ibfd, obfd) new_flags = elf_elfheader (ibfd)->e_flags; old_flags = elf_elfheader (obfd)->e_flags; - if (!elf_ppc_flags_init (obfd)) /* First call, no flags set */ + if (!elf_flags_init (obfd)) /* First call, no flags set */ { - elf_ppc_flags_init (obfd) = true; + elf_flags_init (obfd) = true; elf_elfheader (obfd)->e_flags = new_flags; } |