Fix AArch64 in the same way as other targets updated in 8170f7693bc0a9442c0aa28019792...
[binutils-gdb.git] / bfd / nlm32-sparc.c
index 42c0c5bda6013636dd95d5ce9bbf6c76c5ad3e49..cfd4b9e010d916f5b1b494c731e3abc336127d2f 100644 (file)
@@ -1,6 +1,5 @@
 /* Support for 32-bit SPARC NLM (NetWare Loadable Module)
-   Copyright 1993, 1994, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
-   2007, 2009 Free Software Foundation, Inc.
+   Copyright (C) 1993-2017 Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
 
@@ -50,7 +49,7 @@ enum reloc_type
 
 static reloc_howto_type nlm32_sparc_howto_table[] =
 {
-  HOWTO (R_SPARC_NONE,    0,0, 0,FALSE,0,complain_overflow_dont,    0,"R_SPARC_NONE",    FALSE,0,0x00000000,TRUE),
+  HOWTO (R_SPARC_NONE,    0,3, 0,FALSE,0,complain_overflow_dont,    0,"R_SPARC_NONE",    FALSE,0,0x00000000,TRUE),
   HOWTO (R_SPARC_8,       0,0, 8,FALSE,0,complain_overflow_bitfield,0,"R_SPARC_8",       FALSE,0,0x000000ff,TRUE),
   HOWTO (R_SPARC_16,      0,1,16,FALSE,0,complain_overflow_bitfield,0,"R_SPARC_16",      FALSE,0,0x0000ffff,TRUE),
   HOWTO (R_SPARC_32,      0,2,32,FALSE,0,complain_overflow_bitfield,0,"R_SPARC_32",      FALSE,0,0xffffffff,TRUE),
@@ -96,14 +95,12 @@ nlm_sparc_read_reloc (bfd *abfd,
   unsigned int howto_index;
   unsigned int type;
   struct nlm32_sparc_reloc_ext tmp_reloc;
-  asection *code_sec, *data_sec;
+  asection *code_sec;
 
   if (bfd_bread (&tmp_reloc, (bfd_size_type) 12, abfd) != 12)
     return FALSE;
 
   code_sec = bfd_get_section_by_name (abfd, NLM_CODE_NAME);
-  data_sec = bfd_get_section_by_name (abfd, NLM_INITIALIZED_DATA_NAME);
-
   *secp = code_sec;
 
   val = bfd_get_32 (abfd, tmp_reloc.offset);
@@ -375,7 +372,7 @@ static const struct nlm_backend_data nlm32_sparc_backend =
 };
 
 #define TARGET_BIG_NAME                "nlm32-sparc"
-#define TARGET_BIG_SYM         nlmNAME (sparc_vec)
+#define TARGET_BIG_SYM         sparc_nlm32_vec
 #define TARGET_BACKEND_DATA    & nlm32_sparc_backend
 
 #include "nlm-target.h"