aboutsummaryrefslogtreecommitdiffstats
path: root/linux
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2023-06-24 17:15:21 +0200
committerMattias Andrée <maandree@kth.se>2023-06-24 17:15:21 +0200
commitf61fda368da04a569e10c9928c01cfdca0faff7e (patch)
treec9789d794806a1d1468b7fae32134dcebb6ca67e /linux
parentFix some illegal aliasing (diff)
downloadsctrace-f61fda368da04a569e10c9928c01cfdca0faff7e.tar.gz
sctrace-f61fda368da04a569e10c9928c01cfdca0faff7e.tar.bz2
sctrace-f61fda368da04a569e10c9928c01cfdca0faff7e.tar.xz
Argument 3 and 4 are swapped on SPARC for PTRACE_GETREGS and PTRACE_SETREGS
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r--linux/os.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/linux/os.h b/linux/os.h
index db22f10..c89f602 100644
--- a/linux/os.h
+++ b/linux/os.h
@@ -30,3 +30,9 @@
#else
# error "This program is only implemented for x86-64 on Linux"
#endif
+
+#if defined(__sparc__)
+# define REGARGS(a, b) b, a
+#else
+# define REGARGS(a, b) a, b
+#endif