Code cleanup - renaming.
[deliverable/binutils-gdb.git] / gdb / ia64-linux-nat.c
index c2a06ed634826245dab154d8ed7383420500733d..f9f5bf36e911416c8d577780e6a398a3ce854109 100644 (file)
@@ -2,7 +2,7 @@
    GNU/Linux.
 
    Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
-   2009 Free Software Foundation, Inc.
+   2009, 2010 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
@@ -530,7 +530,8 @@ is_power_of_2 (int val)
 }
 
 static int
-ia64_linux_insert_watchpoint (CORE_ADDR addr, int len, int rw)
+ia64_linux_insert_watchpoint (CORE_ADDR addr, int len, int rw,
+                             struct expression *cond)
 {
   struct lwp_info *lp;
   ptid_t ptid;
@@ -584,7 +585,8 @@ ia64_linux_insert_watchpoint (CORE_ADDR addr, int len, int rw)
 }
 
 static int
-ia64_linux_remove_watchpoint (CORE_ADDR addr, int len, int type)
+ia64_linux_remove_watchpoint (CORE_ADDR addr, int len, int type,
+                             struct expression *cond)
 {
   int idx;
   long dbr_addr, dbr_mask;
@@ -718,7 +720,8 @@ ia64_linux_fetch_register (struct regcache *regcache, int regnum)
    for all registers.  */
 
 static void
-ia64_linux_fetch_registers (struct regcache *regcache, int regnum)
+ia64_linux_fetch_registers (struct target_ops *ops,
+                           struct regcache *regcache, int regnum)
 {
   if (regnum == -1)
     for (regnum = 0;
@@ -775,7 +778,8 @@ ia64_linux_store_register (const struct regcache *regcache, int regnum)
    this for all registers.  */
 
 static void
-ia64_linux_store_registers (struct regcache *regcache, int regnum)
+ia64_linux_store_registers (struct target_ops *ops,
+                           struct regcache *regcache, int regnum)
 {
   if (regnum == -1)
     for (regnum = 0;
@@ -805,6 +809,18 @@ ia64_linux_xfer_partial (struct target_ops *ops,
                             offset, len);
 }
 
+/* For break.b instruction ia64 CPU forgets the immediate value and generates
+   SIGILL with ILL_ILLOPC instead of more common SIGTRAP with TRAP_BRKPT.
+   ia64 does not use gdbarch_decr_pc_after_break so we do not have to make any
+   difference for the signals here.  */
+
+static int
+ia64_linux_status_is_event (int status)
+{
+  return WIFSTOPPED (status) && (WSTOPSIG (status) == SIGTRAP
+                                || WSTOPSIG (status) == SIGILL);
+}
+
 void _initialize_ia64_linux_nat (void);
 
 void
@@ -844,4 +860,5 @@ _initialize_ia64_linux_nat (void)
   /* Register the target.  */
   linux_nat_add_target (t);
   linux_nat_set_new_thread (t, ia64_linux_new_thread);
+  linux_nat_set_status_is_event (t, ia64_linux_status_is_event);
 }
This page took 0.025612 seconds and 4 git commands to generate.