Add dwarf2_per_objfile parameter to create_partial_symtab
[deliverable/binutils-gdb.git] / gdb / sparc-linux-tdep.c
index 856d7357534ebfdc6d573cfaeecc31cac149ef78..247fde21657c41fbde076256e106c5b207f131a1 100644 (file)
@@ -1,6 +1,6 @@
 /* Target-dependent code for GNU/Linux SPARC.
 
-   Copyright (C) 2003-2016 Free Software Foundation, Inc.
+   Copyright (C) 2003-2020 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
@@ -18,7 +18,7 @@
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-#include "dwarf2-frame.h"
+#include "dwarf2/frame.h"
 #include "frame.h"
 #include "frame-unwind.h"
 #include "gdbtypes.h"
@@ -68,9 +68,9 @@ static const struct tramp_frame sparc32_linux_sigframe =
   SIGTRAMP_FRAME,
   4,
   {
-    { 0x821020d8, -1 },                /* mov __NR_sugreturn, %g1 */
-    { 0x91d02010, -1 },                /* ta  0x10 */
-    { TRAMP_SENTINEL_INSN, -1 }
+    { 0x821020d8, ULONGEST_MAX },              /* mov __NR_sigreturn, %g1 */
+    { 0x91d02010, ULONGEST_MAX },              /* ta  0x10 */
+    { TRAMP_SENTINEL_INSN, ULONGEST_MAX }
   },
   sparc32_linux_sigframe_init
 };
@@ -83,9 +83,9 @@ static const struct tramp_frame sparc32_linux_rt_sigframe =
   SIGTRAMP_FRAME,
   4,
   {
-    { 0x82102065, -1 },                /* mov __NR_rt_sigreturn, %g1 */
-    { 0x91d02010, -1 },                /* ta  0x10 */
-    { TRAMP_SENTINEL_INSN, -1 }
+    { 0x82102065, ULONGEST_MAX },              /* mov __NR_rt_sigreturn, %g1 */
+    { 0x91d02010, ULONGEST_MAX },              /* ta  0x10 */
+    { TRAMP_SENTINEL_INSN, ULONGEST_MAX }
   },
   sparc32_linux_sigframe_init
 };
@@ -253,7 +253,7 @@ sparc32_linux_collect_core_fpregset (const struct regset *regset,
 static void
 sparc_linux_write_pc (struct regcache *regcache, CORE_ADDR pc)
 {
-  struct gdbarch_tdep *tdep = gdbarch_tdep (get_regcache_arch (regcache));
+  struct gdbarch_tdep *tdep = gdbarch_tdep (regcache->arch ());
   ULONGEST psr;
 
   regcache_cooked_write_unsigned (regcache, tdep->pc_regnum, pc);
@@ -274,9 +274,9 @@ sparc_linux_write_pc (struct regcache *regcache, CORE_ADDR pc)
 
 static LONGEST
 sparc32_linux_get_syscall_number (struct gdbarch *gdbarch,
-                                 ptid_t ptid)
+                                 thread_info *thread)
 {
-  struct regcache *regcache = get_thread_regcache (ptid);
+  struct regcache *regcache = get_thread_regcache (thread);
   enum bfd_endian byte_order = gdbarch_byte_order (gdbarch);
   /* The content of a register.  */
   gdb_byte buf[4];
@@ -286,7 +286,7 @@ sparc32_linux_get_syscall_number (struct gdbarch *gdbarch,
   /* Getting the system call number from the register.
      When dealing with the sparc architecture, this information
      is stored at the %g1 register.  */
-  regcache_cooked_read (regcache, SPARC_G1_REGNUM, buf);
+  regcache->cooked_read (SPARC_G1_REGNUM, buf);
 
   ret = extract_signed_integer (buf, 4, byte_order);
 
@@ -465,11 +465,9 @@ sparc32_linux_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
                                    sparc32_linux_gdb_signal_to_target);
 }
 
-/* Provide a prototype to silence -Wmissing-prototypes.  */
-extern void _initialize_sparc_linux_tdep (void);
-
+void _initialize_sparc_linux_tdep ();
 void
-_initialize_sparc_linux_tdep (void)
+_initialize_sparc_linux_tdep ()
 {
   gdbarch_register_osabi (bfd_arch_sparc, 0, GDB_OSABI_LINUX,
                          sparc32_linux_init_abi);
This page took 0.025801 seconds and 4 git commands to generate.