/* Target-dependent code for PowerPC systems running FreeBSD.
- Copyright (C) 2013-2020 Free Software Foundation, Inc.
+ Copyright (C) 2013-2021 Free Software Foundation, Inc.
This file is part of GDB.
#include "ppc-fbsd-tdep.h"
#include "fbsd-tdep.h"
#include "solib-svr4.h"
+#include "inferior.h"
/* 32-bit regset descriptions. */
unsigned long insn;
if (!safe_frame_unwind_memory (this_frame, start_pc + *offset,
- buf, sizeof buf))
+ {buf, sizeof buf}))
continue;
/* Check for "li r0,SYS_sigreturn". */
func = get_frame_pc (this_frame);
func &= ~(ppcfbsd_page_size - 1);
- if (!safe_frame_unwind_memory (this_frame, func, buf, sizeof buf))
+ if (!safe_frame_unwind_memory (this_frame, func, {buf, sizeof buf}))
return cache;
base = get_frame_register_unsigned (this_frame, gdbarch_sp_regnum (gdbarch));
struct regcache *regcache;
int tp_offset, tp_regnum;
- regcache = get_thread_arch_regcache (ptid, gdbarch);
+ regcache = get_thread_arch_regcache (current_inferior ()->process_target (),
+ ptid, gdbarch);
if (tdep->wordsize == 4)
{
ppcfbsd_get_thread_local_address);
}
+void _initialize_ppcfbsd_tdep ();
void
-_initialize_ppcfbsd_tdep (void)
+_initialize_ppcfbsd_tdep ()
{
gdbarch_register_osabi (bfd_arch_powerpc, bfd_mach_ppc, GDB_OSABI_FREEBSD,
ppcfbsd_init_abi);