]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - gdb/procfs.c
2004-01-17 Andrew Cagney <cagney@redhat.com>
[thirdparty/binutils-gdb.git] / gdb / procfs.c
index 969bbcb2b614aa921cf8610a35ec6f9728e13abf..090cf73c7b25a3cdedb5068bf7dc64faf6017a50 100644 (file)
@@ -1,5 +1,8 @@
 /* Machine independent support for SVR4 /proc (process file system) for GDB.
-   Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+
+   Copyright 1999, 2000, 2001, 2002, 2003 Free Software Foundation,
+   Inc.
+
    Written by Michael Snyder at Cygnus Solutions.
    Based on work by Fred Fish, Stu Grossman, Geoff Noer, and others.
 
@@ -39,7 +42,7 @@ Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
 #include <sys/syscall.h>
 #endif
 #include <sys/errno.h>
-#include <sys/wait.h>
+#include "gdb_wait.h"
 #include <signal.h>
 #include <ctype.h>
 #include "gdb_assert.h"
@@ -3700,11 +3703,10 @@ procfs_fetch_registers (int regno)
 
   if (FP0_REGNUM >= 0) /* need floating point? */
     {
-      if ((regno >= 0 && regno < FP0_REGNUM) ||
-         regno == PC_REGNUM  ||
-         (NPC_REGNUM >= 0 && regno == NPC_REGNUM) ||
-         regno == FP_REGNUM  ||
-         regno == SP_REGNUM)
+      if ((regno >= 0 && regno < FP0_REGNUM)
+         || regno == PC_REGNUM
+         || regno == DEPRECATED_FP_REGNUM
+         || regno == SP_REGNUM)
        return;                 /* not a floating point register */
 
       if ((fpregs = proc_get_fpregs (pi)) == NULL)
@@ -3774,11 +3776,10 @@ procfs_store_registers (int regno)
 
   if (FP0_REGNUM >= 0)         /* need floating point? */
     {
-      if ((regno >= 0 && regno < FP0_REGNUM) ||
-         regno == PC_REGNUM  ||
-         (NPC_REGNUM >= 0 && regno == NPC_REGNUM) ||
-         regno == FP_REGNUM  ||
-         regno == SP_REGNUM)
+      if ((regno >= 0 && regno < FP0_REGNUM)
+         || regno == PC_REGNUM
+         || regno == DEPRECATED_FP_REGNUM
+         || regno == SP_REGNUM)
        return;                 /* not a floating point register */
 
       if ((fpregs = proc_get_fpregs (pi)) == NULL)
@@ -4160,7 +4161,7 @@ wait_again:
                wstat = (what << 8) | 0177;
                break;
              case PR_FAULTED:
-               switch (what) { /* FIXME: FAULTED_USE_SIGINFO */
+               switch (what) {
 #ifdef FLTWATCH
                case FLTWATCH:
                  wstat = (SIGTRAP << 8) | 0177;
@@ -5516,7 +5517,6 @@ mappingflags (long flags)
  * Callback function, does the actual work for 'info proc mappings'.
  */
 
-/* ARGSUSED */
 static int
 info_mappings_callback (struct prmap *map, int (*ignore) (), void *unused)
 {