+2015-10-29 Pedro Alves <palves@redhat.com>
+
+ * linux-low.h (NULL_REGSET): Define.
+ * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
+ * linux-arm-low.c (arm_regsets): Likewise.
+ * linux-crisv32-low.c (cris_regsets): Likewise.
+ * linux-m68k-low.c (m68k_regsets): Likewise.
+ * linux-mips-low.c (mips_regsets): Likewise.
+ * linux-nios2-low.c (nios2_regsets): Likewise.
+ * linux-ppc-low.c (ppc_regsets): Likewise.
+ * linux-s390-low.c (s390_regsets): Likewise.
+ * linux-sh-low.c (sh_regsets): Likewise.
+ * linux-sparc-low.c (sparc_regsets): Likewise.
+ * linux-tic6x-low.c (tic6x_regsets): Likewise.
+ * linux-tile-low.c (tile_regsets): Likewise.
+ * linux-x86-low.c (x86_regsets): Likewise.
+ * linux-xtensa-low.c (xtensa_regsets): Likewise.
+
2015-10-26 Doug Evans <dje@google.com>
* linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
sizeof (struct user_fpsimd_state), FP_REGS,
aarch64_fill_fpregset, aarch64_store_fpregset
},
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
static struct regsets_info aarch64_regsets_info =
{ PTRACE_GETVFPREGS, PTRACE_SETVFPREGS, 0, 32 * 8 + 4,
EXTENDED_REGS,
arm_fill_vfpregset, arm_store_vfpregset },
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
static struct regsets_info arm_regsets_info =
static struct regset_info cris_regsets[] = {
{ PTRACE_GETREGS, PTRACE_SETREGS, 0, cris_num_regs * 4,
GENERAL_REGS, cris_fill_gregset, cris_store_gregset },
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
EXTENDED_REGS,
};
+/* The arch's regsets array initializer must be terminated with a NULL
+ regset. */
+#define NULL_REGSET \
+ { 0, 0, 0, -1, (enum regset_type) -1, NULL, NULL }
+
struct regset_info
{
int get_request, set_request;
FP_REGS,
m68k_fill_fpregset, m68k_store_fpregset },
#endif /* HAVE_PTRACE_GETREGS */
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
static const gdb_byte m68k_breakpoint[] = { 0x4E, 0x4F };
{ PTRACE_GETFPREGS, PTRACE_SETFPREGS, 0, 33 * 8, FP_REGS,
mips_fill_fpregset, mips_store_fpregset },
#endif /* HAVE_PTRACE_GETREGS */
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
static struct regsets_info mips_regsets_info =
{ PTRACE_GETREGSET, PTRACE_SETREGSET, NT_PRSTATUS,
nios2_num_regs * 4, GENERAL_REGS,
nios2_fill_gregset, nios2_store_gregset },
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
static struct regsets_info nios2_regsets_info =
{ PTRACE_GETEVRREGS, PTRACE_SETEVRREGS, 0, 32 * 4 + 8 + 4, EXTENDED_REGS,
ppc_fill_evrregset, ppc_store_evrregset },
{ 0, 0, 0, 0, GENERAL_REGS, ppc_fill_gregset, NULL },
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
static struct usrregs_info ppc_usrregs_info =
EXTENDED_REGS, s390_fill_vxrs_low, s390_store_vxrs_low },
{ PTRACE_GETREGSET, PTRACE_SETREGSET, NT_S390_VXRS_HIGH, 0,
EXTENDED_REGS, s390_fill_vxrs_high, s390_store_vxrs_high },
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
static struct regset_info sh_regsets[] = {
{ 0, 0, 0, 0, GENERAL_REGS, sh_fill_gregset, NULL },
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
static struct regsets_info sh_regsets_info =
{ PTRACE_GETFPREGS, PTRACE_SETFPREGS, 0, sizeof (fpregset_t),
FP_REGS,
sparc_fill_fpregset, sparc_store_fpregset },
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
static struct regsets_info sparc_regsets_info =
static struct regset_info tic6x_regsets[] = {
{ PTRACE_GETREGS, PTRACE_SETREGS, 0, TIC6X_NUM_REGS * 4, GENERAL_REGS,
tic6x_fill_gregset, tic6x_store_gregset },
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
static void
{
{ PTRACE_GETREGS, PTRACE_SETREGS, 0, tile_num_regs * 8,
GENERAL_REGS, tile_fill_gregset, tile_store_gregset },
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
static struct regsets_info tile_regsets_info =
FP_REGS,
x86_fill_fpregset, x86_store_fpregset },
#endif /* HAVE_PTRACE_GETREGS */
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
static CORE_ADDR
{ PTRACE_GETXTREGS, PTRACE_SETXTREGS, 0, XTENSA_ELF_XTREG_SIZE,
EXTENDED_REGS,
xtensa_fill_xtregset, xtensa_store_xtregset },
- { 0, 0, 0, -1, -1, NULL, NULL }
+ NULL_REGSET
};
#if XCHAL_HAVE_BE