| .. | .. |
|---|
| 7 | 7 | #ifndef _S390_PTRACE_H |
|---|
| 8 | 8 | #define _S390_PTRACE_H |
|---|
| 9 | 9 | |
|---|
| 10 | | -#include <linux/const.h> |
|---|
| 10 | +#include <linux/bits.h> |
|---|
| 11 | 11 | #include <uapi/asm/ptrace.h> |
|---|
| 12 | 12 | |
|---|
| 13 | 13 | #define PIF_SYSCALL 0 /* inside a system call */ |
|---|
| .. | .. |
|---|
| 15 | 15 | #define PIF_SYSCALL_RESTART 2 /* restart the current system call */ |
|---|
| 16 | 16 | #define PIF_GUEST_FAULT 3 /* indicates program check in sie64a */ |
|---|
| 17 | 17 | |
|---|
| 18 | | -#define _PIF_SYSCALL _BITUL(PIF_SYSCALL) |
|---|
| 19 | | -#define _PIF_PER_TRAP _BITUL(PIF_PER_TRAP) |
|---|
| 20 | | -#define _PIF_SYSCALL_RESTART _BITUL(PIF_SYSCALL_RESTART) |
|---|
| 21 | | -#define _PIF_GUEST_FAULT _BITUL(PIF_GUEST_FAULT) |
|---|
| 18 | +#define _PIF_SYSCALL BIT(PIF_SYSCALL) |
|---|
| 19 | +#define _PIF_PER_TRAP BIT(PIF_PER_TRAP) |
|---|
| 20 | +#define _PIF_SYSCALL_RESTART BIT(PIF_SYSCALL_RESTART) |
|---|
| 21 | +#define _PIF_GUEST_FAULT BIT(PIF_GUEST_FAULT) |
|---|
| 22 | 22 | |
|---|
| 23 | 23 | #ifndef __ASSEMBLY__ |
|---|
| 24 | 24 | |
|---|
| .. | .. |
|---|
| 184 | 184 | return regs->gprs[15]; |
|---|
| 185 | 185 | } |
|---|
| 186 | 186 | |
|---|
| 187 | +static inline void regs_set_return_value(struct pt_regs *regs, unsigned long rc) |
|---|
| 188 | +{ |
|---|
| 189 | + regs->gprs[2] = rc; |
|---|
| 190 | +} |
|---|
| 191 | + |
|---|
| 187 | 192 | #endif /* __ASSEMBLY__ */ |
|---|
| 188 | 193 | #endif /* _S390_PTRACE_H */ |
|---|