Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: rbrown64@csc.com.au
To: gdb-patches@sources.redhat.com
Cc: <msnyder@redhat.com>
Subject: PATCH: procfs.c for UnixWare (v4)
Date: Thu, 17 Jan 2002 23:10:00 -0000	[thread overview]
Message-ID: <OFE3950F2D.E8203C5E-ONCA256B45.0026BE5D@int.csc.com.au> (raw)

2001-01-18  Rodney Brown  <rbrown64@csc.com.au>
     * procfs.c: Prototype elfcore_write_prstatus, elfcore_write_pstatus,
     elfcore_write_prfpreg, elfcore_write_prpsinfo.
     (procfs_do_thread_registers): Call elfcore_write_gdb_prstatus.

--- procfs.c.orig   Tue Jan 15 15:01:48 2002
+++ procfs.c   Fri Jan 18 16:41:38 2002
@@ -55,7 +55,7 @@ Inc., 59 Temple Place - Suite 330, Bosto
  *   Unixware
  *   AIX5
  *
- * /proc works by immitating a file system: you open a simulated file
+ * /proc works by imitating a file system: you open a simulated file
  * that represents the process you wish to interact with, and
  * perform operations on that "file" in order to examine or change
  * the state of the other process.
@@ -135,6 +135,14 @@ static int proc_find_memory_regions (int

 static char * procfs_make_note_section (bfd *, int *);

+#ifndef  HAVE_PSTATUS_T
+char *elfcore_write_prstatus (bfd *, char *, int *, long, int, void *);
+#else
+char *elfcore_write_pstatus (bfd *, char *, int *, long, int, void *);
+#endif
+char *elfcore_write_prfpreg (bfd  *, char *, int  *, void *, int);
+char *elfcore_write_prpsinfo (bfd  *, char *, int  *, char *, char *);
+
 struct target_ops procfs_ops;           /* the target vector */

 static void
@@ -5733,12 +5741,22 @@ procfs_do_thread_registers (bfd *obfd, p
   merged_pid = TIDGET (ptid) << 16 | PIDGET (ptid);

   fill_gregset (&gregs, -1);
+/* Solaris 2.7 has NEW_PROC_API, but defaults to !HAVE_PSTATUS_T.  */
+#ifndef  HAVE_PSTATUS_T
   note_data = (char *) elfcore_write_prstatus (obfd,
                                                note_data,
                                                note_size,
                                merged_pid,
                                stop_signal,
                                                &gregs);
+#else
+  note_data = (char *) elfcore_write_pstatus (obfd,
+                                              note_data,
+                                              note_size,
+                              merged_pid,
+                              stop_signal,
+                                              &gregs);
+#endif
   fill_fpregset (&fpregs, -1);
   note_data = (char *) elfcore_write_prfpreg (obfd,
                               note_data,


             reply	other threads:[~2002-01-18  7:10 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-01-17 23:10 rbrown64 [this message]
2002-03-23 11:03 ` Andrew Cagney
2002-03-25 11:26   ` Michael Snyder

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=OFE3950F2D.E8203C5E-ONCA256B45.0026BE5D@int.csc.com.au \
    --to=rbrown64@csc.com.au \
    --cc=gdb-patches@sources.redhat.com \
    --cc=msnyder@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox