diff options
author | David S. Miller <davem@davemloft.net> | 2005-07-24 22:36:26 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2005-07-24 22:36:26 -0400 |
commit | db7d9a4eb700be766cc9f29241483dbb1e748832 (patch) | |
tree | 48848384df15d9404ceab05867d7f4ef6b1a4bbe /include/asm-sparc64/ptrace.h | |
parent | cdd5186f753b23ab51f86679bdc4cc698ab0b893 (diff) |
[SPARC64]: Move syscall success and newchild state out of thread flags.
These two bits were accesses non-atomically from assembler
code. So, in order to eliminate any potential races resulting
from that, move these pieces of state into two bytes elsewhere
in struct thread_info.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/asm-sparc64/ptrace.h')
-rw-r--r-- | include/asm-sparc64/ptrace.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/include/asm-sparc64/ptrace.h b/include/asm-sparc64/ptrace.h index 2d2b5a113d24..6194f771e9fc 100644 --- a/include/asm-sparc64/ptrace.h +++ b/include/asm-sparc64/ptrace.h | |||
@@ -94,8 +94,9 @@ struct sparc_trapf { | |||
94 | #define STACKFRAME32_SZ sizeof(struct sparc_stackf32) | 94 | #define STACKFRAME32_SZ sizeof(struct sparc_stackf32) |
95 | 95 | ||
96 | #ifdef __KERNEL__ | 96 | #ifdef __KERNEL__ |
97 | #define force_successful_syscall_return() \ | 97 | #define force_successful_syscall_return() \ |
98 | set_thread_flag(TIF_SYSCALL_SUCCESS) | 98 | do { current_thread_info()->syscall_noerror = 1; \ |
99 | } while (0) | ||
99 | #define user_mode(regs) (!((regs)->tstate & TSTATE_PRIV)) | 100 | #define user_mode(regs) (!((regs)->tstate & TSTATE_PRIV)) |
100 | #define instruction_pointer(regs) ((regs)->tpc) | 101 | #define instruction_pointer(regs) ((regs)->tpc) |
101 | #ifdef CONFIG_SMP | 102 | #ifdef CONFIG_SMP |