2007-02-05 Dave Brolley <brolley@redhat.com>
[deliverable/binutils-gdb.git] / bfd / elf32-m68hc12.c
index 34461b3d4dc708ade1bf71407947fff4e0aee17f..310baae383b09fb0f55d26be5e5fba1cc7294509 100644 (file)
@@ -1,5 +1,6 @@
 /* Motorola 68HC12-specific support for 32-bit ELF
-   Copyright 1999, 2000, 2002, 2003, 2004 Free Software Foundation, Inc.
+   Copyright 1999, 2000, 2002, 2003, 2004, 2005, 2006
+   Free Software Foundation, Inc.
    Contributed by Stephane Carrez (stcarrez@nerim.fr)
    (Heavily copied from the D10V port by Martin Hunt (hunt@cygnus.com))
 
@@ -537,30 +538,12 @@ m68hc12_elf_set_mach_from_flags (bfd *abfd)
      vectors.  */
 static const struct bfd_elf_special_section elf32_m68hc12_special_sections[] =
 {
-  { ".eeprom",   7, 0, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
-  { ".page0",    6, 0, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
-  { ".softregs", 9, 0, SHT_NOBITS,   SHF_ALLOC + SHF_WRITE },
-  { ".vectors",  8, 0, SHT_PROGBITS, SHF_ALLOC },
-  { NULL,        0, 0, 0,            0 }
+  { STRING_COMMA_LEN (".eeprom"),   0, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
+  { STRING_COMMA_LEN (".page0"),    0, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
+  { STRING_COMMA_LEN (".softregs"), 0, SHT_NOBITS,   SHF_ALLOC + SHF_WRITE },
+  { STRING_COMMA_LEN (".vectors"),  0, SHT_PROGBITS, SHF_ALLOC },
+  { NULL,                       0,  0, 0,            0 }
 };
-
-static const struct bfd_elf_special_section *
-elf32_m68hc12_get_sec_type_attr (bfd *abfd, asection *sec)
-{
-  const struct bfd_elf_special_section *ssect;
-
-  /* See if this is one of the special sections.  */
-  if (sec->name == NULL)
-    return NULL;
-
-  ssect = _bfd_elf_get_special_section (sec->name,
-                                       elf32_m68hc12_special_sections,
-                                       sec->use_rela_p);
-  if (ssect != NULL)
-    return ssect;
-
-  return _bfd_elf_get_sec_type_attr (abfd, sec);
-}
 \f
 #define ELF_ARCH               bfd_arch_m68hc12
 #define ELF_MACHINE_CODE       EM_68HC12
@@ -571,14 +554,12 @@ elf32_m68hc12_get_sec_type_attr (bfd *abfd, asection *sec)
 
 #define elf_info_to_howto      0
 #define elf_info_to_howto_rel  m68hc11_info_to_howto_rel
-#define elf_backend_gc_mark_hook     elf32_m68hc11_gc_mark_hook
-#define elf_backend_gc_sweep_hook    elf32_m68hc11_gc_sweep_hook
 #define elf_backend_check_relocs     elf32_m68hc11_check_relocs
 #define elf_backend_relocate_section elf32_m68hc11_relocate_section
 #define elf_backend_object_p           m68hc12_elf_set_mach_from_flags
 #define elf_backend_final_write_processing     0
 #define elf_backend_can_gc_sections            1
-#define elf_backend_get_sec_type_attr elf32_m68hc12_get_sec_type_attr
+#define elf_backend_special_sections elf32_m68hc12_special_sections
 #define elf_backend_post_process_headers     elf32_m68hc11_post_process_headers
 #define elf_backend_add_symbol_hook  elf32_m68hc11_add_symbol_hook
 
This page took 0.042312 seconds and 4 git commands to generate.