+2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
+
+ * linux-low.c (regsets_store_inferior_registers): Skip regsets
+ without a fill_function.
+ * linux-s390-low.c (s390_fill_last_break): Remove.
+ (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
+ (s390_arch_setup): Use regset's size instead of fill_function for
+ loop end condition.
+
2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
* linux-low.c (regsets_fetch_inferior_registers): Do not invoke
/* Fill and store functions for extended register sets. */
-static void
-s390_fill_last_break (struct regcache *regcache, void *buf)
-{
- /* Last break address is read-only. */
-}
-
static void
s390_store_last_break (struct regcache *regcache, const void *buf)
{
static struct regset_info s390_regsets[] = {
{ 0, 0, 0, 0, GENERAL_REGS, s390_fill_gregset, NULL },
- /* Last break address is read-only; do not attempt PTRACE_SETREGSET. */
- { PTRACE_GETREGSET, PTRACE_GETREGSET, NT_S390_LAST_BREAK, 0,
- EXTENDED_REGS, s390_fill_last_break, s390_store_last_break },
+ /* Last break address is read-only; no fill function. */
+ { PTRACE_GETREGSET, -1, NT_S390_LAST_BREAK, 0, EXTENDED_REGS,
+ NULL, s390_store_last_break },
{ PTRACE_GETREGSET, PTRACE_SETREGSET, NT_S390_SYSTEM_CALL, 0,
EXTENDED_REGS, s390_fill_system_call, s390_store_system_call },
{ 0, 0, 0, -1, -1, NULL, NULL }
#endif
/* Update target_regsets according to available register sets. */
- for (regset = s390_regsets; regset->fill_function != NULL; regset++)
+ for (regset = s390_regsets; regset->size >= 0; regset++)
if (regset->get_request == PTRACE_GETREGSET)
switch (regset->nt_type)
{