RISC-V: Add RV32E support.
[deliverable/binutils-gdb.git] / bfd / elf32-d10v.c
index 0d1453cbc19b7b084ae9fefe4581d674a5728e78..c901595817fa83e4a078e0e0c574b05000fc346b 100644 (file)
@@ -220,8 +220,8 @@ bfd_elf32_bfd_reloc_name_lookup (bfd *abfd ATTRIBUTE_UNUSED,
 
 /* Set the howto pointer for an D10V ELF reloc.  */
 
-static void
-d10v_info_to_howto_rel (bfd *abfd ATTRIBUTE_UNUSED,
+static bfd_boolean
+d10v_info_to_howto_rel (bfd *abfd,
                        arelent *cache_ptr,
                        Elf_Internal_Rela *dst)
 {
@@ -231,10 +231,13 @@ d10v_info_to_howto_rel (bfd *abfd ATTRIBUTE_UNUSED,
   if (r_type >= (unsigned int) R_D10V_max)
     {
       /* xgettext:c-format */
-      _bfd_error_handler (_("%B: invalid D10V reloc number: %d"), abfd, r_type);
-      r_type = 0;
+      _bfd_error_handler (_("%pB: unsupported relocation type %#x"),
+                         abfd, r_type);
+      bfd_set_error (bfd_error_bad_value);
+      return FALSE;
     }
   cache_ptr->howto = &elf_d10v_howto_table[r_type];
+  return TRUE;
 }
 
 static asection *
@@ -539,7 +542,7 @@ elf32_d10v_relocate_section (bfd *output_bfd,
 #define TARGET_BIG_SYM         d10v_elf32_vec
 #define TARGET_BIG_NAME                "elf32-d10v"
 
-#define elf_info_to_howto                   0
+#define elf_info_to_howto                   NULL
 #define elf_info_to_howto_rel               d10v_info_to_howto_rel
 #define elf_backend_object_p                0
 #define elf_backend_final_write_processing   0
This page took 0.023705 seconds and 4 git commands to generate.