|
14 | 14 | * Offsets in the user_regs_struct. They are used for the ptrace |
15 | 15 | * system call and in entry.S |
16 | 16 | */ |
17 | | -#ifndef __s390x__ |
18 | | - |
19 | | -#define PT_PSWMASK 0x00 |
20 | | -#define PT_PSWADDR 0x04 |
21 | | -#define PT_GPR0 0x08 |
22 | | -#define PT_GPR1 0x0C |
23 | | -#define PT_GPR2 0x10 |
24 | | -#define PT_GPR3 0x14 |
25 | | -#define PT_GPR4 0x18 |
26 | | -#define PT_GPR5 0x1C |
27 | | -#define PT_GPR6 0x20 |
28 | | -#define PT_GPR7 0x24 |
29 | | -#define PT_GPR8 0x28 |
30 | | -#define PT_GPR9 0x2C |
31 | | -#define PT_GPR10 0x30 |
32 | | -#define PT_GPR11 0x34 |
33 | | -#define PT_GPR12 0x38 |
34 | | -#define PT_GPR13 0x3C |
35 | | -#define PT_GPR14 0x40 |
36 | | -#define PT_GPR15 0x44 |
37 | | -#define PT_ACR0 0x48 |
38 | | -#define PT_ACR1 0x4C |
39 | | -#define PT_ACR2 0x50 |
40 | | -#define PT_ACR3 0x54 |
41 | | -#define PT_ACR4 0x58 |
42 | | -#define PT_ACR5 0x5C |
43 | | -#define PT_ACR6 0x60 |
44 | | -#define PT_ACR7 0x64 |
45 | | -#define PT_ACR8 0x68 |
46 | | -#define PT_ACR9 0x6C |
47 | | -#define PT_ACR10 0x70 |
48 | | -#define PT_ACR11 0x74 |
49 | | -#define PT_ACR12 0x78 |
50 | | -#define PT_ACR13 0x7C |
51 | | -#define PT_ACR14 0x80 |
52 | | -#define PT_ACR15 0x84 |
53 | | -#define PT_ORIGGPR2 0x88 |
54 | | -#define PT_FPC 0x90 |
55 | | -/* |
56 | | - * A nasty fact of life that the ptrace api |
57 | | - * only supports passing of longs. |
58 | | - */ |
59 | | -#define PT_FPR0_HI 0x98 |
60 | | -#define PT_FPR0_LO 0x9C |
61 | | -#define PT_FPR1_HI 0xA0 |
62 | | -#define PT_FPR1_LO 0xA4 |
63 | | -#define PT_FPR2_HI 0xA8 |
64 | | -#define PT_FPR2_LO 0xAC |
65 | | -#define PT_FPR3_HI 0xB0 |
66 | | -#define PT_FPR3_LO 0xB4 |
67 | | -#define PT_FPR4_HI 0xB8 |
68 | | -#define PT_FPR4_LO 0xBC |
69 | | -#define PT_FPR5_HI 0xC0 |
70 | | -#define PT_FPR5_LO 0xC4 |
71 | | -#define PT_FPR6_HI 0xC8 |
72 | | -#define PT_FPR6_LO 0xCC |
73 | | -#define PT_FPR7_HI 0xD0 |
74 | | -#define PT_FPR7_LO 0xD4 |
75 | | -#define PT_FPR8_HI 0xD8 |
76 | | -#define PT_FPR8_LO 0XDC |
77 | | -#define PT_FPR9_HI 0xE0 |
78 | | -#define PT_FPR9_LO 0xE4 |
79 | | -#define PT_FPR10_HI 0xE8 |
80 | | -#define PT_FPR10_LO 0xEC |
81 | | -#define PT_FPR11_HI 0xF0 |
82 | | -#define PT_FPR11_LO 0xF4 |
83 | | -#define PT_FPR12_HI 0xF8 |
84 | | -#define PT_FPR12_LO 0xFC |
85 | | -#define PT_FPR13_HI 0x100 |
86 | | -#define PT_FPR13_LO 0x104 |
87 | | -#define PT_FPR14_HI 0x108 |
88 | | -#define PT_FPR14_LO 0x10C |
89 | | -#define PT_FPR15_HI 0x110 |
90 | | -#define PT_FPR15_LO 0x114 |
91 | | -#define PT_CR_9 0x118 |
92 | | -#define PT_CR_10 0x11C |
93 | | -#define PT_CR_11 0x120 |
94 | | -#define PT_IEEE_IP 0x13C |
95 | | -#define PT_LASTOFF PT_IEEE_IP |
96 | | -#define PT_ENDREGS 0x140-1 |
97 | | - |
98 | | -#define GPR_SIZE 4 |
99 | | -#define CR_SIZE 4 |
100 | | - |
101 | | -#define STACK_FRAME_OVERHEAD 96 /* size of minimum stack frame */ |
102 | | - |
103 | | -#else /* __s390x__ */ |
104 | | - |
105 | 17 | #define PT_PSWMASK 0x00 |
106 | 18 | #define PT_PSWADDR 0x08 |
107 | 19 | #define PT_GPR0 0x10 |
|
166 | 78 |
|
167 | 79 | #define STACK_FRAME_OVERHEAD 160 /* size of minimum stack frame */ |
168 | 80 |
|
169 | | -#endif /* __s390x__ */ |
170 | | - |
171 | | -#ifndef __s390x__ |
172 | | - |
173 | | -#define PSW_MASK_PER _AC(0x40000000, UL) |
174 | | -#define PSW_MASK_DAT _AC(0x04000000, UL) |
175 | | -#define PSW_MASK_IO _AC(0x02000000, UL) |
176 | | -#define PSW_MASK_EXT _AC(0x01000000, UL) |
177 | | -#define PSW_MASK_KEY _AC(0x00F00000, UL) |
178 | | -#define PSW_MASK_BASE _AC(0x00080000, UL) /* always one */ |
179 | | -#define PSW_MASK_MCHECK _AC(0x00040000, UL) |
180 | | -#define PSW_MASK_WAIT _AC(0x00020000, UL) |
181 | | -#define PSW_MASK_PSTATE _AC(0x00010000, UL) |
182 | | -#define PSW_MASK_ASC _AC(0x0000C000, UL) |
183 | | -#define PSW_MASK_CC _AC(0x00003000, UL) |
184 | | -#define PSW_MASK_PM _AC(0x00000F00, UL) |
185 | | -#define PSW_MASK_RI _AC(0x00000000, UL) |
186 | | -#define PSW_MASK_EA _AC(0x00000000, UL) |
187 | | -#define PSW_MASK_BA _AC(0x00000000, UL) |
188 | | - |
189 | | -#define PSW_MASK_USER _AC(0x0000FF00, UL) |
190 | | - |
191 | | -#define PSW_ADDR_AMODE _AC(0x80000000, UL) |
192 | | -#define PSW_ADDR_INSN _AC(0x7FFFFFFF, UL) |
193 | | - |
194 | | -#define PSW_ASC_PRIMARY _AC(0x00000000, UL) |
195 | | -#define PSW_ASC_ACCREG _AC(0x00004000, UL) |
196 | | -#define PSW_ASC_SECONDARY _AC(0x00008000, UL) |
197 | | -#define PSW_ASC_HOME _AC(0x0000C000, UL) |
198 | | - |
199 | | -#else /* __s390x__ */ |
200 | | - |
201 | 81 | #define PSW_MASK_PER _AC(0x4000000000000000, UL) |
202 | 82 | #define PSW_MASK_DAT _AC(0x0400000000000000, UL) |
203 | 83 | #define PSW_MASK_IO _AC(0x0200000000000000, UL) |
|
224 | 104 | #define PSW_ASC_SECONDARY _AC(0x0000800000000000, UL) |
225 | 105 | #define PSW_ASC_HOME _AC(0x0000C00000000000, UL) |
226 | 106 |
|
227 | | -#endif /* __s390x__ */ |
228 | | - |
229 | 107 | #define NUM_GPRS 16 |
230 | 108 | #define NUM_FPRS 16 |
231 | 109 | #define NUM_CRS 16 |
@@ -308,9 +186,7 @@ typedef struct { |
308 | 186 | #define PER_EM_MASK 0xE8000000UL |
309 | 187 |
|
310 | 188 | typedef struct { |
311 | | -#ifdef __s390x__ |
312 | 189 | unsigned : 32; |
313 | | -#endif /* __s390x__ */ |
314 | 190 | unsigned em_branching : 1; |
315 | 191 | unsigned em_instruction_fetch : 1; |
316 | 192 | /* |
|
0 commit comments