* elf64-ppc.c (ppc64_elf_size_dynamic_sections): Don't allocate
[deliverable/binutils-gdb.git] / bfd / coff-rs6000.c
index b1db78fe25c8a91f06548647ad303d005dc2d68b..6d5597875aa2e16292e8c1723381ba7289f9b25d 100644 (file)
@@ -155,15 +155,7 @@ static boolean do_copy PARAMS((bfd *, bfd *));
 static boolean do_shared_object_padding PARAMS ((bfd *, bfd *, ufile_ptr *, int));
 
 /* Relocation functions */
-static boolean xcoff_reloc_type_noop PARAMS ((XCOFF_RELOC_FUNCTION_ARGS));
-static boolean xcoff_reloc_type_fail PARAMS ((XCOFF_RELOC_FUNCTION_ARGS));
-static boolean xcoff_reloc_type_pos PARAMS ((XCOFF_RELOC_FUNCTION_ARGS));
-static boolean xcoff_reloc_type_neg PARAMS ((XCOFF_RELOC_FUNCTION_ARGS));
-static boolean xcoff_reloc_type_rel PARAMS ((XCOFF_RELOC_FUNCTION_ARGS));
-static boolean xcoff_reloc_type_toc PARAMS ((XCOFF_RELOC_FUNCTION_ARGS));
-static boolean xcoff_reloc_type_ba PARAMS ((XCOFF_RELOC_FUNCTION_ARGS));
 static boolean xcoff_reloc_type_br PARAMS ((XCOFF_RELOC_FUNCTION_ARGS));
-static boolean xcoff_reloc_type_crel PARAMS ((XCOFF_RELOC_FUNCTION_ARGS));
 
 static boolean xcoff_complain_overflow_dont_func 
   PARAMS ((XCOFF_COMPLAIN_FUNCTION_ARGS));
@@ -956,6 +948,21 @@ reloc_howto_type xcoff_howto_table[] =
         0xffff,                /* dst_mask */
         false),                /* pcrel_offset */
 
+  /* Modifiable branch relative.  */
+  HOWTO (R_RBA,                        /* type */
+        0,                     /* rightshift */
+        1,                     /* size (0 = byte, 1 = short, 2 = long) */
+        16,                    /* bitsize */
+        false,                 /* pc_relative */
+        0,                     /* bitpos */
+        complain_overflow_signed, /* complain_on_overflow */
+        0,                     /* special_function */
+        "R_RBA_16",            /* name */
+        true,                  /* partial_inplace */
+        0xffff,                /* src_mask */
+        0xffff,                /* dst_mask */
+        false),                /* pcrel_offset */
+
 };
 
 void
@@ -976,6 +983,8 @@ xcoff_rtype2howto (relent, internal)
        relent->howto = &xcoff_howto_table[0x1c];
       else if (R_RBR == internal->r_type) 
        relent->howto = &xcoff_howto_table[0x1d];
