]> git.wh0rd.org - dump.git/blobdiff - dump/tape.c
Better s390 patch from Adam Tkac.
[dump.git] / dump / tape.c
index edcf5d691925a6532dd71e8b30f75514d8190109..e46d62630cc839884c481d2db406c51692a1db61 100644 (file)
@@ -37,7 +37,7 @@
 
 #ifndef lint
 static const char rcsid[] =
-       "$Id: tape.c,v 1.91 2009/06/18 09:50:54 stelian Exp $";
+       "$Id: tape.c,v 1.93 2011/05/20 09:52:19 stelian Exp $";
 #endif /* not lint */
 
 #include <config.h>
@@ -211,8 +211,17 @@ static int gtperr = 0;
  * Neither is useful in our case, so this is easy to handle.
  */
 #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,49)
-/* clone_flags, child_stack, parent_tidptr, child_tidptr */
+/*
+ * Parameters of the sys_clone syscall are
+ * clone_flags, child_stack, parent_tidptr, child_tidptr
+ * on all architectures except s390 and s390x
+ * s390* have child_stack, clone_flags, parent_tidptr, child_tidptr
+ */
+#if defined(__s390__) || defined(__s390x__)
+#define CLONE_ARGS 0, SIGCHLD|CLONE_IO, NULL, NULL
+#else
 #define CLONE_ARGS SIGCHLD|CLONE_IO, 0, NULL, NULL
+#endif
 #else
 #define CLONE_ARGS SIGCHLD|CLONE_IO, 0
 #endif /* LINUX_VERSION_CODE */