aboutsummaryrefslogtreecommitdiffstats
path: root/main/strace/s390-fix-SIGNAL_FRAMESIZE-macro-4.24.patch
blob: 0d9e738f2956a805af96bda8731446f73a4ab7e1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
diff --git a/linux/s390/arch_sigreturn.c b/linux/s390/arch_sigreturn.c
index 9c9e0dd..0d4cec8 100644
--- a/linux/s390/arch_sigreturn.c
+++ b/linux/s390/arch_sigreturn.c
@@ -2,7 +2,7 @@
 # define S390_FRAME_PTR s390_frame_ptr
 #endif
 #ifndef SIGNAL_FRAMESIZE
-# define SIGNAL_FRAMESIZE __SIGNAL_FRAMESIZE
+# define SIGNAL_FRAMESIZE 96
 #endif
 #ifndef PTR_TYPE
 # define PTR_TYPE unsigned long
diff --git a/linux/s390/rt_sigframe.h b/linux/s390/rt_sigframe.h
index 7e8743e..9e77ebb 100644
--- a/linux/s390/rt_sigframe.h
+++ b/linux/s390/rt_sigframe.h
@@ -30,8 +30,14 @@
 
 #include <signal.h>
 
+#ifdef __s390x__
+# define SIGNAL_FRAMESIZE 160
+#else /* __s390__ */
+# define SIGNAL_FRAMESIZE 96
+#endif
+
 typedef struct {
-	uint8_t		callee_used_stack[__SIGNAL_FRAMESIZE];
+	uint8_t		callee_used_stack[SIGNAL_FRAMESIZE];
 	uint16_t	svc_insn;
 	siginfo_t	info;
 	ucontext_t	uc;
diff --git a/linux/s390x/arch_sigreturn.c b/linux/s390x/arch_sigreturn.c
index edc9edd..38dd650 100644
--- a/linux/s390x/arch_sigreturn.c
+++ b/linux/s390x/arch_sigreturn.c
@@ -1,8 +1,6 @@
 #include <stdint.h>
 
-#define S390_SIGNAL_FRAMESIZE      96
 
-#define SIGNAL_FRAMESIZE	S390_SIGNAL_FRAMESIZE
 #define PTR_TYPE		uint32_t
 #define S390_FRAME_PTR		s390_frame_ptr
 #define arch_sigreturn	s390_arch_sigreturn
@@ -12,6 +10,7 @@
 #undef PTR_TYPE
 #undef SIGNAL_FRAMESIZE
 
+#define S390_SIGNAL_FRAMESIZE      160
 #define S390_FRAME_PTR		s390x_frame_ptr
 #define arch_sigreturn	s390x_arch_sigreturn
 #include "s390/arch_sigreturn.c"