+      else if (R_RBA == internal->r_type) 
+       relent->howto = &xcoff_howto_table[0x1e];
     }
   
   /* The r_size field of an XCOFF reloc encodes the bitsize of the
@@ -2726,7 +2735,7 @@ xcoff_swap_ldrel_out (abfd, src, d)
 }
 \f
 
-static boolean 
+boolean 
 xcoff_reloc_type_noop (input_bfd, input_section, output_bfd, rel, sym, howto, 
                       val, addend, relocation, contents)
      bfd *input_bfd ATTRIBUTE_UNUSED;
@@ -2743,7 +2752,7 @@ xcoff_reloc_type_noop (input_bfd, input_section, output_bfd, rel, sym, howto,
   return true;
 }
 
-static boolean 
+boolean 
 xcoff_reloc_type_fail (input_bfd, input_section, output_bfd, rel, sym, howto, 
                       val, addend, relocation, contents)
      bfd *input_bfd;
@@ -2764,7 +2773,7 @@ xcoff_reloc_type_fail (input_bfd, input_section, output_bfd, rel, sym, howto,
   return false;
 }
 
-static boolean 
+boolean 
 xcoff_reloc_type_pos (input_bfd, input_section, output_bfd, rel, sym, howto, 
                      val, addend, relocation, contents)
      bfd *input_bfd ATTRIBUTE_UNUSED;
@@ -2782,7 +2791,7 @@ xcoff_reloc_type_pos (input_bfd, input_section, output_bfd, rel, sym, howto,
   return true;
 }
 
-static boolean 
+boolean 
 xcoff_reloc_type_neg (input_bfd, input_section, output_bfd, rel, sym, howto, 
                      val, addend, relocation, contents)
      bfd *input_bfd ATTRIBUTE_UNUSED;
@@ -2800,7 +2809,7 @@ xcoff_reloc_type_neg (input_bfd, input_section, output_bfd, rel, sym, howto,
   return true;
 }
 
-static boolean 
+boolean 
 xcoff_reloc_type_rel (input_bfd, input_section, output_bfd, rel, sym, howto, 
                      val, addend, relocation, contents)
      bfd *input_bfd ATTRIBUTE_UNUSED;
@@ -2824,7 +2833,8 @@ xcoff_reloc_type_rel (input_bfd, input_section, output_bfd, rel, sym, howto,
                  input_section->output_offset);
   return true;
 }
-static boolean 
+
+boolean 
 xcoff_reloc_type_toc (input_bfd, input_section, output_bfd, rel, sym, howto, 
                      val, addend, relocation, contents)
      bfd *input_bfd;
@@ -2866,7 +2876,8 @@ xcoff_reloc_type_toc (input_bfd, input_section, output_bfd, rel, sym, howto,
                 (sym->n_value - xcoff_data (input_bfd)->toc));
   return true;
 }
-static boolean 
+
+boolean 
 xcoff_reloc_type_ba (input_bfd, input_section, output_bfd, rel, sym, howto, 
                     val, addend, relocation, contents)
      bfd *input_bfd ATTRIBUTE_UNUSED;
@@ -2967,7 +2978,7 @@ xcoff_reloc_type_br (input_bfd, input_section, output_bfd, rel, sym, howto,
   return true;
 }
 
-static boolean 
+boolean 
 xcoff_reloc_type_crel (input_bfd, input_section, output_bfd, rel, sym, howto, 
                       val, addend, relocation, contents)
      bfd *input_bfd ATTRIBUTE_UNUSED;
@@ -4173,7 +4184,8 @@ const bfd_target rs6000coff_vec =
   _bfd_xcoff_bfd_link_hash_table_create,   /* _bfd_link_hash_table_create */
   _bfd_generic_link_hash_table_free,       /* _bfd_link_hash_table_free */
   _bfd_xcoff_bfd_link_add_symbols,         /* _bfd_link_add_symbols */
-  _bfd_xcoff_bfd_final_link,               /* _bfd_filnal_link */
+  _bfd_generic_link_just_syms,             /* _bfd_link_just_syms */
+  _bfd_xcoff_bfd_final_link,               /* _bfd_final_link */
   _bfd_generic_link_split_section,         /* _bfd_link_split_section */
   bfd_generic_gc_sections,                 /* _bfd_gc_sections */
   bfd_generic_merge_sections,              /* _bfd_merge_sections */
@@ -4434,7 +4446,8 @@ const bfd_target pmac_xcoff_vec =
   _bfd_xcoff_bfd_link_hash_table_create,   /* _bfd_link_hash_table_create */
   _bfd_generic_link_hash_table_free,       /* _bfd_link_hash_table_free */
   _bfd_xcoff_bfd_link_add_symbols,         /* _bfd_link_add_symbols */
-  _bfd_xcoff_bfd_final_link,               /* _bfd_filnal_link */
+  _bfd_generic_link_just_syms,             /* _bfd_link_just_syms */
+  _bfd_xcoff_bfd_final_link,               /* _bfd_final_link */
   _bfd_generic_link_split_section,         /* _bfd_link_split_section */
   bfd_generic_gc_sections,                 /* _bfd_gc_sections */
   bfd_generic_merge_sections,               /* _bfd_merge_sections */
This page took 0.02491 seconds and 4 git commands to generate.