summaryrefslogtreecommitdiff
path: root/bfd/cpu-riscv.c
diff options
context:
space:
mode:
Diffstat (limited to 'bfd/cpu-riscv.c')
-rw-r--r--bfd/cpu-riscv.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/bfd/cpu-riscv.c b/bfd/cpu-riscv.c
index 153a84e8835..aca7ade0af3 100644
--- a/bfd/cpu-riscv.c
+++ b/bfd/cpu-riscv.c
@@ -39,11 +39,11 @@ riscv_compatible (const bfd_arch_info_type *a, const bfd_arch_info_type *b)
return a;
}
-#define N(BITS_WORD, BITS_ADDR, NUMBER, PRINT, DEFAULT, NEXT) \
+#define N(BITS, NUMBER, PRINT, DEFAULT, NEXT) \
{ \
- BITS_WORD, /* bits in a word */ \
- BITS_ADDR, /* bits in an address */ \
- 8, /* 8 bits in a byte */ \
+ BITS, /* Bits in a word. */ \
+ BITS, /* Bits in an address. */ \
+ 8, /* Bits in a byte. */ \
bfd_arch_riscv, \
NUMBER, \
"riscv", \
@@ -54,6 +54,7 @@ riscv_compatible (const bfd_arch_info_type *a, const bfd_arch_info_type *b)
bfd_default_scan, \
bfd_arch_default_fill, \
NEXT, \
+ 0 /* Maximum offset of a reloc from the start of an insn. */\
}
/* This enum must be kept in the same order as arch_info_struct. */
@@ -69,11 +70,11 @@ enum
and each entry except the last should end with NN (my enum value). */
static const bfd_arch_info_type arch_info_struct[] =
{
- N (64, 64, bfd_mach_riscv64, "riscv:rv64", FALSE, NN (I_riscv64)),
- N (32, 32, bfd_mach_riscv32, "riscv:rv32", FALSE, 0)
+ N (64, bfd_mach_riscv64, "riscv:rv64", FALSE, NN (I_riscv64)),
+ N (32, bfd_mach_riscv32, "riscv:rv32", FALSE, NULL)
};
/* The default architecture is riscv:rv64. */
const bfd_arch_info_type bfd_riscv_arch =
- N (64, 64, 0, "riscv", TRUE, &arch_info_struct[0]);
+ N (64, 0, "riscv", TRUE, &arch_info_struct[0]);