summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoland McGrath <roland@redhat.com>2004-03-01 20:30:48 +0000
committerRoland McGrath <roland@redhat.com>2004-03-01 20:30:48 +0000
commitb4ce17690f176b972a8cb5cbdd1005bbd4aecf15 (patch)
tree4fe27efa142640b78b5b435ffa0ce27f3593fb41
parent176ac32167992711eca4a47e331ff6616590b347 (diff)
downloadstrace-b4ce17690f176b972a8cb5cbdd1005bbd4aecf15.tar.gz
strace-b4ce17690f176b972a8cb5cbdd1005bbd4aecf15.tar.bz2
strace-b4ce17690f176b972a8cb5cbdd1005bbd4aecf15.tar.xz
2004-02-26 Andreas Schwab <schwab@suse.de>
* defs.h [LINUX && IA64]: Declare getrval2 also on IA64. * net.c (sys_pipe) [LINUX && IA64]: For IA64 use the two return values. * syscall.c (getrval2) [LINUX && IA64]: Implement for IA64.
-rw-r--r--defs.h2
-rw-r--r--net.c4
-rw-r--r--syscall.c3
3 files changed, 6 insertions, 3 deletions
diff --git a/defs.h b/defs.h
index 7641e67..6d22d34 100644
--- a/defs.h
+++ b/defs.h
@@ -484,7 +484,7 @@ extern void tv_div P((struct timeval *, struct timeval *, int));
#ifdef SUNOS4
extern int fixvfork P((struct tcb *));
#endif
-#if !(defined(LINUX) && !defined(SPARC))
+#if !(defined(LINUX) && !defined(SPARC) && !defined(IA64))
extern long getrval2 P((struct tcb *));
#endif
#ifdef USE_PROCFS
diff --git a/net.c b/net.c
index 7dcd286..e986a42 100644
--- a/net.c
+++ b/net.c
@@ -1166,7 +1166,7 @@ sys_pipe(tcp)
struct tcb *tcp;
{
-#if defined(LINUX) && !defined(SPARC) && !defined(SH)
+#if defined(LINUX) && !defined(SPARC) && !defined(SH) && !defined(IA64)
int fds[2];
if (exiting(tcp)) {
@@ -1179,7 +1179,7 @@ struct tcb *tcp;
else
tprintf("[%u, %u]", fds[0], fds[1]);
}
-#elif defined(SPARC) || defined(SH) || defined(SVR4) || defined(FREEBSD)
+#elif defined(SPARC) || defined(SH) || defined(SVR4) || defined(FREEBSD) || defined(IA64)
if (exiting(tcp))
tprintf("[%lu, %lu]", tcp->u_rval, getrval2(tcp));
#endif
diff --git a/syscall.c b/syscall.c
index d2981b7..214e38b 100644
--- a/syscall.c
+++ b/syscall.c
@@ -2432,6 +2432,9 @@ struct tcb *tcp;
if (upeek(tcp->pid, 4*(REG_REG0+1), &val) < 0)
return -1;
#endif /* SPARC */
+#elif defined(IA64)
+ if (upeek(tcp->pid, PT_R9, &val) < 0)
+ return -1;
#endif /* LINUX */
#ifdef SUNOS4