gdb/testsuite/
[deliverable/binutils-gdb.git] / gdb / amd64-linux-nat.c
index 16e97a2d04e2236bef3992f94b00caf3cbdb29fc..caf2e963060cce9d67f5c83c3f31bb2b32a6ccc3 100644 (file)
@@ -1,7 +1,7 @@
 /* Native-dependent code for GNU/Linux x86-64.
 
-   Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
-   Free Software Foundation, Inc.
+   Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
+   2011 Free Software Foundation, Inc.
    Contributed by Jiri Smid, SuSE Labs.
 
    This file is part of GDB.
@@ -40,7 +40,7 @@
    <asm/ptrace.h> because the latter redefines FS and GS for no apparent
    reason, and those definitions don't match the ones that libpthread_db
    uses, which come from <sys/reg.h>.  */
-/* ezannoni-2003-07-09: I think this is fixed. The extraneous defs have
+/* ezannoni-2003-07-09: I think this is fixed.  The extraneous defs have
    been removed from ptrace.h in the kernel.  However, better safe than
    sorry.  */
 #include <asm/ptrace.h>
@@ -319,11 +319,10 @@ static void
 amd64_linux_dr_set_control (unsigned long control)
 {
   struct lwp_info *lp;
-  ptid_t ptid;
 
   amd64_linux_dr[DR_CONTROL] = control;
-  ALL_LWPS (lp, ptid)
-    amd64_linux_dr_set (ptid, DR_CONTROL, control);
+  ALL_LWPS (lp)
+    amd64_linux_dr_set (lp->ptid, DR_CONTROL, control);
 }
 
 /* Set address REGNUM (zero based) to ADDR in all LWPs of LWP_LIST.  */
@@ -332,13 +331,12 @@ static void
 amd64_linux_dr_set_addr (int regnum, CORE_ADDR addr)
 {
   struct lwp_info *lp;
-  ptid_t ptid;
 
   gdb_assert (regnum >= 0 && regnum <= DR_LASTADDR - DR_FIRSTADDR);
 
   amd64_linux_dr[DR_FIRSTADDR + regnum] = addr;
-  ALL_LWPS (lp, ptid)
-    amd64_linux_dr_set (ptid, DR_FIRSTADDR + regnum, addr);
+  ALL_LWPS (lp)
+    amd64_linux_dr_set (lp->ptid, DR_FIRSTADDR + regnum, addr);
 }
 
 /* Set address REGNUM (zero based) to zero in all LWPs of LWP_LIST.  */
@@ -363,15 +361,14 @@ static void
 amd64_linux_dr_unset_status (unsigned long mask)
 {
   struct lwp_info *lp;
-  ptid_t ptid;
 
-  ALL_LWPS (lp, ptid)
+  ALL_LWPS (lp)
     {
       unsigned long value;
       
-      value = amd64_linux_dr_get (ptid, DR_STATUS);
+      value = amd64_linux_dr_get (lp->ptid, DR_STATUS);
       value &= ~mask;
-      amd64_linux_dr_set (ptid, DR_STATUS, value);
+      amd64_linux_dr_set (lp->ptid, DR_STATUS, value);
     }
 }
 
This page took 0.023629 seconds and 4 git commands to generate.